To LUGNET HomepageTo LUGNET News HomepageTo LUGNET Guide Homepage
 Help on Searching
 
Post new message to lugnet.cadOpen lugnet.cad in your NNTP NewsreaderTo LUGNET News Traffic PageSign In (Members)
 CAD / 14469
Subject: 
Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 02:11:02 GMT
Viewed: 
10421 times
  
I’m sure this has been done before, but I realized an amusing application of LDView’s “fly through” camera mode is to look at the world through the eyes of a minifig, particularly from perspectives where you couldn’t normally fit a camera (or your eyeballs).

Here’s a quick example: sitting in a LEGO cockpit looking out at your wingman.

look ma, no hands!

Travis, since I already had the LDView code set up I reduced the strafeAmount and motionAmount values used in ModelWindow::processKeyDown to 0.05. This made it much easier to make fine adjustments to the camera position; even smaller values may be useful. Perhaps it would be worth adding a Preferences setting to control these values?

(On a side note, I haven’t tinkered much more with Qt or a Universal LDView build. It’s still in the rotation, but I just haven’t gotten back to it.)

Anyway, thought this was fun so I thought I would share. Anyone else have any similar examples?

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 02:24:53 GMT
Viewed: 
5472 times
  
In lugnet.cad, Jim DeVona wrote:
   I’m sure this has been done before, but I realized an amusing application of LDView’s “fly through” camera mode is to look at the world through the eyes of a minifig, particularly from perspectives where you couldn’t normally fit a camera (or your eyeballs).

Here’s a quick example: sitting in a LEGO cockpit looking out at your wingman.

look ma, no hands!

Anyway, thought this was fun so I thought I would share. Anyone else have any similar examples?

That’s a nice pic Jim.

