Jump to content


[Software] Bluerender, a rendering engine for LDD

LDD Rendering Blueprint Bluerender

  • Please log in to reply
757 replies to this topic

#1 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 28 May 2015 - 08:48 AM

Thanks to the open source SunFlow rendering system, i'm able to present:

Bluerender
A rendering engine for Lego Digital Designer.

How it works:

You just open the LXF file with Bluerender and click the big Render button. Optionally, you can choose an output png file and do a "preview" render: it will render the model in wireframe (useful for testing and framing your model). A set of default settings is provided that should looks good for most renders, but you can tinker with the scene description to use the full power of SunFlow.
Rendering is fast, a 1024x768 image usually take no more than five minutes on average pc.
This project came about as an experiment when i discovered that i could integrate SunFlow into Blueprint code with minimal effort. It's by no mean a competitor to Povray, which is slow but ultra-high quality, professional renderer.

Features:
  • Renders models, even big ones (tested on 12k piece models)
  • Completely customizable scene
  • Use camera settings from lxf file, so you can just frame your model in LDD.
  • Support for LDD decorations and decoration substitution
Limitations:
  • many :P
Documentation:

A wiki is available with plenty of documentation.

Using the renderer with default settings is quite simple. If you want to customize light, materials etc, you can change the scene description, simply edit the included scene.sc file. The syntax of the scene description is that of Sunflow and should be easy, there are some examples inside. Anyway some documentation is available here (note: it may be a little outdated at times).
You can optionally have a custom scene file for each model: simply copy the scene.sc file and name it like your lxf model (for example, if you have spaceship.lxf, create the file spaceship.sc, in the same folder of course).
You can override LDD decoration with your own adding lines like this in your scene file (the number is the decoration ID):
##CHANGEDECOR 59879 c:\path\to\custom\mydecor.png

Issue Tracker:

Have any bug or feature request? Be a good fellow and report it in our shiny issue tracker.

Requirements: Disclaimer:

Use at your own risk, i decline any responsability for anything that may happen to you using the program.

Download:

You can download Bluerender vers. 0005 here.

Flickr Group:

You can add your renders to the official Bluerender Lego Rendering group.

Running on Mac:

Some people were able to run Bluerender on Mac. Try the following instructions:
  • Remove all java installations
  • Install Java, but not from Oracle, from Homebrew instead. What's HomeBrew? I've no idea, but you can try following these instruction.
  • Open a command prompt/shell/terminal, cd to the folder where you unzipped Bluerender
  • Enter the following command: java -cp "bin/*" bluerender.BlueRender
  • If the program manage to start, it will ask you to locate the db.lif file, you should find it here: /Users/USERNAME/Library/Application Support/LEGO Company/LEGO Digital Designer/db.lif

Special thanks:
to Bublible for his help with the renderer.
to Jackalope for his help testing the app on Mac.
to Fabrizio for his precious time as beta tester.


Screenshot:

Posted Image

Example Output:
(these models are taken from the web, not mine)

Posted Image

Posted Image

Posted Image

Posted Image

Posted Image

More examples can be found here.

Here you can find a 3027x2304 render of a 12000 parts model, took about 30 minutes.

Changelog:
0005:
  • Black is now real black #93
  • Glass is now lighter #82 (thanks to bublible)
  • Implemented bublible chrome materials #73 (thanks to bublible)
  • Corrected NPE with invalid color codes (default to white) #86
  • Implemented aliases parsing and caching #81, #68
  • 360° rotation renders #71
  • can now place light with transform{} blocks #72 (thanks to bublible)
  • overwrite and other options are now persisted #64
  • basic parameters are now in the app #65
  • changed default background to white
0004:
  • Janino shaders now work
  • Automatic aspect ratio
  • Overwrite without asking checkbox
  • No longer "forget" some flexible elements
  • Correct background color reflection for mirrors (no more black)
0003:
  • Model loading is fast again (even faster!)
  • Some textured glass support (not perfect yet)
  • Clickable scene label (opens the scene file)
  • Self adjusting plane height
  • Search file in db folder beside db.lif
  • Bugfixes
0002:
  • remembers last used folder
  • ask before overwrite
  • use a single scene.sc file instead of three files for setup, materials, lights
  • scene files are not shown on the program anymore (was more confusion than anything)
  • optional per-model scene file
  • LDD decoration support
  • custom decoration support
0001:
  • initial release

Edited by msx80, 23 September 2015 - 10:55 AM.

Posted ImagePosted Image Posted Image

#2 Calabar

