LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

3d picture control example

Anyone have an example using the new 3d picture control VIs -- esp something reading a WRL resource.
Message 1 of 18
(9,887 Views)
Hi,

There are 3 examples that come with the 3D Picture Control VIs found in the \examples\picture3d directory:

  • Animate Object

  • Robot Arm

  • Simple

I don't have any support for reading WRL files on my computer, but it might be possible for the Draw Scene.vi to accept a WRL file as the "Picture In" input.

Also, there is a dedicated Discussion Forum topic on the new LabVIEW 3D Picture Controls that you might find better luck posting your 3D picture control questions to.

Thanks and best of luck with the new 3D Picture Control Software! NI is
definitely very excited about this new utility and would appreciate any and all feedback.

Kileen C.
Applications Engineer
National Instruments
0 Kudos
Message 2 of 18
(9,881 Views)
thanks for the reference. I did find those examples in the interim but am still VERY interested in a WRL-based example.

I'm specifically asking about that as there is a WRL-based VI included in the evaluation release so I suspect that means that someone at NI has been "playing" with that capability and I'd appreciate having a peek at what they've been doing.
0 Kudos
Message 3 of 18
(9,881 Views)
Kileen,

Has this been available in all LV7.1 distributions? I don't have a
"LabVIEW7.1\examples\picture3d" directory, and I also don't have a Draw
Scene.vi.

The picture control looks exactly the same. Should there be an extra
property or method?

Regards,

Wiebe.


"KileenC" wrote in message
news:506500000005000000C9B50100-1079395200000@exchange.ni.com...
> Hi,
>
> There are 3 examples that come with the 3D Picture Control VIs found
> in the \examples\picture3d directory:
>

    >
  • Animate Object

  • >
  • Robot Arm

  • >
  • Simple

> I don't have any support for reading WRL files on my computer, but it
> might be possible for the Draw Scene.vi to accept a WRL file as the
> "Picture In" input.
>
> Also, there is a

>
href="http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=205&
HUSERSHADE=0&HOID=50650...

that
> you might find better luck posting your 3D picture control questions
> to.
>
> Thanks and best of luck with the new 3D Picture Control Software! NI
> is definitely very excited about this new utility and would appreciate
> any and all feedback.
>
> Kileen C.
> Applications Engineer
> National Instruments
0 Kudos
Message 4 of 18
(9,883 Views)
Hi Weibe,

The 3D Picture Control Evaluation Software was just released on July 15, 2004 and we posted the news as a Discussion Forum topic. Go to this page for more information and the download zip file for this new set of modeling tools.

Although the picture control is the same, we have added additional rendering and modeling capabilities for 3D scenes for advanced visualization in LabVIEW, levering off OpenGL technology.

Please do try it out and post any feedback you have regarding these controls.

Thanks!

Kileen C.
NI
0 Kudos
Message 5 of 18
(9,883 Views)
Hi,

Thanks for the link (I actually got the link just before you mentioned it,
from our local NI contacts).

It works nicelly, but it is complicated (need a lot of code to do simple
things). And everything needs to be correct, but that is always the case
with 3D stuff...

Also, most of the processor load is generated by "Render Scene.vi". And this
vi is nessecary for each frame. So even for a simple animation (where only
the rotation is changed), "Render Scene.vi" wastes a lot of processor time,
while only 16 (or so) bytes are actually changed! This makes the
construction (as it is now) less suitable for animation.

This problem is the same for the normal picture functions, and can be solved
with custom code (using a complex bu
ffer), but it would be nice if it was
inplemented by NI. Perhaps I'm being a bit hard, but the graphics scene
always tries to get the most out of everything...

For static scenes it is nice.

Regards,

Wiebe.



"KileenC" wrote in message
news:506500000005000000B9BB0100-1079395200000@exchange.ni.com...
> Hi Weibe,
>
> The 3D Picture Control Evaluation Software was just released on
> July 15, 2004 and we posted the news as a
>
href="http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=205&
HUSERSHADE=0&HOID=50650...

