Login
Username:

Password:

Remember me



Lost Password?

Register now!
Main Menu
H3D.org Feeds


Browsing this Thread: 






Node definition and description
#1
Quite a regular
Quite a regular


See User information
Hello forum,

I have read some nodes attributes from the H3DNodeDatabase.

I believe that every node contains at least two fields that define the node . One is the DEF and the other is DESCRIPTION.

DEF is used so that later somewhere in the scene it can be referenced through USE.


TAKE FOR EXAMPLE THE FOLLOWING NODE:

TouchSensor . I read its field contents from the database and the fields are as follows:


Node name: "TouchSensor"
Size of the field contents: 9
"TouchSensor" is not Abstract
Field Name: "enabled" and Field type: "SFBool"
Field Name: "description" and Field type: "SFString"
Field Name: "isActive" and Field type: "SFBool"
Field Name: "hitPoint_changed" and Field type: "SFVec3f"
Field Name: "hitNormal_changed" and Field type: "SFVec3f"
Field Name: "touchTime" and Field type: "SFTime"
Field Name: "isOver" and Field type: "SFBool"
Field Name: "metadata" and Field type: "SFNode"
Field Name: "hitTexCoord_changed" and Field type: "SFVec2f"


Which of the above fields contanis what is defines after DEF=''?

Regards
Sajjad



Posted on: 2011/2/11 16:25
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong Top


Re: Node definition and description
#2
Webmaster
Webmaster


See User information
To get the DEF of a node you need the a pointer to an instance of the node. If I am not wrong you can not get a list of DEF-names directly from the database. If you created the scene using C++ createX3D(Node)From* functions then you can supply a DEFNodes map which, when the function returns, will contain all DEF-names in the scene.

Posted on: 2011/2/15 8:40
Twitter Facebook Google Plus Linkedin Del.icio.us Digg Reddit Mr. Wong Top







You can view topic.
You cannot start a new topic.
You cannot reply to posts.
You cannot edit your posts.
You cannot delete your posts.
You cannot add new polls.
You cannot vote in polls.
You cannot attach files to posts.
You cannot post without approval.
You cannot use topic type.
You cannot use HTML syntax.
You cannot use signature.
You cannot create pdf.
You cannot get print page.

[Advanced Search]





(C) 2012 SenseGraphics AB    ---    Powered by XOOPS