Saturday, April 28, 2007

Rendering Lego

I've been getting more and more of my "official" legos put into MLCad format. I'm then doing 4 views of the scene rendered in Pov-Ray. Most of the final detail renders in 720p resolution with high anti-aliasing and two-pass radiosity settings are taking just about 46 hours for each image. I'm really not happy with the anti-aliasing in Pov-Ray, and I may try to render an image at 4x and then anti-alias it down in a post process image tool.

One thing that has really made a difference, is lighting. This is a light ray tool, and the importance of good lighting is critical. Doing a two-bounce radiosity also adds a lot to illuminate the model, and the background (namely the sky sphere) makes a HUGE difference on how dark the scene is. A single point light, like the sun, only illuminates so much, and it can tend to glare and shine/reflect off the model surface. But with a blue or grey sky sphere, there is a lot of soft natural light that helps light the model (the difference between a black sky and a blue one is shocking on the render).

I sure hope the great efforts at LDraw.org continue to put out some of the GREAT models for all the lego parts. Without them, making all these great renders would be impossible.

Tuesday, October 24, 2006

Lego Star Wars 2 Cutscenes

I recorded all the cutscenes from Lego Star Wars 2, Episode IV, Episode V, and Episode VI and posted them up. Hope you like them.

Wednesday, September 27, 2006

POV-Ray work

Luke Skywalker's Landspeeder I have begun working on Pov-Ray renders of my virtual lego sets again. I'm trying to get some more realism into the scenes (like grass, sand, trees, realistic sky/cloud maps, height field mountains/terrain). I'm also beginning to put more than just the single model in the scenes (trying to get full realistic "scenes"). Eventually, I'll try to get some of the .mdl and .pov code up on the downloads page, but it is all changing so much right now (as I learn more things about ray tracing).



585


712


851


4500


4501


7166


7256


8859


Tuesday, September 26, 2006

New lego sets

