H15 Baking

   26413   75   8
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
Just thought I'd show some baking in H15, it's seriously cool because you could generate 100's of these very quickly.

And this is just a super simple setup, putting some more time into the HiRes shader would make it realy shine.

Attachments:
H15_Baking_Small.jpg (644.2 KB)

/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
1755 posts
Joined: March 2014
Offline
looking pretty cool
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@McNistor, thanks!

Here is another test.

Attachments:
H15_Baking2_Small.jpg (462.2 KB)

/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: These tests are looking terrific Could you explain a bit about your method for the procedural weathering (eg. VDB operations, etc.)?

There are some new additions to baking coming that should help in your work:

-Max distance control. Hits on the highres object farther away than this value will be ignored.

-Ray controls. You will be able to specify the origin and direction of trace rays manually. These will be controlled using vector attributes on the lowres object. Normally the trace method uses the surface normal, however this will help in cases where finer control is required.

-Diagnostic output. The bake will store this in the ‘C’ image plane, which has caused some confusion in the past, being black by default. The diagnostic colors are:

Red - Rays missed the highres object
Green - Rays hit the highres object along the positive normal
Cyan - Rays hit the highres object along the negative normal

-Alpha output. This will be a “stencil” mask, with white in areas where the highres object was hit. This is helpful when the lowres object is a flat plane wrapped to detailed highres geometry. This is intended to be used as an opacity map.

I'll let you know once there is a build available with these features for testing. Thanks for all your help in moving these tools along; it has been great to have your input
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@MDavies, Thanks ! it's been a bunch of fun trying out.

Looks like alot of nice things are comming. Btw I still havent been able to output TGA's for the seperate image planes and I seem to recall you saying it was possible, is this something that could be posted as a example ?

For the weathering effects I just use the “VDB from polygons” and then I hook up a “Volume VOP”

Inside the Volume VOP I put in a bind VOP for the “surface” (make sure you did fill interior previously) and a bind export for the “surface” aswell, hooking the bind and bind export togeather, adding a “Add VOP” inbetween that also gets hooked up to a Turbulence VOP.

After that back out to SOP level and convert the VDB to polygons.

Then generally I put down a attribute transfer between a “un-weatherd” hi-res and the generated “weatherd” mesh, usually I do this with the “Cd” attribute so it is easily to see, changing the distance for the transfer to a low level makes the worn parts a different color than the not so worn. This attribute can then drive the blending between materials in the shader.
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
1755 posts
Joined: March 2014
Offline
Oh wow, I looked at the pics mostly and just glanced over the text, no wonder I didn't notice that these are obtained procedural. They look great as they are and I'm guessing if in need of a “hero” object you can easily export one of those dense meshes and further sculpt it in Zbrush.
I'd be curios to be able to make a comparison between the level of control you have here and that of Zbrush's noise generator.
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
McNistor
Oh wow, I looked at the pics mostly and just glanced over the text, no wonder I didn't notice that these are obtained procedural. They look great as they are and I'm guessing if in need of a “hero” object you can easily export one of those dense meshes and further sculpt it in Zbrush.
I'd be curios to be able to make a comparison between the level of control you have here and that of Zbrush's noise generator.

Yeah I wish there where more build in noise patterns in Houdini even though you can come pretty far with whats already there. But my “dream” with this, just for personal fun, is say that you want todo a cemetary and instead of Z-brushing 100 run down tombstones, you just procedurally generate them. Just press render frame range 1-100 and put $F in your noise offset.
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: Thanks for describing your workflow; it looks like a really nice setup for automating weathering/damage effects.

In terms of working with meshes between Houdini and other applications, there are plans to offer an option to bake out displaced meshes, inclusive of dicing. This would include the output of shaders, as well as offering options to bake to per-vertex attributes (eg. for pre-lighting scenes/assets).

The attached shows the use of max distance for the trace between lowres > highres objects. In the C plane (diagnostic) you can see where the highres object is being hit (light green above the normal, dark green below), and missed (red). The alpha plane could be used to cut out areas that are missed in the trace, like windows, for example. The base normals are left unmodified in the missing areas for the normal map (ie. as opposed to filling with black).

Attachments:
diagnostic-plane-c.png (98.3 KB)
alpha-plane-ab.png (74.9 KB)
tangent-plane-nt.png (187.4 KB)

User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: I will look into the use of TGA's for image plane output. If this is not possible we may add an output format parameter to use when extracting image planes.
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@MDavies: Yeah I kinda like it, there are some things I would love, like more Noise Patterns to achive different looks etc, but all around it is working.

On a previous project I tried exporting meshes from Houdini to bake Hi-Lo-Poly in Modo, and that turned out to be _hard_ because the geo files easily reached around 300mb and that was only the plain VDB mesh without displacement so I can only imagen how huge they would be with that. So not highest on my “need” list
Plus the shader posibilitys in Houdini are way more interesting, specially with stuff like Eetu's grit shader, which unfortunatley dont have a “scope” function right now so it doesnt work to bake with. But I heard from him that he will look into that.
I have a setup I'll post once that works (fingers crossed).

