art3mis Posted July 2, 2021 Share Posted July 2, 2021 (edited) Successfully exporting a small crowd using the stadium shelf tool into Unreal. The problem is I only get a single character material or texture atlas applied to ALL 50 crowd agents in the alembic. In Houdini there are 9 different texture atlases randomly applied. Since inside Unreal you lose access to the individual crowd agents, my thinking is that the correct solution is the following. For 9 material variations represented by 9 different texture atlases I would create one 3x3 master texture containing all 9 variations Then I would need to somehow create a shader that will randomly offset the UVs for each character BEFORE they get rendered as an alembic. Can anyone help with this? Edited July 3, 2021 by art3mis Quote Link to comment Share on other sites More sharing options...
Atom Posted July 3, 2021 Share Posted July 3, 2021 (edited) I think you will have to build a special material inside Unreal, just like Houdini has done for the mocap biped asset. What's happening inside Houdini is a the texture index is used to select which map to apply. You'll need to find the equivalent of that inside of Unreal, such as passing an attribute index along with the mesh geometry. Perhaps check out MaterialLayers..? https://docs.unrealengine.com/4.26/en-US/RenderingAndGraphics/Materials/MaterialLayers/ Once you come up with a material that works for your case, you may want to write a tool in Houdini that examines your Houdini materials and kicks out an Unreal python script that you can run inside the Unreal Editor to migrate that materials into that render system. Here is a link to a short script that shows how to generate a material linked to external files. (i.e. diffuse, normal, ao maps.) https://forums.unrealengine.com/t/solved-connect-a-texture-to-a-material/151392 Edited July 3, 2021 by Atom Quote Link to comment Share on other sites More sharing options...
art3mis Posted July 3, 2021 Author Share Posted July 3, 2021 (edited) Thanks for the feedback! I considered passing an attribute index along with each crowd agent however what I don't understand is how to access the mesh of individual crowd agents inside the alembic once it has been imported inside Unreal. Won't this be necessary to accomplish what you are describing? AFAIK Unreal just looks at the alembic (in my case comprised of 50 crowd agents) as a single object when imported as Geometry Cache? That's why I reasoned the material variation has to be done via offset UVs in Houdini on each crowd agent before it gets rendered out as alembic. I'm probably missing something... Edited July 3, 2021 by art3mis 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.