Jump to content

[SOLVED] Is there a way to force material to shader compile?


JCPalmer
 Share

Recommended Posts

I am starting to use ShaderBuilder for some new 'grand entrances'.  That is when a mesh is instanced (after any textures have been loaded), it is accompanied with some kind of effect & sound.  My entrances till now have been assigning temp materials, scaling, or animating a shapekey.

ShaderBuilder is actually done against a temporary mesh.  A cylinder for Teleport entrance, and sphere for a Poof entrance.  I wanted to show the mesh & any kids when 85% of the animation is complete.  Problem is, if this is the first time permanent mesh is being made visible, there is a slight hesitation right in the middle of the shader builder animations.  It just kind of ruins it.

Works purrrrfect on subsequent entrances.  Is there something I can call on the permanent meshes before I start the animation, to make sure everything is ready?  I could do a quick show while mesh was at scale(0.0000001, 0.0000001, 0.0000001), but looking to find a crap-free method.

Link to comment
Share on other sites

Actually, setting the scaling incredibly small works good.  A little bit of a hack, but I was already hacking a bit.  QI was setup not to allow new queue items to start while mesh was not enabled.  I was enabling the mesh to get the queue to process events, but setting visibility to 0.  At 85% complete, was setting visibility back to 1.  Visibility does not apply to child meshes, unlike scaling, so had to get all the descendants & apply visibility both ways in loops.  Using scaling at just the mesh is still cleaner on a relative basis.

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.

Loading...
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...