Jump to content

sprite shader


tallen

Recommended Posts

having troubles manipulating the texturepath of the sprite shader (param: sprite_baseColorMap) Trying to randonmize my renders a bit.

I think I am getting tripped up with where the shader is being referenced. If I create a point (or any other class) attribute with the matching param name it doesn't recognize the attribute (override).

To complicate, the sprite pop requires that you give a path to the shader. If I don't use the path, I can render with the shader for sure but i am assuming that I can no longer manipulate the material in sop? Confused.

Any help from someone who has used this approach before? Just trying to have each sprite (particle) point to a few different texture maps...And I'd like to stick with the sprite shader.

Link to comment
Share on other sites

Digital Tutors.... reminded me that I should be going about it differently. Forgot about the offset $MAPU filmstrip approach (and not mess with any point attribute overrides!)

For an eight image filmstrip cycle (static):

Texture offset: ceil(fit01(rand$ID),0,7))/8 (in place of $STEXU)

Texture Size: 1/8 (in place of $STEXW)

having troubles manipulating the texturepath of the sprite shader (param: sprite_baseColorMap) Trying to randonmize my renders a bit.

I think I am getting tripped up with where the shader is being referenced. If I create a point (or any other class) attribute with the matching param name it doesn't recognize the attribute (override).

To complicate, the sprite pop requires that you give a path to the shader. If I don't use the path, I can render with the shader for sure but i am assuming that I can no longer manipulate the material in sop? Confused.

Any help from someone who has used this approach before? Just trying to have each sprite (particle) point to a few different texture maps...And I'd like to stick with the sprite shader.

Link to comment
Share on other sites

  • 1 month later...

Hi Tallen

I'm trying to do something similar.

I want my sprites to reference a random selection of stills.

I've made a material which references some very simple vex code some texture and a color multiplied into an output.

Did you work out how to get a sop variable into the string reference of the texture to select multiple texture files for your sprites

or do you have a completely different approach?

Any help would be well appreciated.

John

Link to comment
Share on other sites

having troubles manipulating the texturepath of the sprite shader (param: sprite_baseColorMap) Trying to randonmize my renders a bit.

If I create a point (or any other class) attribute with the matching param name it doesn't recognize the attribute (override).

...

you need to create string point attribute named "baseColorMap" which is the real name of the parm used in shops

"sprite_baseColorMap" is only the name for the promoted parameter in material

you also need to add "baseColorMap" string to Attributes parameter of the sprite material (Geometry Tab)

...

To complicate, the sprite pop requires that you give a path to the shader. If I don't use the path, I can render with the shader for sure but i am assuming that I can no longer manipulate the material in sop? Conf.used.

...

have you seen this thread?

http://www.sidefx.com/index.php?option=com_forum&Itemid=172&page=viewtopic&t=18468

Link to comment
Share on other sites

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.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...