Questions tagged [geometry-instancing]

51 questions
1
vote
0 answers

multiDrawElementsInstancedWEBGL / select geometry to render using LOD

I'm looking for answer regarding the multiDrawElementsInstancedWEBGL api on the web, I'm hitting a wall on something and this is quite frustrating, and really afraid this could confirm my darkest fear haha I did some experiments in implementing…
1
vote
1 answer

DirectX - when to use instancing and when not?

I'm making an application using directx 11. I wanted to make use of instancing in the first place, so I've organized my whole pipeline to always work with instancing for simplicity. This means that currently if I want to draw a single occurrence of…
Gregor Sattel
  • 352
  • 3
  • 12
1
vote
0 answers

WebGL2 instancing with UBO

I'm trying to implement geometry instancing in my engine using Uniform Buffer Objects. The idea is simple. I fill all visible entities states to single UBO for current scene. And then after commands sorting: In case without instancing - I bind…
Andrey Honich
  • 41
  • 1
  • 4
1
vote
1 answer

Can we use ThreeJs Helpers with InstancedMeshes?

I am newbie to Threejs and I am trying to use axesHelper to visualise the three axis of all the objects in a scene. Earlier I was using simple Meshes and all the helpers were working fine. Recently I've moved few objects to Instanced Meshes and the…
1
vote
1 answer

Qt3D - Instance rendering of 2 squares. PrimitiveType? InstanceCount?

I'd like to display on the screen 2 squares using instance rendering. The problem is : When I draw 2 squares, they are connected. I can't draw multiple separate square. I know it has to do with PrimitiveType : i'm using…
Romain
  • 44
  • 6
1
vote
1 answer

Inconsistent behavior in instance rendering with glDrawElementsInstanced, somtimes no rendering with no errors

I've been working on project using OpenGL. Particles are rendered using instanced draw calls. The issue is that sometimes glDrawElementsInstanced will not render anything. And no errors are reported. Other models and effects render fine. But no…
1
vote
0 answers

OpenGL glDrawArraysInstanced faster than glDrawElementsInstanced: Is there a way to make glDrawElementsInstanced faster?

I'm making tests with OpenGL instancing methods and I tested both glDrawArraysInstanced and glDrawElementsInstanced functions with the rest of the code being practically the same. The test is to render 1 million colored squares (scaled to become…
1
vote
1 answer

instancing vs bufferGeometry vs interleavedBuffer

I need to draw thousands of points & lines witch have position, size and color attributes and they're position is dynamic (interactive in dragging). I was using buffer Geometry until now but now I had found two more things instancing interleaved…
1
vote
1 answer

OpenGL instancing : how to debug missing per instance data

I am relatively familiar with instanced drawing and per instance data: I've implemented this in the past with success. Now I am refactoring some old code, and I introduced a bug on how per instance data are supplied to shaders. The relevant bits are…
Heisenbug
  • 38,762
  • 28
  • 132
  • 190
1
vote
0 answers

Geometry instancing in Silverlight 5.0 - is it possible?

I am working on Silverlight 5.0 app. Because I am rendering a lot of models at once (hundreds of them) I would like to use geometry instancing. Unfortunatelly from my research i found out that silverlight uses shader model 2.0. Is it possible to…
bartosz.baczek
  • 1,567
  • 1
  • 17
  • 32
1
vote
1 answer

Opengl - instanced attributes

I use oglplus - it's a c++ wrapper for OpenGL. I have a problem with defining instanced data for my particle renderer - positions work fine but something goes wrong when I want to instance a bunch of ints from the same VBO. I am going to skip some…
user2521472
  • 137
  • 11
1
vote
1 answer

Instanced-based VR rendering in OpenGL

I'm trying to use instancing to do VR rendering in OpenGL with 1 draw call, 2 instances (one for left eye, one for right eye). The vertex shader then translates the vertices left for instanceID 0 and right for instanceID 1. The only thing I need…
Tuxer
  • 753
  • 1
  • 6
  • 20
1
vote
1 answer

Draw selected instances of VAO (glDrawArraysInstanced)

I'm using glDrawArraysInstanced to draw multiple instances of a tree at different positions to generate a forest. Is there a way to draw selected instances? For example: I got 100 trees with different attributes. Due to culling I only want to draw…
H4kor
  • 1,552
  • 10
  • 28
0
votes
2 answers

How to draw selected instances with gl_InstanceID and glDrawElements...?

I want to draw a selected number of instances using glDrawElements... but I don't know which function to use and how to set the parameters. I set the gl_InstanceID in shader and set the shader data through SSBO: glGenBuffers(1,…
KennyTan
  • 73
  • 1
  • 8
0
votes
0 answers

How do I get the THREE.JS InstancedMesh working?

I'm trying to use the THREE.JS InstancedMesh to make copies of an imported gltf file, but nothing shows up in the scene. This is the code I've used so far: const equatorMaterial = new THREE.MeshStandardMaterial({color: 0x242526, metalness:1, …
Gift G.
  • 57
  • 4