I seem to recall there was a view from inside a Santa Fe car a while back, can’t remember who rendered it though :(

ROSCO


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 05:30:35 GMT
Viewed: 
5731 times
  
In lugnet.cad, Jim DeVona wrote:
   Here’s a quick example: sitting in a LEGO cockpit looking out at your wingman.

look ma, no hands!

It’s worth noting that if you get the POV-Ray camera info from LDView and render in POV-Ray, you should get exactly the same view there (assuming you use the same aspect ratio).


   Travis, since I already had the LDView code set up I reduced the strafeAmount and motionAmount values used in ModelWindow::processKeyDown to 0.05. This made it much easier to make fine adjustments to the camera position; even smaller values may be useful. Perhaps it would be worth adding a Preferences setting to control these values?

The sensitivity is pretty messed up. It doesn’t properly track the frame rate, so if you have a high frame rate it goes too fast, and if you have a low frame rate, it goes too slow. I think the proper solution would be for me to fix that.

--Travis


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 14:46:10 GMT
Viewed: 
5810 times
  
In lugnet.cad, Travis Cobbs wrote:
   In lugnet.cad, Jim DeVona wrote:
   Here’s a quick example: sitting in a LEGO cockpit looking out at your wingman.

look ma, no hands!

It’s worth noting that if you get the POV-Ray camera info from LDView and render in POV-Ray, you should get exactly the same view there (assuming you use the same aspect ratio).

I was thinking of that. I tried it briefly the other night but I must have had a different aspect ratio, because the rendering appeared far outside the ship. I’m getting up to speed on POV-Ray, though, so I’ll definitely try it again.

  
   Travis, since I already had the LDView code set up I reduced the strafeAmount and motionAmount values used in ModelWindow::processKeyDown to 0.05. This made it much easier to make fine adjustments to the camera position; even smaller values may be useful. Perhaps it would be worth adding a Preferences setting to control these values?

The sensitivity is pretty messed up. It doesn’t properly track the frame rate, so if you have a high frame rate it goes too fast, and if you have a low frame rate, it goes too slow. I think the proper solution would be for me to fix that.

Ah, I see. Sounds good. Yes, initially the camera would jump across or out of the cockpit at the slightest touch. I changed the value so I could nudge it around easier within that area.

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 16:42:20 GMT
Viewed: 
5912 times
  
In lugnet.cad, Jim DeVona wrote:
   In lugnet.cad, Travis Cobbs wrote:
   It’s worth noting that if you get the POV-Ray camera info from LDView and render in POV-Ray, you should get exactly the same view there (assuming you use the same aspect ratio).

I was thinking of that. I tried it briefly the other night but I must have had a different aspect ratio, because the rendering appeared far outside the ship. I’m getting up to speed on POV-Ray, though, so I’ll definitely try it again.

The aspect ratio shouldn’t make enough of a difference to put the camera out of the ship. It should only change the cropping. If you have the same aspect ratio, you should should get nearly pixel-perfect alignment of all polygons that don’t involve reflection or refraction. I’m not sure if this is a Mac-specific bug, or if you did something that I haven’t done in my testing on Windows. Here’s an example of what I’m talking about:

LDView (wide picture):



POV-Ray (640x480):



LDView (640x480):



--Travis


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 17:35:45 GMT
Viewed: 
5952 times
  
In lugnet.cad, Travis Cobbs wrote:
   In lugnet.cad, Jim DeVona wrote:
   In lugnet.cad, Travis Cobbs wrote:
   It’s worth noting that if you get the POV-Ray camera info from LDView and render in POV-Ray, you should get exactly the same view there (assuming you use the same aspect ratio).

I was thinking of that. I tried it briefly the other night but I must have had a different aspect ratio, because the rendering appeared far outside the ship. I’m getting up to speed on POV-Ray, though, so I’ll definitely try it again.

The aspect ratio shouldn’t make enough of a difference to put the camera out of the ship. It should only change the cropping. If you have the same aspect ratio, you should should get nearly pixel-perfect alignment of all polygons that don’t involve reflection or refraction. I’m not sure if this is a Mac-specific bug, or if you did something that I haven’t done in my testing on Windows.

You’re right - it does work. I retried it with L3P output and the view is positioned correctly. My previous effort used POV-Ray code from Anton’s converter. That’s not necessarily the reason it didn’t work before, though: it was late and I was tired. At any rate, LDView is certainly exonerated (not that it was accused).

This isn’t the exact same position as my previous LDView screenshot, but it confirms it works OK:

This POV is kind of trippy

There seems to be an awful lot of refraction looking through that canopy, incidentally, and some unexpected opacity in the front. I see povray did print a bunch of parse warnings related to refraction, and two rendering warnings:
Rendering Warning: Camera is inside a non-hollow object. Fog and participating media may not work as expected.
Possible Rendering Error: Maximum trace level reached! If your scene contains black spots read more about the max_trace_level setting in the documentation!
so there are still some things to figure out.

Thanks,

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 17:57:03 GMT
Viewed: 
6045 times
  
--snip--

   You’re right - it does work. I retried it with L3P output and the view is positioned correctly. My previous effort used POV-Ray code from Anton’s converter. That’s not necessarily the reason it didn’t work before, though: it was late and I was tired. At any rate, LDView is certainly exonerated (not that it was accused).

This isn’t the exact same position as my previous LDView screenshot, but it confirms it works OK:

This POV is kind of trippy

There seems to be an awful lot of refraction looking through that canopy, incidentally, and some unexpected opacity in the front. I see povray did print a bunch of parse warnings related to refraction, and two rendering warnings:
Rendering Warning: Camera is inside a non-hollow object. Fog and participating media may not work as expected.
Possible Rendering Error: Maximum trace level reached! If your scene contains black spots read more about the max_trace_level setting in the documentation!
so there are still some things to figure out.

Thanks,

Jim

Hi Jim,

The second error there is certainly to blame for the opacity. You need to add a line
global_settings { max_trace_level N }
where N is high enough (probably 8 will do). Partially this is because LDraw parts are constructed of surfaces rather than solid blocks of material so that you end up passing through at least two transparent objects every time you go through a clear brick.

Of course opacity is not neccessarily all that incorrect as a quick glance at a brick built windscreen will show :)

Tim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad, lugnet.cad.dev, lugnet.cad.dev.mac
Date: 
Mon, 19 Mar 2007 18:42:44 GMT
Viewed: 
6096 times
  
In lugnet.cad, Timothy Gould wrote:

  
   This POV is kind of trippy

There seems to be an awful lot of refraction looking through that canopy, incidentally, and some unexpected opacity in the front. I see povray did print a bunch of parse warnings related to refraction, and two rendering warnings:
Rendering Warning: Camera is inside a non-hollow object. Fog and participating media may not work as expected.
Possible Rendering Error: Maximum trace level reached! If your scene contains black spots read more about the max_trace_level setting in the documentation!
so there are still some things to figure out.

