Jump to content

Recommended Posts

Hi,

 

I've been struggling with this problem for a few days now and can't figure it out so would really appreciate some help!

 

I'm creating a procedural city which is on a deforming (ocean) ground. Procedurally modelling it is fine but I can't figure out a solid method for UVing the buildings - it seems Houdinis UV tools are slightly lacking..

 

So, currently i've done the following:

 

1. City block layout from voronoi pattern

2. Deform this surface

3. Create a base for every building in the blocks

3. Extrude the buildings upwards

 

So its very simple but since the buildings are on a deforming surface they are not straight and are constantly moving, UVing them is a bit tricky (unless i'm being very stupid). My initial methods were:

  1. Do extrusions and UV buildings while on a flat surface then somehow transfer them back on to the deformed surface (rivet sop, copy sop??). Problem: buildings must be copied back in the same order to maintain the city layout.
  2. Convert primitive normal vector to rotation matrix and align UV project (cylindrical) node to building
  3. UV project (Y axis) city layout then edit UVs of the building walls with each extrusion problem: effectively results in a Z orthographic projection for the walls so UVs must be horizontally unwrapped
    1. ​​​​Iterate through building walls and calculate the area of the each primitive in UV space and scale it based on the area of the primitive in 3D space
    2. After UV projection of the city layout, duplicate the primitive and layout the points along the X axis in UV space based on their length, then all extrusions will be in proportion. Then transfer the UVs from the duplicated primitive back to the roof of the building

I've attached a slightly simplified version of my scene with annotations.

 

Thanks very much,

Mike

 

 

texture_problem.hipnc

Share this post


Link to post
Share on other sites

 

Thanks,

 

I noticed these before but I was hoping it would be fairly simple and I wouldn't have to spend any money to fix it... I basically just need the horizontal unfold like in Maya!

Share this post


Link to post
Share on other sites

Hiya Michael
 
Here is a simple example showing the idea.

Freeze the geometry as a reference to add the uvs to....then reference these from the deforming geo.
Open up the hip and check the names of the nodes...
let me know if this helps
best
mark

fixUVExample.hipnc

Edited by spev

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

×