LDView Image save based on real life size? - Printable Version +- LDraw.org Discussion Forums (https://forums.ldraw.org) +-- Forum: LDraw Programs (https://forums.ldraw.org/forum-7.html) +--- Forum: LDraw Editors and Viewers (https://forums.ldraw.org/forum-11.html) +--- Thread: LDView Image save based on real life size? (/thread-23731.html) |
LDView Image save based on real life size? - Cam's Bricks - 2019-10-31 If I wanted to export an image and have the export be 1:1 for real life scale at a given dpi is this possible? RE: LDView Image save based on real life size? - Travis Cobbs - 2019-10-31 (2019-10-31, 22:58)Cam\s Bricks Wrote: If I wanted to export an image and have the export be 1:1 for real life scale at a given dpi is this possible? In theory, yes, but in practice it would take some trial and error. You would want to use the minimum supported Field of View, which is 0.1. You'd then need to experiment with camera distances until you found the one that produced the desired size for a given DPI. So, on the command line, it might be something like so: <Path to LDView executable> -cg0,0,12345 -ca0.1 -SaveZoomToFit=0 -SaveWidth=2048 -SaveHeight=2048 -AutoCrop=1 -SaveSnapshots=1 my_file.ldr You would then tweak the 12345 above until you found the number that produced output at the size you want. You can adjust SaveWidth and SaveHeight based on the desired total output size. Note that the 0,0 above is for the latitude and longitude. You can change these to any value, but if you're looking for something that is "actual size", you'll often want them both to be divisible by 90. RE: LDView Image save based on real life size? - Travis Cobbs - 2019-10-31 It occurred to me that something is probably not obvious from the above: once you find a distance that is correct for the DPI you are interested in, you can use that value with any model. You may have to adjust SaveWidth and SaveHeight for physically larger models, but the distance calculation will be fixed for all models at a given DPI. RE: LDView Image save based on real life size? - Cam's Bricks - 2019-11-01 (2019-10-31, 23:45)Travis Cobbs Wrote: It occurred to me that something is probably not obvious from the above: once you find a distance that is correct for the DPI you are interested in, you can use that value with any model. You may have to adjust SaveWidth and SaveHeight for physically larger models, but the distance calculation will be fixed for all models at a given DPI.So if I work it out on a 2x2 Brick then I just expand the save width and height to fit whatever larger models I have? thanks for your quick response! RE: LDView Image save based on real life size? - Travis Cobbs - 2019-11-01 (2019-11-01, 0:43)Cam\s Bricks Wrote: So if I work it out on a 2x2 Brick then I just expand the save width and height to fit whatever larger models I have? That is correct. By setting the distance on the command line, it ensures that a given real world size in any model will take up the same number of pixels. AutoCrop=1 crops out all the blank areas around whatever you render. If you want the image to be a specific size, you can change the 1 to a 0, and it will then output an image that is the exact dimensions you specify via SaveWidth and SaveHeight. RE: LDView Image save based on real life size? - Roland Melkert - 2019-11-01 (2019-10-31, 23:40)Travis Cobbs Wrote: In theory, yes, but in practice it would take some trial and error. You would want to use the minimum supported Field of View, which is 0.1. You'd then need to experiment with camera distances until you found the one that produced the desired size for a given DPI.I was wondering (also as a result from lpub fov problems thread)... Why does LDView use such a low FOV value? With such a FOV it's like you extremely far away. I would measure the real life width and observer distance to get a realistic FOV. my 2cts. RE: LDView Image save based on real life size? - Travis Cobbs - 2019-11-01 (2019-11-01, 1:08)Roland Melkert Wrote: I was wondering (also as a result from lpub fov problems thread)... LDView does not support true orthographic mode, so using a very small FOV simulates it. For instructions, that is normally what you want. (As far as I know, all of LEGO's official instructions use orthographic projection.) For a 3D viewer, probably not so much, which is why LDView's default FOV is 45 degrees. Since the request here was for the brick to look actual size, I assumed that Cam's Bricks would also want an orthographic projection of the brick, and hence that is what I suggested. "Actual size" doesn't mean much if the bricks that are farther away are smaller than the ones that are close. RE: LDView Image save based on real life size? - Michael Horvath - 2020-02-03 (2019-11-01, 3:41)Travis Cobbs Wrote: LDView does not support true orthographic mode, so using a very small FOV simulates it. For instructions, that is normally what you want. (As far as I know, all of LEGO's official instructions use orthographic projection.) For a 3D viewer, probably not so much, which is why LDView's default FOV is 45 degrees. Since the request here was for the brick to look actual size, I assumed that Cam's Bricks would also want an orthographic projection of the brick, and hence that is what I suggested. "Actual size" doesn't mean much if the bricks that are farther away are smaller than the ones that are close. If we're assuming the render is orthographic, then the calculation should be pretty simple to do using a calculator or Excel. |