I would very much like if the image planes output worked because then I could comform the output to the name standard we use (which is a bit bonkers but nothing I can do about).
Edited by - Oct. 19, 2015 15:42:36
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
For noise pattern insperation look at Mari and Modo as an example:

Mari:
http://www.davidgurrea.com/index.php/documentation/mari-procedurals [davidgurrea.com]

Modo:
http://modo.docs.thefoundry.co.uk/modo/601/help/pages/shaderendering/EmodoTextures.html#page=page-2 [modo.docs.thefoundry.co.uk]
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
8531 posts
Joined: July 2007
Online
mdavies

In terms of working with meshes between Houdini and other applications, there are plans to offer an option to bake out displaced meshes, inclusive of dicing. …

now that you've mentioned it
it would be really cool if mantra can do adaptive displacements as that can be much lighter for transferring between apps an maybe even on mantra render itself, at least when Full Predicing is on as then the full geo needs to be subdivided anyway so there may not be a limitation to use only per bucket dicing anymore

as an example I found this constant density and adaptive displacement comparison from corona renderer

Tomas Slancik
FX Supervisor
Method Studios, NY
User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: We can certainly look at adding different noise patterns. I'm not sure of how much material there is out there, but other users may have added additional noise VOPs; have you had a look?

Yes, the diced mesh baking with displacement would produce a large mesh, but if handled in tiles it could be brought into another application without too much of a headache. Even without dicing, just being able to bake down shading to vertex attributes should come in handy (eg. for pre-lighting).

It should be possible to offer some control over the output image plane naming. We could add a post-frame script that would be passed the file path to any generated images, which would give you the opportunity to rename/edit them. There is also an option in the image plane dialog to save to a different file, with custom naming. I'm not sure if this competes with the built-in planes, though (eg. overriding the ‘Nt’ plane with your own filename). What sort of naming format are you using?

@tamte: Yes, Corona has some great features, like Importons:

https://corona-renderer.com/blog/research-corner-progressive-importance-sampling/ [corona-renderer.com]

We could look at adding adaptive displacements. It would certainly help with reducing the complexity of baked geometry.
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@MDavies, Havent looked around for other noise patterns, didnt even relize people might be creating them but I will surely take a google search session now

Well dicing hi-polys etc, for us as a game studio generating tons and tons of props and wondering how to bring that effectivly into Modo still probably would be a not used feature, but probably useful for others.
I personally would like to stay as much as possible inside Houdini for these type of things I imagen todo with Houdini.
(the biggest hurdle for that to become true right now is good procedural UV mapping, but it also depends heavily on what type object you are doing.)

Yes the different file option for the imag eplanes is what I was hoping to use for now because then I would have absolute control
Our whacky name standard is:

Diffuse = texture.tga
Normal = texture_local.tga
Specular = texture_s.tga
Glossiness = texture_pm.tga
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
BTW, here is my updated test using Eetu's grit VOP with some custom fixes to fix the “scope”'ing issues. Seem there are still some things to work out with that but I still like the result.

Attachments:
H15_Baking3_Small.jpg (529.2 KB)

/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: Looking fantastic

It will be easier to incorporate custom outputs like this with H16. The new setup will separate the unwrapping/correspondence from the shading, which means that you will not need to worry about scope for the trace. You will also not be limited to a fixed set of outputs when baking from highres > lowres, either (eg. ‘diff_clr’). This should be helpful with textures like your grit mask.
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@MDavies, thanks are you teasing me about H16 2 days after H15 release ? grrr
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
Now the generated mesh with it's texture is in Unreal Engine.

Attachments:
H15_Baking_Unreal.jpg (461.0 KB)

/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
User Avatar
Member
110 posts
Joined: May 2015
Offline
@MagnusL3D: Wow! Very nice work. Great to see this living in the engine

I've added an option to choose the extracted format for the image planes (see attached). In terms of handling custom naming formats it might be safest to do this via a script. We could call a python script with the output filenames and let you handle any post-processing (eg. renaming, filtering, converting, publishing to database).

Attachments:
extract-format.png (50.9 KB)

User Avatar
Member
1104 posts
Joined: Aug. 2008
Offline
@mdavies, thanks ! I have grand plans for this

Very nice with the format option ! the python script seems interesting, perhaps it could do things like flipping the green channel too ? I had to do that witht he unreal maps it seems, was thinking of setting up a cop network to process the .rat files but it this python script could do that too besides naming that would be wonderful.

How would that work? would the there be something like a default script that you can edit or you have to write it from scratch ..?

/M
/M

Personal Houdini test videos, http://vimeo.com/magnusl3d/ [vimeo.com]
  • Quick Links