MeshInstancerFromTexture_v3 Op
Draw the same mesh multiple times on the GPU
Summary (oneliner)
A performant way to render a 3d object many times.
Data like position, scaling, colors etc. are delivered as RGB channels in textures. RGB values represent XYZ coordinates in the position or scale input texture. Make sure the texture format has the required precision (16 bit or 32bit textures are a probably a must)
The 3d object or mesh to be rendered needs to be connected as a geometry. Most meshes in cables output a geometry object that you can connect. Imported 3d meshes can also output geometries, e.g. see GltfGeometry operator.
The object can be scaled differently each time, or have a different color, etc.
The Billboarding option will render the object always perpendicular to the screen. Spherical billboarding means the object will be oriented flat to the screen, this is handy for 2d overlays. Cylindrical billboarding can be used for instancing flat objects in a 3d environment, often used in games for rendering trees, grass or bushes as 2d planes.
- Ops.Gl.Meshes.MeshInstancerFromTexture_v3
- Core Op - Official cables op
- MIT
Documentation (markdown)
Issues
Example patch id
Youtube ids (comma seperated)
Op Licence
Caniuse query
Example Patch Mesh Instancer from Texture
Use a texture to position geometry instances in your scene.
Using HDR textures will alow for precise control.
Youtube Video Tutorial
INPUT PORTS
Trigger In
Global scale for all instances, disabled if scale array is used
OUTPUT PORTS
Trigger Out
Total number of instances/shapes
Patches using MeshInstancerFromTexture_v3
Changelog
created op | cables - 2019-11-14 17:46 | |
Ops.User.cables.MeshInstancer_v3 renamed to Ops.Gl.MeshInstancer_v3 | cables - 2019-11-14 19:03 | |
Ops.Gl.MeshInstancer_v3 renamed to Ops.Gl.MeshInstancer_v4 | pandur - 2020-07-23 11:24 | |
added core lib: cgl_shadermodifier | pandur - 2020-07-23 15:13 | |
cloned op from Ops.Gl.MeshInstancer_v4 | pandur - 2021-03-01 07:41 | |
Ops.User.pandur.MeshInstancerFromTexture renamed to Ops.Gl.Meshes.MeshInstancerFromTexture | pandur - 2021-03-01 08:18 | |
Ops.Gl.Meshes.MeshInstancerFromTexture renamed to Ops.Dev.Gl.Meshes.MeshInstancerFromTexture | pandur - 2021-08-04 10:41 | |
cloned op from Ops.Dev.Gl.Meshes.MeshInstancerFromTexture | pandur - 2021-11-02 18:55 | |
Ops.User.pandur.MeshInstancerFromTexture2 renamed to Ops.Dev.Gl.Meshes.MeshInstancerFromTexture_v2 | pandur - 2021-11-02 19:40 | |
Ops.Dev.Gl.Meshes.MeshInstancerFromTexture_v2 renamed to Ops.Gl.Meshes.MeshInstancerFromTexture_v2 | pandur - 2022-02-07 11:14 | |
cloned op from Ops.Gl.Meshes.MeshInstancerFromTexture_v2 | pandur - 2023-02-07 16:52 | |
rename | Ops.User.pandur.MeshInstancerFromTexture3 renamed to Ops.Gl.Meshes.MeshInstancerFromTexture_v3 | pandur - 2023-02-07 17:06 |
feature | Added options for billboarding | pandur - 2024-02-15 10:22 |
bugfix | Fix bug not rendering correctly on the first frame | pandur - 2024-08-08 12:22 |