Welcome, Guest |
You have to register before you can post on our site.
|
Online Users |
There are currently 1041 online users. » 1 Member(s) | 1035 Guest(s) Applebot, Baidu, Bing, Google, Yandex, Orion Pobursky
|
|
|
Patterned part reminder |
Posted by: Orion Pobursky - 2020-10-26, 4:31 - Forum: Parts Authoring
- Replies (3)
|
 |
Since I've seen a few new parts where this is not the case and as a reminder to all authors:
All patterned parts currently on the PT need to have, at a minimum, a !KEYWORDS entry of: Set <set number>. If you authored (or review) a part where this is not the case no hold is needed but please email Chris to fix the header. I also highly encourage a Bricklink or Rebrickable number as it makes both my (with the PBG generator) and the Rebrickable's parts admin's life easier.
Please see:
https://www.ldraw.org/article/512.html#pattern_key
|
|
|
POV-Ray rendering in 2020 |
Posted by: Ber - 2020-10-21, 3:07 - Forum: Rendering Techniques
- Replies (4)
|
 |
I've been exploring lego rendering using the LDraw system over the last few months, and it's been quite a journey. I've found several guides online from over the last ten years that have had various tips on how to get a good render using LDraw & POV-Ray. There was a lot of great info in them, but some of the advice was now out of date, and I had to spend a while comparing info between guides to get a good process.
So, now that I have a process that I'm pretty happy with, I thought I'd share it here for other's interest, and feedback is also welcome.
0. Install the LDraw AIOI package
Install whatever designers you like, and for rendering I am using LDView, the LDraw parts library, and Pov-Ray 3.7. (I am not using any of the POV-Ray alternatives such as Mega-Ray etc, as it seems POV-Ray 3.7 is newer / better than them.)
After installing that, I also install the latest version of LDView I can get, newer than what is in the LDraw AIOI at time of writing, which does change the .pov file exported, it seems to use new features of POV-Ray 3.7. I downloaded it from here: https://github.com/tcobbs/ldview/release...v4.4_Beta2
1. Generate the POV-Ray file in LDView
When LDView exports to a .pov file, it knows about high resolution part models designed for rendering, which results in a much better quality render. (It's doing this by using LGEO.xml to map to .inc part files, instead of using the standard / editor .dat part definition files).
The process to generate the pov file is to open your model file (probably an .ldr file) in LDView, then choose file menu, export...
I don't edit any of the options here, just save the file
2. Set up POV-Ray to render larger resolutions
You'll probably want to render a larger file than what POV-Ray offers by default. For one thing, the Anti-Aliasing in POVRay is not great. So, render at 2x the dimensions you want, then resize down in a program that has bicubic (or other better) resize algorithm (eg. I use the free image editor, Paint.net).
So, to do this, you need to make a one-time edit to a file that POV-Ray reads to get the render size options to offer. The file will be located at: C:\Users\[yourusername]\Documents\POV-Ray\v3.7\ini\quickres.ini
Making sure POV-Ray is closed at the time, open that file into a text editor.
If you wanted to render at 1920x1080 as you final resolution, you would want an option to render initially as 3840x2160, which you would add to the end of the file as:
[3840x2160, No AA]
Width=3840
Height=2160
Antialias=Off
Once you've added this once, save and close the file. Now this size will be available all the time in POV-Ray as a render option - which we'll get to in a minute.
3. Edit your .pov file in POV-Ray - change it to use Radiosity rendering
The default lighting provided in the .pov file from LDView has a standard 3-lights lighting setup, which casts some fairly strong shadows. I prefer to use an alternative lighting option called Radiosity rendering. To change to this I make two simple copy-paste changes at the top of .pov file, which I can do exactly the same on any file I want to render. They are:
Open the .pov file in POV-Ray first. Look at the top of the file, right below the comments, for these two lines:
Code: #version 3.7;
#if (version >= 3.7) global_settings {assumed_gamma 1} #end
Replace them with (don't miss the scroll bar and extra lines here):
Code: #version 3.7;
#include "rad_def.inc"
global_settings {
max_trace_level 10
radiosity {
Rad_Settings(Radiosity_Final, on, off)
}
assumed_gamma 1
}
light_source { // X, Y, Z
<-1000, -1500, -1000>
color rgb 0.5
area_light 200, 200, 10, 10
jitter
}
#declare LDXSkipLight1 = 1;
#declare LDXSkipLight2 = 1;
#declare LDXSkipLight3 = 1;
Then scroll down just a bit to the // Camera settings section, and look for these 5 lines:
Code: #ifndef (LDXFloorR) #declare LDXFloorR = 0.8; #end // Floor Red
#ifndef (LDXFloorG) #declare LDXFloorG = 0.8; #end // Floor Green
#ifndef (LDXFloorB) #declare LDXFloorB = 0.8; #end // Floor Blue
#ifndef (LDXFloorAmb) #declare LDXFloorAmb = 0.4; #end // Floor Ambient
#ifndef (LDXFloorDif) #declare LDXFloorDif = 0.4; #end // Floor Diffuse
Replace with:
Code: #ifndef (LDXFloorR) #declare LDXFloorR = 1; #end // Floor Red
#ifndef (LDXFloorG) #declare LDXFloorG = 1; #end // Floor Green
#ifndef (LDXFloorB) #declare LDXFloorB = 1; #end // Floor Blue
#ifndef (LDXFloorAmb) #declare LDXFloorAmb = 0; #end // Floor Ambient
#ifndef (LDXFloorDif) #declare LDXFloorDif = 0.9; #end // Floor Diffuse
4. Do a test render
The final render can take a while, even on a multi-core i7 cpu, so you want to be sure you're happy. So do a small test render to make sure its looking right.
You do this by, in POV-Ray, in the dropdown list of resolutions in the top left corner choose a small size (eg 800x600) , then press the Run icon across the top toolbar.
5. Do the final render
Once a test render looks good, time to do the final render.
To do this, go back to that dropdown list of resolutions, and look for your large size you added earlier, and choose that. Then press Run again. For a fairly simple model, the render will probably take 15 mins to an hour, depending on your hardware.
6. Resize to your final size
Open your resulting .png file in your image editing program, and resize it down 50% to your final resolution, and save.
So that's my process, I think it produces pretty nice results, with a fairly simple workflow per image. I hope someone finds it helpful. And also would be interested to hear what anyone else is doing with POV-Ray now in 2020.
|
|
|
LDraw AIOI, LDView, the LDraw parts library, and LGEO.xml |
Posted by: Ber - 2020-10-21, 2:28 - Forum: LDraw Editors and Viewers
- Replies (4)
|
 |
I've been learning my way around rendering using LDView & POV-Ray. Along the way I've learnt about the basic/editor .dat part files, the much more detailed LGEO .inc files, and how LDView uses LGEO.xml to know when .inc part files are available, then the .dat files as a fallback in other cases. (Side note: Please let me know if I have any of that wrong!)
What I've discovered in my adventures is that the LGEO.xml file in use seems to be the one that resides in the LDView folder (C:\program files (x86)\Ldraw\LDView\), which comes with LDraw AIOI. I think in theory this should be synchronised with the .inc files available in the Ldraw parts library also installed in LDraw AIOI. However, for at least one part - 2815 technic tyre - the .inc file is in my parts library, but missing from my LGEO.xml file.
I have edited it in manually, and now my pov renders use the high resolution part.
I wonder though if I am missing something. How is LGEO.xml normally kept up to date / edited? Is there any automated tools, or official downloads that should maintain and update it?
|
|
|
James Jessiman Memorial Award for 2020 awarded to Lasse Deleuran |
Posted by: Orion Pobursky - 2020-10-20, 15:15 - Forum: LDraw.org Announcements
- Replies (10)
|
 |
The LDraw.org Steering Committee is pleased to announce that the 2020 James Jessiman Memorial Award (JJMA) recipient is Lasse Deleuran.
Lasse has been instrumental in bringing LDraw rendering to web browsers. His WebGL software package, buildinginstructions.js, powers the part preview on the Parts Tracker, the model viewer on the LDraw.org main site, instructions on Rebrickable, and his own site, Brickhub.org (and maybe more that I don't know about). His can do attitude, willingness to help, and passion for LDraw has helped to improve LDraw's usability and visibility. In addition to all of this, he has graciously made his code open and sharable to allow others use it in their projects.
Learn more about Lasse in his wiki bio:
https://wiki.ldraw.org/wiki/Meet_Lasse_Deleuran
On behalf of the LDraw Steering Committee, we thank Lasse for his contributions and look forward to working with him in the future.
Orion Pobursky
|
|
|
Some Gear Rotations are "disconnected" |
Posted by: NikosSprocket - 2020-10-18, 7:23 - Forum: LDraw Editors and Viewers
- Replies (7)
|
 |
Hello
I am new with LDCad (but not with CADD) and I am baffled with the following issue.
For some gears, when I try to rotate them so the teeth mess correctly, the hub and the teeth are "disconnected"!
For example for 32269 if I rotate it clockwise the hub will follow my rotation but the teeth will rotate counter-clockwise!
Another example for 3648b I can only rotate the hub but not the teeth.
I have tried both using the GUI rotation {R} and the entry {Ctr-r} with the same result.
Am I missing something?
Nikos
|
|
|
Wiki fixed and site updates |
Posted by: Orion Pobursky - 2020-10-17, 1:53 - Forum: LDraw.org Announcements
- No Replies
|
 |
I've updated the wiki to the latest Mediawiki version. Apparently, some backend stuff has been broken for some time. If you were trying to create and account or edit and encountered an error, I apologize.
In related news, the wiki.ldraw.org domain will be retired soon and the wiki moved to www.ldraw.org/wiki. I'll be doing the same thing with the forums and omr. These changes will happen as soon as I've tested and verified that nothing will break.
|
|
|
|