LDraw.org Discussion Forums
Custom road baseplates - Printable Version

+- LDraw.org Discussion Forums (https://forums.ldraw.org)
+-- Forum: LDraw Programs (https://forums.ldraw.org/forum-7.html)
+--- Forum: Parts Author Tools (https://forums.ldraw.org/forum-24.html)
+--- Thread: Custom road baseplates (/thread-23556.html)



Custom road baseplates - Michael Horvath - 2019-07-14

I am thinking of recreating this in native LDraw format:

http://lib.povray.org/searchcollection/index2.php?objectName=LegoRoad&contributorTag=SharkD

I plan on using bitmap textures for the surface features just to make things easier. I have one question though: does LDraw support repeating textures, or are they just one-offs? Thanks.


RE: Custom road baseplates - Rene Frijhoff - 2019-07-21

(2019-07-14, 13:29)Michael Horvath Wrote: I am thinking of recreating this in native LDraw format:

http://lib.povray.org/searchcollection/index2.php?objectName=LegoRoad&contributorTag=SharkD

I plan on using bitmap textures for the surface features just to make things easier. I have one question though: does LDraw support repeating textures, or are they just one-offs? Thanks.
LDraw itself doesn't support textures (or backgrounds for that matter).
All parts, prints and stickers need to be created through primitives in the form of colored lines, triangles and squares.
There are some programs used to create models that can support backgrounds through special metacommands/functions which are not part of LDraw.
There are also programs through which you can create the print/sticker (either by hand or through conversion) where you can you use the original file/rendering/photo for reference only.


RE: Custom road baseplates - Michael Horvath - 2019-07-21

(2019-07-21, 9:55)Rene Frijhoff Wrote: LDraw itself doesn't support textures (or backgrounds for that matter).
All parts, prints and stickers need to be created through primitives in the form of colored lines, triangles and squares.
There are some programs used to create models that can support backgrounds through special metacommands/functions which are not part of LDraw.
There are also programs through which you can create the print/sticker (either by hand or through conversion) where you can you use the original file/rendering/photo for reference only.

Thanks. For some reason I thought LDraw supported bitmap textures too. The center road stripe is going to be non-trivial to create without repeating textures.


RE: Custom road baseplates - Orion Pobursky - 2019-07-21

(2019-07-21, 13:18)Michael Horvath Wrote: Thanks. For some reason I thought LDraw supported bitmap textures too. The center road stripe is going to be non-trivial to create without repeating textures.

LDraw does support textures via the !TEXMAP extension:
https://www.ldraw.org/documentation/ldraw-org-file-format-standards/language-extension-for-texture-mapping.html

It's intended for patterned parts but I don't see any reason it couldn't apply to a model file as well.


RE: Custom road baseplates - Michael Horvath - 2019-07-22

(2019-07-21, 23:25)Orion Pobursky Wrote: LDraw does support textures via the !TEXMAP extension:
https://www.ldraw.org/documentation/ldraw-org-file-format-standards/language-extension-for-texture-mapping.html

It's intended for patterned parts but I don't see any reason it couldn't apply to a model file as well.

Which method would be best to map a single flat texture to a single triangle? Imagine a short section of road made of four vertices and two triangles. (The triangles need not be coplanar.) The texture should be oriented correctly in the direction of travel.

Can textures repeat? That would be very useful. Typically, the parametric functions I will be using create shorter road sections where the curvature is greater, and longer sections where the curvature is minimal. But the textures themselves need to always remain the same scale.