. Go to this page for more information and the
> download zip file for this new set of modeling tools.
>
> Although the picture control is the same, we have added additional
> rendering and modeling capabilities for 3D scenes for advanced
> visualization in LabVIEW, levering off OpenGL technology.
>
> Please do try it out and post any feedback you have re
garding these
> controls.
>
> Thanks!
>
> Kileen C.
> NI



[Attachment example 1.vi, see below]
0 Kudos
Message 6 of 18
(9,885 Views)
Hi,

I played some more with it, and what is missing is a way to get the
Z-buffer. Because it is missing, it is not possible to do picking and
pointing... It would be great if there was a property or sub vi "Get
Z-buffer", or at least a setting so the Z-buffer is drawn instead of the
color buffer.

Regards,

Wiebe.


"KileenC" wrote in message
news:506500000005000000B9BB0100-1079395200000@exchange.ni.com...
> Hi Weibe,
>
> The 3D Picture Control Evaluation Software was just released on
> July 15, 2004 and we posted the news as a
>
href="http://exchange.ni.com/servlet/ProcessRequest?RHIVEID=101&RPAGEID=205&
HUSERSHADE=0&HOID=50650...


. Go to this page for more information and the
> download zip file for this new set of modeling tools.
>
> Although the picture control is the same, we have added additional
> rendering and modeling capabilities for 3D scenes for advanced
> visualization in LabVIEW, levering off OpenGL technology.
>
> Please do try it out and post any feedback you have regarding these
> controls.
>
> Thanks!
>
> Kileen C.
> NI
0 Kudos
Message 7 of 18
(9,885 Views)
Hi Wiebe,

Thanks for the feedback! I would also suggest posting any suggestions/comments you have regarding the 3D picture controls on the above-mentioned Discussion Forum posting since NI will be monitoring that thread for future reference. Although I'm not that familiar with OpenGL and 3D picture rendering myself, it seems that the Z-buffer can be problematic (e.g. "flimmering", "Z-fighting", alpha-blending issues), and this may be the reason this was not initially introduced...

Thanks again,
Kileen
0 Kudos
Message 8 of 18
(9,885 Views)
The Z-buffer is an difficult concept. However, it is a standard part of
OpenGL. If you can draw something in OpenGL properly, you have a Z-buffer
properly filled (most of the time, if you draw a normal 3d scene).

If you have a opengl window initialised with GL_DEPTH (this is needed to
draw a 3D shape properly), you have a Z-buffer. If it is used (or misused)
correctly of not, is up to the user...

I think the Z buffer bitmap (actually pixelmap) can be queried with
glReadPixels. This can also be used to read the color buffer, and perhaps
glReadPixels is even used internally to copy the color buffer to the picture
control. If this is the case, a simple switch can be used to choose either
one... Otherwise, an property t
hat returns a 2D array or a pixmap won't be
too difficult.

Regards,

Wiebe.

Btw. I'v noticed that a opengl stream can be put into a LV 7.0 picture
control. Are there any unstable functions, or is it just the same?


"KileenC" wrote in message
news:506500000005000000E7BF0100-1079395200000@exchange.ni.com...
> Hi Wiebe,
>
> Thanks for the feedback! I would also suggest posting any
> suggestions/comments you have regarding the 3D picture controls on the
> above-mentioned Discussion Forum posting since NI will be monitoring
> that thread for future reference. Although I'm not that familiar with
> OpenGL and 3D picture rendering myself, it seems that the Z-buffer can
> be problematic (e.g.
>
href="http://www.sjbaker.org/steve/omniv/love_your_z_buffer.html">"flimmerin
g",
> "Z-fighting"
,
>
href="http://www.sjbaker.org/steve/omniv/alpha_sorting.html">alpha-blending<
/a>
> issues), and this ...





0 Kudos
Message 9 of 18
(9,887 Views)
Hi Wiebe,

As far as I know, there are no reported bugs or problems with using OpenGL functions in the LabVIEW picture control. Go ahead and give it a shot and let us know if you have any questions! 🙂

Kileen C.
NI
0 Kudos
Message 10 of 18
(9,887 Views)