A new version of Cineversity has been launched. This legacy site and its tutorials will remain accessible for a limited transition period

Visit the New Cineversity
   
 
baking a displacement map
Posted: 09 April 2012 03:47 PM   [ Ignore ]  
Total Posts:  27
Joined  2009-02-02

Is there a way to bake a displacement map in order to speed up render times?

Scene File:
http://joelhebert.com/wp-content/uploads/2012/04/displacement-Joel-Hebert-2.zip

Thanks
Joel H.

Profile
 
 
Posted: 09 April 2012 04:14 PM   [ Ignore ]   [ # 1 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Hey Joel H.

The texture in your scene indicates a repetitive pattern. You might build one hole* and merge it to the smallest possible unit, then repeat it, e.g., in MoGraph. 

*Have one polygon with a hole and one without (both same size, same origin) then use MoGraph with a MG selection to get things sorted out. So far I know my series about mass-production of holes will be public (finally) in summer. Well, I guess you need it now.

Displacement maps, for SPD I highly recumbent to use 16bit/c formats. Eight bit/c are mostly just a waste of time.

You asked for baking a displacement map. I guess you have in mind to bake the resulting mesh. I can’t recall if that is possible in any way. What C4D offers as Baking a Displacement map is more based on a high resolution object where the resulting displacement map allows a low resolution texture via SPD to “recreate” this high res. object but with the advantage to produce only polygons where you really need it. This seems to be not the case here, at least if I understand your project correctly. A reason why I started out to suggest the “model” option. Stable, clean and optimized. (More information about Displacement baking: Manual>Bake Texture)

All the best

Sassi

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 09 April 2012 04:43 PM   [ Ignore ]   [ # 2 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

P.S. here is an example. Only the holes. If you found the right amount etc, make it editable and merge (optimize) the grid to one object. Select the outline edges and extrude a “frame” without holes in the way you need it. Done :o)

The options with this method are endless, especially with variations of the hole diameter (MoGraph Blend! and Falloff!)

File Attachments
CV2_r13_drs_12_MOho_31.c4d.zip  (File Size: 60KB - Downloads: 225)
 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 09 April 2012 05:18 PM   [ Ignore ]   [ # 3 ]  
Total Posts:  27
Joined  2009-02-02

This method looks great Dr. Sassi,

Although, two issues. 1. It’s kinda crooked towards the right side and 2.I have to get it to scale to the exact size of my displacement version so it’ll fit properly into the rest of the overall model being animated. I messed with the settings but wasn’t quite able to get it exactly how I wanted.

See screen shot
http://joelhebert.com/wp-content/uploads/2012/04/Screen-shot-2012-04-09-at-3.08.05-PM.png

Thanks

Joel H.

Profile
 
 
Posted: 09 April 2012 07:24 PM   [ Ignore ]   [ # 4 ]  
Administrator
Avatar
Total Posts:  12043
Joined  2011-03-04

Hey Joel H.,

I checked your screen shot, but it might communicate only after a briefing about your target.

This is of course only one (well in post one I described another method) way to go.

If you can’t model it, I guess in this case the displacement won’t help either.

The Cheese-Grader should be build along your flat texture, then transformed into your shape.

If the stretch around the bending or curve is a problem, check the bounding box, or try to pre-stretch or squeeze the model with an FFD cage. In that way the Spline Wrap sit below (!) the FFD (oterhwise the object is pulled away from the FFD. Try it with a plane or a cube to see “its mechanic”.

All the best

Sassi

 Signature 

Dr. Sassi V. Sassmannshausen Ph.D.
Cinema 4D Mentor since 2004
Maxon Master Trainer, VES, DCS

Photography For C4D Artists: 200 Free Tutorials.
https://www.youtube.com/user/DrSassiLA/playlists

NEW:

NEW: Cineversity [CV4]

Profile
 
 
Posted: 09 April 2012 07:26 PM   [ Ignore ]   [ # 5 ]  
Total Posts:  27
Joined  2009-02-02

Cool. Ill try these suggestions out. Thanks again
Joel H.

Profile
 
 
Posted: 10 April 2012 05:00 PM   [ Ignore ]   [ # 6 ]  
Administrator
Avatar
Total Posts:  365
Joined  2006-05-17

http://dl.dropbox.com/u/8306001/joel_h_disp/01.PNG

As an alternate to the modeling you could still optimize the mesh a lot.
Here you have these really irregular polygons that you are then trying to compensate for by using really high subdivision levels in your displacement settings. This means alot of time lost to prep work…remember each subdivision does not double the poly count, it quadruples it! so 1 polygon == 4 polygons after 1 subdivision.

http://dl.dropbox.com/u/8306001/joel_h_disp/02.PNG

now here I have adjusted the spline and the extrude nurbs so that I am left with very uniform divisions.
Then in the material I only add a couple steps of subdivision.

The results for me are as such:

http://dl.dropbox.com/u/8306001/joel_h_disp/displacement Joel Hebert 2.jpg
http://dl.dropbox.com/u/8306001/joel_h_disp/displacement Joel Hebert 3.jpg

now, another option is to use the alpha map to generate a normal map for the dents, this would be fastest…but you lose quality up close as the effect can break apart.

Profile
 
 
Posted: 10 April 2012 05:11 PM   [ Ignore ]   [ # 7 ]  
Total Posts:  27
Joined  2009-02-02

Patrick,
Cool stuff. What steps did you take to
“adjust the spline and the extrude nurbs so that I am left with very uniform divisions”
Thanks

Joel H.

Profile
 
 
Posted: 10 April 2012 05:41 PM   [ Ignore ]   [ # 8 ]  
Administrator
Avatar
Total Posts:  365
Joined  2006-05-17

Spline type: Uniform
Intermediate points: Adjust to taste.

The Extrude Nurbs subdivisions should then be adjusted until you get squares rather than rectangles.

The scene file is on my laptop ATM, but I think I had set the splines intermediate points to around 70.

Profile
 
 
Posted: 10 April 2012 05:51 PM   [ Ignore ]   [ # 9 ]  
Total Posts:  27
Joined  2009-02-02

oh ok. I see. Thanks
Joel H.

Profile
 
 
Posted: 10 April 2012 05:57 PM   [ Ignore ]   [ # 10 ]  
Administrator
Avatar
Total Posts:  365
Joined  2006-05-17

Happy to help smile

Profile