tag:blogger.com,1999:blog-29866791305045251232024-03-18T04:03:31.092+01:00Small Blender ThingsCustomizing Blender with Python and OSLMichelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.comBlogger334125tag:blogger.com,1999:blog-2986679130504525123.post-1216948983982789362024-01-25T17:13:00.004+01:002024-01-25T17:13:51.165+01:00Add-on to fit a cylinder to vertices<p>I previously <a href="https://blog.michelanders.nl/2024/01/planefitpy-and-linefitpy-updated-for.html">updated two small add-ons</a> that can fit a line or a plane to a collection of vertices and was asked if it was possible to create an add-on that fits a cylinder.</p><p>That is a bit more challenging though, but luckily there are people who spend some serious time on designing an algorithm and even providing code (see references below).</p><p>Based on that I created a small add-on that can indeed fit a cylinder to a collection of selected vertices. Note that it fits a cylinder where the vertices lie as closely as possible on the <i>surface</i> of the cylinder (see image). If you want to fit a cylinder that encloses all vertices, so more of a solid rod, simply use the linefit add-on and align a cylinder to the best fit line.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk-D9o3nENtzIhaHPdjEKMMITiNPA4-UzUexDnbvIEo6D3CCNlHAkGLyLky2oR99fBYY8Q00089qCfkL41eBlmSCx3LnKAZLR5rnwrRS0S2tAvdPWa29GXLTQ4YraifNiKhzP4plNfVA-rAT4PG3_Oj-TlsBML8Gm1apS098_vlPIGTyZJrXC1O5LEOmQ/s518/example.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="468" data-original-width="518" height="289" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgk-D9o3nENtzIhaHPdjEKMMITiNPA4-UzUexDnbvIEo6D3CCNlHAkGLyLky2oR99fBYY8Q00089qCfkL41eBlmSCx3LnKAZLR5rnwrRS0S2tAvdPWa29GXLTQ4YraifNiKhzP4plNfVA-rAT4PG3_Oj-TlsBML8Gm1apS098_vlPIGTyZJrXC1O5LEOmQ/s320/example.png" width="320" /></a></div><br /><h3 style="text-align: left;">Usage</h3><p>Simply download <b>cyclinderfit.zip</b> from the repo and install and enable the add-on from this zip-file.</p><p>Then select the mesh with the vertices you want to fit the cylinder to and select <b>Fit cylinder</b> from the <b>Add </b>menu (in edit mode). The new cylinder object will be added as a separate object that will be in edit mode.</p><h3 style="text-align: left;">Code availability</h3><p>The code is available in <a href="https://github.com/varkenvarken/cylinderfit" target="_blank">this GitHub repository.</a></p><h3 style="text-align: left;">References</h3><p>The cylinder fitting code was adapted from code in <a href="https://github.com/xingjiepan/cylinder_fitting" target="_blank">Xing Jiepan's repo</a>, which in turn was based on the algorithms described in <a href="https://www.geometrictools.com/Documentation/LeastSquaresFitting.pdf" target="_blank">this paper by David Eberly</a>.</p><p>To remove dependencies on external packages (except <b>numpy</b>, which is included with Blender), we replaced calls to the <b><a href="https://docs.scipy.org/doc/scipy/reference/generated/scipy.optimize.minimize.html" target="_blank">scikit.optimize.minimize</a></b> function with a different implementation of Powells' minimization function from the <a href="https://cxc.harvard.edu/sherpa/methods/fminpowell.py.txt" target="_blank">Sherpa code-base</a> of the Chandra project. </p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><p><br /></p><div><br /></div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-59464679228581234802024-01-19T11:03:00.000+01:002024-01-19T11:03:11.110+01:00Planefit.py and linefit.py updated for Blender 4.x<p>Always happy to see any of my add-ons being used, even if it's a really old one, so based on a <a href="https://blenderartists.org/t/fit-a-plane-through-selected-vertices/699954/8?u=varkenvarken" target="_blank">BlenderArtists request</a> I updated planefit.py and linefit.py.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4qbuz6mRNQtLy0tUVrl9ngNn-ID_KMN4QEWJIOUlSneM9D2d8lmbJB_BMSRkiAzOF2v2zYKbgr1Kbe0QE-pDnsNWTOnOvdm2ESkBFDmVjTa9jK7hq6P7S0VQ47ZR_XVJbu7ibV9IIWrq4V-1uKg9pmNIw3bwqppO4xmy96YUmNRmCkWbCo4hZkgQjbLg/s743/Screenshot_2017-12-11_16-09-18.png" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" data-original-height="579" data-original-width="743" height="156" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEg4qbuz6mRNQtLy0tUVrl9ngNn-ID_KMN4QEWJIOUlSneM9D2d8lmbJB_BMSRkiAzOF2v2zYKbgr1Kbe0QE-pDnsNWTOnOvdm2ESkBFDmVjTa9jK7hq6P7S0VQ47ZR_XVJbu7ibV9IIWrq4V-1uKg9pmNIw3bwqppO4xmy96YUmNRmCkWbCo4hZkgQjbLg/w200-h156/Screenshot_2017-12-11_16-09-18.png" width="200" /></a></div><br /><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXub-6-sv_ubAZgahDZPaRnBfWn4Yc8_qZ7pqtfsvwWfEpCZi7_baxp88_hbv1dJfsLXfnG1VK3U2sXrT1X9W7cFY_H_7WNdAtbhEgu93DTsTUUH2_fpT6gGzyeRMW-ZKLYDFu44wpzpjrXIdFrURoN41H8-hdeeG3DtpbtiE5n2ZiWyk-g7yJCU5kmEE/s741/linefit.png" style="clear: left; float: left; margin-bottom: 1em; margin-right: 1em;"><img border="0" data-original-height="259" data-original-width="741" height="70" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhXub-6-sv_ubAZgahDZPaRnBfWn4Yc8_qZ7pqtfsvwWfEpCZi7_baxp88_hbv1dJfsLXfnG1VK3U2sXrT1X9W7cFY_H_7WNdAtbhEgu93DTsTUUH2_fpT6gGzyeRMW-ZKLYDFu44wpzpjrXIdFrURoN41H8-hdeeG3DtpbtiE5n2ZiWyk-g7yJCU5kmEE/w200-h70/linefit.png" width="200" /></a></div><br /><p><br /></p><p><br /></p><p><b>Planefit</b> adds a plane (=face) to your mesh that fits any selected vertices as well as possible (details <a href="https://blog.michelanders.nl/2017/12/planefit-blender-add-on-to-fit-plane.html" target="_blank">in this post</a>), and <b>linefit</b> is similar and adds a line (=edge) (<a href="https://blog.michelanders.nl/2017/12/linefit-add-on.html" target="_blank">details here)</a>. The articles also explain the math involved a bit if you are interested.</p><p>The updated add-ons can be found on GitHub:</p><p></p><ul style="text-align: left;"><li>planefit.py<br /> <a href="https://github.com/varkenvarken/blenderaddons/blob/master/linefit.py" target="_blank">https://github.com/varkenvarken/blenderaddons/blob/master/linefit.py</a></li><li>linefit.py<br /> <a href="https://github.com/varkenvarken/blenderaddons/blob/master/planefit.py" target="_blank">https://github.com/varkenvarken/blenderaddons/blob/master/planefit.py</a></li></ul><p></p><p><br /></p><p>Both add-ons can be downloaded in the same manner: Near the top right of the linked pages is a download button; click it to save the .py file, then (re)install the add-on in the usual manner.</p>
<h3 style="text-align: left;">Technical details</h3>
<p>For any nerds out there: even though the commits seem large, that's mainly because I now use the <a href="https://black.readthedocs.io/en/stable/" target="_blank">Black formatter</a> in all my Python projects so lots of whitespace was changed 😁. The actual change to planefit.py was only 1 line (the current line 116): the <code>loop_total</code> property of a polygon is read only nowadays so we cannot (and need not) set it: It is automatically updated when we add the vertex indices.</p>
<p>The change to linefit.py was a bit more involved, mainly because it was even older: Properties in an Operator are now annotated class variables (and have been since version 2.8 I think), so we had to change line 53 from
</p><p>
<code>size = bpy.props.FloatProperty( ....</code>
</p><p>to
</p><p>
<code>size : bpy.props.FloatProperty(...</code>
</p><p>A small but necessary change that does not even give you a warning anymore, so something to look out for if you revisit very old add-ons.</p><p>Likewise, the function <code>bpy.utils.register_module()</code> doesn't exist anymore and had to be replaced by <code>bpy.utils.register_class()</code></p><p><br /></p><p></p><p></p><p></p><p></p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-51228857985706063462023-11-22T19:42:00.000+01:002023-11-22T19:42:26.620+01:00Blender Market Black Friday Cyber Sale<div class="separator" style="clear: both;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRwbHw2I7cSP0LjAr15dEKeCMdf6gT8VS9u_vAZ4rNG3ZrDl1CgjInxkn7FceEipvcgettoZ4AcjaCCGUhPuO6fWvXw6u3s4pihwzbNeqcal_-KE6TQNrzWntOZCm-DTWQKJhXQKUE514BSA2898ESmo5zA9bWqFymkqVc6kEFKtvT0JbXr__cKteDFms/s1200/fffdb7cd-e657-c4a3-22c9-ed364c354d37.png" style="display: block; padding: 1em 0px; text-align: center;"><img alt="" border="0" data-original-height="675" data-original-width="1200" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhRwbHw2I7cSP0LjAr15dEKeCMdf6gT8VS9u_vAZ4rNG3ZrDl1CgjInxkn7FceEipvcgettoZ4AcjaCCGUhPuO6fWvXw6u3s4pihwzbNeqcal_-KE6TQNrzWntOZCm-DTWQKJhXQKUE514BSA2898ESmo5zA9bWqFymkqVc6kEFKtvT0JbXr__cKteDFms/w400-h225/fffdb7cd-e657-c4a3-22c9-ed364c354d37.png" width="400" /></a></div><p> </p>
Of course BlenderMarket does Black Friday and my add-ons are in it too. Check
<a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket shop</a> if you were thinking about purchasing one. Whether you think it's all commercial bullshit or not, there are some nice discounts to be had Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-39667054419248184262023-11-06T13:07:00.001+01:002023-11-06T13:07:00.122+01:00WeightLifter add-on updated for Blender 4.0<div><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQbvRHoq6lYWxGUrD1w63hzPnJZ5mBg5sUAY3f6-CgpIT_6IhF81O0-2pTASXL82wBeuE_cexH1IcVLy_Tj9VdWm8F92uru3g1EnbJugv8l-WGObxxRiySsZdkPp05rl_E_zAa2dQl2fA/s1920/logo+close.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQbvRHoq6lYWxGUrD1w63hzPnJZ5mBg5sUAY3f6-CgpIT_6IhF81O0-2pTASXL82wBeuE_cexH1IcVLy_Tj9VdWm8F92uru3g1EnbJugv8l-WGObxxRiySsZdkPp05rl_E_zAa2dQl2fA/w400-h225/logo+close.png" width="400" />
</a>
</div>
</div>
<p><b>WeightLifter</b> has been been updated for 4.0 compatibility. It has been tested with the daily built of November 3rd and only minor modifications were needed to make it compatible. If you still encounter a bug, please let me know so that I can have a look at it.</p>
<p><b>WeightLifter</b> is <a href="https://blendermarket.com/products/weightlifter">available on BlenderMarket</a>. This update is free for customers who bought previous versions of WeightLifter.</p>
<p><b>WeightLifter</b> is an add-on that can calculate all sorts of information and store this into vertex groups or vertex color layers. It can for example determine the visibility of vertices for a certain camera or the distance to some light source and much, much more (the add-on comes with a 30 page fully illustrated manual), information that can for example be used as a density map in particle systems. You can even bake this information if your scene is animated. </p>
<h2>The future</h2>
<p>The code in the add-on is very old (9 years, which in Internet terms is ancient) and it does show its age in the way it is structured and also, as I experience myself, it is not very fast, especially on large meshes.</p>
<p>I was tempted to modernize it, and improve its speed if possible, but this might also be an opportunity to add features. So if you have an idea or suggestion, please drop me a note in the contact box at the top right of the page or via BlenderMarket and I'll be happy to consider it.</p>
Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-5790161223526234522023-11-04T12:33:00.000+01:002023-11-04T12:33:06.408+01:00IDMapper add-on ported to Blender 4.0<p> </p><p><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/s900/IDMapper%20900x600.png" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" data-original-height="600" data-original-width="900" height="266" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/w400-h266/IDMapper%20900x600.png" width="400" /></a></p><p><br /></p><p>I am pleased to announce that <b>IDMapper</b> is now available for Blender 4.0. </p><p>It has been tested against the daily of November 3rd, but I expect no changes will be needed for the 4.0 release candidate or the final release.</p><p>Blender 4.0 introduced quite a few breaking changes, so this version is not backwards compatible with 3.x</p><p>Although no new functionality was introduced in this release, please be aware of the following:</p><p></p><ul style="text-align: left;"><li>IDMapper can currently not work with facemaps, because they are no longer supported in 4.0. This may change in the future (hopefully, see <a href="https://projects.blender.org/blender/blender/issues/105317" target="_blank">this discussion</a>) and if possible I will try to get this back into IDMapper. Meanwhile, I did create a small, <a href="https://blog.michelanders.nl/2023/10/adding-selecting-from-face-maps-to-blender-4.0.html.html" target="_blank">free add-on</a> to make selecting faces from facemaps possible in 4.0 which may be useful in some workflows.</li><li>Color picking in Face Paint Mode (with the S-key) is no longer restricted to the 3d-View area, so colors can be picked from anywhere in the Blender application (although still not outside of it).</li></ul><p></p><div><b>IDMapper</b> simplifies creation and editing of vertex color layers that can be used as ID-maps in texturing software like Substance Painter or Quixel. It aims to reduce the time it takes to create an ID-map significantly, especially for complex hard surface models. It uses powerful heuristics to create an ID-map from scratch and lets you interactively adjust the results. It offers options to use existing information, like uv-seams, but can also intelligently assign the same color to similar mesh parts. </div><div><br /></div><div>The new version is available on <a href="https://blendermarket.com/products/idmapper">BlenderMarket</a>.</div><div><br /></div><div>This <a href="https://blog.michelanders.nl/2023/07/idmapper-ported-to-blender-36-lts.html">previous article</a> showcases some of IDMapper's functionality.</div><div><br /></div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-45025533403052379102023-11-04T10:43:00.003+01:002023-11-04T10:43:35.845+01:00Snap! add-on ported to Blender 4.0<p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji""><b>Snap!</b> has been updated to run on Blender 4.0.</span></p><p>It has been tested against the daily of November 3rd, but I expect no changes will be needed for the 4.0 release candidate or the final release.</p><p>Blender 4.0 introduced quite a few breaking changes, so this version is <u>not</u> backwards compatible with 3.x</p>
<p>For an introduction to Snap! <a href="https://blog.michelanders.nl/2021/09/Snap-A-new-add-on-to-simplify-working-with-modular-assets.html">see this article</a> and for the new functionality added in the April 2022 release, <a href="https://blog.michelanders.nl/2022/04/Snap-April-2022-release.html">see this article</a>. Both articles have links to demo videos as well.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/s1920/logo1920x1080.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/w400-h225/logo1920x1080.jpg" width="400" /></a></div><p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" style="background-color: white; color: #212529; font-size: 16px;"><br style="color: black; font-size: medium;" /></span></p><h3><br /></h3><p><b>Snap!</b> is a time saving tool for people who often work with modular assets packs or creators of asset packs who want to make there product easier to use.</p><p><b>Snap!</b> allows you to define snap-points with a predefined location and orientation on objects which can then be used to interactively snap objects together without the hassle of precise positioning.</p><p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" style="background-color: white; color: #212529; font-size: 16px;"></span></p><p><b>Snap!</b> is available in a personal and a redistributable version on <a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket shop</a>.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-90531018553691573792023-10-14T15:56:00.000+02:002023-10-14T15:56:37.797+02:00Adding selecting from face maps to Blender 4.0<p>Because it is <a href="https://projects.blender.org/blender/blender/issues/105317" rel="nofollow" target="_blank">currently not possible</a> to select faces based on the values in a face map, and because creating new face maps is cumbersome (First: Add attribute, select name, domain and type, then: Mesh -> Set attribute), I decided to create a tiny add-on that provides this functionality for the time being.</p><p>It is called <b>facemap_select.py</b> and can be downloaded from <a href="https://github.com/varkenvarken/blenderaddons" rel="" target="_blank">this GitHub repository</a> (or you can right click and <a href="https://raw.githubusercontent.com/varkenvarken/blenderaddons/master/facemap_select.py">this link</a> directly and select download.)</p><p>It is a bit rough-and-ready, but once downloaded, you can install and enable it in the usual way by selecting Edit -> Preferences -> Add-ons -> Install and then locating the file you downloaded. Don't forget the check the enable checkbox.</p><p>The add-on will add two options to the Select menu (in mesh edit mode):</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOdxkbhRhwo3In-xjetN9L-izBFJqJgBPwLRp_cEWHx_jI0EYaD1yH1EI17aWPWwP5HeDfoiw9khXJele9nfk8QkHF1eth7ku6GWvcUPdmU36F16sTtmNJHtOH1ma44Ul10UMtQgB6tW-nynuTEcelsFQ8civQQXO266QGoNZaLKFNQXvAX_vnbnKBXts/s491/Screenshot%202023-10-14%2015:40:23.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="491" data-original-width="170" height="320" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhOdxkbhRhwo3In-xjetN9L-izBFJqJgBPwLRp_cEWHx_jI0EYaD1yH1EI17aWPWwP5HeDfoiw9khXJele9nfk8QkHF1eth7ku6GWvcUPdmU36F16sTtmNJHtOH1ma44Ul10UMtQgB6tW-nynuTEcelsFQ8civQQXO266QGoNZaLKFNQXvAX_vnbnKBXts/w111-h320/Screenshot%202023-10-14%2015:40:23.png" width="111" /></a></div><br /><p><b>From facemap </b>will select faces based on the currently active face map, while <b>Create facemap</b> will create a new facemap and set its values to reflect the currently selected faces.</p><p><b>From facemap </b>will be grayed out if no suitable facemap is selected.</p><p>A created face map will have a name starting with 'Facemap' and will be in the FACE domain and have a boolean type.</p><p>Note: face maps are not typically called that in the Blender documentation but are custom attributes (to be found in the Object data properties of a mesh object in the Attributes panel:</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_JlFWhyphenhyphen4Tt8bKH3yULm3hQF6vdkrwaZsRrJ40fQxGMZlPWqzV9VuDp7gBe4UOjaPVOZmWRLWz0THSfTyD8-dqK_Vob1gYOjIM97LAaOdjnaSU5ARXe37fDUJ6UONEoR5l7VR4XSym4jxpzagNROU9O2Au1MU0_3ocYMMgXscaJapQFlE_omzh_D036yc/s586/Screenshot%202023-10-14%2015:48:31.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="181" data-original-width="586" height="99" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEj_JlFWhyphenhyphen4Tt8bKH3yULm3hQF6vdkrwaZsRrJ40fQxGMZlPWqzV9VuDp7gBe4UOjaPVOZmWRLWz0THSfTyD8-dqK_Vob1gYOjIM97LAaOdjnaSU5ARXe37fDUJ6UONEoR5l7VR4XSym4jxpzagNROU9O2Au1MU0_3ocYMMgXscaJapQFlE_omzh_D036yc/s320/Screenshot%202023-10-14%2015:48:31.png" width="320" /></a></div><p>There might be more and different kinds of attribute layers here as well, like a uv map, as shown in the image).</p><p>I don't think (hope?) this add-on will last forever, as I expect this missing bit of functionality to be added to Blender sometime in the future (or someone might take my code and incorporate it, that's fine too of course). In the mean time I hope this might help some people with multiple complex selections to switch easily between those.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-79061258320508092142023-09-17T15:13:00.001+02:002023-11-05T13:06:37.707+01:00Weightlifter updated for 3.6<h3>Celebrations! 🎉</h3>
<div>
<div class="separator" style="clear: both; text-align: center;">
<a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQbvRHoq6lYWxGUrD1w63hzPnJZ5mBg5sUAY3f6-CgpIT_6IhF81O0-2pTASXL82wBeuE_cexH1IcVLy_Tj9VdWm8F92uru3g1EnbJugv8l-WGObxxRiySsZdkPp05rl_E_zAa2dQl2fA/s1920/logo+close.png" style="margin-left: 1em; margin-right: 1em;">
<img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjQbvRHoq6lYWxGUrD1w63hzPnJZ5mBg5sUAY3f6-CgpIT_6IhF81O0-2pTASXL82wBeuE_cexH1IcVLy_Tj9VdWm8F92uru3g1EnbJugv8l-WGObxxRiySsZdkPp05rl_E_zAa2dQl2fA/w400-h225/logo+close.png" width="400" />
</a>
</div>
</div>
<p><b>WeightLifter</b> has been been updated for 3.6 LTS compatibility. It has been tested on Blender 3.6.2 and only minor modifications were needed to make it compatible. If you still encounter a bug, please let me know so that I can have a look at it.</p>
<p>The history of this add-on goes back more than 9 years(!) and this update forced me to reduce the font of the revision history section of the manual to make it fit on one page. 😊</p>
<p><b>WeightLifter</b> is <a href="https://blendermarket.com/products/weightlifter">available on BlenderMarket</a>. This update is free for customers who bought previous versions of WeightLifter.</p>
<p><b>WeightLifter</b> is an add-on that can calculate all sorts of information and store this into vertex groups or vertex color layers. It can for example determine the visibility of vertices for a certain camera or the distance to some light source and much, much more (the add-on comes with a 30 page fully illustrated manual), information that can for example be used as a density map in particle systems. You can even bake this information if your scene is animated. </p>
<h2>The future</h2>
<p>The code in the add-on is very old (9 years, which in Internet terms is ancient) and it does show its age in the way it is structured and also, as I experience myself, it is not very fast, especially on large meshes.</p>
<p>I was tempted to modernize it, and improve its speed if possible, but this might also be an opportunity to add features. So if you have an idea or suggestion, please drop me a note in the contact box at the top right of the page or via BlenderMarket and I'll be happy to consider it.</p>
Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-87718185239518087312023-08-20T18:54:00.001+02:002023-08-20T18:54:00.131+02:00Blender Market Summer Sale<p> <a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></p><div><br /></div>A summer sale is on at <a href="https://blendermarket.com/">BlenderMarket</a> ! They are having a sale from <span face="Slack-Lato, Slack-Fractions, appleLogo, sans-serif" style="background-color: #f8f8f8; color: #1d1c1d; font-size: 15px; font-variant-ligatures: common-ligatures;">August 21 - August 27.</span><div><span face="Slack-Lato, Slack-Fractions, appleLogo, sans-serif" style="color: #1d1c1d;"><span style="font-size: 15px; font-variant-ligatures: common-ligatures;"><br /></span></span>This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too, including <a href="https://blendermarket.com/products/snap">Snap!</a><br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-35874818946984314552023-07-23T15:44:00.000+02:002023-07-23T15:44:03.383+02:00IDMapper ported to Blender 3.6 LTS<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/s900/IDMapper%20900x600.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="600" data-original-width="900" height="213" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/s320/IDMapper%20900x600.png" width="320" /></a></div><h2>IDMapper has been ported to Blender 3.6 LTS</h2><p>I am happy to announce that I have updated IDMapper to work with Blender 3.6.</p><p>It sports a few bug-fixes and internal changes to work with the newer Blender versions, and also has two bits of new functionality:</p><p></p><ul style="text-align: left;"><li>you can change the color of the help text shown in face paint mode, to better adapt it to your theme (in the add-on preferences), and</li><li>the IDMapper operator is now applied to all selected objects, instead of just to the active object. This ensures that assigned colors are unique across those objects. If you prefer the old behavior you can select that in the add-on preferences</li></ul><p></p><p></p>
<div>I have also created a new demo video that shows the basic workflow when using the add-on in Blender 3.6</div><div class="separator" style="clear: both; text-align: center;"><iframe allowfullscreen="" class="BLOG_video_class" height="266" src="https://www.youtube.com/embed/NV4K4ZFeFKI" width="506" youtube-src-id="NV4K4ZFeFKI"></iframe></div><br /><div><br /></div><div><b><br /></b></div><div><b>IDMapper</b> simplifies creation and editing of vertex color layers that can be used as ID-maps in texturing software like Substance Painter or Quixel.
It aims to reduce the time it takes to create an ID-map significantly, especially for complex hard surface models.
It uses powerful heuristics to create an ID-map from scratch and lets you interactively adjust the results. It offers options to use existing information, like uv-seams, but can also intelligently assign the same color to similar mesh parts. </div><div><br /></div><div>The new version is available on <a href="https://blendermarket.com/products/idmapper">BlenderMarket</a>.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-30485681442037394892023-07-21T18:54:00.004+02:002023-07-21T18:54:54.811+02:00Prometheus metrics for Blender: Demo video<iframe allowfullscreen="" class="BLOG_video_class" height="343" src="https://www.youtube.com/embed/Pfl5NTtCIHU" width="541" youtube-src-id="Pfl5NTtCIHU"></iframe><div><br /></div><div>In the video I showcase the add-on presented in the previous two blog posts (<a href="https://blog.michelanders.nl/2023/07/prometheus-metrics-for-blender.html">1</a>, <a href="https://blog.michelanders.nl/2023/07/prometheus-metrics-for-blender-new-repo.html">2</a>) and show how to install and configure it.</div><div><br /></div><div>The video is a bit too detailed perhaps for something that is basically a simple install and doesn't go into detail on how to install <a href="https://prometheus.io/">Prometheus</a> or <a href="https://grafana.com/">Grafana</a> itself, but I was learning to use <a href="https://obsproject.com/">OBS</a> and wanted to try some stuff out, so I decided to have some fun with it 😀</div><div><br /></div><div>If you have questions or suggestions, consider opening an issue in <a href="https://github.com/varkenvarken/blender-prometheus">the GitHub repository</a>.</div><div><br /></div><div><br /></div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-91879948325989358742023-07-10T12:01:00.007+02:002023-07-10T17:52:13.840+02:00Prometheus metrics for Blender: New repo<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguKNmyTMJCLnB4a1hU8aKSejabBy05UaiAIRZlzuI6kj1cGKld4T_kQ15g_l6eWZGmlF79Q-GwRzIgQTahJ2J5GCBcXpFm0Hr_DgkAcW1Ku1No944LNmgf44FKSnAPf3fan2L5C6uL3L2CFZlD8VPOOO0XgKgmFnS0FXzLlwCIlHisrsDZBSl0-Lgw5kE/s242/Prometheus_software_logo.svg.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="240" data-original-width="242" height="240" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguKNmyTMJCLnB4a1hU8aKSejabBy05UaiAIRZlzuI6kj1cGKld4T_kQ15g_l6eWZGmlF79Q-GwRzIgQTahJ2J5GCBcXpFm0Hr_DgkAcW1Ku1No944LNmgf44FKSnAPf3fan2L5C6uL3L2CFZlD8VPOOO0XgKgmFnS0FXzLlwCIlHisrsDZBSl0-Lgw5kE/s1600/Prometheus_software_logo.svg.png" width="242" /></a></div><br />
<p>The add-on introduced in <a href="https://blog.michelanders.nl/2023/07/prometheus-metrics-for-blender.html">the previous post</a> has moved to its own <a href="https://github.com/varkenvarken/blender-prometheus">repository</a></p>
<p>That repository also includes installation and build instructions<br />
We moved it to its own repo to facilitate rapid development and also because that way we can easily incorporate the prometheus client library as a git submodule.</p>
<h2>Donations welcome</h2>
<p>You are more than welcome to use this add-on: It is completely free and open source.
<br />
But if you would like to show your appreciation and you can afford it, consider following the sponsor button at the top of the repo, or directly via this
<a href="https://paypal.me/varkenvarken?country.x=NL&locale.x=nl_NL">Paypal link</a>.
Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-15506906418678520622023-07-09T17:17:00.000+02:002023-07-09T17:17:25.662+02:00Prometheus metrics for Blender<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguKNmyTMJCLnB4a1hU8aKSejabBy05UaiAIRZlzuI6kj1cGKld4T_kQ15g_l6eWZGmlF79Q-GwRzIgQTahJ2J5GCBcXpFm0Hr_DgkAcW1Ku1No944LNmgf44FKSnAPf3fan2L5C6uL3L2CFZlD8VPOOO0XgKgmFnS0FXzLlwCIlHisrsDZBSl0-Lgw5kE/s242/Prometheus_software_logo.svg.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="240" data-original-width="242" height="240" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEguKNmyTMJCLnB4a1hU8aKSejabBy05UaiAIRZlzuI6kj1cGKld4T_kQ15g_l6eWZGmlF79Q-GwRzIgQTahJ2J5GCBcXpFm0Hr_DgkAcW1Ku1No944LNmgf44FKSnAPf3fan2L5C6uL3L2CFZlD8VPOOO0XgKgmFnS0FXzLlwCIlHisrsDZBSl0-Lgw5kE/s1600/Prometheus_software_logo.svg.png" width="242" /></a></div><br /><p><br /></p><p>Exposes <a href="https://prometheus.io/">Prometheus</a> metrics on port 8000 when enabled.</p>
<p>In particular, it exposes a <a href="https://prometheus.io/docs/concepts/metric_types/#gauge">Gauge</a>, <em>Blender_Render</em>, that is 1 when the Blender instance is rendering, and 0 when it is not. The standard metrics, like cpu usage are also exposed.</p>
<h2 id="building-the-add-on">Building the add-on</h2>
<p>Currently we use an embedded and slightly modified version of the <a href="https://github.com/prometheus/client_python/tree/master">prometheus_client</a> for Python, which is in the <a href="prometheus_client/"></a> subdirectory. That is not ideal and might change once I have figured out how to monkey path the server instead of hacking the source, but i don´t like to depend on external Python packages because that makes it difficult to distribute and add-on.
Copying is also very far from ideal, so a git sub-repository is probably the way to go.</p>
<pre><code class="language-bash">
git <span class="hljs-built_in">clone</span> https://github.com/varkenvarken/blenderaddons.git
<span class="hljs-built_in">cd</span> blenderaddons
zip -urv prometheus.zip prometheus
</code></pre>
<p>Then install <code>prometheus.zip</code> in the usual way and enable the add-on.</p>
<p>You can inspect the published metrics on <a href="http://localhost:8000">http://localhost:8000</a>.</p>
<p>Scraping this with a <a href="https://hub.docker.com/r/prom/prometheus">Prometheus container</a> and creating a <a href="https://hub.docker.com/r/grafana/grafana">Grafana</a> dashboard is something you'll have to figure out yourself.</p>
<h2 id="source-code">Source code</h2>
<p>Available on <a href="https://github.com/varkenvarken/blenderaddons/tree/master/prometheus">Github</a>.</p>
<p>The code is extremely simple: when the add-on is enabled we create a Gauge metric and start the prometheus http server. We then register a <a href="https://docs.blender.org/api/latest/bpy.app.timers.html#bpy.app.timers.register">Blender timer</a> that checks every 10 seconds if we are rendering or not with the <a href="https://docs.blender.org/api/latest/bpy.app.html#bpy.app.is_job_running">is_app_running()</a> function and sets the Gauge accordingly.</p>
<p>The timer is made persistent, so it will keep running even if we load another .blend file.
The Prometheus server is running in a separate (daemon) thread and will only end if we exit Blender or if we invoke our custom <code>stop_http_server()</code> function, and that's where the ugly hack comes in: the <code>start_http-server()</code> function does not return the server it creates, so w e have no way to call its <code>shutdown()</code> function (which is present, because it is a subclass of <a href="https://docs.python.org/3.11/library/http.server.html">http.server</a>) or call <code>close()</code> on the socket it is listening on, and this would prevent us from disabling and then enabling the add-on again, because we would get an address in use exception.</p>
<p>Same goes for the Gauge: If we want o be able to reenable the add-on we have to make sure to remove it from the registry in the <code>unregister()</code> function.</p>
<pre language="js" name="code">import bpy # type: ignore
from .prometheus_client import Gauge, start_http_server, stop_http_server, REGISTRY
def every_10_seconds():
global g
r = bpy.app.is_job_running("RENDER")
if r:
g.set(1.0)
else:
g.set(0.0)
return 10.0
def register():
global g
g = Gauge("Blender_Render", "Rendering processes")
start_http_server(8000)
bpy.app.timers.register(every_10_seconds, persistent=True)
def unregister():
global g
bpy.app.timers.unregister(every_10_seconds)
REGISTRY.unregister(g)
stop_http_server()
</pre>
Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-41334579613716680032022-11-24T16:00:00.004+01:002022-11-24T16:00:00.210+01:00BlenderMarket Black Friday / Cyber Monday Sale<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></div><div><br /></div>That whole Black Friday / Cyber Monday thing could be considered the pinnacle of consumerism, but why deny yourself a nice discount if you planned on purchasing something from <a href="https://blendermarket.com/">BlenderMarket</a> ? They are having a sale from Friday, November 25th 12:01am - Monday, November 28th 11:59pm CST<br />This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too!<br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-3132850577049412072022-10-27T09:47:00.000+02:002022-10-27T09:47:40.029+02:00Blender Market Fall Sale<p> <a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></p><div><br /></div>To celebrate the Blender Conference there is a sale on at <a href="https://blendermarket.com/">BlenderMarket</a> ! The sale runs from Thursday 27 October - Sunday 30 October. <div><span face="Slack-Lato, Slack-Fractions, appleLogo, sans-serif" style="color: #1d1c1d;"><span style="font-size: 15px; font-variant-ligatures: common-ligatures;"><br /></span></span>This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too, including <a href="https://blendermarket.com/products/snap">Snap!</a><br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-16648633282548231812022-10-14T09:59:00.002+02:002022-10-14T09:59:35.077+02:00<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnRG8DK8enwGHsGBl1KfV899ONAbdvyyw-_hl1AaD7GtglwE7mXF7DO908X1mAQuXvG3OwvX-A964Ta65PzFntCUTO97Aj1ODcHxlA2ReauVoTRsah0t02kqeQMjrNAOQnCVWRjJf1oX8bZeMGeh_tEGAiHb8kn1x72nTmoxBbgsUe6vilAJgbkOjn/s2508/LogoB+motto4096x2048.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1254" data-original-width="2508" height="200" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjnRG8DK8enwGHsGBl1KfV899ONAbdvyyw-_hl1AaD7GtglwE7mXF7DO908X1mAQuXvG3OwvX-A964Ta65PzFntCUTO97Aj1ODcHxlA2ReauVoTRsah0t02kqeQMjrNAOQnCVWRjJf1oX8bZeMGeh_tEGAiHb8kn1x72nTmoxBbgsUe6vilAJgbkOjn/w400-h200/LogoB+motto4096x2048.png" width="400" /></a></div><br /><p><br /></p><p>I am pleased to announce that <b>NodeSet Pro</b> has been tested on <b>Blender 3.3 LTS</b> and is available from <a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket store</a>.</p><p><b>NodeSet Pro</b> is an add-on that greatly simplifies the process of importing sets of textures to create a node based material.</p><p>It allows you import a set of related texture maps by simply pointing to one of them, takes care of setting the color data attribute correctly, adds bump nodes and normal map nodes where needed and wires up everything to the principled shader or a shader node group you have defined, all with a few simple clicks.</p><p>Instead of importing textures like basecolor, normalmap, roughness, etc. one by one, with <b>NodeSet Pro</b> you will only need to select a single texture and textures with the same base name will be loaded as well. <b>NodeSet Pro</b> will also apply non-color data options to texture maps that need this, create normal map and bump nodes and wire everything up to a shader.</p><p>Besides individual texture sets <b>NodeSet Pro</b> also offers panels that let you manage collections of textures sets in a straight forward manner.</p><p><b>NodeSet Pro</b> works out of the box with substance painter textures but every aspect of it can be configured in the preferences to seamlessly adapt to your workflow and these preferences can be saved as presets.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-51006045689084138802022-09-24T12:24:00.000+02:002022-09-24T12:24:13.824+02:00Snap! September 2022 bugfix release<p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" >Snap! has been updated to fix an annoying bug that might occur when you would try to flip an object that only shared extra points with other objects.</span></p><p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" >Snap! was also tested on Blender 3.3.</span></p>
<p>For an introduction to Snap! <a href="https://blog.michelanders.nl/2021/09/Snap-A-new-add-on-to-simplify-working-with-modular-assets.html">see this article</a> and for the new functionality added in the April 2022 release, <a href="https://blog.michelanders.nl/2022/04/Snap-April-2022-release.html">see this article</a>. Both articles have links to demo videos as well.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/s1920/logo1920x1080.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/w400-h225/logo1920x1080.jpg" width="400" /></a></div><p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" style="background-color: white; color: #212529; font-size: 16px;"><br style="color: black; font-size: medium;" /></span></p><h3><br /></h3><p><b>Snap!</b> is a time saving tool for people who often work with modular assets packs or creators of asset packs who want to make there product easier to use.</p><p><b>Snap!</b> allows you to define snap-points with a predefined location and orientation on objects which can then be used to interactively snap objects together without the hassle of precise positioning.</p><p><span face="-apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", "Noto Color Emoji"" style="background-color: white; color: #212529; font-size: 16px;"></span></p><p><b>Snap!</b> is available in a personal and a redistributable version on <a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket shop</a>.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-24953919957735475842022-08-02T13:05:00.001+02:002022-08-02T13:05:00.215+02:00Blendermarket Summer Sale<p> <a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></p><div><br /></div>A summer sale is on at <a href="https://blendermarket.com/">BlenderMarket</a> ! They are having a sale from <span face="Slack-Lato, Slack-Fractions, appleLogo, sans-serif" style="background-color: #f8f8f8; color: #1d1c1d; font-size: 15px; font-variant-ligatures: common-ligatures;">August 3 - August 8.</span><div><span face="Slack-Lato, Slack-Fractions, appleLogo, sans-serif" style="color: #1d1c1d;"><span style="font-size: 15px; font-variant-ligatures: common-ligatures;"><br /></span></span>This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too, including <a href="https://blendermarket.com/products/snap">Snap!</a><br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-11119724893221513692022-07-31T16:50:00.003+02:002022-07-31T16:50:59.193+02:00IDMapper ported to Blender 3.3 beta<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/s900/IDMapper%20900x600.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="600" data-original-width="900" height="213" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgSz8Lc_7SZAicWya44rrPg_ZnPDUaYTJkOJB0g_3W1PPJ07WkwhIqLaovhicKgq37E1L9lnMySU8vjLaVjEBb7tjXBL9CPpXmZx7Pj9cCjMv84pq-I0uLy0wWlCkkygFj3MQ_Vv2xXPpEOcG_JPR6lYrOYOUE9qdKN5wanqKevczep2cYrmTCZBRMt/s320/IDMapper%20900x600.png" width="320" /></a></div><h2>IDMapper has been ported to Blender 3.3 beta</h2><p>That may sound a bit premature, but I am confident no changes will be needed for the official release of Blender 3.3. However, if necessary we update the add-on again of course.</p><p>Note that this version will <span style="box-sizing: border-box; font-weight: bolder;">not</span> run on older versions of Blender.</p> <p></p>
<div><b>IDMapper</b> simplifies creation and editing of vertex color layers that can be used as ID-maps in texturing software like Substance Painter or Quixel.
It aims to reduce the time it takes to create an ID-map significantly, especially for complex hard surface models.
It uses powerful heuristics to create an ID-map from scratch and lets you interactively adjust the results. It offers options to use existing information, like uv-seams, but can also intelligently assign the same color to similar mesh parts. </div><div><br /></div><div>The new version is available on <a href="https://blendermarket.com/products/idmapper">BlenderMarket</a>.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-89590268318061744462022-07-06T13:20:00.005+02:002022-07-06T13:20:16.866+02:00Snap! July 2022 release<p>The release of 3 July 2022 adds no new functionality but does fix a number of small bugs. This release is also tested on Blender 3.2.</p><p>For an introduction to Snap! <a href="https://blog.michelanders.nl/2021/09/Snap-A-new-add-on-to-simplify-working-with-modular-assets.html">see this article</a> and for the new functionality added in the April 2022 release, <a href="https://blog.michelanders.nl/2022/04/Snap-April-2022-release.html">see this article</a>. Both articles have links to demo videos as well.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/s1920/logo1920x1080.jpg" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/w400-h225/logo1920x1080.jpg" width="400" /></a></div><br /><h3><br /></h3><p><b>Snap!</b> is a time saving tool for people who often work with modular assets packs or creators of asset packs who want to make there product easier to use.</p><p><b>Snap!</b> allows you to define snap-points with a predefined location and orientation on objects which can then be used to interactively snap objects together without the hassle of precise positioning.</p><p><b>Snap!</b> is available in a personal and a redistributable version on <a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket shop</a>.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-35453574688174996872022-04-12T20:00:00.005+02:002022-04-12T20:00:00.242+02:00<p> <a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em; text-align: center;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></p><div><br /></div>Spring sale is on at <a href="https://blendermarket.com/">BlenderMarket</a> ! They are having a sale from <span style="background-color: #f8f8f8; color: #1d1c1d; font-family: Slack-Lato, Slack-Fractions, appleLogo, sans-serif; font-size: 15px; font-variant-ligatures: common-ligatures;">April 13 until April 18.</span><div><span style="color: #1d1c1d; font-family: Slack-Lato, Slack-Fractions, appleLogo, sans-serif;"><span style="font-size: 15px; font-variant-ligatures: common-ligatures;"><br /></span></span>This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too, including <a href="https://blendermarket.com/products/snap">Snap!</a><br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.</div>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-69116738303860513612022-04-01T19:00:00.002+02:002022-07-06T13:12:28.763+02:00Snap! April 2022 release<p>The release of 2 April 2022 adds new functionality to snap based on matching tags and allows for an unlimited number of snap-points. (For an introduction to Snap! <a href="https://blog.michelanders.nl/2021/09/Snap-A-new-add-on-to-simplify-working-with-modular-assets.html">see this article</a>).</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/s1920/logo1920x1080.jpg" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="225" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEjM_pIVre2Pm_pD0g_N75XgYCjgJR_ZyszF9Nm6m4FDm77VU-Xkl7EE9E2kLfmNulREBqUK-w5JnOK2gzvluGuIngLUryd9ghQ_8xmrvE9xQf32mcR8T8E_9HJJiANLebgL0uJYsNu_bf_eTw2Pkthd-oO1FDu85jAJxRTfXk3PZr8ZvcDf0xVvtLvZ/w400-h225/logo1920x1080.jpg" width="400" /></a></div><br /><h3><br /></h3><h3>Extra snap-points</h3><p>Snap! is no longer limited to just four snap-points. In the new <i>Extra point definitions</i> panel you can now add as many points as you like.These extra points are in their own panel for backwards compatibility, but behave in the exact same way as the other points.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhIkCsI2FzHb4OMsKZwEK8dq8kiPDDGPy9mA4MjD6vtBj_ISqHYX8uGVqe7p9Sl8zzZW3mCnatlAfV8nju8IaWsMsxWkj2YER0zf0R-LQNODISQPvW6frTr_cImdkgddLn6stMA6r9ri72_Q_Z0LNQWZw7-YAhypxrwSK5CvIqbr6J2EFPtT5gzgCJ8/s374/Extra%20point%20definitions%20panel.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="297" data-original-width="374" height="254" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhIkCsI2FzHb4OMsKZwEK8dq8kiPDDGPy9mA4MjD6vtBj_ISqHYX8uGVqe7p9Sl8zzZW3mCnatlAfV8nju8IaWsMsxWkj2YER0zf0R-LQNODISQPvW6frTr_cImdkgddLn6stMA6r9ri72_Q_Z0LNQWZw7-YAhypxrwSK5CvIqbr6J2EFPtT5gzgCJ8/w320-h254/Extra%20point%20definitions%20panel.png" width="320" /></a></div><br /><p>You can even filter and sort them based on their labels if you have many of them. </p><h3 style="text-align: left;">Tag based snapping</h3><p>Sometimes you don't want that each snap-point can snap to any snap-point on another object. You can now limit the possible connections by assigning <i>tags</i> and <i>accept tags</i> to a snap-point. If the <i>match tags</i> option is set, point will only snap if the have a tag that will match the accept tag of the other snap-point.</p><h3 style="text-align: left;">Snap 3d Cursor to snap-point</h3><p>Sometimes it is helpful to be able to move the 3d-cursor to the exact location of a snap-point. There is now an operator/button provided for this.</p><h3 style="text-align: left;">Auto parenting</h3><p>Normally when you snap an object to another object, it is moved into position and oriented, but nothing else. The objects are not connected in any way, so after the snap you can move them around freely.</p><p>With the new auto parenting option however, a point that is snapped in place is also parented to the target object, so will then move with the target after it is snapped in place.</p><h3 style="text-align: left;">Select neighbors</h3><p>Is a small feature that allows you to select any objects that share an overlapping snap-point.</p><p>A playlist with (among other things) a video demonstrating the new features is available as well</p><p><br />
<iframe width="560" height="315" src="https://www.youtube.com/embed/videoseries?controls=0&list=PLxyAbGpHucHZpoPBYVe8u2xWwIHP8p3yu" title="YouTube video player" frameborder="0" allow="accelerometer; autoplay; clipboard-write; encrypted-media; gyroscope; picture-in-picture" allowfullscreen></iframe>
</p><p><b>Snap!</b> is a time saving tool for people who often work with modular assets packs or creators of asset packs who want to make there product easier to use.</p><p><b>Snap!</b> allows you to define snap-points with a predefined location and orientation on objects which can then be used to interactively snap objects together without the hassle of precise positioning.</p><p><b>Snap!</b> is available in a personal and a redistributable version on <a href="https://blendermarket.com/creators/varkenvarken">my BlenderMarket shop</a>.</p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-77201912035059314832021-11-24T20:00:00.002+01:002021-11-24T20:00:00.181+01:00BlenderMarket Black friday / Cyber Monday 2021<div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s116/Sale.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="52" data-original-width="116" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEhwXWGY5p2Uyd41OTAGR7nCufLTF-udc9usj-Fe1LmA-8TkzGcWpUBfrdEPMz_DX05OiMA_qIiH2aWAAWEzX3UnsBcesvsOuhIz_TAlPOOQbtIs8YePT4CfAFQpaZpMvGLfbACavSk5XOs/s0/Sale.png" /></a></div><div><br /></div>That whole Black Friday / Cyber Monday thing could be considered the pinnacle of consumerism, but why deny yourself a nice discount if you planned on purchasing something from <a href="https://blendermarket.com/">BlenderMarket</a> ? They are having a sale from Friday, November 26th 12:00am - Monday, November 29th 11:59pm CST<br />This means serious discounts on participating products and of course <a href="https://blendermarket.com/creators/varkenvarken">my add-ons are on sale</a> too!<br /><br />Check out <a href="https://blendermarket.com/">BlenderMarket</a> to see if that special product on your wish list now has an 'on sale' label.Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-15934785966719376862021-10-24T15:08:00.004+02:002021-10-24T15:08:53.730+02:00Ortho updated to Blender 2.93 LTS<p>A bit overdue perhaps, but I have just made a version of <b>Ortho</b> available that is tested against Blender 2.93 LTS.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpyMef-AoR6drIjUAcO2zym7VzzGhoQ_-hhmYgSRLJeH1W2ljwbDVjlTZc3-YivUZLtZUBIPVhyvZc5if2nbzQt28jolMJ8Bb1Pfpy9WctEAlbcHpcsxLx-rlZP5eoS39PbM2cb82zBII/s1920/Ortho+Availlable+on+Blender+Market.png" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="1080" data-original-width="1920" height="288" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEgpyMef-AoR6drIjUAcO2zym7VzzGhoQ_-hhmYgSRLJeH1W2ljwbDVjlTZc3-YivUZLtZUBIPVhyvZc5if2nbzQt28jolMJ8Bb1Pfpy9WctEAlbcHpcsxLx-rlZP5eoS39PbM2cb82zBII/w512-h288/Ortho+Availlable+on+Blender+Market.png" width="512" /></a></div><div class="separator" style="clear: both; text-align: center;"><b style="text-align: left;"><br /></b></div><div class="separator" style="clear: both; text-align: center;"><br /></div><div class="separator" style="clear: both; text-align: center;"><p style="text-align: left;"><b>Ortho</b> offers a collection of tools that allows you to move, rotate, scale, snap and align selections of a mesh relative to a user-defined reference plane. Working relative to a reference plane can greatly simplify the positioning of mesh parts and can help clean up distorted meshes. Blender already offers several tools to transform and snap mesh parts but they work in the context of predefined coordinates, which makes it difficult to position or align mesh parts in meshes that are transformed with respect to their local coordinates or in situations where orthogonal coordinates are not sufficient, for example when positioning a window inside a slanted roof.</p><p style="text-align: left;"><b>Ortho</b> offers a simple and interactive way to define a plane that fits a selection of vertices in a mesh and offers a set of tools that operate with respect to this reference plane. You can for example align and snap a selection to the reference plane or move this selection along its normal or its surface. Scaling is also an option, offering ways to rectify slightly distorted meshes even in situations where such a distorted plane is not aligned with any axis and scaling along individual normals with Alt-S gives strange results.</p><h2 style="text-align: left;">Availability</h2><div style="text-align: left;"><b>Ortho</b> is available from <a href="https://blendermarket.com/creators/varkenvarken">my Blender Market store</a>.</div></div><p></p>Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0tag:blogger.com,1999:blog-2986679130504525123.post-63685537524117534552021-10-09T13:41:00.000+02:002021-10-09T13:41:00.873+02:00Units in Blender add-ons<p>It might not be immediately obvious how to make Blender to show units along with the properties you define in your add-ons, but fortunately it is not all that difficult.</p><p>There are two aspects to the display of units, representation and definition.</p><h3 style="text-align: left;">Representation</h3><p>This determines how property values are displayed and is something that is is controlled by the end user.</p><p>It is configured in the Scene properties, specifically in the Units panel.</p><div class="separator" style="clear: both; text-align: center;"><a href="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigRY3bhXmk_BubxwC3DI7KibPOqq8rQQJrUN7oxkse5jcLn_7Djp2m8YDhAKlrHHuiQkB3zBhsj6qSdH8ZeSrdm4E9NbvMDNirjsjBK9piH8fT4FnwaF-6bPfS7dJI04wXtsFUW-rBPcQ/s398/SceneUnits.png" imageanchor="1" style="margin-left: 1em; margin-right: 1em;"><img border="0" data-original-height="389" data-original-width="398" height="313" src="https://blogger.googleusercontent.com/img/b/R29vZ2xl/AVvXsEigRY3bhXmk_BubxwC3DI7KibPOqq8rQQJrUN7oxkse5jcLn_7Djp2m8YDhAKlrHHuiQkB3zBhsj6qSdH8ZeSrdm4E9NbvMDNirjsjBK9piH8fT4FnwaF-6bPfS7dJI04wXtsFUW-rBPcQ/s320/SceneUnits.png" width="320" /></a></div><br /><p><br /></p><p>The main choice here is between Metric and Imperial, but you can also choose specific units for certain quantities, for example, you might prefer Celsius instead of Kelvin.</p><p>The <b>Unit Scale</b> property is convenient if you are working to scale. I work with model trains in the H0 scale and sometimes make visualizations in Blender. Then I set the unit scale to 87 (because H0 is 1:87 scale) and then building dimensions etc. will show up with their real world dimensions. </p><h3 style="text-align: left;">Definition</h3><p>This determines what kind of quantity we are talking about.</p><p>This is something you configure in you property definitions. For a <a href="https://docs.blender.org/api/current/bpy.props.html?highlight=floatproperty#bpy.props.FloatProperty" target="_blank">FloatProperty</a> for example, you have <b>subtype</b> and <b>unit</b> parameters. If you leave unit at NONE, Blender will not show any units!</p><p>Let's say you want to define add a property called floorarea to your add-on, you might want to configure it like this:</p>
<pre name="code"> floorarea = FloatProperty(
<span> </span>name='Floor area',
<span> </span>subtype='DISTANCE',
<span> </span>unit='AREA')
</pre>
<p>So the <b>subtype</b> defines what quantity we're dealing with, and DISTANCE is used for anything that can be expressed as a length (or in the case of an area, length squared). Some other options for subtype are ANGLE and TIME.</p><p>The subtype determines the widget that is used too, which is especially important for properties that are lists of things, like a <a href="https://docs.blender.org/api/current/bpy.props.html?highlight=floatproperty#bpy.props.FloatVectorProperty" target="_blank">FloatVectorProperty</a>, that shows a color picker when the subtype is COLOR and other widgets when the subtype is for example a DIRECTION.</p><p>Each type of property has its own set of possible subtypes and units.</p><p>The <b>unit</b> parameter defines the actual unit to use. For example, for a DISTANCE subtype you could use LENGTH, AREA or VOLUME. For an AREA the value of the property would be displayed as m² or ft², depending on the Unit System selected in the Scene properties.</p>
Michelhttp://www.blogger.com/profile/07415131908018321030noreply@blogger.com0