UCS Star Destroyer I placed an order for just over $1200 of sets last week. They got here tonight. I picked up a ton of Star Wars stuff (both the UCS and new Star Destroyer, UCS AT-ST, UCS Darth Vaders Tie, UCS Sandcrawler, Jabba's Sail Barge) and some technic sets (Tow Rig, Crane Crawler, Dune Buggy (Tractor), Forklift). I can't believe how big that UCS Star Destroyer box is. I'm tempted to not open it (damn...I SHOULD just buy 2 or 3 more, because you KNOW they will be $500 as soon as Lego takes them off the market).

Monday, September 11, 2006

Improved Lighting and using radiosity in my renders

KoyanFound a really good article in the 4th Issue of Brick Journal about rendering legos, setting good lighting, and correcting colors. There is a great link to Lego Colors, with full include files. There is also a great Tutorial that shows various lighting progressions with POV-Ray on the 5571 Black Cat set (it looks like this was the bulk of what was used for the Brick Journal article). The renders look phenomenal with the switch to radiosity processing, however, they have pushed my render times up from under 30 minutes on a 1280x1024 AA scene, to over 6 hours on a P4-2.8GHz with 2GB of RAM! But the results are pretty impressive. I hope to get one of the new Intel Core Duo processors soon, and hopefully POVRay 3.7 with SMTP is working better there.

Below are some pictures of the difference between using radiosity and the best lighting I could come up with on two tractor models (851 and 8859). Note how, first of all, the more realistic colors look with the new includes, and also how much better the model is lit with the radiosity modes (you don't get dark shadows and specular blinding reflections quite as much, because most of the lighting is coming from a natural ambient radiosity light). New mode is on the left. Render times (for a 1280x1024 AA scene) went from around 25 minutes the old way to around 1:15 with tweeked radiosity (no HDR) "fast" settings. I can get it to look just a little better (although that is a bit subjective on different models) if I crank it up to the 2 pass hi quality, but that was taking over 6 hours per render. I also spent more time on the POVRay code and managed to get a better way to set the camera angle and use the clock to rotate through 4 different angles (45, 135, 225, 315) around a central focal point that is NOT on the origin (vector math actually comes in handy!!). Anyway, I'm playing with some other things, like adding barns and lego "fence posts" to the scene, and played around with some grass include files, but when you get too much grass patch in the scene, I end up blowing up even my 2GB render space...grin...and that is with VERY sparse grass and a very limited patch. Makes sense, once you start exponentially increasing the blade counts (at one point I was up over 2.5 billion tokens rendered in the scene...I don't know where it was when it failed).
New radiosity and old renders
New radiosity and old renders

Friday, March 10, 2006

Ray traced landscape scene thoughts

In my quest to produce better and better lego renders, I'm slowly getting sucked into a whole range of rendering things. It seems like ray tracing and terrain generation is right up my alley. The technical description, in a nutshell, for it is mathematically representing real world imagery through light tracing and fractal generation (for terrain) with less "artistic" concern or skills. Yup, that's pretty much me. I'm finding myself wondering how a certain cloud pattern I see on the way home would be mathematically represented, and what height field I would use (would it be 2 cloud layers or not). How did they (don't ask me who they is) get that cool light ray to shine through the misty cloud scene, and noticing how the snow is scattered on just one side of the mountains from a directional snow storm, and could I do that in terragen. Whoa...too freaky.

So, next, I'm looking for ways to get povray to render some of these height fields and landscapes rather than having to render them in Terragen, then match from the Terragen lighting to the pov render and mask off the model pov render (as well as shadows), which never looks "quite right" when the shadow is on a flat white floor, rather than the actual terrain, and combine all that in a post-process image alpha channel merge. It would be much easier to find a better way to render the whole scene (landscape and all) in povray. I know Forester can pull in simple model objects from povray and can render Terragen terrain files (though none of the surface map textures or clouds and cool water), but it is not nearly as good as povray or Terragen can do with the various objects separately. So, I'm looking for better ways to get believable landscape and cloud/water scenes rendered in povray. Looks like Christoph's Landscape of the Week is exactly what I want/need. Also, some more work by Jaime at The Persistance of Ignorance page. I'm going to have to spend some more time with it (and I even found some include files for believable lightening and rain effects for povray). Also, this is some pretty simplistic code sample for some random mountain chains that might work if you fix the camera in the correct place...just very specific and no clouds, or snow).

Monday, March 06, 2006

Scene Renders page

Got a new render with the fallen Rebel Soldiers and the Stormtroopers (without the helmets, still) put up on my Render Scenes Image Gallery page. There are also images there of work in Terragen landscape scenes.

Sunday, March 05, 2006

POV-Ray Lego Renders

I finally got some time this weekend to go back and work on some Lego POV-Ray renders. Unfortunately, it looks like a LOT of star wars parts are still missing from the Ldraw. Namely, there aren't ANY stormtrooper helmets defined. So, it is going to make designing my openening scene from Star Wars IV: A New Hope pretty hard. Grin. I got most of the set done for the part where Darth Vader strolls into Princess Leia's cruiser after blowing a hole in the access hatch and the Storm Troopers fight it out with the Rebels, while looking for the stolen plans to the Death Star. I'm going to add some mini-fig "place holders" until I figure out what to do for storm troopers...

Star Wars IV: A New Hope
50% White Lighting
POV-Ray scene.pov


One thing I'm finding with ray tracing, is that lighting is everything (duh...not sure why that didn't occur to me before). It was sort of obvious when doing the X-Wing in space before, but it is really becoming obvious with this latest render attempt. I really am having a hard time with how reflective the lego blocks are (I remember seeing this on the Snow Speeder too). I get too much texture shadow on some bricks (making them appear gritty/grainy, like on the upper slopes) and too much reflected light on others. I am going to try to add some ground fog, and maybe some smoke effects, which may help disperse the light a little, but the way this renders right now, it looks way too clear and reflective. Sigh. Below is an example of the original scene and my attempts to match it (full size is a 2.35:1 aspect ratio 1405x600 anti-aliased scene). I have to get this right before I can even THINK about annimating Darth (which I also did a quick little work on shown below)...this is going to be a lot harder than I thought.



My initial attempts to add some variable density scatter media to the full scene ended up taking 9 hours of render time to get through just 33% of the scene on my P4-2.8GHz with 2GB of RAM (with no real noticeable improvements on what I was seeing), so I canceled that. White fog just makes everything look like a flash bang went off. I think I'm going to have to spend some more time learning about POV-Ray and working with the lighting sources.

Sunday, December 18, 2005

Lego Star Wars

If you love Lego or Star Wars, you owe it to yourself to get a copy of Lego Star Wars for the XBox or other gaming platform. It can be found for $19 these days, and it is probably one of the best and well made games I've ever seen. It has good puzzles, awesome lego construction, follows the first three episodes quite well, great mixed game play and story line. Humorous Lego minifig animation, expression and acting, and great control (wish you could control the camera a bit, however).

Friday, December 02, 2005

Lego's and Mech's...mmmm

So, as if Lego's and computers wasn't about as nerdy as you could get, why not lump in sci-fi mechwarrior in with it. Cool!

http://www.legomechwarrior.net/

and

http://www.brickcommander.com/