From: blue r. <bl...@gm...> - 2006-11-08 16:28:29
|
Hello I am trying to load a VRML file and then read the values off it using openvrml. I noticed a strange thing that the rotation values in the transform node do not match the values in the vrml file when they are floating point values. Am I doing something wrong? I am using version 0.15.10. ( I am using windows and cannot compile 0.16.1 yet). I appreciate any help I receive. Thanks a lot. |
From: Braden M. <br...@en...> - 2006-11-09 23:59:02
|
On Wed, 2006-11-08 at 16:28 +0000, blue rpk wrote: > Hello > I am trying to load a VRML file and then read the values off it using > openvrml. I noticed a strange thing that the rotation values in the > transform node do not match the values in the vrml file when they are > floating point values. Am I doing something wrong? Well, it's possible your expectations are off. Some inaccuracy is built into the nature of floating point values. By how much are the values off? > I am using version 0.15.10. ( I am using windows and cannot compile > 0.16.1 yet). Are you aware that 0.16.1 should compile with the free Visual C++ 2005 Express compiler? -- Braden McDaniel e-mail: <br...@en...> <http://endoframe.com> Jabber: <br...@ja...> |
From: blue r. <bl...@gm...> - 2006-11-10 10:52:06
Attachments:
cornellBox-notNested.wrl
|
Thanks for your reply. Some examples of the values that are read in and expected values are as follows. In VRML file - 0.979336 Rotation field value 0.96029615 In VRML file - -0.143005 Rotation field value -0.19626954 In VRML file - -0.143005 Rotation field value -0.19826628 As you can see, the same value is read in as a different value in openVRML. It is most probably something that I am doing or haven't understood properly. I am attaching the VRML file that I am reading. Any help and comments appreciated. Thank you for your suggestion about Visual Studio Express 2005. I will try it out today. On 11/9/06, Braden McDaniel <br...@en...> wrote: > > On Wed, 2006-11-08 at 16:28 +0000, blue rpk wrote: > > Hello > > I am trying to load a VRML file and then read the values off it using > > openvrml. I noticed a strange thing that the rotation values in the > > transform node do not match the values in the vrml file when they are > > floating point values. Am I doing something wrong? > > Well, it's possible your expectations are off. Some inaccuracy is built > into the nature of floating point values. By how much are the values > off? > > > I am using version 0.15.10. ( I am using windows and cannot compile > > 0.16.1 yet). > > Are you aware that 0.16.1 should compile with the free Visual C++ 2005 > Express compiler? > > -- > Braden McDaniel e-mail: <br...@en...> > <http://endoframe.com> Jabber: <br...@ja...> > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > openvrml-develop mailing list > ope...@li... > https://lists.sourceforge.net/lists/listinfo/openvrml-develop > |
From: Braden M. <br...@en...> - 2006-11-10 15:17:32
|
On Fri, 2006-11-10 at 10:52 +0000, blue rpk wrote: > Thanks for your reply. > > Some examples of the values that are read in and expected values are as > follows. > > In VRML file - 0.979336 Rotation field value 0.96029615 > In VRML file - -0.143005 Rotation field value -0.19626954 > In VRML file - -0.143005 Rotation field value -0.19826628 > > As you can see, the same value is read in as a different value in > openVRML. It is most probably something that I am doing or haven't > understood properly. I am attaching the VRML file that I am reading. > Any help and comments appreciated. If I add this Script node to the end of your file: Script { field SFNode t USE VCube01 url [ "javascript: function initialize() { print(t.rotation); }" ] } I get this console output using 0.16.1: 0.979336 -0.143005 -0.143005 -1.592 That tells me that the values have made it into the runtime okay. If you see the same output with 0.15.10, I'd guess the problem is introduced by however you're retrieving the values. (Note that the rotation axis value for VCube02 is not normalized; OpenVRML *will* change the axis values here because it will normalize the vector. Note that rotation axis values that are not normalized are technically nonconforming; that's why OpenVRML emits a warning about them.) -- Braden McDaniel e-mail: <br...@en...> <http://endoframe.com> Jabber: <br...@ja...> |
From: blue r. <bl...@gm...> - 2006-11-14 11:52:36
|
Hello Pardon me for my ignorance, but how do I see the console output. I am using the library and not any application. Does it appear when I run an application? Also, if I have a transform node pointer, what is the recommended way to extract the rotation values? Right now I am just checking the value by using the watch method of the debugger in Visual Studio. Thanks a lot for your help. On 11/10/06, Braden McDaniel <br...@en...> wrote: > > On Fri, 2006-11-10 at 10:52 +0000, blue rpk wrote: > > Thanks for your reply. > > > > Some examples of the values that are read in and expected values are as > > follows. > > > > In VRML file - 0.979336 Rotation field value 0.96029615 > > In VRML file - -0.143005 Rotation field value -0.19626954 > > In VRML file - -0.143005 Rotation field value -0.19826628 > > > > As you can see, the same value is read in as a different value in > > openVRML. It is most probably something that I am doing or haven't > > understood properly. I am attaching the VRML file that I am reading. > > Any help and comments appreciated. > > If I add this Script node to the end of your file: > > Script { > field SFNode t USE VCube01 > url [ > "javascript: function initialize() { print(t.rotation); }" > ] > } > > I get this console output using 0.16.1: > > 0.979336 -0.143005 -0.143005 -1.592 > > That tells me that the values have made it into the runtime okay. If you > see the same output with 0.15.10, I'd guess the problem is introduced by > however you're retrieving the values. > > (Note that the rotation axis value for VCube02 is not normalized; > OpenVRML *will* change the axis values here because it will normalize > the vector. Note that rotation axis values that are not normalized are > technically nonconforming; that's why OpenVRML emits a warning about > them.) > > -- > Braden McDaniel e-mail: <br...@en...> > <http://endoframe.com> Jabber: <br...@ja...> > > > > ------------------------------------------------------------------------- > Using Tomcat but need to do more? Need to support web services, security? > Get stuff done quickly with pre-integrated technology to make your job > easier > Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo > http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642 > _______________________________________________ > openvrml-develop mailing list > ope...@li... > https://lists.sourceforge.net/lists/listinfo/openvrml-develop > |
From: Braden M. <br...@en...> - 2006-11-14 13:39:43
|
On Tue, 2006-11-14 at 11:52 +0000, blue rpk wrote: > Hello > Pardon me for my ignorance, but how do > I see the console output. I am using the library and not any > application. Does it appear when I run an application? Well, you must be using *some* application. Have a look at what 0.16.1's sdl-viewer does; lines 89-94 and 121-124: <http://openvrml.cvs.sourceforge.net/openvrml/openvrml/examples/sdl_viewer.cpp?revision=1.11&view=markup> > Also, if I have a transform node pointer, what is the recommended > way to extract the rotation values? Right now I am just checking the > value by using the watch method of the debugger in Visual Studio. Call openvrml::transform_node::transform to get the openvrml::mat4f and use the openvrml::mat4f::transformation accessor. -- Braden McDaniel e-mail: <br...@en...> <http://endoframe.com> Jabber: <br...@ja...> |