Thanks,

Jim

Hi Jim,

The second error there is certainly to blame for the opacity. You need to add a line
global_settings { max_trace_level N }
where N is high enough (probably 8 will do). Partially this is because LDraw parts are constructed of surfaces rather than solid blocks of material so that you end up passing through at least two transparent objects every time you go through a clear brick.

Thanks for the tip, Tim! The point about LDraw (and POV-Ray) objectives being comprised of surfaces rather than solids is worth keeping in mind, too.

After re-rendering the little test scene with max_trace_level set to 8, I realized that the front part of the canopy I had previously considered “opaque” is indeed transparent - the curvature of the canopy makes the nose of the ship appear to “bubble up” in front:

Improbability Shielding?

   Of course opacity is not neccessarily all that incorrect as a quick glance at a brick built windscreen will show :)

I suppose not. I had just hoped this windscreen “brick” would present a more plausible internal perspective!

On an unrelated note, did you ever see my question here about the sticker vectorization tool you announced here? I’m just curious what became of it because I haven’t been able to find any other information about it.

Be well,

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad.ray
Date: 
Mon, 19 Mar 2007 19:00:35 GMT
Viewed: 
7170 times
  
(Moved to lugnet.cad.ray.)

In lugnet.cad, Jim DeVona wrote:
   In lugnet.cad, Travis Cobbs wrote:
   The aspect ratio shouldn’t make enough of a difference to put the camera out of the ship. It should only change the cropping. If you have the same aspect ratio, you should should get nearly pixel-perfect alignment of all polygons that don’t involve reflection or refraction. I’m not sure if this is a Mac-specific bug, or if you did something that I haven’t done in my testing on Windows.

You’re right - it does work. I retried it with L3P output and the view is positioned correctly. My previous effort used POV-Ray code from Anton’s converter. That’s not necessarily the reason it didn’t work before, though: it was late and I was tired. At any rate, LDView is certainly exonerated (not that it was accused).


I think Anton’s library isn’t in LDraw units. Since the camera placement is in LDraw units, it won’t work right. If you know the conversion factor, you can probably multiply the camera location by that and have it work.

--Travis


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad.ray
Date: 
Mon, 19 Mar 2007 19:57:08 GMT
Viewed: 
7231 times
  
In lugnet.cad.ray, Travis Cobbs wrote:
   (Moved to lugnet.cad.ray.)

In lugnet.cad, Jim DeVona wrote:
   In lugnet.cad, Travis Cobbs wrote:
   The aspect ratio shouldn’t make enough of a difference to put the camera out of the ship. It should only change the cropping. If you have the same aspect ratio, you should should get nearly pixel-perfect alignment of all polygons that don’t involve reflection or refraction. I’m not sure if this is a Mac-specific bug, or if you did something that I haven’t done in my testing on Windows.

You’re right - it does work. I retried it with L3P output and the view is positioned correctly. My previous effort used POV-Ray code from Anton’s converter. That’s not necessarily the reason it didn’t work before, though: it was late and I was tired. At any rate, LDView is certainly exonerated (not that it was accused).


I think Anton’s library isn’t in LDraw units. Since the camera placement is in LDraw units, it won’t work right. If you know the conversion factor, you can probably multiply the camera location by that and have it work.

Ah, that’s a logical explanation. I just looked in the manual.txt that came with Anton’s part library and it does state that it considers a POV-Ray unit 1 millimeter. If one LDraw unit is equal to 0.4 mm, then the conversion probably is straightforward (I haven’t tried it). I hate to provoke feature creep, but maybe LDView could select which units to output the camera in?

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad.ray
Date: 
Mon, 19 Mar 2007 22:49:07 GMT
Viewed: 
7322 times
  
In lugnet.cad.ray, Jim DeVona wrote:
   In lugnet.cad.ray, Travis Cobbs wrote:
   (Moved to lugnet.cad.ray.)

In lugnet.cad, Jim DeVona wrote:
   In lugnet.cad, Travis Cobbs wrote:
   The aspect ratio shouldn’t make enough of a difference to put the camera out of the ship. It should only change the cropping. If you have the same aspect ratio, you should should get nearly pixel-perfect alignment of all polygons that don’t involve reflection or refraction. I’m not sure if this is a Mac-specific bug, or if you did something that I haven’t done in my testing on Windows.