Calabar

    Posts: 2506
    Joined: 11-April 10
    Member: 10232
    Country: Italy

Posted 28 May 2015 - 10:38 AM

Thanks for this tool! I really appreciate.  :grin:

Two fast questions:
- LDD is among requisites, it it necessary that LDD is installed on the machine that performs the rendering?
- Is sunflow integrated in the package? (I didn't get it yet)

Edited by Calabar, 28 May 2015 - 12:23 PM.

"Official LEGO Sets made in LDD" topic: Read guidelines before posting!

#3 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 28 May 2015 - 10:46 AM

View PostCalabar, on 28 May 2015 - 10:38 AM, said:

Thanks for this took! I really appreciate.  :grin:

Two fast questions:
- LDD is among requisites, it it necessary that LDD is installed on the machine that performs the rendering?
- Is sunflow integrated in the package? (I didn't get it yet)

- The program really only need the database file of LDD to read geometries etc. If LDD is installed, it will autolocate it. If it's not installed, you will be asked to locate the db.lif file manually. This way you can simply copy the file to a new machine without installing the software (that's how i use it at work.. but don't tell around :P). The file by default is installed under: C:\Users\USERNAME\AppData\Roaming\LEGO Company\LEGO Digital Designer\db.lif

- Yes, Sunflow is integrated, no need to download anything else.
Posted ImagePosted Image Posted Image

#4 Mario Pascucci

Mario Pascucci

    Posts: 67
    Joined: 02-November 11
    Member: 21317
    Country: Italy

Posted 28 May 2015 - 11:07 AM

Quite impressive!

Really a good work :thumbup:

#5 ___

___

    Posts: 1681
    Joined: 23-May 13
    Member: 55103

Posted 28 May 2015 - 11:57 AM

Not bad, not bad, tho definitely if you can inspire with ldd2povray as for the interchangeable decors functionality...ehm, I mean at least the decors ability intself for first, of course. :laugh: :thumbup:

#6 sparkart

sparkart

    Posts: 149
    Joined: 11-June 10
    Member: 11416

Posted 28 May 2015 - 04:26 PM

Nick, my compliments for another nifty program.  I've had very satisfying results with Bluerender, the combo of speed and quality is really good.
Posted Image
McLaren MLP7 by SPARKART!, on Flickr.
Posted Image Want your  own TRON Light Cycle? Visit LEGO Ideas!
SPARKART on Flickr
sparkart.storenvy.com
facebook.com/sparkart.stuff

#7 bbqqq

bbqqq

    Posts: 842
    Joined: 01-November 10
    Member: 14020

Posted 29 May 2015 - 08:05 AM

Thank for this great tool! Train model below (4,238 bricks) took only  1 min 39 sec!
This rendering speed is good for making animation.

Suggestions:
- Trans clear part material is too dark. (train headlight & windows of nanoblock castle below)
- Error if render scene with many kind of different bricks. (out of memory?)

The road part model by Dilvish.
Posted ImageBluerender0001 test by Nachapon S., on Flickr

Posted ImageCASTLE 5.lxf by Nachapon S., on Flickr

Edited by bbqqq, 29 May 2015 - 08:32 AM.

42043 + BlenderGuru_Lighting_StarterScene / CS de_dust / new rooftile concept / Mr. gold concept / My new brick designs

Posted Image  Posted ImagePosted Image  Posted Image  Posted Image

YouTube Lego Pinball  YouTube Lego Bowling  My Flickr

#8 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 29 May 2015 - 08:18 AM

wow, that's a sweet model and a great render! :) glad to see it works!
Posted ImagePosted Image Posted Image

#9 mzoli

mzoli

    Posts: 162
    Joined: 24-January 14
    Member: 119762
    Country: Hungary

Posted 29 May 2015 - 08:30 AM

Hi msx80,

The pictures are quite impressive! As a pure LDD builder I wanted to give a try.
However, the lwjgl32.dll file in the native directory is infected by a Trojan according to my Symantec Endpoint Security:
Trojan.Gen.SMH.2

Please take a look on it, a clean package would be better. :wink:

Thanks,
Zoli

#10 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 29 May 2015 - 08:37 AM

omg really?? i'll take a look right now. I downloaded the new library just a couple of days ago
Posted ImagePosted Image Posted Image

#11 Bob De Quatre

Bob De Quatre

  • Am I missing the Fifth?


    Posts: 5123
    Joined: 14-July 12
    Member: 29683
    Country: France

Posted 29 May 2015 - 09:00 AM

I also got security warning on all the included .dll :sceptic:

Posted Image

Posted Image


New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide


#12 bbqqq

bbqqq

    Posts: 842
    Joined: 01-November 10
    Member: 14020

Posted 29 May 2015 - 09:07 AM

View Postmsx80, on 29 May 2015 - 08:18 AM, said:

wow, that's a sweet model and a great render! :) glad to see it works!
Thanks, just make some more quick test.
A 3876 pcs death star took 3 min 22 sec.
I tried to render two death star at once but error. After delete some unseen part to 5842 bricks, two partial 10188 took 2 min 55 sec.
Posted Imagedsl.lxf by Nachapon S., on Flickr

Posted ImageBluerender0001 test 2 by Nachapon S., on Flickr

Posted Imageerr by Nachapon S., on Flickr

Edited by bbqqq, 29 May 2015 - 09:14 AM.

42043 + BlenderGuru_Lighting_StarterScene / CS de_dust / new rooftile concept / Mr. gold concept / My new brick designs

Posted Image  Posted ImagePosted Image  Posted Image  Posted Image

YouTube Lego Pinball  YouTube Lego Bowling  My Flickr

#13 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 29 May 2015 - 09:28 AM

View PostBob De Quatre, on 29 May 2015 - 09:00 AM, said:

I also got security warning on all the included .dll :sceptic:

Can you show me the warnings? What software are you using? I'm
I just ran a scan with Norton Power Eraser and it found nothing. I also re-downloaded the lwjgl binaries from here and it looks identical to the one i have here. I'm downloading Symantec Endpoint Protection to check with it too.

Ok, i searched the lwjgl forum and it looks like the problem is on the library itself, they report the same warning about Trojan.Gen.SMH.2

http://forum.lwjgl.o...g30895#msg30895

I'll ask there, but i'm starting to think it's a false positive
Posted ImagePosted Image Posted Image

#14 Bob De Quatre

Bob De Quatre

  • Am I missing the Fifth?


    Posts: 5123
    Joined: 14-July 12
    Member: 29683
    Country: France

Posted 29 May 2015 - 10:30 AM

View Postmsx80, on 29 May 2015 - 09:28 AM, said:

I'll ask there, but i'm starting to think it's a false positive
That's most probable... I have crappy Norton Internet Security at work. It reported the trojan problem on lwjgl32.dll, and marked the other dll as unsafe.

Posted Image

Posted Image


New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide


#15 iceleftd

iceleftd

    Posts: 80
    Joined: 23-January 12
    Member: 24772
    Country: US

Posted 29 May 2015 - 01:03 PM

Same problem Bob reported.

#16 iceleftd

iceleftd

    Posts: 80
    Joined: 23-January 12
    Member: 24772
    Country: US

Posted 29 May 2015 - 02:09 PM

Update: I tried getting the standard lwjgl distribution and had the same problem.  I decided to bypass Norton temporarily and use the DLLs from the lwjgl distribution.

I did a comparison with a recent POV-Ray rendering at high quality.  Bluerenderer was about 10x faster (!), but the quality was much lower.

What expectations should I have for this project?  Is it intended to be a faster replacement for POV-Ray (someday), or just something to make quicker (but less fancy) renderings?

A couple of small observations...
  • readme.txt still references Blueprint instead of Bluerenderer
  • When I changed the resolution in the setup to match the resolution of my POV-Ray image (for comparison), the result was that my image was stretched to fit the new aspect ratio (all the bricks were flatter in this case).  Not what I expected, and I suspect not what anyone wants.


#17 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 29 May 2015 - 02:43 PM

View Posticeleftd, on 29 May 2015 - 02:09 PM, said:

I did a comparison with a recent POV-Ray rendering at high quality.  Bluerenderer was about 10x faster (!), but the quality was much lower.

What expectations should I have for this project?  Is it intended to be a faster replacement for POV-Ray (someday), or just something to make quicker (but less fancy) renderings?


The second one :) If high quality could be made faster, they would have already made it in POV-Ray. It will never be a replacement for it. But let's say you make a small model and you want to show it quickly on flickr, you can do it right away without having your pc work all night and waiting the next day.

What were the quality problem you noticed? Maybe it's something i can fix. One thing i noticed is that sometime, depending on the direction of your model, you get the sunlight "behind" the model and you see the unlit side, for an unpleasant result. Turning the sun direction in the "light" settings  can fix this.

View Posticeleftd, on 29 May 2015 - 02:09 PM, said:

A couple of small observations...
  • readme.txt still references Blueprint instead of Bluerenderer
  • When I changed the resolution in the setup to match the resolution of my POV-Ray image (for comparison), the result was that my image was stretched to fit the new aspect ratio (all the bricks were flatter in this case).  Not what I expected, and I suspect not what anyone wants.

Ops, i have to fix the readme :P

Uhm there's an "aspect" ratio in the "camera" setting under "Setup". Have you changed that too?  I'll see if i can make it automatic, it's quite obvious that it should match the screen resolution.

Thanks for your feedback and for taking the risk despite the warnings. I hope they'll solve the problem soon :)
Posted ImagePosted Image Posted Image

#18 bbqqq

bbqqq

    Posts: 842
    Joined: 01-November 10
    Member: 14020

Posted 29 May 2015 - 04:04 PM

26,000 pcs took only 6 min render time! (by average gaming notebook)
Posted ImageBluerender0001 test 10 by Nachapon S., on Flickr

Edited by bbqqq, 29 May 2015 - 04:08 PM.

42043 + BlenderGuru_Lighting_StarterScene / CS de_dust / new rooftile concept / Mr. gold concept / My new brick designs

Posted Image  Posted ImagePosted Image  Posted Image  Posted Image

YouTube Lego Pinball  YouTube Lego Bowling  My Flickr

#19 ___

___

    Posts: 1681
    Joined: 23-May 13
    Member: 55103

Posted 29 May 2015 - 04:23 PM

View Postmsx80, on 29 May 2015 - 02:43 PM, said:

The second one :) If high quality could be made faster, they would have already made it in POV-Ray.
Ehm, not quite true: see The Foundry MODO rendering engine for example (but it's payed application costing like 1000€, of course) :wink:

#20 iceleftd

iceleftd

    Posts: 80
    Joined: 23-January 12
    Member: 24772
    Country: US

Posted 29 May 2015 - 07:44 PM

View Postmsx80, on 29 May 2015 - 02:43 PM, said:

What were the quality problem you noticed? Maybe it's something i can fix. One thing i noticed is that sometime, depending on the direction of your model, you get the sunlight "behind" the model and you see the unlit side, for an unpleasant result. Turning the sun direction in the "light" settings  can fix this.

I don't think it's a "problem".  Here's a comparison image:

Posted ImageBlueRender comparison by iceleftd, on Flickr

POV has more definition (bevels between bricks, for example) and better shading, but those are white tables and they look light bley in POV.  Seeing some other images in BlueRender (by Nachapon, for example), I'm beginning to like the look of BlueRender better.


View Postmsx80, on 29 May 2015 - 02:43 PM, said:

Uhm there's an "aspect" ratio in the "camera" setting under "Setup". Have you changed that too?  I'll see if i can make it automatic, it's quite obvious that it should match the screen resolution.
Making the aspect ratio match the resolution fixed the problem (thanks).  I think the best solution is to have the aspect ratio default to the resolution size but let it be overridden in the setup file (and then comment out that value in the default file).


I don't know if this is the right forum for bug requests, but here's another small one: It really should prompt you before overwriting an existing image file.

#21 Bob De Quatre

Bob De Quatre

  • Am I missing the Fifth?


    Posts: 5123
    Joined: 14-July 12
    Member: 29683
    Country: France

Posted 29 May 2015 - 07:47 PM

Did some tests too and I like the results :classic:

Posted Image

Posted Image


New Member? Read This | Questions? Need Help? Ask Here

Site Guidelines | Eurobricks FAQ | Visual User Guide


#22 ___

___

    Posts: 1681
    Joined: 23-May 13
    Member: 55103

Posted 29 May 2015 - 07:48 PM

@msx80
Well, I have to admit your SW is doing quite excellent job for my quick renders of MOCs' modularities - it is REALLY QUICK and tho without decors for some reason they look very nice almost artistic like :sweet: , so thanx once more and hoping you will definitely implement that decoration support (I will post my BlueRender renders quite soon today, like a few minutes later in my Sci-Fi subforum posts so you can check them there if you like) :thumbup:

#23 mzoli

mzoli

    Posts: 162
    Joined: 24-January 14
    Member: 119762
    Country: Hungary

Posted 29 May 2015 - 08:54 PM

@msx80,

I saw the answer of the lwjgl forum admin, it seems the Norton product family is giving false positive alert for the dll.

So I created a quick render of my latest builds.

42038 Arctic Truck. 888 pcs was rendered in 3:30 (800x600) on Intel Core i5-3320M (2 cores at 2.6GHz). Java.exe took 1GB of RAM.
Posted Image

42028 Arctic Truck B
Posted Image

5580 Highway Rig
Posted Image

42029 Customized Pick-up Truck (1060 pcs, 4 min)
Posted Image

42006 Excavator (694 pcs, 2:30 min)
Posted Image
The tracks are not fully visible although they are above the horizon in the LXF file.

I think the Transparent items needs some fine tuning, they are almost looking invisible/black.
But I'm very satisfied with the results!

Thank you for your great software! :wink:

Edited by mzoli, 29 May 2015 - 09:47 PM.


#24 ___

___

    Posts: 1681
    Joined: 23-May 13
    Member: 55103

Posted 29 May 2015 - 09:07 PM

View Postmzoli, on 29 May 2015 - 08:54 PM, said:

@msx80,
I saw the answer of the lwjgl forum admin, it seems the Norton product family is giving false positive alert for the dll.
So stop using that pseudo AV and use something that really works without giving you error on false positives and is even for free like for example avast! :wink:
I was using Norton, AVG, even NOD many years back but all of them had some sorts of problems like the one many of you are mentioning here, but since I am using avast! there are no such probs lakily anymore (I am using BlueRender with the AV without any false positives here). :thumbup:

Edited by bublible, 29 May 2015 - 09:08 PM.


#25 msx80

msx80

    Posts: 280
    Joined: 15-May 13
    Member: 53405

Posted 29 May 2015 - 11:05 PM

Thanks everybody for the great feedback!

View Postbbqqq, on 29 May 2015 - 04:04 PM, said:

26,000 pcs took only 6 min render time! (by average gaming notebook)
Posted ImageBluerender0001 test 10 by Nachapon S., on Flickr

Woah, that's just huge :O

View Posticeleftd, on 29 May 2015 - 07:44 PM, said:

I don't think it's a "problem".  Here's a comparison image:

Posted ImageBlueRender comparison by iceleftd, on Flickr

POV has more definition (bevels between bricks, for example) and better shading, but those are white tables and they look light bley in POV.  Seeing some other images in BlueRender (by Nachapon, for example), I'm beginning to like the look of BlueRender better.



Making the aspect ratio match the resolution fixed the problem (thanks).  I think the best solution is to have the aspect ratio default to the resolution size but let it be overridden in the setup file (and then comment out that value in the default file).


I don't know if this is the right forum for bug requests, but here's another small one: It really should prompt you before overwriting an existing image file.

Well they're very different. LDDtoPovray does some processing inbetween LDD and Povray, such as the bevels, or the Lego logo, primitive substitution etc, while bluerender just feed the original geometries as-is to the renderer. Indeed without bevels the bricks just merge together :)

I noted your suggestions, they'll be in the next release

View PostBob De Quatre, on 29 May 2015 - 07:47 PM, said:

Did some tests too and I like the results :classic:

Show us something :)

