Superhive Cybersale 2026

 


Ambivalence all over again: Five days of rampant consumerism or just a way to get a good deal? 🤔

It all up to you of course, so have a peek if you already had something in mind and see if there is something for you on offer. All my items participate too, so maybe if you were thinking about purchasing one of them, you may have a look at my store, or just head over to all the nice things on offer.


Onlyfans for Blender

I created an add-on for Blender to generate a desktop fan from scratch. It's even animated: The blades spin and the head oscillates from side to side.

Originally this was an experiment in vibe-coding a Blender add-on, but even though ChatGPT-6 combined with Gemini generated working code, I wasn't really satisfied with the quality. There were lots of tiny details in the generated geometry that were a bit off, so in the end I spent several days testing and tweaking the code. The two only really useful parts were the parametric equations for the NURBS surface defining the blades and the time saved in generating the many properties. O yes, and spell checking the docs of course.

Anyway, this subject is a bit too niche to release as a commercial add-on, so you can just download it from this GitHub repo (download the .py file from the releases and install it as an add-on).

It was still quite some effort by me to get it all working so if you do find it useful (and can afford it) consider buying me a coffee at Ko-Fi.


Looks cool to me

Articulated lamp


I am getting a taste for modeling and I am happy to present a new model: An articulated lamp.

It is fully rigged and comes with hand crafted 4K textures, in both pristine and slightly weathered variants.

It is available on my Superhive shop, along with my other models.

New release of IDMapper


Remember IDMapper, the tool I open sourced a while ago that facilitates creating I'd maps for meshes? Well, I haven't abandoned it, it fact I use it myself quite a bit these days, so I not only tested it on Blender 5.3, but added a tiny bit of new functionality too: You now can bake the vertex color layer of multiple selected meshes into a single image texture. 

This only gives meaningful results if none of those meshes have overlapping uv-islands, but that is exactly the scenario I find myself working in, if I create a complex model consisting of multiple meshes that I want to paint together in Substance Painter.

Anyway, if that fits your workflow too, you might want to check out the latest release. (Full documentation is available too.)


LED light bulbs


I created a set of LED filament light bulbs with matching packaging. They have realistic dimensions and clean topology, were hand crafted and textured and come with proper uv-maps. 

🎉And to celebrate I extended the coupon code yeah202610 so you can still get 20% off of all my products on Superhive (now expires November 17, 2026).🥳

The light bulbs and my other models are available on my Superhive store.

Street lights (and sale!)

 

I created a set of street lights that can be used in an park or residential area. They have realistic dimensions and clean topology, were hand crafted and textured and come with proper uv-maps and suitable light objects attached. 

🎉And to celebrate you can use the coupon code yeah202610 to get 20% off of all my products on Super hive (expires November 10, 2026).🥳

The street lights are available on my Superhive store.

Efficiently multiplying a list of vectors with a matrix in Blender


An AI generated image abstractly illustrating matrix multiplication











There are many situations when writing Blender add-ons where you might want to multiply a vector with a matrix. A common example is a coordinate transformation, for example to convert object coordinates to world coordinates.

If you only need to convert one vector, it would be no problem to do this directly in Blender:

object_space_vector = Vector((1,0,0,1)) 

world_space_vector = object_space_vector @ context.active_object.matrix_world

(Note that the world matrix is 4x4, so it will not just scale and rotate, but also translate a vector, but then this vector need to be 4d as well! The 4th component, often referred to as 'w', should be 1 if you want to perform that translation, like for positions, and 0 if not, so for normals.)

The challenge

But what if we needed to perform such a transformation on a million vectors? Matrix multiplication itself  isn't exactly cheap, requiring 16 multiplications and 12 additions in the 4d case, and loops in Python are exceptionally slow.

Luckily Blender comes bundled with the numpy module and there are efficient ways to get properties, including vertex coordinates into numpy arrays (as illustrated in this article for example), so we only need a way to use numpy functionality to efficiently multiply a list of vectors with a matrix.

Choices

It is always good to have choices and numpy in fact offers several ways to achieve the same result.

The @ operator

The first is matrix multiplication. If vector is a list of vectors with shape = n,4 and matrix is a 4x4 matrix, we can perform the multiplication of each of the vectors in the list with this expression:

(matrix @ vector.T).T

Because numpy's @ operator expects the first dimensions of each of the operands to match, we have to transpose our list of 4d vectors first, and transpose again at the end to get the results in the right shape. This is a bit unintuitive, but at least those transpose operations are very cheap: they just create a view with a different shape without copying anything.

The alternative approach would be to invert the matrix and write vector @ matrix instead, but inverting a 4x4 transformation matrix is not simply np.linalg.inv(matrix) because we would need to extract the translation and scaling parts first, the invert, then recombine. That's too complicated to my taste, so I go with this approach.

The dot() function

The dot function essentially does the exact same thing, and needs the same transpositions:

np.dot(matrix, vector.T).T

This function is supposed to be more general, in the sense it can deal with tensors too, but that might impact performance. We have a look at that in a minute.

