Jump to content

Additional per vertex data for shader attribute (non-uniform in)


photo

Recommended Posts

I want to pass additional data to vertex shader on per-vertex basis.

Let's say I want to supply additional per-vertex color to my custom shader.

How can I do that?

Edited by tower120
Link to comment

Dear @tower120,

I always try to use the material parameters to map these things. If I need additional things, I simply maps them to textures and get the per pixel things than per vertex things.

Please clarify which extra parameters you want to send per vertex basis to understand how we will do it?

Regards,

Rohit

Link to comment

>> If I need additional things, I simply maps them to textures and get the per pixel things than per vertex things.

You mean you do texture fetch in vertex shader based on its instance_id?

Link to comment

No... As mentioned for additional things I do per pixel than per vertex by using textures.

That's why I have asked which additional information you want to send with Vertices? May you shed some light on your exact requirement?

Rohit

Link to comment
×
×
  • Create New...