29 #ifndef __FREEWRL_HEADERS_H__
30 #define __FREEWRL_HEADERS_H__
32 #define int_t intptr_t
34 extern char *BrowserName;
35 const char* freewrl_get_browser_program();
40 #define IO_FLOAT -2335549.0f
43 #define SPEC_VRML 0x01
44 #define SPEC_X3D30 0x02
45 #define SPEC_X3D31 0x04
46 #define SPEC_X3D32 0x08
47 #define SPEC_X3D33 0x10
48 #define SPEC_X3D34 0x20
49 #define SPEC_VRML1 0x01
55 #define CHILDREN_COUNT int nc = node->_sortedChildren.n;
56 #define RETURN_FROM_CHILD_IF_NOT_FOR_ME \
62 ttrenderstate rs = renderstate(); \
63 if (rs->render_blend == VF_Blend) \
64 if ((node->_renderFlags & VF_Blend) != VF_Blend) { \
67 if (rs->render_proximity == VF_Proximity) \
68 if ((node->_renderFlags & VF_Proximity) != VF_Proximity) { \
71 if (rs->render_light == VF_globalLight) \
72 if ((node->_renderFlags & VF_globalLight) != VF_globalLight) { \
79 #define ARR_SIZE(arr) (int)(sizeof(arr)/sizeof((arr)[0]))
81 extern char *BrowserName;
82 extern char *BrowserFullPath;
88 #define VF_Viewpoint 0x0001
89 #define VF_Geom 0x0002
90 #define VF_localLight 0x0004
91 #define VF_Sensitive 0x0008
92 #define VF_Blend 0x0010
93 #define VF_Proximity 0x0020
94 #define VF_Collision 0x0040
95 #define VF_globalLight 0x0080
96 #define VF_hasVisibleChildren 0x0100
97 #define VF_shouldSortChildren 0x0200
98 #define VF_Other 0x0400
99 #define VF_Picking 0x1000
100 #define VF_HideLeft 0x2000
101 #define VF_HideRight 0x4000
102 #define VF_USE 0x8000
103 #define VF_Cube 0x10000 //when generating generatedcubemap texture to fbo (don't render generatedcubemap parent nodes)
106 #define DEFAULT_NEARPLANE 0.07
107 #define DEFAULT_FARPLANE 21000.0
108 #define DEFAULT_BACKGROUNDPLANE 18000.0
109 extern double geoHeightinZAxis;
113 #define ROUTING_SFNODE -23
114 #define ROUTING_MFNODE -10
115 #define ROUTING_SFIMAGE -12
116 #define ROUTING_MFSTRING -13
117 #define ROUTING_MFFLOAT -14
118 #define ROUTING_MFROTATION -15
119 #define ROUTING_MFINT32 -16
120 #define ROUTING_MFCOLOR -17
121 #define ROUTING_MFVEC2F -18
122 #define ROUTING_MFVEC3F -19
123 #define ROUTING_MFVEC3D -20
124 #define ROUTING_MFDOUBLE -21
125 #define ROUTING_SFSTRING -22
126 #define ROUTING_MFMATRIX4F -30
127 #define ROUTING_MFMATRIX4D -31
128 #define ROUTING_MFVEC2D -32
129 #define ROUTING_MFVEC4F -33
130 #define ROUTING_MFVEC4D -34
131 #define ROUTING_MFMATRIX3F -35
132 #define ROUTING_MFMATRIX3D -36
143 #define NODE_CHANGE_INIT_VAL 153
144 #define COMPILE_POLY_IF_REQUIRED(a,b,c,d,e) \
145 if(!node->_intern || node->_change != (node->_intern)->irep_change) { \
146 compileNode ((void *)compile_polyrep, node, a,b,c,d,e); \
148 if (!node->_intern) return;
150 #define COMPILE_IF_REQUIRED { struct X3D_Virt *v; \
151 if (node->_ichange != node->_change) { \
152 v = virtTable[node->_nodeType]; \
154 compileNode (v->compile, (void *)node, NULL, NULL, NULL, NULL, NULL); \
155 } else {printf ("huh - have COMPIFREQD, but v->compile null for %s at %s:%d\n",stringNodeType(node->_nodeType),__FILE__,__LINE__);} \
157 if (node->_ichange == 0) return; \
160 #define COMPILE_IF_REQUIRED_RETURN_NULL_ON_ERROR { struct X3D_Virt *v; \
161 if (node->_ichange != node->_change) { \
162 v = virtTable[node->_nodeType]; \
164 compileNode (v->compile, (void *)node, NULL, NULL, NULL, NULL, NULL); \
165 } else {printf ("huh - have COMPIFREQD, but v->compile null for %s at %s:%d\n",stringNodeType(node->_nodeType),__FILE__,__LINE__);} \
167 if (node->_ichange == 0) return NULL; \
170 #define COMPILE_TCNODE { \
171 struct X3D_Virt *v; \
172 if (myTCnode->_ichange != myTCnode->_change) { \
173 v = virtTable[myTCnode->_nodeType]; \
175 compileNode (v->compile, (void *)myTCnode, NULL, NULL, NULL, NULL, NULL); \
176 myTCnode->_ichange = myTCnode->_change; \
177 } else {printf ("huh - have COMPIFREQD, but v->compile null for %s at %s:%d\n",stringNodeType(myTCnode->_nodeType),__FILE__,__LINE__);} \
179 if (myTCnode->_ichange == 0) return; \
187 #define offsetPointer_deref(t, me, offs) ((t)(((char*)(me))+offs))
202 #define POSSIBLE_PROTO_EXPANSION(type,inNode,outNode) \
203 outNode = (type)getTypeNode(inNode);
205 #define MARK_NODE_COMPILED node->_ichange = node->_change;
206 #define NODE_NEEDS_COMPILING (node->_ichange != node->_change)
207 #define ROOTNODE_NEEDS_COMPILING (rootNode()->_ichange != rootNode()->_change)
211 #define MARK_SFFLOAT_INOUT_EVENT(good,save,offset) \
212 if (!APPROX(good,save)) { \
213 MARK_EVENT(X3D_NODE(node), offset);\
217 #define MARK_SFTIME_INOUT_EVENT(good,save,offset) \
218 if (!APPROX(good,save)) { \
219 MARK_EVENT(X3D_NODE(node), offset);\
223 #define MARK_SFINT32_INOUT_EVENT(good,save,offset) \
225 MARK_EVENT(X3D_NODE(node), offset);\
229 #define MARK_SFBOOL_INOUT_EVENT(good,save,offset) \
231 MARK_EVENT(X3D_NODE(node), offset);\
236 #define MARK_SFVEC3F_INOUT_EVENT(good,save,offset) \
237 if ((!APPROX(good.c[0],save.c[0])) || (!APPROX(good.c[1],save.c[1])) || (!APPROX(good.c[2],save.c[2]))) { \
238 MARK_EVENT(X3D_NODE(node), offset);\
239 memcpy (&save.c, &good.c, sizeof (struct SFColor));\
242 #define MARK_SFVEC3D_INOUT_EVENT(good,save,offset) \
243 if ((!APPROX(good.c[0],save.c[0])) || (!APPROX(good.c[1],save.c[1])) || (!APPROX(good.c[2],save.c[2]))) { \
244 MARK_EVENT(X3D_NODE(node), offset);\
245 memcpy (&save.c, &good.c, sizeof (struct SFVec3d));\
250 #define MARK_SFNODE_INOUT_EVENT(good,save,offset) \
251 if (good != save) { \
252 MARK_EVENT(X3D_NODE(node), offset);\
257 #define MARK_MFNODE_INOUT_EVENT_PRE_JULY29_2015(good,save,offset) \
259 if (good.p != save.p) { \
260 MARK_EVENT(X3D_NODE(node), offset);\
265 #define MARK_MFNODE_INOUT_EVENT(good,save,offset) \
267 if (good.p != save.p) { \
268 MARK_EVENT(X3D_NODE(node), offset);\
270 FREE_IF_NZ(save.p); \
272 if(good.n && good.p){ \
273 save.p = MALLOCV(good.n * sizeof(void*)); \
274 memcpy(save.p,good.p,good.n * sizeof(void*)); \
282 #define USE_SET_SFVEC3D_IF_CHANGED(setField,regField) \
283 if (!APPROX (node->setField.c[0],node->regField.c[0]) || \
284 !APPROX(node->setField.c[1],node->regField.c[1]) || \
285 !APPROX(node->setField.c[2],node->regField.c[2]) ) { \
287 if (APPROX(node->setField.c[0], IO_FLOAT) && APPROX(node->setField.c[1],IO_FLOAT) && APPROX(node->setField.c[2],IO_FLOAT)) { \
291 memcpy (node->regField.c, node->setField.c, sizeof (struct SFVec3d)); \
295 #define USE_SET_SFROTATION_IF_CHANGED(setField,regField) \
296 if (!APPROX (node->setField.c[0],node->regField.c[0]) || \
297 !APPROX(node->setField.c[1],node->regField.c[1]) || \
298 !APPROX(node->setField.c[2],node->regField.c[2]) || \
299 !APPROX(node->setField.c[3],node->regField.c[3]) ) { \
301 if (APPROX(node->setField.c[0], IO_FLOAT) && APPROX(node->setField.c[1],IO_FLOAT) && APPROX(node->setField.c[2],IO_FLOAT) && APPROX(node->setField.c[3],IO_FLOAT)) { \
305 memcpy (node->regField.c, node->setField.c, sizeof (struct SFRotation)); \
312 int find_key (
int kin,
float frac,
float *keys);
313 void startOfLoopNodeUpdates(
void);
315 void zeroVisibilityFlag(
void);
316 void setField_fromJavascript (
struct X3D_Node *ptr,
char *field,
char *value,
int isXML);
317 unsigned int setField_FromEAI (
char *ptr);
320 #define INITIALIZE_EXTENT { node->EXTENT_MAX_X = (float) -10000.0; \
321 node->EXTENT_MAX_Y = (float) -10000.0; \
322 node->EXTENT_MAX_Z = (float) -10000.0; \
323 node->EXTENT_MIN_X = (float) 10000.0; \
324 node->EXTENT_MIN_Y = (float) 10000.0; \
325 node->EXTENT_MIN_Z = (float) 10000.0; }
330 #if defined(DEBUG) || defined(FW_DEBUG)
335 #undef SETFIELDVERBOSE
337 #undef CPARSERVERBOSE
340 #undef JSVRMLCLASSESVERBOSE
361 #undef STREAM_POLY_VERBOSE
364 #undef COLLISIONVERBOSE
367 #undef CAPABILITIESVERBOSE
372 #define TESS_MAX_COORDS 200000
374 #define offset_of(p_type,field) ((unsigned int)(&(((p_type)NULL)->field)-NULL))
376 #define UNUSED(v) ((void) v)
377 #define ISUSED(v) ((void) v)
379 #define PI 3.14159265358979323846
380 #define PIF 3.1415926535f
383 #define APPROX(a,b) (fabs((a)-(b))<0.00000001)
386 #define NORMAL_VECTOR_LENGTH_TOLERANCE 0.00001
388 #define IS_ROTATION_VEC_NOT_NORMAL(rot) ( \
389 fabs(1-sqrt(rot.c[0]*rot.c[0]+rot.c[1]*rot.c[1]+rot.c[2]*rot.c[2])) \
390 >NORMAL_VECTOR_LENGTH_TOLERANCE \
394 #define XEQ (APPROX(t_r1.x,t_r2.x))
395 #define YEQ (APPROX(t_r1.y,t_r2.y))
396 #define ZEQ (APPROX(t_r1.z,t_r2.z))
398 #define XRAT(a) (((a)-t_r1.x)/(t_r2.x-t_r1.x))
399 #define YRAT(a) (((a)-t_r1.y)/(t_r2.y-t_r1.y))
400 #define ZRAT(a) (((a)-t_r1.z)/(t_r2.z-t_r1.z))
402 #define MRATX(a) (t_r1.x + (a)*(t_r2.x-t_r1.x))
403 #define MRATY(a) (t_r1.y + (a)*(t_r2.y-t_r1.y))
404 #define MRATZ(a) (t_r1.z + (a)*(t_r2.z-t_r1.z))
407 #define POINT_FACES 16
411 void render_node(
struct X3D_Node *node);
413 void rayhit(
float rat,
float cx,
float cy,
float cz,
float nx,
float ny,
float nz,
414 float tx,
float ty,
char *descr) ;
416 void fwnorprint (
float *norm);
424 unsigned char *readpng_get_image(
double display_exponent,
int *pChannels,
425 unsigned long *pRowbytes);
428 void LocalLight_Rend(
void *nod_);
430 void saveLightState2(
int *ls);
431 void restoreLightState2(
int ls);
432 int numberOfLights();
433 void refreshLightUniforms();
434 #define LOCAL_LIGHT_SAVE int lastlight; //savedlight[8];
466 void normalize_ifs_face (
float *point_normal,
475 #define RUNNINGONAMD64 (sizeof(void *) == 8)
504 extern GLint viewport[];
508 extern double defaultExamineDist;
514 void *returnInterpolatorPointer (
int nodeType);
518 #define X3DBoundedObject 1
519 #define X3DBounded2DObject 2
520 #define X3DURLObject 3
521 #define X3DAppearanceNode 10
522 #define X3DAppearanceChildNode 11
523 #define X3DMaterialNode 12
524 #define X3DTextureNode 13
525 #define X3DTexture2DNode 14
526 #define X3DTexture3DNode 15
527 #define X3DTextureTransformNode 16
528 #define X3DTextureTransform2DNode 17
529 #define X3DGeometryNode 18
530 #define X3DTextNode 19
531 #define X3DParametricGeometryNode 20
532 #define X3DGeometricPropertyNode 21
533 #define X3DColorNode 22
534 #define X3DCoordinateNode 23
535 #define X3DNormalNode 24
536 #define X3DTextureCoordinateNode 25
537 #define X3DFontStyleNode 26
538 #define X3DProtoInstance 27
539 #define X3DChildNode 28
540 #define X3DBindableNode 29
541 #define X3DBackgroundNode 30
542 #define X3DGroupingNode 31
543 #define X3DShapeNode 32
544 #define X3DInterpolatorNode 33
545 #define X3DLightNode 34
546 #define X3DScriptNode 35
547 #define X3DSensorNode 36
548 #define X3DEnvironmentalSensorNode 37
549 #define X3DKeyDeviceSensorNode 38
550 #define X3DNetworkSensorNode 39
551 #define X3DPointingDeviceSensorNode 40
552 #define X3DDragSensorNode 41
553 #define X3DTouchSensorNode 42
554 #define X3DSequencerNode 43
555 #define X3DTimeDependentNode 44
556 #define X3DSoundSourceNode 45
557 #define X3DTriggerNode 46
558 #define X3DInfoNode 47
559 #define X3DShaderNode 48
560 #define X3DVertexAttributeNode 49
561 #define X3DProgrammableShaderObject 50
562 #define X3DUrlObject 51
563 #define X3DEnvironmentTextureNode 52
565 #define X3DProductStructureChildNode 54
566 #define X3DComposedGeometryNode 55
567 #define X3DNurbsControlCurveNode 56
568 #define X3DNurbsSurfaceGeometryNode 57
569 #define X3DViewportNode 58
570 #define X3DLayerNode 59
571 #define X3DLayerSetNode 60
572 #define X3DLayoutNode 61
573 #define X3DNBodyCollidableNode 62
574 #define X3DRigidJointNode 63
575 #define X3DChaserNode 64
576 #define X3DDamperNode 65
577 #define X3DParticleEmitterNode 66
578 #define X3DParticlePhysicsModelNode 67
579 #define X3DComposableVolumeRenderStyleNode 68
580 #define X3DVolumeDataNode 69
583 BOOL isManagedField(
int mode,
int type, BOOL isPublic);
585 void AddRemoveChildren (
struct X3D_Node *parent,
struct Multi_Node *tn,
struct X3D_Node * *nodelist,
int len,
int ar,
char * where,
int lin);
586 unsigned long upper_power_of_two(
unsigned long v);
587 void update_node(
struct X3D_Node *ptr);
589 void UPDATE_RENDERFLAG(
struct X3D_Node *ptr,
int flag,
char *fi,
int li);
590 #define update_renderFlag(aaa,bbb) UPDATE_RENDERFLAG(aaa,bbb,__FILE__,__LINE__)
592 int get_touched_flag(uintptr_t fptr, uintptr_t actualscript);
593 void getMultiElementtype(
char *strp,
struct Multi_Vec3f *tn,
int eletype);
594 void CRoutes_RemoveSimple(
struct X3D_Node* from,
int fromOfs,
595 struct X3D_Node* to,
int toOfs,
int len);
596 void CRoutes_RemoveSimpleB(
struct X3D_Node* from,
int fromIndex,
597 struct X3D_Node* to,
int toIndex,
int len);
598 void CRoutes_RegisterSimple(
struct X3D_Node* from,
int fromOfs,
599 struct X3D_Node* to,
int toOfs,
int len);
600 void CRoutes_RegisterSimpleB(
601 struct X3D_Node* from,
int fromIndex,
604 void CRoutes_Register(
int adrem,
struct X3D_Node *from,
612 void CRoutes_free(
void);
613 void propagate_events(
void);
614 int getRoutesCount(
void);
615 void getField_ToJavascript (
int num,
int fromoffset);
616 void add_first(
struct X3D_Node * node);
617 void add_physics(
struct X3D_Node * node);
618 void registerTexture(
struct X3D_Node * node);
619 int checkNode(
struct X3D_Node *node,
char *fn,
int line);
623 void process_eventsProcessed(
void);
631 void frontendUpdateButtons(
void);
637 void setConsoleMessage(
char *stat) ;
638 void fwl_reload(
void);
640 void fwl_do_rawKeyPress(
int key,
int type);
642 int convert_typetoInt (
const char *type);
646 void render_polyrep(
void *node);
653 #define SHADERSCRIPT 4
665 void setRootNode(
struct X3D_Node *rn);
671 struct Vector *libraries();
672 void setLibraries(
struct Vector *);
673 void addLibrary(
char *url,
struct X3D_Proto *library,
void* res);
674 void3 *librarySearch(
char *absoluteUniUrlNoPound);
676 extern int isPerlParsing(
void);
678 extern int isTextureParsing(
void);
683 extern GLfloat boxtex[], boxnorms[], BackgroundVert[];
684 extern GLfloat Backnorms[];
686 extern void new_tessellation(
void);
687 extern void initializePerlThread(
void);
689 extern void setPluginPipe(
const char *optarg);
690 extern void setPluginFD(
const char *optarg);
691 extern void setPluginInstance(
const char *optarg);
693 extern int isPerlinitialized(
void);
695 extern char *getInputURL(
void);
696 extern char *lastReadFile;
700 extern void xs_init(
void);
703 extern void checkAndAllocMemTables(
int *texture_num,
int increment);
704 extern void storeMPGFrameData(
int latest_texture_number,
int h_size,
int v_size,
705 int mt_repeatS,
int mt_repeatT,
char *Image);
706 void mpg_main(
char *filename,
int *x,
int *y,
int *depth,
int *frameCount,
char **ptr);
707 void removeFilenameFromPath (
char *path);
709 int EAI_CreateVrml(
const char *tp,
const char *inputstring,
struct X3D_Node *ectx,
struct X3D_Group *node);
710 int EAI_CreateX3d(
const char *tp,
const char *inputstring,
struct X3D_Node *ectx,
struct X3D_Group *where);
711 void EAI_Route(
char cmnd,
const char *tf);
713 void handle_aqua(
const int mev,
const unsigned int button,
int x,
int y);
715 #define overMark 23425
721 #if defined(_MSC_VER) || defined(_ANDROID) || defined(ANDROIDNDK)
722 #ifndef _MIMIC_X11_SCREEN_BUTTONS
723 #define _MIMIC_X11_SCREEN_BUTTONS
726 #define ButtonPress 4
727 #define ButtonRelease 5
728 #define MotionNotify 6
734 extern void setEAIport(
int pnum);
736 extern void setNoCollision();
739 extern void setBrowserFullPath(
const char *str);
740 extern void setInstance(uintptr_t instance);
742 extern const char *getLibVersion();
743 extern int doBrowserAction ();
746 extern char *myPerlInstallDir;
749 #define EXTENT_MAX_X _extent[0]
750 #define EXTENT_MIN_X _extent[1]
751 #define EXTENT_MAX_Y _extent[2]
752 #define EXTENT_MIN_Y _extent[3]
753 #define EXTENT_MAX_Z _extent[4]
754 #define EXTENT_MIN_Z _extent[5]
756 void freewrlDie(
const char *format);
762 int render_sensitive,render_picking,render_vp,render_light,render_proximity,render_other,verbose,render_blend,render_geom,render_collision,render_cube;
767 int SAI_IntRetCommand (
char cmnd,
const char *fn);
768 char * SAI_StrRetCommand (
char cmnd,
const char *fn);
769 char *EAI_GetTypeName (
unsigned int uretval);
770 char* EAI_GetValue(
unsigned int nodenum,
const char *fieldname,
const char *nodename);
772 void add_parent(
struct X3D_Node *node_,
struct X3D_Node *parent_,
char *file,
int line);
774 void EAI_readNewWorld(
char *inputstring);
779 #define rendray_Text render_ray_polyrep
780 #define rendray_ElevationGrid render_ray_polyrep
781 #define collide_ElevationGrid collide_genericfaceset
782 #define rendray_Extrusion render_ray_polyrep
783 #define rendray_IndexedFaceSet render_ray_polyrep
784 #define make_IndexedFaceSet make_genericfaceset
785 #define make_ElevationGrid make_genericfaceset
786 #define rendray_ElevationGrid render_ray_polyrep
789 #define rendray_IndexedTriangleSet render_ray_polyrep
790 #define rendray_IndexedTriangleFanSet render_ray_polyrep
791 #define rendray_IndexedTriangleStripSet render_ray_polyrep
792 #define rendray_IndexedQuadSet render_ray_polyrep
793 #define rendray_QuadSet render_ray_polyrep
794 #define rendray_TriangleSet render_ray_polyrep
795 #define rendray_TriangleFanSet render_ray_polyrep
796 #define rendray_TriangleStripSet render_ray_polyrep
797 #define collide_IndexedFaceSet collide_genericfaceset
798 #define collide_IndexedTriangleFanSet collide_genericfaceset
799 #define collide_IndexedTriangleSet collide_genericfaceset
800 #define collide_IndexedTriangleStripSet collide_genericfaceset
801 #define collide_IndexedQuadSet collide_genericfaceset
802 #define collide_QuadSet collide_genericfaceset
803 #define collide_TriangleFanSet collide_genericfaceset
804 #define collide_TriangleSet collide_genericfaceset
805 #define collide_TriangleStripSet collide_genericfaceset
806 #define make_IndexedTriangleFanSet make_genericfaceset
807 #define make_IndexedTriangleSet make_genericfaceset
808 #define make_IndexedTriangleStripSet make_genericfaceset
809 #define make_IndexedQuadSet make_genericfaceset
810 #define make_QuadSet make_genericfaceset
811 #define make_TriangleFanSet make_genericfaceset
812 #define make_TriangleSet make_genericfaceset
813 #define make_TriangleStripSet make_genericfaceset
814 #define rendray_GeoElevationGrid render_ray_polyrep
815 #define collide_GeoElevationGrid collide_genericfaceset
816 #define make_GeoElevationGrid make_genericfaceset
820 void do_BooleanFilter (
void *node);
821 void do_BooleanSequencer (
void *node);
822 void do_BooleanToggle (
void *node);
823 void do_BooleanTrigger (
void *node);
824 void do_IntegerSequencer (
void *node);
825 void do_IntegerTrigger (
void *node);
826 void do_TimeTrigger (
void *node);
829 #define ADD_PARENT(a,b) add_parent(a,b,__FILE__,__LINE__)
834 #define LIGHTING_ON if (!tg->RenderFuncs.lightingOn) {tg->RenderFuncs.lightingOn=TRUE;}
835 #define LIGHTING_OFF if(tg->RenderFuncs.lightingOn) {tg->RenderFuncs.lightingOn=FALSE;}
837 #define LIGHTING_INITIALIZE gglobal()->RenderFuncs.lightingOn=TRUE;
839 void zeroAllBindables(
void);
841 int inputParse(
unsigned type,
char *inp,
int bind,
int returnifbusy,
842 void *ptr,
unsigned ofs,
int *complete,
844 void compileNode (
void (*nodefn)(
void *,
void *,
void *,
void *,
void *,
void *),
void *node,
void *a,
void *b,
void *c,
void *d,
void *e);
845 void destroyCParserData();
848 void getMovieTextureOpenGLFrames(
int *highest,
int *lowest,
int myIndex);
849 int ConsoleMessage(
const char *fmt, ...);
850 void closeConsoleMessage(
void);
853 void outOfMemory(
const char *message);
855 void killErrantChildren(
void);
857 void kill_routing(
void);
858 void kill_bindables(
void);
859 void kill_javascript(
void);
860 void kill_oldWorld(
int kill_EAI,
int kill_JavaScript,
char *file,
int line);
861 void reset_Browser();
862 void kill_clockEvents(
void);
864 void kill_X3DDefs(
void);
867 int countCommas (
char *instr);
873 void setglClearColor (
float *val);
874 void doglClearColor(
void);
875 extern int cc_changed;
878 int mapFieldTypeToInernaltype (
unsigned int kwIndex);
879 void resetSensorEvents();
884 void handleUnitDataStringString(
char *categoryname,
char *unitname,
double conversionfactor);
885 void handleProfile(
int myp);
886 void handleComponent(
int com,
int lev);
887 void handleExport (
char *node,
char *as);
888 void handleImport (
char *nodeName,
char *nodeImport,
char *as);
889 void handleVersion (
const char *versionString);
893 void registerX3DNode(
struct X3D_Node * node);
895 void doNotRegisterThisNodeForDestroy(
struct X3D_Node * nodePtr);
899 void replaceWorldNeeded(
char* str);
902 int X3DParse(
struct X3D_Node *ectx,
struct X3D_Node *parent,
const char *inputstring);
903 void *createNewX3DNode (
int nt);
904 void *createNewX3DNode0 (
int nt);
905 void *createNewX3DNodeB(
int nt,
int intable,
void *executionContext);
907 char *findFIELDNAMESfromNodeOffset0(
struct X3D_Node *node,
int offset);
909 void print_routes(FILE* fp);
910 void print_DEFed_node_names_and_pointers(FILE* fp);
913 void profile_start(
char *);
914 void profile_end(
char *);
915 void profile_print_all();
919 char ciflag_get(
int flags,
int index);
920 int ciflag_set(
int flags,
char flag,
int index );
921 int indexChildrenName(
struct X3D_Node *node);
923 int offsetofChildren(
struct X3D_Node *node);