View Postbublible, on 29 May 2015 - 07:48 PM, said:

@msx80
Well, I have to admit your SW is doing quite excellent job for my quick renders of MOCs' modularities - it is REALLY QUICK and tho without decors for some reason they look very nice almost artistic like :sweet: , so thanx once more and hoping you will definitely implement that decoration support (I will post my BlueRender renders quite soon today, like a few minutes later in my Sci-Fi subforum posts so you can check them there if you like) :thumbup:

You're welcome! :) i've seen the renders in sci-fi, great models! Decors are on the way, both in blueprint and bluerender :)

View Postmzoli, on 29 May 2015 - 08:54 PM, said:

@msx80,

I saw the answer of the lwjgl forum admin, it seems the Norton product family is giving false positive alert for the dll.

So I created a quick render of my latest builds.

...

The tracks are not fully visible although they are above the horizon in the LXF file.

I think the Transparent items needs some fine tuning, they are almost looking invisible/black.
But I'm very satisfied with the results!

Thank you for your great software! :wink:

Great renders! The red pickup really shines, while the arctic truck suffer from the "sun behind the model" problem. For the excavator: LDD lowers the ground "on-demand" to adapt it to the lowest point of the model while bluerender does not, it's fixed at height 0. You can change it manually in the "setup" panel, there's a comment there that explains how.

Yes, the trasparents are way too dark, but i haven't been able to find a setting that looked better. If anyone want to tinker with the "materials" tab and find some decent values :)
Posted ImagePosted Image Posted Image





Also tagged with one or more of these keywords: LDD, Rendering, Blueprint, Bluerender

1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users