Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- Process to add detail of a bumpmap to an existing heighfield with World Machine
- 1. Write down the following values of your heightfield: (Can be found in L3DT under Operations > Heightfield > Change Vertical Range)
- a = Minimum Altitude
- b = Maximum Altitude
- c = Full Altitude range
- d = Cell size/Horizontal Scale
- e = Heightfield resolution
- f = Heightfield scale (Can be calculated manually with: d * e = f)
- g = Bump map detail depth (in meters)
- (Replace these letters with their corresponding values in the following steps, if that wasn't obvious)
- 2. Create a new world machine project and set the project settings as follows: (World Commands > Project World Parameters)
- - Start with the third tab: (General Setup)
- - Set 'Dimensionality to' Kilometers
- - Set 'Maximum Elevation' to 'b'
- - Set 'Base Elevation' to 'a'
- - First tab: (Render Extents ....)
- - Width: 'f' (In KM)
- - Height: 'f' (In KM)
- - Normal Build Resolution: 'e' (You can set this lower initially for testing purposes)
- 3. Create 3 new 'File Input' devices: (Devices > Generators > File Input)
- - File Input #1:
- - File details: Load your bump map image that you want to apply
- - Width: 'f' (In KM)
- - Height: 'f' (In KM)
- - Altitude Scaling: 'Specific Elevation Range'
- - Elevation Span: ['a'] to ['a + g'] (You want the bottom of the bump map at the bottom of the worldspace, and it's max height at whatever your detail depth should be.)
- - File Input #2:
- - File details: Load your heightmap. (Not in image/raster format)
- - Width: 'f' (In KM)
- - Height: 'f' (In KM)
- - Altitude Scaling: 'Specific Elevation Range'
- - Elevation Span: ['a'] to ['b'] (Same as using full range option)
- - File Input #3: (Optional)
- - File details: Load your mask image
- - Match the rest of the settings to the main heightfield file input
- 4. Create 1 'Constant' device: (Devices > Generators > Constant)
- - Height: ['a + g'] (This is so you can subtract this amount of the terrain so it's elevation stays the same as it was on input)
- 5. Create 3 'Combiner' devices: (Devices > Combiners > Combiner)
- - Combiner #1:
- - Connect 'File Input #2' primary output to the top input of the combiner
- - Connect the constant's only output to the bottom input of the combiner
- - In the device's settings, set the method to 'Subtract
- - Set the strength to 0.50000
- - Combiner #2:
- - Connect 'File Input #1' primary output to the top input
- - Connect 'Combiner #1' output to the bottom input
- - Method: Add
- - Strength: 1.00000
- - Combiner #3: (Controls the strength of the bump-mapping with strength value, also use with mask, optional)
- - Connect 'File Input #2' primary output to the top input
- - Connect 'Combiner #2' output to the bottom input
- - Method: Average
- - Strength: 0.50000
- 6. Create a 'Height Output' device: (Devices > Outputs > Height Output)
- - Connect 'File Input #2' bottom output (File Metadata) to bottom input
- - Connect 'Combiner #3' (Or #2) output to top input
- - Edit export settings
- (What my final layout looked like: https://i.imgur.com/xFW2MUV.png)
- 7. Build and write output to disk (Once results are satisfactory of course)
- My results:
- Bump map used: https://i.imgur.com/asYKRNt.png
- Before: https://i.imgur.com/kEsNhUs.png
- After: https://i.imgur.com/mD8ezml.png
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement