Creating a displacement map from points

   3825   5   0
User Avatar
Member
15 posts
Joined: July 2009
Offline
Hello, can someone offer some help me with this problem I'm having. I'll try and explain the situation:

I have a model which has points growing over its surface, these points are joined together with lines and so can be resampled etc to increase their number. The model has been UV'd and I would like to be able to use these points on the surface as a displacement map for the model.

It seems like it should be possible but I just don't know where to start.
I'd like to avoid using the attribute transfer - my understand is that it will transfer information to the points but this will be defined by the resolution of the mesh and so could look quite ‘blocky’ unless I'm wrong about this.


(The UV's look like this , they're not continually joined together but separated - I don't know if that makes a difference but thought I should say.)

Attachments:
Screenshot.png (93.1 KB)

User Avatar
Member
8624 posts
Joined: July 2007
Offline
you can use pointclouds

but you can also transfer the points into UV space with point SOP or VOPs
you just need uv information from mesh on the points then something like this in position of the Point SOP: $MAPU,$MAPV, 0

then perhaps delete longest edges which will probably be crossing through your uv space due to discontinued uvs

and render as lines with ortho camera
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
15 posts
Joined: July 2009
Offline
Thanks for the fast reply tamte, thats really helpful.
Sorry to ask what is probably a really basic question but you say to render as lines with an ortho camera. I don't quite see how this applies to what I'm trying to achieve. Would they be rendered out in UV space and then used as a map afterwards?
Thanks again.
User Avatar
Member
8624 posts
Joined: July 2007
Offline
yes, you will be basically rendering displacement map this way
so it is two step process
Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
15 posts
Joined: July 2009
Offline
Hi Tamte, I had a go at your second suggestion of converting the points to UV space then rendering them out. It works quite nicely but seems a bit a bit fiddly, I'm trying to achieve something as procedural as possible that can update every frame so I think point clouds are the way forward.

This is where my problem is, I understand the concept of point clouds but my knowledge of them is at absolute zero. I'm probably pushing my luck but if you could explain or show an example of using point clouds in a simple shader which shades or displaces the surface close to the proximity of any points, that would be a big help.

Sorry to ask for so much but I have looked everywhere for a nice example which explains it to me but I can't find any.
Regards, Michael
User Avatar
Member
8624 posts
Joined: July 2007
Offline
michael1

I'm trying to achieve something as procedural as possible that can update every frame


I am also very procedural oriented and you can bet that this can be done as an digital asset where you connect your geometry and points to, specify path for displacement sequence and hit render/export button

similar to exporting pointcloud sequence, so pretty much exact amount of work

but i can tell you pros/cons of both methods and you can decide

Points to disp:
Pros:
-can be rendered as lines so you get smooth path of your particle traveling over surface or something
-do not require custom shader for displacement (not a big deal, but) you'll get displace sequence directly so you can even use it in other package
-processes only points on surface not approximate points (in pointclouds you will have displacement on all parts of mesh close to the points so if your character scratches his head where are allready points that displace it, the displacemet will also be on his fingers that are close to those points for that moment, unless you utilize some kind of filtering by normal map orientation, which can be done easily i think)

Cons:
-the size/width of the lines will vary if you have uneven UVs
-creating disp sequence takes longer than exporting points(but it depends on resolution)
-it also can consume more disk space
but those depends on how dense is your pointcloud (it has to be dence since you have to have points so close to each other to appear as line)

just invert those to get Pros/Cons of pointclouds for this task

you can search the forums for pointclouds in VEX/VOPs those were discussed many times and i bet you can find an example if you decide for that option
Tomas Slancik
FX Supervisor
Method Studios, NY
  • Quick Links