File size getting out of hand when creating terrain ?

   3692   4   1
User Avatar
Member
8 posts
Joined: Oct. 2016
Offline
Hi,
pretty much what the title says : I've been creating a terrain using heightfield nodes in Houdini and my scene file keeps getting bigger. Before I begun the terrain it was under 1Mo, then as I kept advancing it grew to 290Mo.
Is there any way I can reduce that ? I'm pretty sure this is due to heightfield_paint strokes being cached directly in the scene file. Is there a way to cache strokes outside of my scene ?

Thanks
Val
User Avatar
Member
323 posts
Joined: Jan. 2015
Offline
Yes use a “Heightfield File” node to save the pained stuff and disable and reset the paint node.
Edited by Olaf Finkbeiner - June 20, 2018 02:01:32
User Avatar
Member
8 posts
Joined: Oct. 2016
Offline
Did not know about this node, thanks !
One more concern : because I'm saving an image file, how do I ensure I don't loose too much details ? I'm working on 2000 square terrain with a grid spacing of one. Is 2000px wide enough or should I double it / triple it ?
Val
User Avatar
Member
8 posts
Joined: Oct. 2016
Offline
That did it, my scene size is now back to 2Mo.
Thanks a lot Olaf !


A few things if anyone is interested in the solution : you have to create two nodes :
heightfield_output to save your file. Make sure your resolution parameter is equal to your height field size divided by grid spacing.
heightfield_file to read the file you just created. Set layer mode to “replace” and Size to your height field size.
When your file is saved make sure to click reset stroke on your paint node.
Edited by opika - June 20, 2018 04:22:01

Attachments:
Capture.PNG (12.6 KB)

Val
User Avatar
Staff
6205 posts
Joined: July 2005
Offline
You can also cache out a height field with a “File Cache” SOP or File SOP as it can be saved as .bgeo.sc. This is a 3d file format, but it stores the heightfield as a 2d volume so will round-trip seamlessly.

The growing file size is probably due to heightfield paint. To avoid having to re-apply the strokes every time you load a file, it caches out the final painting you did as a layer. This will thus bloat the .hip file.
  • Quick Links