Rastar Posted January 10, 2014 Share Posted January 10, 2014 Quick question: If I have, say, 10 instances of the same model, of which 5 are frustum culled - will the gl_InstanceID in the shaders only count the visible instances (thus running from 0 to 4) or the "instantiation order number" (meaning it will run from 0 to 9, but some numbers won't show up in the shader)? Quote Link to comment Share on other sites More sharing options...
Admin Posted January 10, 2014 Share Posted January 10, 2014 Only the visible instances will be sent to the shader. So the instance ID is highly variable and can be completely random. Oooh, fun future feature idea: user-defined uniform buffers so you can store any structure along with an entity instance. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.