You’re right - it does work. I retried it with L3P output and the view is positioned correctly. My previous effort used POV-Ray code from Anton’s converter. That’s not necessarily the reason it didn’t work before, though: it was late and I was tired. At any rate, LDView is certainly exonerated (not that it was accused).


I think Anton’s library isn’t in LDraw units. Since the camera placement is in LDraw units, it won’t work right. If you know the conversion factor, you can probably multiply the camera location by that and have it work.

Ah, that’s a logical explanation. I just looked in the manual.txt that came with Anton’s part library and it does state that it considers a POV-Ray unit 1 millimeter. If one LDraw unit is equal to 0.4 mm, then the conversion probably is straightforward (I haven’t tried it). I hate to provoke feature creep, but maybe LDView could select which units to output the camera in?

Jim

Jim,

In the Converter I divide every coordinate the LDraw model has by 2.5 and then I end up with the millimeter system I digitized everything with. I have (since I started to build my Library starting in 1992) always used millimeters when measuring every single brick.

Greetz, Anton


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad.ray
Date: 
Tue, 20 Mar 2007 00:16:41 GMT
Viewed: 
7496 times
  
In lugnet.cad.ray, Anton Raves wrote:

  
  
   I think Anton’s library isn’t in LDraw units. Since the camera placement is in LDraw units, it won’t work right. If you know the conversion factor, you can probably multiply the camera location by that and have it work.

Ah, that’s a logical explanation. I just looked in the manual.txt that came with Anton’s part library and it does state that it considers a POV-Ray unit 1 millimeter. If one LDraw unit is equal to 0.4 mm, then the conversion probably is straightforward (I haven’t tried it). I hate to provoke feature creep, but maybe LDView could select which units to output the camera in?

In the Converter I divide every coordinate the LDraw model has by 2.5 and then I end up with the millimeter system I digitized everything with. I have (since I started to build my Library starting in 1992) always used millimeters when measuring every single brick.

Hi, Anton! Thanks for the explanation. That is a straightforward conversion. I divided LDView’s reported camera location and look_at coordinates by 2.5, reversed the sign of the y coordinates, used the default right vector (positive x), and it came out right:

hurray

Relatively speaking, of course. The scene itself needs work.

I am pleased to discover your library and how to use it, thanks in large part to James Reynolds’ recent video.

Thanks,

Jim


Subject: 
Re: Fun with LDView Fly Through (A Minifig's Eye View)
Newsgroups: 
lugnet.cad.ray
Date: 
Tue, 20 Mar 2007 06:46:17 GMT
Viewed: 
7870 times
  
In lugnet.cad.ray, Jim DeVona wrote:
   In lugnet.cad.ray, Anton Raves wrote:

  
  
   I think Anton’s library isn’t in LDraw units. Since the camera placement is in LDraw units, it won’t work right. If you know the conversion factor, you can probably multiply the camera location by that and have it work.

Ah, that’s a logical explanation. I just looked in the manual.txt that came with Anton’s part library and it does state that it considers a POV-Ray unit 1 millimeter. If one LDraw unit is equal to 0.4 mm, then the conversion probably is straightforward (I haven’t tried it). I hate to provoke feature creep, but maybe LDView could select which units to output the camera in?

In the Converter I divide every coordinate the LDraw model has by 2.5 and then I end up with the millimeter system I digitized everything with. I have (since I started to build my Library starting in 1992) always used millimeters when measuring every single brick.

Hi, Anton! Thanks for the explanation. That is a straightforward conversion. I divided LDView’s reported camera location and look_at coordinates by 2.5, reversed the sign of the y coordinates, used the default right vector (positive x), and it came out right:

hurray

Relatively speaking, of course. The scene itself needs work.

I am pleased to discover your library and how to use it, thanks in large part to James Reynolds’ recent video.

Jim,

You’re welcome! What you could do with the scene is put a hundreds of thousands unit tall white box (not an infinitive plane, they’ll add up to your rendering times!) behind the camera, it’ll give you some indirectional lighting like I have used for the many space scenes you can find on my website. You can find some sample scenes there as well as ways to introduce your scene to the stars! ;-)

Greetz, Anton


©2005 LUGNET. All rights reserved. - hosted by steinbruch.info GbR