LDraw.org Discussion Forums

Full Version: Heightmap to brick converter?
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2 3
(2018-06-25, 19:57)Roland Melkert Wrote: [ -> ]
(2018-06-25, 12:34)Jaco van der Molen Wrote: [ -> ]I get this error:

[string "landscape.lua"]:11: module 'heightmap' not found:
    no field package.preload['heightmap']
    no file 'C:\Users\mj\AppData\Roaming\LDCad 1.6b\scripts\default\global\heightmap.lua'
    no file 'C:\Users\mj\AppData\Roaming\LDCad 1.6b\scripts\default\modules\heightmap.lua'
    no file 'C:\Program Files (x86)\LDraw\LDCad 1.6b\heightmap.dll'
    no file 'C:\Program Files (x86)\LDraw\LDCad 1.6b\..\lib\lua\5.3\heightmap.dll'
    no file 'C:\Program Files (x86)\LDraw\LDCad 1.6b\loadall.dll'
    no file '.\heightmap.dll'
Script main run failed.
Did you put the loose heightmap.lua file in the global folder and not its whole containing folder.

Oops, my mistake. I put the entire folder "heightmap" with heightmap.lua, readme and licence.
It works now, though it still times out on 32x32.
16x16 works fine.

This looks all very promising!

[edit] On another PC 32x32 also works. 48x48 most of the time. 64x64 times out most of the time.
I have also worked with mesh-based terrain where each pixel of the heightfield represents a 640x640 unit area (i.e. a normal baseplate).

Two problems:

1. There are many many steps to get to the final product, using several different software (some I wrote myself).
2. You can't easily edit the mesh inside MLCad, LDCad, etc. Rendering the mesh happens fast if it is a single object. Rendering is very very slow if you load all the triangles as individual sub-parts. If you want to raise or lower a vertex, you have to manually modify every triangle that meets at that vertex.

Here are some instructions:


Here are some pictures as well as a download link to the terrain files:


This process is not streamlined at all!
Pages: 1 2 3