The Einstein summation notation 

The most versatile tool in numpy's drawer is the einsum() function, which lets us define the order of every implicit loop over the list of vectors and the rows and columns of the matrix: 

np.einsum("ni,ji->nj", vector, matrix)

This may look complicated but saves us the double transposition shenanigans, and reads something like: 

use index n to index each vector
    use index i for each element of a vector
        multiply that vector element with an element of the matrix:
            use index j for each row of the matrix
                use index i for each column of the row
        sum the results for the row (because i is used to index the matrix and the vector)
    store each of those row sums as the columns of the nth result vector             

This may take some time to wrap your head around, but it is very versatile and should be fast too.

Performance

Speaking of fast, lets have a look at some benchmarks:

npower of twopure pythondotmatmuleinsum
16384140.0380.0000.0000.000
32768150.0730.0000.0000.001
65536160.1430.0000.0000.001
131072170.2680.0000.0000.002
262144180.5430.0000.0000.005
524288191.1030.0010.0000.010
1048576202.2020.0040.0060.022
2097152210.0100.0160.037
4194304220.0230.0210.070
8388608230.0420.0340.137
16777216240.0880.0670.264
33554432250.1590.1310.522
67108864260.3220.2621.045
134217728270.6250.5112.068
268435456281.2511.027
536870912292.4812.060

For comparison I have also included a pure Python reference implementation to show how slow that is. It is included in the code on Github.

We measure all the way from 16K 4d vectors to over 500 million of those. Tests that are slow were taken out of the race to save time.

The first thing we notice is that all methods scale with the number of vectors: if we double the number of vectors, the time to multiply them all by the same matrix approximately doubles.

The second thing we notice is that Python is really slow: It already takes more than 2 seconds just to multiply a million vectors. This is what we expected of course, so not really remarkable.

An finally, that the @ operator ('matmul') is fastest of them all. So the Einstein summation might be versatile and the dot() function more general but that does come with some overhead.

We can visualize that in the following graph:



(Note the logarithmic scales, so the y-axis top line is 1 second, next one down 0.1 second, etc)

Apart from some irregularities for shorter lists of vectors, the lines are pretty straight and clearly the @ operator is the winner. It might not look all that much in the graph because of the logarithmic scales, but it consistently is 20% faster than the dot() function, and 20% is nothing to be sniffed at in my book.

Caveats & conclusion

Of course your mileage may vary and the exact numbers aren't all that relevant. These timings were measured on a AMD Ryzen 7 7700X with 64 GB memory, and if you have a different CPU and/or amount of memory these timings will differ, but the trends are expected to be the same.

Also, all code uses 64-bit floating point operations and for Blender vertex coordinates that would be overkill. Using 32-bit floating point might save you quite some time, even on a 64-bit CPU, because the vectors would take only half the space, increasing cache efficiency quite a bit, but I didn't tabulate those timings.

In the end, the fastest and simplest to code is probably using the @ operator.


SuperHive summer sale last day

 


The summer sale is closing. So this is your last chance at getting a serious discount on road signs in my shop, but there is loads of other good stuff on sale as well.

US Highway Shield Generator

 




After publishing the US Road Sign Generator I realized people might want a way to generate those highway shields that show the interstate numbers, so I created just that: All lightweight (both geometry and texture) and of course utilizing the common 'Highway Gothic' typeface.

Its available on Superhive (formerly BlenderMarket). Check it out if you want to go on a road trip!

SuperHive summer sale


Yup, the traditional summer sale is there again.  So if you are in the market for some road signs you may want to check my shop, but there is loads of other good stuff on sale as well.

Blender 5.2: Speeding up ImBuf access

In Blender 5.2, the ImBuf object now features a method that can be used as a context manager, yielding a Python memoryview object. This opens up a fast and convenient way to use an ImBuf to draw things using the blf module, and then copy the result to a Blender Image object's pixels attribute.

However, we cannot simply write:

with myimbuf.with_buffer() as mv: myimage.pixels[:] = mv[:]

This fails because Python's memoryview slice assignments have limitations when working with non-flat array configurations, which is what an Imbuf always is (width x height x color channels).  Instead, we have to cast the memoryview to a flat array. 


Furthermore, because either the source or the destination needs to be in a compatible byte format, we cannot cast a multidimensional float view directly to a flat float view in one go. We must resort to a rather inelegant double cast coupled with the foreach_set method:

myimage.pixels.foreach_set(mv.cast("b").cast("f"))

This first casts everything to a flat array of bytes, then to a flat array of floats, what is what foreach_set expects.


It works, and both cast() and foreach_set() are highly performant (cast() does not even touch the data, just the metadata), but it does feel a bit clunky. This isn't Blender's fault, though—it has been a long-standing behavior regarding multidimensional array manipulation discussed on the Python Core Development Issue Tracker.


Note that we now have a fast way to move data from an ImBuf to an Image, but ImBuf objects aren't all that common: we can create one and write text into it with the functions in the blf module, but as far as I can tell the is currently no way to copy a framebuffer to an Image or an ImBuf, nor is there a way to use the gpu module directly to draw into an ImBuf, so quickly creating an Image still requires a laborious route that involves copying the data from the framebuffer pixel-by-pixel to the Image.


Hopefully framebuffers will get buffer protocol support in the future, but that's probably not an easy task as there the actual data lives on the GPU and needs to be transferred. So let's keep an eye on the dev logs. 😀

US Road Sign Generator



After publishing a few sets of US road signs, I went back a created a geometry nodes based road sign generator that can be used to generate the iconic green signs you see along highways in the US.

Configurable to up to three lines, will all sort of options and three different materials. All lightweight (both geometry and texture) and of course utilizing the common 'Highway Gothic' typeface.

Its available on Superhive (formerly BlenderMarket). Check it out if you want to give your drivers some directions!

US Road Signs - Warning Signs Roadwork




After publishing a set of general US road signs, I thought why not publish one with signs commonly seen around road works?

The set is conveniently organized as an asset library and available on Superhive (formerly BlenderMarket). Check it out if you want to keep your rendered road crews and passing driver safe!

US Road Signs - Urban Essentials



I thought I'd quit, but I guess working with Blender is too much fun 😀.

In the past I created some collections with Dutch and German road signs but I thought some US road signs would be a nice addition. There seems to be a bewildering variety of those, much more than their European counterparts, so I limited myself to some of the more common ones seen in (sub)urban setting. If there is some demand for it I might add some other sets. 

The set is conveniently organized as an asset library and available on Superhive (formerly BlenderMarket). Check it out if you want to add some details to your rendered neighborhood!

Visualizing spur gear cutting in Blender

 To get a feeling on how spur gear teeth get their particular shape, I created a short visualizer:


The whole process of emulating the action of the cutter on the rotating blank was done in Blender, this time not using a add-on for once, but a simple script that runs from the text editor.

The script renders a frame, then applies the boolean difference modifier that the spur gear object (the 'blank') has, moves both the blank and the cutter and adds again a boolean modifier and repeats this as many times as desired.

I am not yet sure if I will write a small article explaining the code, it isn´t all that complicated, but in the meanwhile you can download the .blend file from my GitHub repository (click on the 'download raw file' icon in the upper right corner to download). 

Hexagonal patterns in Blender's geometry nodes

 I have been experimenting a bit with geometry nodes lately and I thought I´d share this one

The .blend file is available from my GitHub repository. (Click the 'download raw file' button in the upper right corner to download it; Inside is a sample scene, and the geometry node itself is called 'Hexagon pattern')

Tips

The input mesh is simply repeated across the pattern and nothing fancy is done to it. If the repeated meshes are butted up to each other you may want to remove any coinciding vertices, and I could have done that in the geometry nodes itself but that is unnecessary as you can easily apply a weld modifier to achieve the exact same effect. And other modifier too of course, like a solidify modifier perhaps, to give the grid some thickness.

If you just want a quick hexagonal pattern in a shader, you may want to have a look at this post.

Some details

The node setup is pretty straight forward:

We get the bounding box of the object we want to repeat, scale it a bit so we can add a gap if we like, and the repeat the mesh for a set number of iterations along the x-axis. Then we replicate the result along the y-direction and end with applying a material index.

If we look at the repeat x section, we see that there isn´t much to it:

We simply join a shifted version of the input for a set number of times. The offset in the x-direction is twice the maximum of x dimension of the bounding box, i.e. we assume that the input mesh is symmetrical around the origin.

The repeat y section isn´t all that much different, except for a little detail:

That detail is that we move the new mesh up in the y-direction by a configurable scaling factor, where the default is fit for a six sided cylinder, a.k.a. a hexagon, but you can change that to something else if needed.
We also move the row either to the right or the left, depending on whether we are in an odd or even row. We determine this odd/evenness by taking the iteration number module 2 and using a switch node to provide a multiplication factor of -1 or 1 respectively that we apply to our x offset. If we wouldn´t alternate this move in the x-direction we would get a skewed grid, which might be find, but I prefer to work with a square grid.



New blog: On the back of an envelope

 


I'm interested in more than just Blender ðŸ˜€ so I started a new blog. It might interest some readers of this blog as well as it has a bit of a mathematical focus, just like quite a few articles here.

It is all about assumptions and questions that may pop up in everyday life and that may be solved with a bit of thinking and pen and paper, hence the title "On the back of an envelope".

Focus is on doing our own research up, backed up by proper references to articles by real people, and no easy AI slop. 

Blender add-on development: Multi-file add-ons and custom icons

There are new videos available in the video series on Blender add-on developments for beginners:

 

It is completely free and has a GitHub repository with code .

In this module we will refactor the render_done add-on encountered in the previous module into a multi-file add-on. The first video will take a look at why splitting up an add-on might be beneficial for maintenance, reuse and the options to include non-Python files, something we will make use of in the second video where we will add a custom icon to one of the operators.