diff --git a/CHANGELOG .md b/CHANGELOG .md index 9d20ce6..0ba34a1 100644 --- a/CHANGELOG .md +++ b/CHANGELOG .md @@ -8,7 +8,7 @@ Contact Us @ info@3dhop.net -16 March 2018 +4 June 2018 #### TEAM --------- @@ -21,17 +21,21 @@ Marco Potenziani @ marco.potenziani@isti.cnr.it #### CHANGELOG FILE ------------------- -*Version DEVELOPMENT* +*Version 4.2* **Main Changes** * Added GLOBAL LIGHTING control; * Added basic MOBILE DEVICE support; +* Fixed IE browser critical bug; +* Updated NEXUS TEXTURE HANDLING and DATA CACHING systems; +* Updated PLY parser; +* Updated SHADERS SET; +* Updated SCENE CREATION system; +* Updated ZOOM and CENTERING modes and functions; * Updated CAMERA PROJECTION modes and functions; * Updated TOUCH HANDLING; * Updated UI system; -* Updated TEXTURE HANDLING and DATA CACHING systems; -* Updated PLY parser; * Updated PICKING functions; * Updated PLANES SECTIONING TOOL; * Updated TRACKBALL SET; @@ -39,45 +43,14 @@ Marco Potenziani @ marco.potenziani@isti.cnr.it **Files Added/Modified** * Added "HOWTO_10.0_camera_lighting.html" file; +* Added "HOWTO_10.1_camera_lighting.html" file; * Added "logo.png" file; +* Added "corto.js" file; * Added "meco.js" file; -* Updated "index_all_tools.html" file; +* Added "gargo.nxz" model file; +* Removed "gargo.nxs" model file; +* Removed "meshcoder_worker.js" file; +* Updated all "*.html" files; * Updated all "*.js" files; -* Updated "3dhop.css" file; +* Updated all "*.css" files; * Updated "skins" directory; - -*Version 4.1* - -**Main Changes** - -* Fixed "MISSING PATCH" BUG in NEXUS models rendering; -* Fixed "TEXTURE WAKE UP" BUG in NEXUS models rendering; -* Fixed SAFARI browser PATCH for NEXUS models rendering; -* Fixed MINOR issues in TRACKBALL SET; -* Updated NEXUS RENDERING and MEMORY ALLOCATION system; -* Updated and optimized SHADERS SET; -* Updated TRACKBALL PAN SPEED; -* Updated COLOR CODED ID feature; -* Updated MEASUREMENT HANDLER; -* Added STYLESHEET for viewer informative PANELS; -* Added ALL TOOL viewer TEMPLATE; -* Added NEW SHADER for clusters of points/lines; -* Added TOOLBAR COLOR SWITCH function; -* Added POINTSIZE setup in SCENE CONFIG; -* Added mouse RIGHT BUTTON PAN feature; -* Added REPAINT function; -* Added support for TEXTURES and POINT CLOUDS for PLY models; -* Added ORTHOGRAPHIC CAMERA mode and functions; -* Minified spidergl.js file; -* Cleanup code and indentation in various .js files; - -**Files Added/Modified** - -* Added "3DHpanels.css" file; -* Added "index_all_tools.html" file; -* Updated "index.html" file and renamed "index_no_tools.html"; -* Updated "HOWTO_8.1_point_picking.html" file; -* Updated "HOWTO_8.0_measurement_tool.html" file; -* Updated all "*.js" files; -* Updated "3dhop.css" file; -* Updated "docs.html" file; diff --git a/CHANGELOG.txt b/CHANGELOG.txt index 9d20ce6..0ba34a1 100644 --- a/CHANGELOG.txt +++ b/CHANGELOG.txt @@ -8,7 +8,7 @@ Contact Us @ info@3dhop.net -16 March 2018 +4 June 2018 #### TEAM --------- @@ -21,17 +21,21 @@ Marco Potenziani @ marco.potenziani@isti.cnr.it #### CHANGELOG FILE ------------------- -*Version DEVELOPMENT* +*Version 4.2* **Main Changes** * Added GLOBAL LIGHTING control; * Added basic MOBILE DEVICE support; +* Fixed IE browser critical bug; +* Updated NEXUS TEXTURE HANDLING and DATA CACHING systems; +* Updated PLY parser; +* Updated SHADERS SET; +* Updated SCENE CREATION system; +* Updated ZOOM and CENTERING modes and functions; * Updated CAMERA PROJECTION modes and functions; * Updated TOUCH HANDLING; * Updated UI system; -* Updated TEXTURE HANDLING and DATA CACHING systems; -* Updated PLY parser; * Updated PICKING functions; * Updated PLANES SECTIONING TOOL; * Updated TRACKBALL SET; @@ -39,45 +43,14 @@ Marco Potenziani @ marco.potenziani@isti.cnr.it **Files Added/Modified** * Added "HOWTO_10.0_camera_lighting.html" file; +* Added "HOWTO_10.1_camera_lighting.html" file; * Added "logo.png" file; +* Added "corto.js" file; * Added "meco.js" file; -* Updated "index_all_tools.html" file; +* Added "gargo.nxz" model file; +* Removed "gargo.nxs" model file; +* Removed "meshcoder_worker.js" file; +* Updated all "*.html" files; * Updated all "*.js" files; -* Updated "3dhop.css" file; +* Updated all "*.css" files; * Updated "skins" directory; - -*Version 4.1* - -**Main Changes** - -* Fixed "MISSING PATCH" BUG in NEXUS models rendering; -* Fixed "TEXTURE WAKE UP" BUG in NEXUS models rendering; -* Fixed SAFARI browser PATCH for NEXUS models rendering; -* Fixed MINOR issues in TRACKBALL SET; -* Updated NEXUS RENDERING and MEMORY ALLOCATION system; -* Updated and optimized SHADERS SET; -* Updated TRACKBALL PAN SPEED; -* Updated COLOR CODED ID feature; -* Updated MEASUREMENT HANDLER; -* Added STYLESHEET for viewer informative PANELS; -* Added ALL TOOL viewer TEMPLATE; -* Added NEW SHADER for clusters of points/lines; -* Added TOOLBAR COLOR SWITCH function; -* Added POINTSIZE setup in SCENE CONFIG; -* Added mouse RIGHT BUTTON PAN feature; -* Added REPAINT function; -* Added support for TEXTURES and POINT CLOUDS for PLY models; -* Added ORTHOGRAPHIC CAMERA mode and functions; -* Minified spidergl.js file; -* Cleanup code and indentation in various .js files; - -**Files Added/Modified** - -* Added "3DHpanels.css" file; -* Added "index_all_tools.html" file; -* Updated "index.html" file and renamed "index_no_tools.html"; -* Updated "HOWTO_8.1_point_picking.html" file; -* Updated "HOWTO_8.0_measurement_tool.html" file; -* Updated all "*.js" files; -* Updated "3dhop.css" file; -* Updated "docs.html" file; diff --git a/README.md b/README.md index 6c16e15..7af069a 100644 --- a/README.md +++ b/README.md @@ -8,7 +8,7 @@ Contact Us @ info@3dhop.net -16 March 2018 +4 June 2018 #### TEAM --------- diff --git a/README.txt b/README.txt index 6c16e15..7af069a 100644 --- a/README.txt +++ b/README.txt @@ -8,7 +8,7 @@ Contact Us @ info@3dhop.net -16 March 2018 +4 June 2018 #### TEAM --------- diff --git a/documentation/docs.html b/documentation/docs.html index 47742c2..3a181fe 100644 --- a/documentation/docs.html +++ b/documentation/docs.html @@ -14,340 +14,401 @@

3DHOP
-

Docs

+

Docs

-

Basic documentation

+

Basic documentation

-

Exposed functions

-

- 3DHOP object related native functions: -

- - - +

Exposed functions

+

+ 3DHOP object related native functions: +

+
  • animateToTrackballPosition(position)-set a new position for the used trackball and animate the camera from the current point of view to the new setted;
    Parametersposition[array] : the spatial coordinates of the trackball (the number of values may varying depending on the used trackball);
    + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - - + + - - - + + - - + + - - + + + - - + + + - - - + + + - - - + + + - - + + + - + + + - + + + - + + + - - - + + - + + - + + - + + - + + + - - + + + - - + + - - - - + - - - - + - - + - - + + + - - + - - + - - + - - + - - - - - + + - - - - + + - - + + + + - - + + + + - - + + - - - - - + + - - - - - + + - - - - - + + - - - - - + + - - - - + + - - - - + + + + + - + + + + - + + - - + + - - + + - - + + + + - - - - + + + + - - - - + + + + + - - + + + + + - - + + + + + - + + + + + - + + + + - - - + + + + - - - + - - - + - - - + + - - - + + - - - + + - - - + + + + - - - + + + + - + + - + + - -
  • animateToTrackballPosition(position)-set a new position for the used trackball and animate the camera from the current point of view to the new setted;
    Parametersposition[array] : the spatial coordinates of the trackball (the number of values may varying depending on the used trackball);
  • enableLightTrackball(state)-enable or disable the 3D scene trackball interactive lighting control;
    Parametersstate[boolean] : true to enable, false to disable (light trackball is disabled by default);
  • enableLightTrackball(state)-enable or disable the 3D scene trackball interactive lighting control;
    Parametersstate[boolean] : true to enable, false to disable (light trackball is disabled by default). Enabling the interactive light trackball control also enables the scene lighting (if disabled);
  • enableMeasurementTool(state)-enable or disable the 3D scene interactive measurement tool;
    Parametersstate[boolean] : true to enable, false to disable (measurement tool is disabled by default);
  • enableMeasurementTool(state)-enable or disable the 3D scene interactive measurement tool;
    Parametersstate[boolean] : true to enable, false to disable (measurement tool is disabled by default);
  • enableOnHover(state)-enable or disable the visual effects (spots transparency and mouse cursor changes) related to the movement of the mouse pointer onto a mesh in the 3D scene.
    Parametersstate[boolean] : true to enable, false to disable (on hover effects are disabled by default). Visual effects activation could decreases performance on slower systems;
  • enableOnHover(state)-enable or disable the visual effects (spots transparency and mouse cursor changes) related to the movement of the mouse pointer onto a mesh in the 3D scene.
    Parametersstate[boolean] : true to enable, false to disable (on hover effects are disabled by default). Visual effects activation could decreases performance on slower systems;
  • enablePickpointMode(state)-enable or disable the 3D scene interactive point picking mode;
    Parametersstate[boolean] : true to enable, false to disable (point picking mode is disabled by default);
  • enablePickpointMode(state)-enable or disable the 3D scene interactive point picking mode;
    Parametersstate[boolean] : true to enable, false to disable (point picking mode is disabled by default);
  • getClippingRendermode()return the current rendering setup of the sectioning tool (sectioning planes and edges visibility state, edges size and color values);
    Returns-[array] : the 4-dimensional array containing the sectioning tool setup values: sectioning planes visibility (true if rendered, false if not), sectioning edges visibility (true if rendered, false if not), sectioning edges size value (express in scene space absolute value), sectioning edges color 3-dimensional array (express in RGB arithmetic notation, from 0 to 1, with any fractional value in between);
  • enableSceneLighting(state)-enable or disable the 3D scene lighting system;
    Parametersstate[boolean] : true to enable, false to disable (scene lighting is enabled by default). Disabling the scene lighting also disables the interactive light trackball control (if enabled);
  • getClippingX()return the current operating state of the sectioning plane along the X axis;
    Returns-[number] : the operating state of the sectioning plane along the X axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • getCameraType()return the current setup of the virtual camera (projection mode);
    Returns-[string] : the projection mode name ("perspective" or "orthographic", "perspective" is selected by default);
  • getClippingY()return the current operating state of the sectioning plane along the Y axis;
    Returns-[number] : the operating state of the sectioning plane along the Y axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • getClippingRendermode()return the current rendering setup of the sectioning tool (sectioning planes and edges visibility state, edges size and color values);
    Returns-[array] : the 4-dimensional array containing the sectioning tool setup values: sectioning planes visibility (true if rendered, false if not), sectioning edges visibility (true if rendered, false if not), sectioning edges size value (expressed in scene space absolute value), sectioning edges color 3-dimensional array (expressed in RGB arithmetic notation, from 0 to 1, with any fractional value in between);
  • getClippingZ()return the current operating state of the sectioning plane along the Z axis;
    Returns-[number] : the operating state of the sectioning plane along the Z axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • getClippingX()return the current operating state of the sectioning plane along the X axis;
    Returns-[number] : the operating state of the sectioning plane along the X axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • getTrackballPosition()return the current position of the used trackball;
    Returns-[array] : the spatial coordinates of the trackball (the number of values may vary depending on the used trackball);
  • getClippingY()return the current operating state of the sectioning plane along the Y axis;
    Returns-[number] : the operating state of the sectioning plane along the Y axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • isAnyMeasurementEnabled()return the activation status of the 3D scene interactive measurement tools (measurement tool and point picking mode);
    Returns-[boolean] : true if enabled, false if disabled. The function returns true if at least one of all the measurement tool is enabled;
  • getClippingZ()return the current operating state of the sectioning plane along the Z axis;
    Returns-[number] : the operating state of the sectioning plane along the Z axis: 0 if disabled, 1 if enabled (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also if enabled (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • isInstanceVisibilityEnabled(tag)return the visibility status in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if visible, false if not visible. If tag is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • getTrackballPosition()return the current position of the used trackball;
    Returns-[array] : the spatial coordinates of the trackball (the number of values may vary depending on the used trackball);
  • isInstanceVisibilityEnabledByName(name)return the visibility status in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if visible, false if not visible. If name is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • isAnimate()return the activation status of the 3D scene camera animation feature;
    Returns-[boolean] : true if enabled, false if disabled;
  • isLightTrackballEnabled()return the activation status of the 3D scene trackball interactive lighting control;
    Returns-[boolean] : true if enabled, false if disabled;
  • isAnyMeasurementEnabled()return the activation status of the 3D scene interactive measurement tools (measurement tool and point picking mode);
    Returns-[boolean] : true if enabled, false if disabled. The function returns true if at least one of all the measurement tool is enabled;
  • isMeasurementToolEnabled()return the activation status of the 3D scene interactive measurement tool;
    Returns-[boolean] : true if enabled, false if disabled;
  • isInstanceLightingEnabled(tag)return the lighting activation status in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables lighting;
  • isPickpointModeEnabled()return the activation status of the 3D scene interactive point picking mode;
    Returns-[boolean] : true if enabled, false if disabled;
  • isInstanceLightingEnabledByName(name)return the lighting activation status in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables lighting;
  • isSpotVisibilityEnabled(tag)return the visibility status in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if visible, false if not visible. If tag is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • isInstanceVisibilityEnabled(tag)return the visibility status in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if visible, false if not visible. If tag is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • isSpotVisibilityEnabledByName(name)return the visibility status in the 3D scene of the hot spot instance specified by name;
    Parametersname[string] : the instance name specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if visible, false if not visible. If name is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • isInstanceVisibilityEnabledByName(name)return the visibility status in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if visible, false if not visible. If name is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • isOnHoverEnabled()return the activation status of the visual effects (spots transparency and mouse cursor changes) related to the movement of the mouse pointer onto a mesh in the 3D scene;
    Returns-[boolean] : true if enabled, false if disabled;
  • isInstanceSolidColorEnabled(tag)return the solid color usage status in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the solid color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables solid colors;
  • repaint()redraw the 3D scene;
  • isInstanceSolidColorEnabledByName(name)return the solid color usage status in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the solid color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables solid colors;
  • resetClippingXYZ()-reset both the position and the operating state of the sectioning planes along the X, Y and Z axes to the initial setting;
  • isInstanceTransparencyEnabled(tag)return the transparency status in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables transparency;
  • resetTrackball()-reset both the position and light control trackballs to the initial setting;
  • isInstanceTransparencyEnabledByName(name)return the transparency status in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if active, false if not active. If tag is "HOP_ALL" the function returns true if at least one of all the instances enables transparency;
  • rotateLight(x, y)-rotate the 3D scene light trackball;
    Parametersx[number] : the amount of displacement along the x-axis (accepts values ranging from -0.5 to 0.5);
    y[number] : the amount of displacement along the y-axis (accepts values ranging from -0.5 to 0.5);
  • isLightTrackballEnabled()return the activation status of the 3D scene trackball interactive lighting control;
    Returns-[boolean] : true if enabled, false if disabled;
  • setCameraPerspective()-set the camera type to perspective projection mode;
  • isMeasurementToolEnabled()return the activation status of the 3D scene interactive measurement tool;
    Returns-[boolean] : true if enabled, false if disabled;
  • setCameraOrthographic()-set the camera type to orthographic projection mode;
  • isPickpointModeEnabled()return the activation status of the 3D scene interactive point picking mode;
    Returns-[boolean] : true if enabled, false if disabled;
  • setCenterModeFirst()-set the virtual scene center in the barycenter of its first declared model instance;
  • isSceneLightingEnabled()return the activation status of the 3D scene lighting system;
    Returns-[boolean] : true if enabled, false if disabled;
  • setCenterModeScene()-set the virtual scene center in the barycenter of all model instances which compose the scene;
  • isSpotVisibilityEnabled(tag)return the visibility status in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances ("HOP_ALL is the default tag value");
    Returns-[boolean] : true if visible, false if not visible. If tag is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • setCenterModeSpecific(name)-set the virtual scene center in the barycenter of the specified model instance;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the scene will be centered;
  • isSpotVisibilityEnabledByName(name)return the visibility status in the 3D scene of the hot spot instance specified by name;
    Parametersname[string] : the instance name specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances ("HOP_ALL is the default name value");
    Returns-[boolean] : true if visible, false if not visible. If name is "HOP_ALL" the function returns true if at least one of all the instances is visible;
  • setCenterModeExplicit(point)-set the virtual scene center in the specified spatial coordinates;
    Parameterspoint[array] : the 3-dimensional array containing the point spatial coordinates in vector notation (express in scene space absolute value);
  • isOnHoverEnabled()return the activation status of the visual effects (spots transparency and mouse cursor changes) related to the movement of the mouse pointer onto a mesh in the 3D scene;
    Returns-[boolean] : true if enabled, false if disabled;
  • setClippingPointXYZ(x, y, z)-set the intersection points of the sectioning planes along the X, Y and Z axes (expressed in normalized value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values ranging to 0 and 1);
    y[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values ranging from 0 to 1);
    z[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values ranging from 0 to 1);
  • repaint()redraw the 3D scene;
  • setClippingPointXYZabs(x, y, z)-set the intersection points of the sectioning planes along the X, Y and Z axes (expressed in scene space absolute value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values expressed in scene space absolute value);
    y[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values expressed in scene space absolute value);
    z[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values expressed in scene space absolute value);
  • resetClippingXYZ()-reset both the position and the operating state of the sectioning planes along the X, Y and Z axes to the initial setting;
  • setClippingPointX(x)-set the intersection point of the sectioning plane along the X, axis (expressed in normalized value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values ranging to 0 and 1);
  • resetTrackball()-reset both the position and light control trackballs to the initial setting;
  • setClippingPointXabs(x)-set the intersection point of the sectioning plane along the X axis (expressed in scene space absolute value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values expressed in scene space absolute value);
  • rotateLight(x, y)-rotate the 3D scene light trackball;
    Parametersx[number] : the amount of displacement along the x-axis (accepts values ranging from -0.5 to 0.5);
    y[number] : the amount of displacement along the y-axis (accepts values ranging from -0.5 to 0.5);
  • setClippingPointY(y)-set the intersection point of the sectioning plane along the Y axis (expressed in normalized value);
    Parametersy[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values ranging from 0 to 1);
  • setCameraPerspective()-set the camera type to perspective projection mode;
  • setClippingPointYabs(y)-set the intersection point of the sectioning plane along the Y axis (expressed in scene space absolute value);
    Parametersy[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values expressed in scene space absolute value);
  • setCameraOrthographic()-set the camera type to orthographic projection mode;
  • setClippingPointZ(z)-set the intersection point of the sectioning plane along the Z axis (expressed in normalized value);
    Parametersz[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values ranging from 0 to 1);
  • setCenterModeFirst()-set the virtual scene center in the barycenter of its first declared model instance;
  • setClippingPointZabs(z)-set the intersection point of the sectioning plane along the Z axis (expressed in scene space absolute value);
    Parametersz[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values expressed in scene space absolute value);
  • setCenterModeScene()-set the virtual scene center in the barycenter of all model instances which compose the scene;
  • setClippingRendermode(state, state, *size, *color)-customize the rendering setup of the sectioning tool (sectioning planes and edges visibility state, and optionally edges size and color values);
    Parametersstate[boolean] : true to render the sectioning planes (if any), false to not render (true by default);
    state[boolean] : true to render the sectioning edges (if any), false to not render (false by default);
    size[number] : the size value (express in scene space absolute value) of the sectioning edges (if rendered). Accepts values greater than 0.0. Optional parameter (default sectioning edges size is 0.5);
    color[array] : the 3-dimensional array containing color values of the sectioning edges (if rendered). Accepts values express in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default sectioning edges color is [0.0, 1.0, 1.0]);
  • setCenterModeSpecific(name)-set the virtual scene center in the barycenter of the specified model instance;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the scene will be centered;
  • setClippingXYZ(state, state, state)-set the operating state of the sectioning planes along the X, Y and Z axes;
    Parametersstate[number] : the operating state of the X axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
    state[number] : the operating state of the Y axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
    state[number] : the operating state of the Z axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setCenterModeExplicit(point)-set the virtual scene center in the specified spatial coordinates;
    Parameterspoint[array] : the 3-dimensional array containing the point spatial coordinates in vector notation (expressed in scene space absolute value);
  • setClippingX(state)-set the operating state of the sectioning plane along the X axis;
    Parametersstate[number] : the operating state of the X axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setClippingPointXYZ(x, y, z)-set the intersection points of the sectioning planes along the X, Y and Z axes (expressed in normalized value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values ranging to 0 and 1);
    y[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values ranging from 0 to 1);
    z[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values ranging from 0 to 1);
  • setClippingY(state)-set the operating state of the sectioning plane along the Y axis;
    Parametersstate[number] : the operating state of the Y axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setClippingPointXYZabs(x, y, z)-set the intersection points of the sectioning planes along the X, Y and Z axes (expressed in scene space absolute value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values expressed in scene space absolute value);
    y[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values expressed in scene space absolute value);
    z[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values expressed in scene space absolute value);
  • setClippingZ(state)-set the operating state of the sectioning plane along the Z axis;
    Parametersstate[number] : the operating state of the Z axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setClippingPointX(x)-set the intersection point of the sectioning plane along the X, axis (expressed in normalized value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values ranging to 0 and 1);
  • setInstanceSolidColor(tag, state, redraw, *color)-set a solid color for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance solid color, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    color[array] : the 3-dimensional array containing color values express in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default solid color is [1.0, 1.0, 1.0]);
  • setClippingPointXabs(x)-set the intersection point of the sectioning plane along the X axis (expressed in scene space absolute value);
    Parametersx[number] : the intersection point between the X sectioning plane and the X axis (accepts values expressed in scene space absolute value);
  • setInstanceSolidColorByName(name, state, redraw, *color)-set a solid color for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance solid color, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    color[array] : the 3-dimensional array containing color values express in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default solid color is [1.0, 1.0, 1.0]);
  • setClippingPointY(y)-set the intersection point of the sectioning plane along the Y axis (expressed in normalized value);
    Parametersy[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values ranging from 0 to 1);
  • setInstanceTransparency(tag, state, redraw, *alpha)-set the transparency of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance transparency, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    alpha[number] : the alpha transparency value, varying from 0 (max transparency) to 1 (min transparency), with any fractional value in between. Optional parameter (default alpha value is 0.5);
  • setClippingPointYabs(y)-set the intersection point of the sectioning plane along the Y axis (expressed in scene space absolute value);
    Parametersy[number] : the intersection point between the Y sectioning plane and the Y axis (accepts values expressed in scene space absolute value);
  • setInstanceTransparencyByName(name, state, redraw, *alpha)-set the transparency of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance transparency, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    alpha[number] : the alpha transparency value, varying from 0 (max transparency) to 1 (min transparency), with any fractional value in between. Optional parameter (default alpha value is 0.5);
  • setClippingPointZ(z)-set the intersection point of the sectioning plane along the Z axis (expressed in normalized value);
    Parametersz[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values ranging from 0 to 1);
  • setInstanceVisibility(tag, state, redraw)-set the visibility in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setClippingPointZabs(z)-set the intersection point of the sectioning plane along the Z axis (expressed in scene space absolute value);
    Parametersz[number] : the intersection point between the Z sectioning plane and the Z axis (accepts values expressed in scene space absolute value);
  • setInstanceVisibilityByName(name, state, redraw)-set the visibility in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setClippingRendermode(state, state, *size, *color)-customize the rendering setup of the sectioning tool (sectioning planes and edges visibility state, and optionally edges size and color values);
    Parametersstate[boolean] : true to render the sectioning planes (if any), false to not render (true by default);
    state[boolean] : true to render the sectioning edges (if any), false to not render (false by default);
    size[number] : the size value (expressed in scene space absolute value) of the sectioning edges (if rendered). Accepts values greater than 0.0. Optional parameter (default sectioning edges size is 0.5);
    color[array] : the 3-dimensional array containing color values of the sectioning edges (if rendered). Accepts values expressed in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default sectioning edges color is [0.0, 1.0, 1.0]);
  • setRadiusModeFirst()-scale the virtual scene to fit in the viewer the first declared model instance;
  • setClippingXYZ(state, state, state)-set the operating state of the sectioning planes along the X, Y and Z axes;
    Parametersstate[number] : the operating state of the X axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
    state[number] : the operating state of the Y axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
    state[number] : the operating state of the Z axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setRadiusModeScene()-scale the virtual scene to fit in the viewer all model instances which compose the scene;
  • setClippingX(state)-set the operating state of the sectioning plane along the X axis;
    Parametersstate[number] : the operating state of the X axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the X axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the X axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setRadiusModeSpecific(name)-scale the virtual scene to fit in the viewer the specified model instance;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the scene will be scaled;
  • setClippingY(state)-set the operating state of the sectioning plane along the Y axis;
    Parametersstate[number] : the operating state of the Y axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Y axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Y axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setRadiusModeExplicit(size)-scale the virtual scene to fit in the viewer an object with the specified size;
    Parameterssize[number] : the size value (express in scene space absolute value) on which the scene will be scaled. Accepts values greater than 0.0;
  • setClippingZ(state)-set the operating state of the sectioning plane along the Z axis;
    Parametersstate[number] : the operating state of the Z axis sectioning plane. Accepts three values: 0 to disable the related sectioning plane, 1 to enable it (splitting the 3D scene along the Z axis, cutting out the clippable instances on the positive side of the intersection), and -1 also to enable it (again splitting the 3D scene along the Z axis, but this time cutting out the clippable instances on the negative side of the intersection);
  • setScene(options)-3DHOP main method, set the 3D scene;
    Parametersoptions[multiple values] : all the text fields that define the virtual scene (meshes, modelInstances, spots, trackball, space). Check the how to section for more details;
  • setInstanceLighting(tag, state, redraw)-set the lighting for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance lighting, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setSpotVisibility(tag, state, redraw)-set the visibility in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setInstanceLightingByName(name, state, redraw)-set the lighting for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance lighting, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setSpotVisibilityByName(name, state, redraw)-set the visibility in the 3D scene of the hot spot instance specified by name;
    Parametersname[string] : the instance name specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setInstanceSolidColor(tag, state, redraw, *color)-set a solid color for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance solid color, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    color[array] : the 3-dimensional array containing color values expressed in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default solid color is [1.0, 1.0, 1.0]);
  • setTrackballPosition(position)-set a new position for the used trackball and redraw the 3D scene with the camera in the new setted point;
    Parametersposition[array] : the spatial coordinates of the trackball (the number of values may varying depending on the used trackball);
  • setInstanceSolidColorByName(name, state, redraw, *color)-set a solid color for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance solid color, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    color[array] : the 3-dimensional array containing color values expressed in RGB arithmetic notation (from 0 to 1, with any fractional value in between). Optional parameter (default solid color is [1.0, 1.0, 1.0]);
  • supportsWebGL()check if the system supports the WebGL API;
    Returns-[boolean] : true if supported, false if not supported;
  • setInstanceTransparency(tag, state, redraw, *alpha)-set the transparency of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance transparency, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    alpha[number] : the alpha transparency value, varying from 0 (max transparency) to 1 (min transparency), with any fractional value in between. Optional parameter (default alpha value is 0.5);
  • toggleCameraType()-toggle the camera type between perspective and orthographic projection modes;
  • setInstanceTransparencyByName(name, state, redraw, *alpha)-set the transparency of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to active the instance transparency, false to not active;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
    alpha[number] : the alpha transparency value, varying from 0 (max transparency) to 1 (min transparency), with any fractional value in between. Optional parameter (default alpha value is 0.5);
  • toggleDebugMode()-toggle 3DHOP between normal mode and debug mode;
  • setInstanceVisibility(tag, state, redraw)-set the visibility in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • toggleInstanceSolidColor(tag, redraw)-toggle the solid color usage for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setInstanceVisibilityByName(name, state, redraw)-set the visibility in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • toggleInstanceSolidColorByName(name, redraw)-toggle the solid color usage for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setRadiusModeFirst()-scale the virtual scene to fit in the viewer the first declared model instance;
  • toggleInstanceTransparency(tag, redraw)-toggle the transparency usage for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setRadiusModeScene()-scale the virtual scene to fit in the viewer all model instances which compose the scene;
  • toggleInstanceTransparencyByName(name, redraw)-toggle the transparency usage for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setRadiusModeSpecific(name)-scale the virtual scene to fit in the viewer the specified model instance;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the scene will be scaled;
  • toggleInstanceVisibility(tag, redraw)-toggle the visibility in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setRadiusModeExplicit(size)-scale the virtual scene to fit in the viewer an object with the specified size;
    Parameterssize[number] : the size value (expressed in scene space absolute value) on which the scene will be scaled. Accepts values greater than 0.0;
  • toggleInstanceVisibilityByName(name, redraw)-toggle the visibility in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setScene(options)-3DHOP main method, set the 3D scene;
    Parametersoptions[multiple values] : all the text fields that define the virtual scene (meshes, modelInstances, spots, trackball, space). Check the how to section for more details;
  • toggleSpotVisibility(tag, redraw)-toggle the visibility in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setSpotVisibility(tag, state, redraw)-set the visibility in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • toggleSpotVisibilityByName(name, redraw)-toggle the visibility in the 3D scene of the hot spot instance specified by name;
    Parameterstag[string] : the name instance specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • setSpotVisibilityByName(name, state, redraw)-set the visibility in the 3D scene of the hot spot instance specified by name;
    Parametersname[string] : the instance name specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    state[boolean] : true to make the instance visible, false to not make;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • zoomIn()-zoom the camera one step into the 3D scene;
  • setTrackballPosition(position)-set a new position for the used trackball and redraw the 3D scene with the camera in the new setted point;
    Parametersposition[array] : the spatial coordinates of the trackball (the number of values may varying depending on the used trackball);
  • zoomOut()-zoom the camera one step out of the 3D scene;
  • supportsWebGL()check if the system supports the WebGL API;
    Returns-[boolean] : true if supported, false if not supported;
    -
    +
  • toggleCameraType()-toggle the camera type between perspective and orthographic projection modes; -

    Hooked functions

    -

    - 3DHOP object related callback functions (activated by specific events): -

    - - - - - + - - + + + - - + + + - - + + + - - + + + - - + + + - - + + + - - -
  • _onEndMeasurement(measure, *point, *point)-bind an event handler to be fired when a measurement action ends;
    Parametersmeasure[number] : the size of the last measurement performed (expressed in scene space absolute value);
    point[array] : the 3-dimensional array containing the spatial coordinates of the first measure point picked (expressed in scene space absolute value). Optional parameter;
    point[array] : the 3-dimensional array containing the spatial coordinates of the last measure point picked (expressed in scene space absolute value). Optional parameter;
  • toggleDebugMode()-toggle 3DHOP between normal mode and debug mode;
  • _onEndPickingPoint(point)-bind an event handler to be fired when a point picking action ends;
    Parameterspoint[array] : the 3-dimensional array containing the spatial coordinates of the last point picked (expressed in scene space absolute value);
  • toggleInstanceLighting(tag, redraw)-toggle the lighting in the 3D scene of the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onEnterInstance(id)-bind an event handler to be fired when the mouse enters an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • toggleInstanceLightingByName(name, redraw)-toggle the lighting in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the lighting command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onEnterSpot(id)-bind an event handler to be fired when the mouse enters a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
  • toggleInstanceSolidColor(tag, redraw)-toggle the solid color usage for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onLeaveInstance(id)-bind an event handler to be fired when the mouse leaves an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • toggleInstanceSolidColorByName(name, redraw)-toggle the solid color usage for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the color command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onLeaveSpot(id)-bind an event handler to be fired when the mouse leaves a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
  • toggleInstanceTransparency(tag, redraw)-toggle the transparency usage for the model instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onPickedInstance(id)-bind an event handler to be fired when the mouse clicks an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • toggleInstanceTransparencyByName(name, redraw)-toggle the transparency usage for the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the transparency command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • _onPickedSpot(id)-bind an event handler to be fired when the mouse clicks a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
    -
    +
  • toggleInstanceVisibility(tag, redraw)-toggle the visibility in the 3D scene of the model instance specified by tag; + Parameterstag[string] : the tag keyword specified in the "tags" field of "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances; + redraw[boolean] : true to redraw the 3D scene, false to not redraw; -

    Utility functions

    -

    - 3DHOP object independent utility functions: -

    - - + + + - + + + - + + + - + + - + - + - - - + +
  • colorSwitch()-switch between on/off toolbar related color mode button icon;
  • toggleInstanceVisibilityByName(name, redraw)-toggle the visibility in the 3D scene of the model instance specified by name;
    Parametersname[string] : the instance name specified in "modelInstance" (in "setScene") that refers the instance of the model on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the models instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • fullscreenSwitch()-switch between 3DHOP element fullscreen and normal mode, simultaneously updating the toolbar related button icon;
  • toggleSpotVisibility(tag, redraw)-toggle the visibility in the 3D scene of the hot spot instance specified by tag;
    Parameterstag[string] : the tag keyword specified in the "tags" field of "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • hotspotSwitch()-switch between on/off toolbar related hotspot button icon;
  • toggleSpotVisibilityByName(name, redraw)-toggle the visibility in the 3D scene of the hot spot instance specified by name;
    Parameterstag[string] : the name instance specified in "spots" (in "setScene") that refers the instance of the hot spot on which the visibility command acts. Accepts the constant value "HOP_ALL" too (without quotes) that refers all the hot spots instances;
    redraw[boolean] : true to redraw the 3D scene, false to not redraw;
  • lightSwitch()-switch between on/off toolbar related light control button icon;
  • version()check the 3DHOP version;
    Returns-[constant] : the constant value that refers to the framework version number (expressed in "version major" dot "version minor" dot "version revision" format);
  • measureSwitch()-switch between on/off toolbar related measurement tool button icon;
  • zoomIn()-zoom the camera one step into the 3D scene;
  • measurementSwitch()-switch between on/off toolbar related measurement tool button icon. This functionality is DEPRECATED, use "measureSwitch()" instead;
  • zoomOut()-zoom the camera one step out of the 3D scene;
  • moveMeasurebox(right, top)-move the 3DHOP measure output box around the screen. This functionality is DEPRECATED, use "moveMeasurementbox(left, top)" instead;
    Parametersright[number] : measure box right space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : measure box top space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
    +
    -
  • moveMeasurementbox(left, top)-move the 3DHOP measure output box around the screen; - Parametersleft[number] : measure box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes); - top[number] : measure box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes); +

    Hooked functions

    +

    + 3DHOP object related callback functions (activated by specific events): +

    + + + + + - - - + + - - - + + - - - + + - + + - - - + + - + + - + + +
  • _onEndMeasurement(measure, *point, *point)-bind an event handler to be fired when a measurement action ends;
    Parametersmeasure[number] : the size of the last measurement performed (expressed in scene space absolute value);
    point[array] : the 3-dimensional array containing the spatial coordinates of the first measure point picked (expressed in scene space absolute value). Optional parameter;
    point[array] : the 3-dimensional array containing the spatial coordinates of the last measure point picked (expressed in scene space absolute value). Optional parameter;
  • movePickpointbox(left, top)-move the 3DHOP point picking output box around the screen;
    Parametersleft[number] : point picking box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : point picking box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
  • _onEndPickingPoint(point)-bind an event handler to be fired when a point picking action ends;
    Parameterspoint[array] : the 3-dimensional array containing the spatial coordinates of the last point picked (expressed in scene space absolute value);
  • moveSectionsbox(left, top)-move the 3DHOP planes section output box around the screen;
    Parametersleft[number] : planes section output box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : planes section output box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
  • _onEnterInstance(id)-bind an event handler to be fired when the mouse enters an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • moveToolbar(left, top)-move the 3DHOP toolbar around the screen;
    Parametersleft[number] : toolbar left space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : toolbar top space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
  • _onEnterSpot(id)-bind an event handler to be fired when the mouse enters a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
  • pickpointSwitch()-switch between on/off toolbar related point picking tool button icon;
  • _onLeaveInstance(id)-bind an event handler to be fired when the mouse leaves an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • resizeCanvas(width, height)-change the 3DHOP sizes;
    Parameterswidth[number] : 3DHOP width value in px (default is full browser). Accepts the CSS width syntax too (enclosed in quotes);
    height[number] : 3DHOP height value in px (default is full browser). Accepts the CSS height syntax too (enclosed in quotes);
  • _onLeaveSpot(id)-bind an event handler to be fired when the mouse leaves a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
  • sectiontoolInit()-initialize the components in the planes section tool output box;
  • _onPickedInstance(id)-bind an event handler to be fired when the mouse clicks an instance;
    Parametersid[string] : the instance name specified in the "modelInstance" field of "setScene";
  • sectiontoolReset()-reset the components in the planes section tool output box;
  • _onPickedSpot(id)-bind an event handler to be fired when the mouse clicks a spot;
    Parametersid[string] : the spot name specified in the "spots" field of "setScene";
    +
    -
  • sectiontoolSwitch()-switch between on/off toolbar related planes section tool button icon; - -
    +

    Utility functions

    +

    + 3DHOP object independent utility functions: +

    + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  • cameraSwitch()-switch between on/off toolbar related camera projection button icon;
  • colorSwitch()-switch between on/off toolbar related color mode button icon;
  • fullscreenSwitch()-switch between 3DHOP element fullscreen and normal mode, simultaneously updating the toolbar related button icon;
  • hotspotSwitch()-switch between on/off toolbar related hotspot button icon;
  • lightSwitch()-switch between on/off toolbar related light control button icon. Turning on the light control button icon also turns on the lighting button icon (if present and off);
  • lightingSwitch()-switch between on/off toolbar related lighting button icon. Turning off the lighting button icon also turns off the light control button icon (if present and on);
  • measureSwitch()-switch between on/off toolbar related measurement tool button icon;
  • measurementSwitch()-switch between on/off toolbar related measurement tool button icon. This functionality is DEPRECATED, use "measureSwitch()" instead;
  • moveMeasurebox(right, top)-move the 3DHOP measure output box around the screen. This functionality is DEPRECATED, use "moveMeasurementbox(left, top)" instead;
    Parametersright[number] : measure box right space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : measure box top space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
  • moveMeasurementbox(left, top)-move the 3DHOP measure output box around the screen;
    Parametersleft[number] : measure box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : measure box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
  • movePickpointbox(left, top)-move the 3DHOP point picking output box around the screen;
    Parametersleft[number] : point picking box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : point picking box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
  • moveSectionsbox(left, top)-move the 3DHOP planes section output box around the screen;
    Parametersleft[number] : planes section output box left space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : planes section output box top space in px (relative to 3DHOP container, due to anchorage default value is related to toolbar position). Accepts the CSS positioning syntax too (enclosed in quotes);
  • moveToolbar(left, top)-move the 3DHOP toolbar around the screen;
    Parametersleft[number] : toolbar left space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
    top[number] : toolbar top space in px (relative to 3DHOP container, default value is 10). Accepts the CSS positioning syntax too (enclosed in quotes);
  • pickpointSwitch()-switch between on/off toolbar related point picking tool button icon;
  • resizeCanvas(width, height)-change the 3DHOP sizes;
    Parameterswidth[number] : 3DHOP width value in px (default is full browser). Accepts the CSS width syntax too (enclosed in quotes);
    height[number] : 3DHOP height value in px (default is full browser). Accepts the CSS height syntax too (enclosed in quotes);
  • sectiontoolInit()-initialize the components in the planes section tool output box;
  • sectiontoolReset()-reset the components in the planes section tool output box;
  • sectiontoolSwitch()-switch between on/off toolbar related planes section tool button icon;
    +
    - \ No newline at end of file + diff --git a/examples/HOWTO_1.0_canvas_personalization.html b/examples/HOWTO_1.0_canvas_personalization.html index dd85e17..e7e5704 100644 --- a/examples/HOWTO_1.0_canvas_personalization.html +++ b/examples/HOWTO_1.0_canvas_personalization.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_10.0_camera_lighting.html b/examples/HOWTO_10.0_camera_lighting.html index d5e60a8..b10a9c4 100644 --- a/examples/HOWTO_10.0_camera_lighting.html +++ b/examples/HOWTO_10.0_camera_lighting.html @@ -25,15 +25,15 @@
    -
    -
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    + +
    @@ -75,8 +75,7 @@ scale : [20.0, 20.0, 20.0] }, color : [ 0.2, 1.0, 0.2 ], - useSolidColor : true, - useLighting : false + useSolidColor : true }, "S3" : { mesh : "Sphere", @@ -118,21 +117,20 @@ centerMode : "scene", radiusMode : "scene", cameraFOV : 60.0, - cameraNearFar : [0.1, 10.0], + cameraNearFar : [0.01, 10.0], cameraType : "perspective", useLighting : true - }, + } }); } function actionsToolbar(action) { - if(action=='home') presenter.resetTrackball(); + if(action=='home') presenter.resetTrackball(); else if(action=='zoomin') presenter.zoomIn(); - else if(action=='zoomout') presenter.zoomOut(); - else if(action=='ortho') {presenter.toggleCameraType();} - else if(action=='lighting') {presenter.toggleSceneLighting();} - else if(action=='light' || action=='light_on') { presenter.enableLightTrackball(!presenter.isLightTrackballEnabled()); lightSwitch(); } - else if(action=='full' || action=='full_on') fullscreenSwitch(); + else if(action=='zoomout') presenter.zoomOut(); + else if(action=='lighting' || action=='lighting_off') { presenter.enableSceneLighting(!presenter.isSceneLightingEnabled()); lightingSwitch(); } + else if(action=='perspective' || action=='orthographic') { presenter.toggleCameraType(); cameraSwitch(); } + else if(action=='full' || action=='full_on') fullscreenSwitch(); } $(document).ready(function(){ diff --git a/examples/HOWTO_10.1_camera_lighting.html b/examples/HOWTO_10.1_camera_lighting.html new file mode 100644 index 0000000..b4e4482 --- /dev/null +++ b/examples/HOWTO_10.1_camera_lighting.html @@ -0,0 +1,146 @@ + + + + +3DHOP - 3D Heritage Online Presenter + + + + + + + + + + + + + + + + + + + + +
    +
    +
    +
    +
    + +
    + +
    + +
    + + +
    + +
    + + + + + diff --git a/examples/HOWTO_2.0_models_loading.html b/examples/HOWTO_2.0_models_loading.html index 1806df5..f7adc98 100644 --- a/examples/HOWTO_2.0_models_loading.html +++ b/examples/HOWTO_2.0_models_loading.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_3.0_trackball_setting.html b/examples/HOWTO_3.0_trackball_setting.html index fb118ee..30c0d09 100644 --- a/examples/HOWTO_3.0_trackball_setting.html +++ b/examples/HOWTO_3.0_trackball_setting.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_3.1_trackball_setting.html b/examples/HOWTO_3.1_trackball_setting.html index 18c9636..b35396c 100644 --- a/examples/HOWTO_3.1_trackball_setting.html +++ b/examples/HOWTO_3.1_trackball_setting.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_3.2_trackball_setting.html b/examples/HOWTO_3.2_trackball_setting.html index 13b19c5..eb7976b 100644 --- a/examples/HOWTO_3.2_trackball_setting.html +++ b/examples/HOWTO_3.2_trackball_setting.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_3.3_trackball_setting.html b/examples/HOWTO_3.3_trackball_setting.html index 9759292..fc3d61b 100644 --- a/examples/HOWTO_3.3_trackball_setting.html +++ b/examples/HOWTO_3.3_trackball_setting.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_4.0_complex_scene.html b/examples/HOWTO_4.0_complex_scene.html index 4fa8f1b..6ffb5cc 100644 --- a/examples/HOWTO_4.0_complex_scene.html +++ b/examples/HOWTO_4.0_complex_scene.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    @@ -49,7 +49,7 @@ "Gargoyle" : { url: "models/multires/gargo.nxz" }, "Box" : { url: "models/singleres/cube.ply", - transform : { matrix: SglMat4.scaling([13.0, 0.5, 10.0]) }, + transform : { matrix: SglMat4.scaling([13.0, 0.5, 10.0]) }, } }, modelInstances : { @@ -64,7 +64,7 @@ mesh : "Gargoyle", transform : { translation : [-120.0, 12.5, 150.0], - rotation : [0.0, 90, 0.0], + rotation : [0.0, 90, 0.0], scale : [1.5, 1.5, 1.5] } }, diff --git a/examples/HOWTO_5.0_visibility_color_transparency.html b/examples/HOWTO_5.0_visibility_color_transparency.html index 5ec9bdb..68f219e 100644 --- a/examples/HOWTO_5.0_visibility_color_transparency.html +++ b/examples/HOWTO_5.0_visibility_color_transparency.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_6.0_animations.html b/examples/HOWTO_6.0_animations.html index 9e9ba3f..75ed916 100644 --- a/examples/HOWTO_6.0_animations.html +++ b/examples/HOWTO_6.0_animations.html @@ -26,13 +26,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/examples/HOWTO_7.0_hotspots_events.html b/examples/HOWTO_7.0_hotspots_events.html index 118ece7..815f937 100644 --- a/examples/HOWTO_7.0_hotspots_events.html +++ b/examples/HOWTO_7.0_hotspots_events.html @@ -25,15 +25,15 @@
    -
    -
    -
    - -
    - -
    - - +
    +
    +
    + +
    + +
    + +
    diff --git a/examples/HOWTO_8.0_measurement_tool.html b/examples/HOWTO_8.0_measurement_tool.html index 4c9535b..cecf8d8 100644 --- a/examples/HOWTO_8.0_measurement_tool.html +++ b/examples/HOWTO_8.0_measurement_tool.html @@ -25,15 +25,15 @@
    -
    -
    -
    - -
    - -
    - - +
    +
    +
    + +
    + +
    + +
    Measured length
    0.0
    @@ -93,7 +93,7 @@ } function onEndMeasure(measure) { - // .toFixed(2) sets the number of decimals when displaying the measure + // measure.toFixed(2) sets the number of decimals when displaying the measure // depending on the model measure units, use "mm","m","km" or whatever you have $('#measure-output').html(measure.toFixed(2) + " mm"); } diff --git a/examples/HOWTO_8.1_point_picking.html b/examples/HOWTO_8.1_point_picking.html index 3044e31..2238c1a 100644 --- a/examples/HOWTO_8.1_point_picking.html +++ b/examples/HOWTO_8.1_point_picking.html @@ -25,15 +25,15 @@
    -
    -
    -
    - -
    - -
    - - +
    +
    +
    + +
    + +
    + +
    XYZ picked point
    [ 0 , 0 , 0 ]
    @@ -93,11 +93,11 @@ } function onEndPick(point) { - // .toFixed(2) sets the number of decimals when displaying the X, Y and Z components of the picked point coordinates + // point.toFixed(2) sets the number of decimals when displaying the picked point var x = point[0].toFixed(2); var y = point[1].toFixed(2); var z = point[2].toFixed(2); - $('#pickpoint-output').html("[ "+x+" , "+y+" , "+z+" ]"); + $('#pickpoint-output').html("[ "+x+" , "+y+" , "+z+" ]"); } $(document).ready(function(){ diff --git a/examples/HOWTO_9.0_planes_sections.html b/examples/HOWTO_9.0_planes_sections.html index 4690462..e03172b 100644 --- a/examples/HOWTO_9.0_planes_sections.html +++ b/examples/HOWTO_9.0_planes_sections.html @@ -25,15 +25,15 @@
    -
    -
    -
    - -
    - -
    - - +
    +
    +
    + +
    + +
    + +
    diff --git a/examples/js/init.js b/examples/js/init.js index 2ce9cfe..dc03f23 100644 --- a/examples/js/init.js +++ b/examples/js/init.js @@ -152,6 +152,8 @@ function lightSwitch(on) { if(on){ $('#light').css("visibility", "hidden"); $('#light_on').css("visibility", "visible"); + $('#lighting_off').css("visibility", "hidden"); //manage lighting combined interface + $('#lighting').css("visibility", "visible"); //manage lighting combined interface } else{ $('#light_on').css("visibility", "hidden"); @@ -159,6 +161,21 @@ function lightSwitch(on) { } } +function lightingSwitch(on) { + if(on === undefined) on = presenter.isSceneLightingEnabled(); + + if(on){ + $('#lighting_off').css("visibility", "hidden"); + $('#lighting').css("visibility", "visible"); + } + else{ + $('#lighting').css("visibility", "hidden"); + $('#lighting_off').css("visibility", "visible"); + $('#light_on').css("visibility", "hidden"); //manage light combined interface + $('#light').css("visibility", "visible"); //manage light combined interface + } +} + function hotspotSwitch(on) { if(on === undefined) on = presenter.isSpotVisibilityEnabled(); @@ -225,6 +242,19 @@ function colorSwitch(on) { } } +function cameraSwitch(on) { + if(on === undefined) on = $('#perspective').css("visibility")=="visible"; + + if(on){ + $('#perspective').css("visibility", "hidden"); + $('#orthographic').css("visibility", "visible"); + } + else{ + $('#orthographic').css("visibility", "hidden"); + $('#perspective').css("visibility", "visible"); + } +} + function sectiontoolSwitch(on) { if(on === undefined) on = $('#sections').css("visibility")=="visible"; diff --git a/examples/js/nexus.js b/examples/js/nexus.js index 3ed9db7..ef7fe14 100644 --- a/examples/js/nexus.js +++ b/examples/js/nexus.js @@ -330,13 +330,13 @@ Mesh.prototype = { r.onload = function(){ switch (this.status){ case 0: - console.log("0 response: server unreachable.");//returned in chrome for local files +// console.log("0 response: server unreachable.");//returned in chrome for local files case 206: // console.log("206 response: partial content loaded."); load.bind(this)(); break; case 200: - console.log("200 response: server does not support byte range requests."); +// console.log("200 response: server does not support byte range requests."); } }; r.onerror = error; @@ -986,8 +986,14 @@ function requestNodeGeometry(context, node) { m.noffsets[n], m.noffsets[n+1], function() { loadNodeGeometry(this, context, node); }, - function() { console.log("Geometry request error!"); recoverNode(context, node, 0); }, - function() { console.log("Geometry request abort!"); removeNode(context, node); }, + function() { +// console.log("Geometry request error!"); + recoverNode(context, node, 0); + }, + function() { +// console.log("Geometry request abort!"); + removeNode(context, node); + }, 'arraybuffer' ); } @@ -1008,8 +1014,14 @@ function requestNodeTexture(context, node) { m.textures[tex], m.textures[tex+1], function() { loadNodeTexture(this, context, node, tex); }, - function() { console.log("Texture request error!"); recoverNode(context, node, 1); }, - function() { console.log("Texture request abort!"); removeNode(context, node); }, + function() { +// console.log("Texture request error!"); + recoverNode(context, node, 1); + }, + function() { +// console.log("Texture request abort!"); + removeNode(context, node); + }, 'blob' ); } diff --git a/examples/js/presenter.js b/examples/js/presenter.js index 0610630..7c79d1e 100644 --- a/examples/js/presenter.js +++ b/examples/js/presenter.js @@ -23,7 +23,7 @@ SpiderGL.openNamespace(); // CONSTANTS //---------------------------------------------------------------------------------------- // version -const HOP_VERSION = "4.1.14"; +const HOP_VERSION = "4.2"; // selectors const HOP_ALL = 256; // starting debug mode @@ -1113,8 +1113,8 @@ _pickingRefresh: function(x,y) { if (spots[spt].ID == ID) { this._pickedSpot = spt; if(this._onHover){ - if(spots[this._lastPickedSpot]) spots[this._lastPickedSpot].alpha -= 0.2; - spots[this._pickedSpot].alpha += 0.2; + if(spots[this._lastPickedSpot]) spots[this._lastPickedSpot].alpha -= 0.3; + spots[this._pickedSpot].alpha += 0.3; cursor = spots[spt].cursor; if(/*!this._movingLight ||*/ !this._isMeasuring){ this._lastCursor = document.getElementById(this.ui.canvas.id).style.cursor; @@ -1133,7 +1133,7 @@ _pickingRefresh: function(x,y) { else{ this._pickedSpot = null; if(this._onHover){ - if(spots[this._lastPickedSpot]) spots[this._lastPickedSpot].alpha -= 0.2; + if(spots[this._lastPickedSpot]) spots[this._lastPickedSpot].alpha -= 0.3; if(/*!this._movingLight ||*/ !this._isMeasuring) document.getElementById(this.ui.canvas.id).style.cursor = "default"; if(this._onLeaveSpot && this._lastPickedSpot!=null) this._onLeaveSpot(this._lastPickedSpot); //if(this._onEnterSpot) this._onEnterSpot(this._pickedSpot); @@ -1892,7 +1892,7 @@ _drawScene : function () { // draw transparent spot geometries for (var spt in spots) { var spot = spots[spt]; - var mesh = meshes[spot.mesh]; + var mesh = meshes[spot.mesh]; if (!mesh) continue; var renderable = mesh.renderable; if (!renderable) continue; @@ -2836,41 +2836,6 @@ onDraw : function () { //---------------------------------------------------------------------------------------- // EXPOSED FUNCTIONS //---------------------------------------------------------------------------------------- -supportsWebGL : function () { - return this._supportsWebGL; -}, - -toggleDebugMode : function () { - this._isDebugging = !this._isDebugging; -}, - -setNexusTargetFps: function(fps) { - this._nexusTargetFps = fps; - Nexus.setTargetFps(this.ui.gl, fps); -}, - -getNexusTargetFps: function() { - return this._nexusTargetFps; -}, - -setNexusTargetError: function(error) { - this._nexusTargetError = error; - Nexus.setTargetError(this.ui.gl, error); -}, - -getNexusTargetError: function() { - return this._nexusTargetError; -}, - -setNexusCacheSize: function(size) { - this._nexusCacheSize = size; - Nexus.setMaxCacheSize(this.ui.gl, size); -}, - -getNexusCacheSize: function() { - return this._nexusCacheSize; -}, - setScene : function (options) { if (!options) return; @@ -2929,14 +2894,14 @@ setScene : function (options) { Nexus.setTargetFps(gl, this._nexusTargetFps); Nexus.setMaxCacheSize(gl, this._nexusCacheSize); - var instance = new Nexus.Renderer(gl); - instance.onLoad = function () { that._onMeshReady(); }; - instance.onUpdate = this.ui.postDrawEvent; + var nexus_instance = new Nexus.Renderer(gl); + nexus_instance.onLoad = function () { that._onMeshReady(); }; + nexus_instance.onUpdate = this.ui.postDrawEvent; - mesh.renderable = instance; + mesh.renderable = nexus_instance; mesh.isNexus = true; - instance.open(mesh.url); + nexus_instance.open(mesh.url); } else { mesh.renderable = null; @@ -2979,6 +2944,55 @@ setScene : function (options) { this._sceneParsed = true; }, +get version() { + return HOP_VERSION; +}, + +supportsWebGL : function () { + return this._supportsWebGL; +}, + +toggleDebugMode : function () { + this._isDebugging = !this._isDebugging; +}, + +repaint : function () { + this.ui.postDrawEvent(); +}, + +//----------------------------------------------------------------------------- +// nexus + +setNexusTargetFps: function(fps) { + this._nexusTargetFps = fps; + Nexus.setTargetFps(this.ui.gl, fps); +}, + +getNexusTargetFps: function() { + return this._nexusTargetFps; +}, + +setNexusTargetError: function(error) { + this._nexusTargetError = error; + Nexus.setTargetError(this.ui.gl, error); +}, + +getNexusTargetError: function() { + return this._nexusTargetError; +}, + +setNexusCacheSize: function(size) { + this._nexusCacheSize = size; + Nexus.setMaxCacheSize(this.ui.gl, size); +}, + +getNexusCacheSize: function() { + return this._nexusCacheSize; +}, + +//----------------------------------------------------------------------------- +// trackball + resetTrackball : function () { this.trackball.reset(); this.trackball.track(SglMat4.identity(), 0.0, 0.0, 0.0); @@ -2995,6 +3009,9 @@ setTrackballPosition : function (newposition) { this.repaint(); }, +//----------------------------------------------------------------------------- +// camera animations + animateToTrackballPosition : function (newposition, newtime) { this.ui.animateRate = 30; this.trackball.animateToState(newposition, newtime); @@ -3008,7 +3025,7 @@ isAnimate : function () { }, //----------------------------------------------------------------------------- -// functions to dynamically change center/radius mode +// dynamic center/radius mode setCenterModeFirst : function () { this._scene.space.centerMode = "first"; @@ -3076,6 +3093,7 @@ setRadiusModeExplicit : function (newradius) { //----------------------------------------------------------------------------- // instance solid color + setInstanceSolidColorByName : function (name, newState, redraw, newColor) { var instances = this._scene.modelInstances; @@ -3148,8 +3166,57 @@ toggleInstanceSolidColor : function (tag, redraw) { this.repaint(); }, +isInstanceSolidColorEnabledByName : function (name) { + var solidcolor = false; + var instances = this._scene.modelInstances; + + if(!name || name==HOP_ALL) { + for (var inst in instances) { + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + else { + if(instances[name]) { // if an instance with that name exists + if(instances[name].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + return solidcolor; +}, + +isInstanceSolidColorEnabled : function (tag) { + var solidcolor = false; + var instances = this._scene.modelInstances; + + for (var inst in instances) { + if(!tag || tag==HOP_ALL){ + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + else{ + for (var tg in instances[inst].tags){ + if(instances[inst].tags[tg] == tag){ + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + } + } + return solidcolor; +}, + //----------------------------------------------------------------------------- // instance transparency + setInstanceTransparencyByName : function (name, newState, redraw, newAlpha) { var instances = this._scene.modelInstances; @@ -3228,9 +3295,59 @@ toggleInstanceTransparency : function (tag, redraw) { this.repaint(); }, + +isInstanceTransparencyEnabledByName : function (name) { + var transparency = false; + var instances = this._scene.modelInstances; + + if(!name || name==HOP_ALL) { + for (var inst in instances) { + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + } + else { + if(instances[name]) { // if an instance with that name exists + if(instances[name].useTransparency){ + transparency = true; + return transparency; + } + } + } + return transparency; +}, + +isInstanceTransparencyEnabled : function (tag) { + var transparency = false; + var instances = this._scene.modelInstances; + + for (var inst in instances) { + if(!tag || tag==HOP_ALL){ + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + else{ + for (var tg in instances[inst].tags){ + if(instances[inst].tags[tg] == tag){ + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + } + } + } + return transparency; +}, + //----------------------------------------------------------------------------- // instance shading //----specular + setInstanceSpecularityByName : function (name, color, hardness, redraw) { var instances = this._scene.modelInstances; @@ -3265,6 +3382,7 @@ setInstanceSpecularity : function (tag, color, hardness, redraw) { }, //----backface + setInstanceBackfaceByName : function (name, color, mode, redraw) { var instances = this._scene.modelInstances; var modecode = 0.0; @@ -3308,6 +3426,7 @@ setInstanceBackface : function (tag, color, mode, redraw) { //----------------------------------------------------------------------------- // instance visibility + setInstanceVisibilityByName : function (name, newState, redraw) { var instances = this._scene.modelInstances; @@ -3426,6 +3545,7 @@ isInstanceVisibilityEnabled : function (tag) { //----------------------------------------------------------------------------- // spot visibility + setSpotVisibilityByName : function (name, newState, redraw) { var spots = this._scene.spots; @@ -3543,6 +3663,7 @@ isSpotVisibilityEnabled : function (tag) { //----------------------------------------------------------------------------- // sections + resetClippingXYZ: function() { this._calculateBounding(); this._clipAxis = [0.0, 0.0, 0.0]; @@ -3723,6 +3844,7 @@ setClippingPlaneExplicit : function (axis, offset) { this._clipPlane = [axis[0], axis[1], axis[2], offset]; this.repaint(); }, + setClippingPlane : function (angleH, angleV, sign, delta, deltaabs) { this._calculateBounding(); var axis; @@ -3749,6 +3871,8 @@ setClippingPlane : function (angleH, angleV, sign, delta, deltaabs) { }, //----------------------------------------------------------------------------- +// zoom + zoomIn: function() { this.onMouseWheel(1); }, @@ -3758,6 +3882,8 @@ zoomOut: function() { }, //----------------------------------------------------------------------------- +// light + rotateLight: function(x, y) { x *= 2; y *= 2; @@ -3774,6 +3900,10 @@ rotateLight: function(x, y) { enableLightTrackball: function(on) { this._movingLight = on; + + if(on && !this._scene.space.useLighting) this._scene.space.useLighting = on; + + this.repaint(); }, isLightTrackballEnabled: function() { @@ -3781,6 +3911,8 @@ isLightTrackballEnabled: function() { }, //----------------------------------------------------------------------------- +// onHover + enableOnHover: function(on) { this._onHover = on; }, @@ -3790,6 +3922,8 @@ isOnHoverEnabled: function() { }, //----------------------------------------------------------------------------- +// linear measure + enableMeasurementTool: function(on) { if(on) this._startMeasurement(); @@ -3802,6 +3936,8 @@ isMeasurementToolEnabled: function() { }, //----------------------------------------------------------------------------- +// point measure + enablePickpointMode: function(on) { if(on) this._startPickPoint(); @@ -3814,11 +3950,15 @@ isPickpointModeEnabled: function() { }, //----------------------------------------------------------------------------- +// measurements + isAnyMeasurementEnabled: function() { return this._isMeasuring; }, //----------------------------------------------------------------------------- +// camera type + toggleCameraType: function() { if(this._scene.space.cameraType == "orthographic") this._scene.space.cameraType = "perspective" @@ -3843,6 +3983,8 @@ getCameraType : function () { }, //----------------------------------------------------------------------------- +// trackball lock + toggleTrackballLock: function() { this._scene.trackball.locked = !this._scene.trackball.locked; }, @@ -3856,17 +3998,17 @@ isTrackballLockEnabled: function() { }, //----------------------------------------------------------------------------- -toggleSceneLighting : function () { - this._scene.space.useLighting = !this._scene.space.useLighting; - this.repaint(); -}, +// lighting + +enableSceneLighting: function(on) { + this._scene.space.useLighting = on; + + if(!on && this._movingLight) this._movingLight = on; -setSceneLighting : function (newState) { - this._scene.space.useLighting = newState; this.repaint(); }, -getSceneLighting : function () { +isSceneLightingEnabled: function() { return this._scene.space.useLighting; }, @@ -3984,16 +4126,6 @@ isInstanceLightingEnabled : function (tag) { } } return Lighting; -}, - -//----------------------------------------------------------------------------- -repaint : function () { - this.ui.postDrawEvent(); -}, - -//----------------------------------------------------------------------------- -get version() { - return HOP_VERSION; } }; // Presenter.prototype END diff --git a/examples/skins/dark/light_off.png b/examples/skins/dark/light_off.png index 6806438..34f078e 100644 Binary files a/examples/skins/dark/light_off.png and b/examples/skins/dark/light_off.png differ diff --git a/examples/skins/dark/lightcontrol.png b/examples/skins/dark/lightcontrol.png new file mode 100644 index 0000000..ece6887 Binary files /dev/null and b/examples/skins/dark/lightcontrol.png differ diff --git a/examples/skins/dark/lightcontrol_on.png b/examples/skins/dark/lightcontrol_on.png new file mode 100644 index 0000000..ef56315 Binary files /dev/null and b/examples/skins/dark/lightcontrol_on.png differ diff --git a/examples/skins/dark/lighting.png b/examples/skins/dark/lighting.png new file mode 100644 index 0000000..4dd4352 Binary files /dev/null and b/examples/skins/dark/lighting.png differ diff --git a/examples/skins/dark/lighting_off.png b/examples/skins/dark/lighting_off.png new file mode 100644 index 0000000..5bcbf02 Binary files /dev/null and b/examples/skins/dark/lighting_off.png differ diff --git a/examples/skins/dark/ortho.png b/examples/skins/dark/ortho.png deleted file mode 100644 index 9583e7f..0000000 Binary files a/examples/skins/dark/ortho.png and /dev/null differ diff --git a/examples/skins/dark/orthographic.png b/examples/skins/dark/orthographic.png new file mode 100644 index 0000000..855f992 Binary files /dev/null and b/examples/skins/dark/orthographic.png differ diff --git a/examples/skins/dark/perspective.png b/examples/skins/dark/perspective.png index 8b0b08e..e53bef4 100644 Binary files a/examples/skins/dark/perspective.png and b/examples/skins/dark/perspective.png differ diff --git a/examples/skins/light/light_off.png b/examples/skins/light/light_off.png new file mode 100644 index 0000000..bf4f53e Binary files /dev/null and b/examples/skins/light/light_off.png differ diff --git a/examples/skins/light/lightcontrol.png b/examples/skins/light/lightcontrol.png new file mode 100644 index 0000000..cf00b3f Binary files /dev/null and b/examples/skins/light/lightcontrol.png differ diff --git a/examples/skins/light/lightcontrol_on.png b/examples/skins/light/lightcontrol_on.png new file mode 100644 index 0000000..b935929 Binary files /dev/null and b/examples/skins/light/lightcontrol_on.png differ diff --git a/examples/skins/light/lighting.png b/examples/skins/light/lighting.png new file mode 100644 index 0000000..7bc59eb Binary files /dev/null and b/examples/skins/light/lighting.png differ diff --git a/examples/skins/light/lighting_off.png b/examples/skins/light/lighting_off.png new file mode 100644 index 0000000..98065e3 Binary files /dev/null and b/examples/skins/light/lighting_off.png differ diff --git a/examples/skins/light/orthographic.png b/examples/skins/light/orthographic.png new file mode 100644 index 0000000..865c5fb Binary files /dev/null and b/examples/skins/light/orthographic.png differ diff --git a/examples/skins/light/perspective.png b/examples/skins/light/perspective.png new file mode 100644 index 0000000..dcbf5a0 Binary files /dev/null and b/examples/skins/light/perspective.png differ diff --git a/examples/skins/minimal_dark/light_off.png b/examples/skins/minimal_dark/light_off.png new file mode 100644 index 0000000..22d8321 Binary files /dev/null and b/examples/skins/minimal_dark/light_off.png differ diff --git a/examples/skins/minimal_dark/lightcontrol.png b/examples/skins/minimal_dark/lightcontrol.png new file mode 100644 index 0000000..c9f2357 Binary files /dev/null and b/examples/skins/minimal_dark/lightcontrol.png differ diff --git a/examples/skins/minimal_dark/lightcontrol_on.png b/examples/skins/minimal_dark/lightcontrol_on.png new file mode 100644 index 0000000..f227244 Binary files /dev/null and b/examples/skins/minimal_dark/lightcontrol_on.png differ diff --git a/examples/skins/minimal_dark/lighting.png b/examples/skins/minimal_dark/lighting.png new file mode 100644 index 0000000..d2eadff Binary files /dev/null and b/examples/skins/minimal_dark/lighting.png differ diff --git a/examples/skins/minimal_dark/lighting_off.png b/examples/skins/minimal_dark/lighting_off.png new file mode 100644 index 0000000..7f5921a Binary files /dev/null and b/examples/skins/minimal_dark/lighting_off.png differ diff --git a/examples/skins/minimal_dark/orthographic.png b/examples/skins/minimal_dark/orthographic.png new file mode 100644 index 0000000..1f07ed9 Binary files /dev/null and b/examples/skins/minimal_dark/orthographic.png differ diff --git a/examples/skins/minimal_dark/perspective.png b/examples/skins/minimal_dark/perspective.png new file mode 100644 index 0000000..4ea1b1f Binary files /dev/null and b/examples/skins/minimal_dark/perspective.png differ diff --git a/examples/skins/minimal_light/light_off.png b/examples/skins/minimal_light/light_off.png new file mode 100644 index 0000000..1971a81 Binary files /dev/null and b/examples/skins/minimal_light/light_off.png differ diff --git a/examples/skins/minimal_light/lightcontrol.png b/examples/skins/minimal_light/lightcontrol.png new file mode 100644 index 0000000..3567244 Binary files /dev/null and b/examples/skins/minimal_light/lightcontrol.png differ diff --git a/examples/skins/minimal_light/lightcontrol_on.png b/examples/skins/minimal_light/lightcontrol_on.png new file mode 100644 index 0000000..4b63fce Binary files /dev/null and b/examples/skins/minimal_light/lightcontrol_on.png differ diff --git a/examples/skins/minimal_light/lighting.png b/examples/skins/minimal_light/lighting.png new file mode 100644 index 0000000..5996246 Binary files /dev/null and b/examples/skins/minimal_light/lighting.png differ diff --git a/examples/skins/minimal_light/lighting_off.png b/examples/skins/minimal_light/lighting_off.png new file mode 100644 index 0000000..9ac9788 Binary files /dev/null and b/examples/skins/minimal_light/lighting_off.png differ diff --git a/examples/skins/minimal_light/orthographic.png b/examples/skins/minimal_light/orthographic.png new file mode 100644 index 0000000..3160ffa Binary files /dev/null and b/examples/skins/minimal_light/orthographic.png differ diff --git a/examples/skins/minimal_light/perspective.png b/examples/skins/minimal_light/perspective.png new file mode 100644 index 0000000..5e4985b Binary files /dev/null and b/examples/skins/minimal_light/perspective.png differ diff --git a/examples/skins/transparent_dark/light_off.png b/examples/skins/transparent_dark/light_off.png new file mode 100644 index 0000000..09adde1 Binary files /dev/null and b/examples/skins/transparent_dark/light_off.png differ diff --git a/examples/skins/transparent_dark/lightcontrol.png b/examples/skins/transparent_dark/lightcontrol.png new file mode 100644 index 0000000..00631fa Binary files /dev/null and b/examples/skins/transparent_dark/lightcontrol.png differ diff --git a/examples/skins/transparent_dark/lightcontrol_on.png b/examples/skins/transparent_dark/lightcontrol_on.png new file mode 100644 index 0000000..77b5ae9 Binary files /dev/null and b/examples/skins/transparent_dark/lightcontrol_on.png differ diff --git a/examples/skins/transparent_dark/lighting.png b/examples/skins/transparent_dark/lighting.png new file mode 100644 index 0000000..0568133 Binary files /dev/null and b/examples/skins/transparent_dark/lighting.png differ diff --git a/examples/skins/transparent_dark/lighting_off.png b/examples/skins/transparent_dark/lighting_off.png new file mode 100644 index 0000000..40308f2 Binary files /dev/null and b/examples/skins/transparent_dark/lighting_off.png differ diff --git a/examples/skins/transparent_dark/orthographic.png b/examples/skins/transparent_dark/orthographic.png new file mode 100644 index 0000000..c1504a2 Binary files /dev/null and b/examples/skins/transparent_dark/orthographic.png differ diff --git a/examples/skins/transparent_dark/perspective.png b/examples/skins/transparent_dark/perspective.png new file mode 100644 index 0000000..09e893f Binary files /dev/null and b/examples/skins/transparent_dark/perspective.png differ diff --git a/examples/skins/transparent_light/light_off.png b/examples/skins/transparent_light/light_off.png new file mode 100644 index 0000000..c0ff3e4 Binary files /dev/null and b/examples/skins/transparent_light/light_off.png differ diff --git a/examples/skins/transparent_light/lightcontrol.png b/examples/skins/transparent_light/lightcontrol.png new file mode 100644 index 0000000..c37eaf2 Binary files /dev/null and b/examples/skins/transparent_light/lightcontrol.png differ diff --git a/examples/skins/transparent_light/lightcontrol_on.png b/examples/skins/transparent_light/lightcontrol_on.png new file mode 100644 index 0000000..1c340d5 Binary files /dev/null and b/examples/skins/transparent_light/lightcontrol_on.png differ diff --git a/examples/skins/transparent_light/lighting.png b/examples/skins/transparent_light/lighting.png new file mode 100644 index 0000000..3096058 Binary files /dev/null and b/examples/skins/transparent_light/lighting.png differ diff --git a/examples/skins/transparent_light/lighting_off.png b/examples/skins/transparent_light/lighting_off.png new file mode 100644 index 0000000..9eee289 Binary files /dev/null and b/examples/skins/transparent_light/lighting_off.png differ diff --git a/examples/skins/transparent_light/orthographic.png b/examples/skins/transparent_light/orthographic.png new file mode 100644 index 0000000..49ceab9 Binary files /dev/null and b/examples/skins/transparent_light/orthographic.png differ diff --git a/examples/skins/transparent_light/perspective.png b/examples/skins/transparent_light/perspective.png new file mode 100644 index 0000000..cce2428 Binary files /dev/null and b/examples/skins/transparent_light/perspective.png differ diff --git a/examples/stylesheet/3DHpanels.css b/examples/stylesheet/3DHpanels.css index c25d7a7..e1e6c4c 100644 --- a/examples/stylesheet/3DHpanels.css +++ b/examples/stylesheet/3DHpanels.css @@ -1,7 +1,7 @@ /* 3DHOP - 3D Heritage Online Presenter -Copyright (c) 2014-2017, Visual Computing Lab, ISTI - CNR -All rights reserved. +Copyright (c) 2014-2018, Visual Computing Lab, ISTI - CNR +All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by diff --git a/examples/stylesheet/3dhop.css b/examples/stylesheet/3dhop.css index 757c7bc..43907a0 100644 --- a/examples/stylesheet/3dhop.css +++ b/examples/stylesheet/3dhop.css @@ -1,7 +1,7 @@ /* 3DHOP - 3D Heritage Online Presenter -Copyright (c) 2014-2017, Visual Computing Lab, ISTI - CNR -All rights reserved. +Copyright (c) 2014-2018, Visual Computing Lab, ISTI - CNR +All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by diff --git a/minimal/index_all_tools.html b/minimal/index_all_tools.html index 0e95555..69c1347 100644 --- a/minimal/index_all_tools.html +++ b/minimal/index_all_tools.html @@ -30,9 +30,13 @@

    + + +
    + - -
    + +
    @@ -50,6 +54,10 @@
    + + +
    + @@ -145,9 +153,15 @@ else if(action=='zoomin') presenter.zoomIn(); else if(action=='zoomout') presenter.zoomOut(); //--ZOOM-- +//--LIGHTING-- + else if(action=='lighting' || action=='lighting_off') { presenter.enableSceneLighting(!presenter.isSceneLightingEnabled()); lightingSwitch(); } +//--LIGHTING-- //--LIGHT-- else if(action=='light' || action=='light_on') { presenter.enableLightTrackball(!presenter.isLightTrackballEnabled()); lightSwitch(); } //--LIGHT-- +//--CAMERA-- + else if(action=='perspective' || action=='orthographic') { presenter.toggleCameraType(); cameraSwitch(); } +//--CAMERA-- //--COLOR-- else if(action=='color' || action=='color_on') { presenter.toggleInstanceSolidColor(HOP_ALL, true); colorSwitch(); } //--COLOR-- diff --git a/minimal/index_no_tools.html b/minimal/index_no_tools.html index 4298177..a64c5a6 100644 --- a/minimal/index_no_tools.html +++ b/minimal/index_no_tools.html @@ -25,13 +25,13 @@
    -
    -
    -
    - -
    - - +
    +
    +
    + +
    + +
    diff --git a/minimal/js/init.js b/minimal/js/init.js index 2ce9cfe..dc03f23 100644 --- a/minimal/js/init.js +++ b/minimal/js/init.js @@ -152,6 +152,8 @@ function lightSwitch(on) { if(on){ $('#light').css("visibility", "hidden"); $('#light_on').css("visibility", "visible"); + $('#lighting_off').css("visibility", "hidden"); //manage lighting combined interface + $('#lighting').css("visibility", "visible"); //manage lighting combined interface } else{ $('#light_on').css("visibility", "hidden"); @@ -159,6 +161,21 @@ function lightSwitch(on) { } } +function lightingSwitch(on) { + if(on === undefined) on = presenter.isSceneLightingEnabled(); + + if(on){ + $('#lighting_off').css("visibility", "hidden"); + $('#lighting').css("visibility", "visible"); + } + else{ + $('#lighting').css("visibility", "hidden"); + $('#lighting_off').css("visibility", "visible"); + $('#light_on').css("visibility", "hidden"); //manage light combined interface + $('#light').css("visibility", "visible"); //manage light combined interface + } +} + function hotspotSwitch(on) { if(on === undefined) on = presenter.isSpotVisibilityEnabled(); @@ -225,6 +242,19 @@ function colorSwitch(on) { } } +function cameraSwitch(on) { + if(on === undefined) on = $('#perspective').css("visibility")=="visible"; + + if(on){ + $('#perspective').css("visibility", "hidden"); + $('#orthographic').css("visibility", "visible"); + } + else{ + $('#orthographic').css("visibility", "hidden"); + $('#perspective').css("visibility", "visible"); + } +} + function sectiontoolSwitch(on) { if(on === undefined) on = $('#sections').css("visibility")=="visible"; diff --git a/minimal/js/nexus.js b/minimal/js/nexus.js index d035d20..ef7fe14 100644 --- a/minimal/js/nexus.js +++ b/minimal/js/nexus.js @@ -305,6 +305,7 @@ Mesh.prototype = { if(mesh.reqAttempt < maxReqAttempt) mesh.open(mesh.url + '?' + Math.random()); // BLINK ENGINE CACHE BUG PATCH return null; } + mesh.reqAttempt = 0; for(i in header) mesh[i] = header[i]; mesh.vertex = mesh.signature.vertex; @@ -329,13 +330,13 @@ Mesh.prototype = { r.onload = function(){ switch (this.status){ case 0: - console.log("0 response: server unreachable.");//returned in chrome for local files +// console.log("0 response: server unreachable.");//returned in chrome for local files case 206: // console.log("206 response: partial content loaded."); load.bind(this)(); break; case 200: - console.log("200 response: server does not support byte range requests."); +// console.log("200 response: server does not support byte range requests."); } }; r.onerror = error; @@ -508,18 +509,6 @@ Instance.prototype = { open: function(url) { var t = this; t.context = getContext(t.gl); - var mesh; - t.context.meshes.forEach(function(m) { - if(m.url == url) - t.mesh = m; - //m.instances.push(t); - }); - if(!t.mesh) { - t.mesh = new Mesh(); - t.mesh.onLoad = function() { t.renderMode = t.mesh.renderMode; t.mode = t.renderMode[0]; t.onLoad(); } - t.mesh.open(url); - t.context.meshes.push(t.mesh); - } t.modelMatrix = new Float32Array(16); t.viewMatrix = new Float32Array(16); @@ -531,7 +520,24 @@ Instance.prototype = { t.planes = new Float32Array(24); t.viewport = new Float32Array(4); t.viewpoint = new Float32Array(4); + + t.context.meshes.forEach(function(m) { + if(m.url == url){ + t.mesh = m; + t.renderMode = t.mesh.renderMode; + t.mode = t.renderMode[0]; + t.onLoad(); + } + }); + + if(!t.mesh) { + t.mesh = new Mesh(); + t.mesh.onLoad = function() { t.renderMode = t.mesh.renderMode; t.mode = t.renderMode[0]; t.onLoad(); } + t.mesh.open(url); + t.context.meshes.push(t.mesh); + } }, + close: function() { //remove instance from mesh. }, @@ -980,8 +986,14 @@ function requestNodeGeometry(context, node) { m.noffsets[n], m.noffsets[n+1], function() { loadNodeGeometry(this, context, node); }, - function() { console.log("Geometry request error!"); recoverNode(context, node, 0); }, - function() { console.log("Geometry request abort!"); removeNode(context, node); }, + function() { +// console.log("Geometry request error!"); + recoverNode(context, node, 0); + }, + function() { +// console.log("Geometry request abort!"); + removeNode(context, node); + }, 'arraybuffer' ); } @@ -1002,8 +1014,14 @@ function requestNodeTexture(context, node) { m.textures[tex], m.textures[tex+1], function() { loadNodeTexture(this, context, node, tex); }, - function() { console.log("Texture request error!"); recoverNode(context, node, 1); }, - function() { console.log("Texture request abort!"); removeNode(context, node); }, + function() { +// console.log("Texture request error!"); + recoverNode(context, node, 1); + }, + function() { +// console.log("Texture request abort!"); + removeNode(context, node); + }, 'blob' ); } diff --git a/minimal/js/presenter.js b/minimal/js/presenter.js index bcd762f..7c79d1e 100644 --- a/minimal/js/presenter.js +++ b/minimal/js/presenter.js @@ -193,14 +193,14 @@ _parseSpace : function (options) { explicitRadius : 1.0, transform : null, cameraFOV : 60.0, - cameraNearFar : [0.1, 10.0], + cameraNearFar : [0.01, 10.0], cameraType : "perspective", useLighting : true, }, options); r.transform = this._parseTransform(r.transform); - if(r.cameraFOV < 2.0) r.cameraFOV=2.0; - if(r.cameraFOV > 88.0) r.cameraFOV=88.0; - if((r.cameraType != "perspective") && (r.cameraType != "ortho")) + if(r.cameraFOV < 2.0) r.cameraFOV = 2.0; + if(r.cameraFOV > 88.0) r.cameraFOV = 88.0; + if((r.cameraType != "perspective") && (r.cameraType != "orthographic")) r.cameraType = "perspective"; return r; }, @@ -1072,7 +1072,7 @@ _testReady : function () { this._sceneReady = this._scenePrepare(); - this.repaint() + this.repaint(); }, _scenePrepare : function () { @@ -1122,7 +1122,7 @@ _pickingRefresh: function(x,y) { } if(this._onLeaveSpot && this._lastPickedSpot!=null) this._onLeaveSpot(this._lastPickedSpot); if(this._onEnterSpot && this._pickedSpot!=null) this._onEnterSpot(this._pickedSpot); - this.repaint() + this.repaint(); } this._lastPickedSpot = spt; break; @@ -1138,7 +1138,7 @@ _pickingRefresh: function(x,y) { if(this._onLeaveSpot && this._lastPickedSpot!=null) this._onLeaveSpot(this._lastPickedSpot); //if(this._onEnterSpot) this._onEnterSpot(this._pickedSpot); this._lastPickedSpot = null; - this.repaint() + this.repaint(); } this._lastSpotID = ID; } @@ -1159,7 +1159,7 @@ _pickingRefresh: function(x,y) { if(/*!this._movingLight ||*/ !this._isMeasuring){ this._lastCursor = cursor; if(this._pickedSpot==null)document.getElementById(this.ui.canvas.id).style.cursor = cursor; - this.repaint() + this.repaint(); } if(this._onLeaveInstance && this._lastPickedInstance!=null) this._onLeaveInstance(this._lastPickedInstance); if(this._onEnterInstance && this._pickedInstance!=null) this._onEnterInstance(this._pickedInstance); @@ -1176,7 +1176,7 @@ _pickingRefresh: function(x,y) { if((/*!this._movingLight ||*/ !this._isMeasuring) && this._pickedSpot==null) document.getElementById(this.ui.canvas.id).style.cursor = "default"; if(this._onLeaveInstance && this._lastPickedInstance!=null) this._onLeaveInstance(this._lastPickedInstance); //if(this._onEnterInstance) this._onEnterInstance(this._pickedInstance); - this.repaint() + this.repaint(); } this._lastPickedInstance = null; } @@ -1193,13 +1193,13 @@ _measureRefresh : function (button, x, y, e) { if ((ppoint!=null)&&(this._measurementStage != 2)) { this._pointA = ppoint; this._measurementStage=2; - this.repaint() + this.repaint(); } else if ((ppoint!=null)&&(this._measurementStage == 2)) { this._pointB = ppoint; this.measurement = SglVec3.length(SglVec3.sub(this._pointA, this._pointB)); this._measurementStage=3; - this.repaint() + this.repaint(); if(this._onEndMeasurement) this._onEndMeasurement(this.measurement, [this._pointA[0], this._pointA[1], this._pointA[2]], [this._pointB[0], this._pointB[1], this._pointB[2]]); } @@ -1213,7 +1213,7 @@ _startMeasurement : function () { this._pointA = [0.0, 0.0, 0.0]; this._pointB = [0.0, 0.0, 0.0]; this.measurement = 0.0; - this.repaint() + this.repaint(); }, _stopMeasurement : function () { @@ -1223,7 +1223,7 @@ _stopMeasurement : function () { this._pointA = [0.0, 0.0, 0.0]; this._pointB = [0.0, 0.0, 0.0]; this.measurement = 0.0; - this.repaint() + this.repaint(); }, _pickpointRefresh : function (button, x, y, e) { @@ -1237,7 +1237,7 @@ _pickpointRefresh : function (button, x, y, e) { this._pickedPoint = ppoint; this._pickValid = true; if(this._onEndPickingPoint) this._onEndPickingPoint([this._pickedPoint[0], this._pickedPoint[1], this._pickedPoint[2]]); - this.repaint() + this.repaint(); } } }, @@ -1247,7 +1247,7 @@ _startPickPoint : function () { this._isMeasuring = this._isMeasuringPickpoint = true; this._pickValid = false; this._pickedPoint = [0.0, 0.0, 0.0]; - this.repaint() + this.repaint(); }, _stopPickPoint : function () { @@ -1255,7 +1255,7 @@ _stopPickPoint : function () { if (!this._isMeasuringDistance) this._isMeasuring = this._isMeasuringPickpoint; this._pickValid = false; this._pickedPoint = [0.0, 0.0, 0.0]; - this.repaint() + this.repaint(); }, //---------------------------------------------------------------------------------------- @@ -1490,9 +1490,9 @@ _setupDraw : function () { xform.projection.loadIdentity(); - if(space.cameraType == "ortho") + if(space.cameraType == "orthographic") { - //default camera distance in ortho view is "as large as scene size" + //default camera distance in orthographic view is "as large as scene size" // then, if the trackball is able to provide a better value, we use it var cDistance = 1.0; if(typeof this.trackball.distance != "undefined") @@ -2739,7 +2739,7 @@ onClick : function (button, x, y, e) { if (ppoint!=null) { this.ui.animateRate = 30; this.trackball.recenter(ppoint); - this.repaint() + this.repaint(); } } } @@ -2754,15 +2754,16 @@ onClick : function (button, x, y, e) { onKeyPress : function (key, e) { if(this._isDebugging) { // DEBUGGING-AUTHORING keys - if((e.charCode == '80') || (e.charCode == '112')) // key "P" to print trackball - console.log(this.trackball.getState()); if (e.charCode == '49') { // key "1" to show nexus patches - Nexus.Debug.nodes=!Nexus.Debug.nodes; - this.repaint() + Nexus.Debug.nodes =! Nexus.Debug.nodes; + this.repaint(); } - if (e.charCode == '50') { // key "2" to toggle camera perspective/ortho + else if (e.charCode == '50') { // key "2" to toggle camera perspective/orthographic this.toggleCameraType(); + this.repaint(); } + else if((e.charCode == '80') || (e.charCode == '112')) // key "P" to print trackball + console.log(this.trackball.getState()); } }, @@ -2809,14 +2810,14 @@ onMouseWheel: function (wheelDelta, x, y, e) { } } - if(diff) this.repaint() + if(diff) this.repaint(); }, onAnimate : function (dt) { if (this._isSceneReady()) { // animate trackball if(this.trackball.tick(dt)) { - this.repaint() + this.repaint(); } else { this.ui.animateRate = 0; @@ -2835,41 +2836,6 @@ onDraw : function () { //---------------------------------------------------------------------------------------- // EXPOSED FUNCTIONS //---------------------------------------------------------------------------------------- -supportsWebGL : function () { - return this._supportsWebGL; -}, - -toggleDebugMode : function () { - this._isDebugging = !this._isDebugging; -}, - -setNexusTargetFps: function(fps) { - this._nexusTargetFps = fps; - Nexus.setTargetFps(this.ui.gl, fps); -}, - -getNexusTargetFps: function() { - return this._nexusTargetFps; -}, - -setNexusTargetError: function(error) { - this._nexusTargetError = error; - Nexus.setTargetError(this.ui.gl, error); -}, - -getNexusTargetError: function() { - return this._nexusTargetError; -}, - -setNexusCacheSize: function(size) { - this._nexusCacheSize = size; - Nexus.setMaxCacheSize(this.ui.gl, size); -}, - -getNexusCacheSize: function() { - return this._nexusCacheSize; -}, - setScene : function (options) { if (!options) return; @@ -2921,19 +2887,21 @@ setScene : function (options) { for (var m in scene.meshes) { var mesh = scene.meshes[m]; + if (!mesh.url) continue; if((String(mesh.url).lastIndexOf(".nxs") == (String(mesh.url).length - 4))||(String(mesh.url).lastIndexOf(".nxz") == (String(mesh.url).length - 4))) { Nexus.setTargetError(gl, this._nexusTargetError); Nexus.setTargetFps(gl, this._nexusTargetFps); Nexus.setMaxCacheSize(gl, this._nexusCacheSize); - var nxs = new Nexus.Renderer(gl); - nxs.onLoad = function () { that._onMeshReady(); }; - nxs.onUpdate = this.ui.postDrawEvent; - nxs.open(mesh.url); + var nexus_instance = new Nexus.Renderer(gl); + nexus_instance.onLoad = function () { that._onMeshReady(); }; + nexus_instance.onUpdate = this.ui.postDrawEvent; - mesh.renderable = nxs; + mesh.renderable = nexus_instance; mesh.isNexus = true; + + nexus_instance.open(mesh.url); } else { mesh.renderable = null; @@ -2969,18 +2937,67 @@ setScene : function (options) { } // create point-to-point line model - this._createLineModel() + this._createLineModel(); // create quad models this._createQuadModels(); this._sceneParsed = true; }, +get version() { + return HOP_VERSION; +}, + +supportsWebGL : function () { + return this._supportsWebGL; +}, + +toggleDebugMode : function () { + this._isDebugging = !this._isDebugging; +}, + +repaint : function () { + this.ui.postDrawEvent(); +}, + +//----------------------------------------------------------------------------- +// nexus + +setNexusTargetFps: function(fps) { + this._nexusTargetFps = fps; + Nexus.setTargetFps(this.ui.gl, fps); +}, + +getNexusTargetFps: function() { + return this._nexusTargetFps; +}, + +setNexusTargetError: function(error) { + this._nexusTargetError = error; + Nexus.setTargetError(this.ui.gl, error); +}, + +getNexusTargetError: function() { + return this._nexusTargetError; +}, + +setNexusCacheSize: function(size) { + this._nexusCacheSize = size; + Nexus.setMaxCacheSize(this.ui.gl, size); +}, + +getNexusCacheSize: function() { + return this._nexusCacheSize; +}, + +//----------------------------------------------------------------------------- +// trackball + resetTrackball : function () { this.trackball.reset(); this.trackball.track(SglMat4.identity(), 0.0, 0.0, 0.0); this._lightDirection = HOP_DEFAULTLIGHT; // also reset lighting - this.repaint() + this.repaint(); }, getTrackballPosition : function () { @@ -2989,13 +3006,16 @@ getTrackballPosition : function () { setTrackballPosition : function (newposition) { this.trackball.setState(newposition); - this.repaint() + this.repaint(); }, +//----------------------------------------------------------------------------- +// camera animations + animateToTrackballPosition : function (newposition, newtime) { this.ui.animateRate = 30; this.trackball.animateToState(newposition, newtime); - this.repaint() + this.repaint(); }, isAnimate : function () { @@ -3005,32 +3025,35 @@ isAnimate : function () { }, //----------------------------------------------------------------------------- -// functions to dynamically change center/radius mode +// dynamic center/radius mode setCenterModeFirst : function () { this._scene.space.centerMode = "first"; - this.repaint() + this.repaint(); }, + setCenterModeScene : function () { this._scene.space.centerMode = "scene"; - this.repaint() + this.repaint(); }, + setCenterModeSpecific : function (instancename) { if(this._scene.modelInstances[instancename]) { this._scene.space.centerMode = "specific"; this._scene.space.whichInstanceCenter = instancename; - this.repaint() + this.repaint(); } else return "ERROR - No such instance"; }, + setCenterModeExplicit : function (newcenter) { if((newcenter.constructor === Array)&&(newcenter.length = 3)&&(isFinite(String(newcenter[0])))&&(isFinite(String(newcenter[1])))&&(isFinite(String(newcenter[2])))) { this._scene.space.centerMode = "explicit"; this._scene.space.explicitCenter = newcenter; - this.repaint() + this.repaint(); } else return "ERROR - Not a point"; @@ -3038,28 +3061,31 @@ setCenterModeExplicit : function (newcenter) { setRadiusModeFirst : function () { this._scene.space.radiusMode = "first"; - this.repaint() + this.repaint(); }, + setRadiusModeScene : function () { this._scene.space.radiusMode = "scene"; - this.repaint() + this.repaint(); }, + setRadiusModeSpecific : function (instancename) { if(this._scene.modelInstances[instancename]) { this._scene.space.radiusMode = "specific"; this._scene.space.whichInstanceRadius = instancename; - this.repaint() + this.repaint(); } else return "ERROR - No such instance"; }, + setRadiusModeExplicit : function (newradius) { if((isFinite(String(newradius)))&&(newradius>0.0)) { this._scene.space.radiusMode = "explicit"; this._scene.space.explicitRadius = newradius; - this.repaint() + this.repaint(); } else return "ERROR - Not a radius"; @@ -3067,6 +3093,7 @@ setRadiusModeExplicit : function (newradius) { //----------------------------------------------------------------------------- // instance solid color + setInstanceSolidColorByName : function (name, newState, redraw, newColor) { var instances = this._scene.modelInstances; @@ -3085,7 +3112,7 @@ setInstanceSolidColorByName : function (name, newState, redraw, newColor) { } } if(redraw) - this.repaint() + this.repaint(); }, setInstanceSolidColor : function (tag, newState, redraw, newColor) { @@ -3108,7 +3135,7 @@ setInstanceSolidColor : function (tag, newState, redraw, newColor) { } } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceSolidColorByName : function (name, redraw) { @@ -3121,7 +3148,7 @@ toggleInstanceSolidColorByName : function (name, redraw) { if(instances[name]) // if an instance with that name exists instances[name].useSolidColor = !instances[name].useSolidColor; if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceSolidColor : function (tag, redraw) { @@ -3136,11 +3163,60 @@ toggleInstanceSolidColor : function (tag, redraw) { instances[inst].useSolidColor = !instances[inst].useSolidColor; } if(redraw) - this.repaint() + this.repaint(); +}, + +isInstanceSolidColorEnabledByName : function (name) { + var solidcolor = false; + var instances = this._scene.modelInstances; + + if(!name || name==HOP_ALL) { + for (var inst in instances) { + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + else { + if(instances[name]) { // if an instance with that name exists + if(instances[name].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + return solidcolor; +}, + +isInstanceSolidColorEnabled : function (tag) { + var solidcolor = false; + var instances = this._scene.modelInstances; + + for (var inst in instances) { + if(!tag || tag==HOP_ALL){ + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + else{ + for (var tg in instances[inst].tags){ + if(instances[inst].tags[tg] == tag){ + if(instances[inst].useSolidColor){ + solidcolor = true; + return solidcolor; + } + } + } + } + } + return solidcolor; }, //----------------------------------------------------------------------------- // instance transparency + setInstanceTransparencyByName : function (name, newState, redraw, newAlpha) { var instances = this._scene.modelInstances; @@ -3158,7 +3234,7 @@ setInstanceTransparencyByName : function (name, newState, redraw, newAlpha) { } } if(redraw) - this.repaint() + this.repaint(); }, setInstanceTransparency : function (tag, newState, redraw, newAlpha) { @@ -3181,7 +3257,7 @@ setInstanceTransparency : function (tag, newState, redraw, newAlpha) { } } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceTransparencyByName : function (name, redraw) { @@ -3196,7 +3272,7 @@ toggleInstanceTransparencyByName : function (name, redraw) { instances[name].useTransparency = !instances[name].useTransparency; } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceTransparency : function (tag, redraw) { @@ -3216,12 +3292,62 @@ toggleInstanceTransparency : function (tag, redraw) { } } if(redraw) - this.repaint() + this.repaint(); +}, + + +isInstanceTransparencyEnabledByName : function (name) { + var transparency = false; + var instances = this._scene.modelInstances; + + if(!name || name==HOP_ALL) { + for (var inst in instances) { + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + } + else { + if(instances[name]) { // if an instance with that name exists + if(instances[name].useTransparency){ + transparency = true; + return transparency; + } + } + } + return transparency; +}, + +isInstanceTransparencyEnabled : function (tag) { + var transparency = false; + var instances = this._scene.modelInstances; + + for (var inst in instances) { + if(!tag || tag==HOP_ALL){ + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + else{ + for (var tg in instances[inst].tags){ + if(instances[inst].tags[tg] == tag){ + if(instances[inst].useTransparency){ + transparency = true; + return transparency; + } + } + } + } + } + return transparency; }, //----------------------------------------------------------------------------- // instance shading //----specular + setInstanceSpecularityByName : function (name, color, hardness, redraw) { var instances = this._scene.modelInstances; @@ -3234,7 +3360,7 @@ setInstanceSpecularityByName : function (name, color, hardness, redraw) { instances[name].specularColor = [color[0], color[1], color[2], hardness]; } if(redraw) - this.repaint() + this.repaint(); }, setInstanceSpecularity : function (tag, color, hardness, redraw) { @@ -3252,10 +3378,11 @@ setInstanceSpecularity : function (tag, color, hardness, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, //----backface + setInstanceBackfaceByName : function (name, color, mode, redraw) { var instances = this._scene.modelInstances; var modecode = 0.0; @@ -3272,7 +3399,7 @@ setInstanceBackfaceByName : function (name, color, mode, redraw) { instances[name].backfaceColor = [color[0], color[1], color[2], modecode]; } if(redraw) - this.repaint() + this.repaint(); }, setInstanceBackface : function (tag, color, mode, redraw) { @@ -3294,11 +3421,12 @@ setInstanceBackface : function (tag, color, mode, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, //----------------------------------------------------------------------------- // instance visibility + setInstanceVisibilityByName : function (name, newState, redraw) { var instances = this._scene.modelInstances; @@ -3311,7 +3439,7 @@ setInstanceVisibilityByName : function (name, newState, redraw) { instances[name].visible = newState; } if(redraw) - this.repaint() + this.repaint(); }, setInstanceVisibility : function (tag, newState, redraw) { @@ -3329,7 +3457,7 @@ setInstanceVisibility : function (tag, newState, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceVisibilityByName : function (name, redraw) { @@ -3344,7 +3472,7 @@ toggleInstanceVisibilityByName : function (name, redraw) { instances[name].visible = !instances[name].visible; } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceVisibility : function (tag, redraw) { @@ -3364,7 +3492,7 @@ toggleInstanceVisibility : function (tag, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, isInstanceVisibilityEnabledByName : function (name) { @@ -3417,6 +3545,7 @@ isInstanceVisibilityEnabled : function (tag) { //----------------------------------------------------------------------------- // spot visibility + setSpotVisibilityByName : function (name, newState, redraw) { var spots = this._scene.spots; @@ -3429,7 +3558,7 @@ setSpotVisibilityByName : function (name, newState, redraw) { spots[name].visible = newState; } if(redraw) - this.repaint() + this.repaint(); }, setSpotVisibility : function (tag, newState, redraw) { @@ -3448,7 +3577,7 @@ setSpotVisibility : function (tag, newState, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, toggleSpotVisibilityByName : function (name, redraw) { @@ -3462,7 +3591,7 @@ toggleSpotVisibilityByName : function (name, redraw) { spots[name].visible = !spots[name].visible; } if(redraw) - this.repaint() + this.repaint(); }, toggleSpotVisibility : function (tag, redraw) { @@ -3481,7 +3610,7 @@ toggleSpotVisibility : function (tag, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, isSpotVisibilityEnabledByName : function (name) { @@ -3534,33 +3663,34 @@ isSpotVisibilityEnabled : function (tag) { //----------------------------------------------------------------------------- // sections + resetClippingXYZ: function() { this._calculateBounding(); this._clipAxis = [0.0, 0.0, 0.0]; this._clipPoint = [0.0, 0.0, 0.0]; - this.repaint() + this.repaint(); }, setClippingXYZ: function(cx, cy, cz) { this._calculateBounding(); this._clipAxis = [cx,cy,cz]; - this.repaint() + this.repaint(); }, setClippingX: function(cx) { this._calculateBounding(); this._clipAxis[0] = cx; - this.repaint() + this.repaint(); }, setClippingY: function(cy) { this._calculateBounding(); this._clipAxis[1] = cy; - this.repaint() + this.repaint(); }, setClippingZ: function(cz) { this._calculateBounding(); this._clipAxis[2] = cz; - this.repaint() + this.repaint(); }, getClippingX : function () { @@ -3576,23 +3706,23 @@ getClippingZ : function () { setClippingPointXYZabs: function(clx, cly, clz) { this._calculateBounding(); this._clipPoint = [clx, cly, clz]; - this.repaint() + this.repaint(); }, setClippingPointXabs: function(clx) { this._calculateBounding(); this._clipPoint[0] = clx; - this.repaint() + this.repaint(); }, setClippingPointYabs: function(cly) { this._calculateBounding(); this._clipPoint[1] = cly; - this.repaint() + this.repaint(); }, setClippingPointZabs: function(clz) { this._calculateBounding(); this._clipPoint[2] = clz; - this.repaint() + this.repaint(); }, setClippingPointXYZ: function(clx, cly, clz) { @@ -3609,7 +3739,7 @@ setClippingPointXYZ: function(clx, cly, clz) { nClipPoint[2] = this._sceneBboxMin[2] + clz * (this._sceneBboxMax[2] - this._sceneBboxMin[2]); this._clipPoint = nClipPoint; - this.repaint() + this.repaint(); }, setClippingPointX: function(clx) { @@ -3618,7 +3748,7 @@ setClippingPointX: function(clx) { if(clx<0.0) clx=0.0; else if(clx>1.0) clx=1.0; nClipPoint = this._sceneBboxMin[0] + clx * (this._sceneBboxMax[0] - this._sceneBboxMin[0]); this._clipPoint[0] = nClipPoint; - this.repaint() + this.repaint(); }, setClippingPointY: function(cly) { var nClipPoint = 0.0; @@ -3626,7 +3756,7 @@ setClippingPointY: function(cly) { if(cly<0.0) cly=0.0; else if(cly>1.0) cly=1.0; nClipPoint = this._sceneBboxMin[1] + cly * (this._sceneBboxMax[1] - this._sceneBboxMin[1]); this._clipPoint[1] = nClipPoint; - this.repaint() + this.repaint(); }, setClippingPointZ: function(clz) { var nClipPoint = 0.0; @@ -3634,7 +3764,7 @@ setClippingPointZ: function(clz) { if(clz<0.0) clz=0.0; else if(clz>1.0) clz=1.0; nClipPoint = this._sceneBboxMin[2] + clz * (this._sceneBboxMax[2] - this._sceneBboxMin[2]); this._clipPoint[2] = nClipPoint; - this.repaint() + this.repaint(); }, _calculateBounding: function() { @@ -3695,7 +3825,7 @@ setClippingRendermode: function(showPlanes, showBorder, borderSize, borderColor) this._scene.config.clippingBorderSize = borderSize; if(borderColor) this._scene.config.clippingBorderColor = borderColor; - this.repaint() + this.repaint(); }, getClippingRendermode: function() { @@ -3706,14 +3836,15 @@ getClippingRendermode: function() { resetClippingPlane : function () { this._calculateBounding(); this._clipPlane = [0.0, 0.0, 0.0, 0.0]; - this.repaint() + this.repaint(); }, setClippingPlaneExplicit : function (axis, offset) { this._calculateBounding(); this._clipPlane = [axis[0], axis[1], axis[2], offset]; - this.repaint() + this.repaint(); }, + setClippingPlane : function (angleH, angleV, sign, delta, deltaabs) { this._calculateBounding(); var axis; @@ -3736,10 +3867,12 @@ setClippingPlane : function (angleH, angleV, sign, delta, deltaabs) { sceneOff = SglVec3.dot([axis[0], axis[1], axis[2]], position); this._clipPlane = [axis[0], axis[1], axis[2], -sceneOff]; - this.repaint() + this.repaint(); }, //----------------------------------------------------------------------------- +// zoom + zoomIn: function() { this.onMouseWheel(1); }, @@ -3749,6 +3882,8 @@ zoomOut: function() { }, //----------------------------------------------------------------------------- +// light + rotateLight: function(x, y) { x *= 2; y *= 2; @@ -3760,11 +3895,15 @@ rotateLight: function(x, y) { } var z = Math.sqrt(1 - r*r); this._lightDirection = [-x, -y, -z]; - this.repaint() + this.repaint(); }, enableLightTrackball: function(on) { this._movingLight = on; + + if(on && !this._scene.space.useLighting) this._scene.space.useLighting = on; + + this.repaint(); }, isLightTrackballEnabled: function() { @@ -3772,6 +3911,8 @@ isLightTrackballEnabled: function() { }, //----------------------------------------------------------------------------- +// onHover + enableOnHover: function(on) { this._onHover = on; }, @@ -3781,6 +3922,8 @@ isOnHoverEnabled: function() { }, //----------------------------------------------------------------------------- +// linear measure + enableMeasurementTool: function(on) { if(on) this._startMeasurement(); @@ -3793,6 +3936,8 @@ isMeasurementToolEnabled: function() { }, //----------------------------------------------------------------------------- +// point measure + enablePickpointMode: function(on) { if(on) this._startPickPoint(); @@ -3805,33 +3950,41 @@ isPickpointModeEnabled: function() { }, //----------------------------------------------------------------------------- +// measurements + isAnyMeasurementEnabled: function() { return this._isMeasuring; }, //----------------------------------------------------------------------------- +// camera type + toggleCameraType: function() { - if(this._scene.space.cameraType == "ortho") + if(this._scene.space.cameraType == "orthographic") this._scene.space.cameraType = "perspective" else - this._scene.space.cameraType = "ortho" + this._scene.space.cameraType = "orthographic" - this.repaint() + this.repaint(); }, setCameraPerspective: function() { this._scene.space.cameraType = "perspective"; - this.repaint() + this.repaint(); }, + setCameraOrthographic: function() { - this._scene.space.cameraType = "ortho"; - this.repaint() + this._scene.space.cameraType = "orthographic"; + this.repaint(); }, + getCameraType : function () { return this._scene.space.cameraType; }, //----------------------------------------------------------------------------- +// trackball lock + toggleTrackballLock: function() { this._scene.trackball.locked = !this._scene.trackball.locked; }, @@ -3845,16 +3998,17 @@ isTrackballLockEnabled: function() { }, //----------------------------------------------------------------------------- -toggleSceneLighting : function () { - this._scene.space.useLighting = !this._scene.space.useLighting; - this.repaint() -}, +// lighting + +enableSceneLighting: function(on) { + this._scene.space.useLighting = on; + + if(!on && this._movingLight) this._movingLight = on; -setSceneLighting : function (newState) { - this._scene.space.useLighting = newState; - this.repaint() + this.repaint(); }, -getSceneLighting : function () { + +isSceneLightingEnabled: function() { return this._scene.space.useLighting; }, @@ -3870,7 +4024,7 @@ setInstanceLightingByName : function (name, newState, redraw) { instances[name].useLighting = newState; } if(redraw) - this.repaint() + this.repaint(); }, setInstanceLighting : function (tag, newState, redraw) { @@ -3888,7 +4042,7 @@ setInstanceLighting : function (tag, newState, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceLightingByName : function (name, redraw) { @@ -3903,7 +4057,7 @@ toggleInstanceLightingByName : function (name, redraw) { instances[name].useLighting = !instances[name].useLighting; } if(redraw) - this.repaint() + this.repaint(); }, toggleInstanceLighting : function (tag, redraw) { @@ -3923,7 +4077,7 @@ toggleInstanceLighting : function (tag, redraw) { } } if(redraw) - this.repaint() + this.repaint(); }, isInstanceLightingEnabledByName : function (name) { @@ -3972,16 +4126,6 @@ isInstanceLightingEnabled : function (tag) { } } return Lighting; -}, - -//----------------------------------------------------------------------------- -repaint : function () { - this.ui.postDrawEvent(); -}, - -//----------------------------------------------------------------------------- -get version() { - return HOP_VERSION; } }; // Presenter.prototype END diff --git a/minimal/models/gargo.nxs b/minimal/models/gargo.nxs deleted file mode 100644 index c1f1f15..0000000 Binary files a/minimal/models/gargo.nxs and /dev/null differ diff --git a/minimal/skins/dark/light_off.png b/minimal/skins/dark/light_off.png index 6806438..34f078e 100644 Binary files a/minimal/skins/dark/light_off.png and b/minimal/skins/dark/light_off.png differ diff --git a/minimal/skins/dark/lightcontrol.png b/minimal/skins/dark/lightcontrol.png new file mode 100644 index 0000000..ece6887 Binary files /dev/null and b/minimal/skins/dark/lightcontrol.png differ diff --git a/minimal/skins/dark/lightcontrol_on.png b/minimal/skins/dark/lightcontrol_on.png new file mode 100644 index 0000000..ef56315 Binary files /dev/null and b/minimal/skins/dark/lightcontrol_on.png differ diff --git a/minimal/skins/dark/lighting.png b/minimal/skins/dark/lighting.png new file mode 100644 index 0000000..4dd4352 Binary files /dev/null and b/minimal/skins/dark/lighting.png differ diff --git a/minimal/skins/dark/lighting_off.png b/minimal/skins/dark/lighting_off.png new file mode 100644 index 0000000..5bcbf02 Binary files /dev/null and b/minimal/skins/dark/lighting_off.png differ diff --git a/minimal/skins/dark/ortho.png b/minimal/skins/dark/ortho.png deleted file mode 100644 index 9583e7f..0000000 Binary files a/minimal/skins/dark/ortho.png and /dev/null differ diff --git a/minimal/skins/dark/orthographic.png b/minimal/skins/dark/orthographic.png new file mode 100644 index 0000000..855f992 Binary files /dev/null and b/minimal/skins/dark/orthographic.png differ diff --git a/minimal/skins/dark/perspective.png b/minimal/skins/dark/perspective.png index 8b0b08e..e53bef4 100644 Binary files a/minimal/skins/dark/perspective.png and b/minimal/skins/dark/perspective.png differ diff --git a/minimal/skins/light/light_off.png b/minimal/skins/light/light_off.png new file mode 100644 index 0000000..bf4f53e Binary files /dev/null and b/minimal/skins/light/light_off.png differ diff --git a/minimal/skins/light/lightcontrol.png b/minimal/skins/light/lightcontrol.png new file mode 100644 index 0000000..cf00b3f Binary files /dev/null and b/minimal/skins/light/lightcontrol.png differ diff --git a/minimal/skins/light/lightcontrol_on.png b/minimal/skins/light/lightcontrol_on.png new file mode 100644 index 0000000..b935929 Binary files /dev/null and b/minimal/skins/light/lightcontrol_on.png differ diff --git a/minimal/skins/light/lighting.png b/minimal/skins/light/lighting.png new file mode 100644 index 0000000..7bc59eb Binary files /dev/null and b/minimal/skins/light/lighting.png differ diff --git a/minimal/skins/light/lighting_off.png b/minimal/skins/light/lighting_off.png new file mode 100644 index 0000000..98065e3 Binary files /dev/null and b/minimal/skins/light/lighting_off.png differ diff --git a/minimal/skins/light/orthographic.png b/minimal/skins/light/orthographic.png new file mode 100644 index 0000000..865c5fb Binary files /dev/null and b/minimal/skins/light/orthographic.png differ diff --git a/minimal/skins/light/perspective.png b/minimal/skins/light/perspective.png new file mode 100644 index 0000000..dcbf5a0 Binary files /dev/null and b/minimal/skins/light/perspective.png differ diff --git a/minimal/skins/minimal_dark/light_off.png b/minimal/skins/minimal_dark/light_off.png new file mode 100644 index 0000000..22d8321 Binary files /dev/null and b/minimal/skins/minimal_dark/light_off.png differ diff --git a/minimal/skins/minimal_dark/lightcontrol.png b/minimal/skins/minimal_dark/lightcontrol.png new file mode 100644 index 0000000..c9f2357 Binary files /dev/null and b/minimal/skins/minimal_dark/lightcontrol.png differ diff --git a/minimal/skins/minimal_dark/lightcontrol_on.png b/minimal/skins/minimal_dark/lightcontrol_on.png new file mode 100644 index 0000000..f227244 Binary files /dev/null and b/minimal/skins/minimal_dark/lightcontrol_on.png differ diff --git a/minimal/skins/minimal_dark/lighting.png b/minimal/skins/minimal_dark/lighting.png new file mode 100644 index 0000000..d2eadff Binary files /dev/null and b/minimal/skins/minimal_dark/lighting.png differ diff --git a/minimal/skins/minimal_dark/lighting_off.png b/minimal/skins/minimal_dark/lighting_off.png new file mode 100644 index 0000000..7f5921a Binary files /dev/null and b/minimal/skins/minimal_dark/lighting_off.png differ diff --git a/minimal/skins/minimal_dark/orthographic.png b/minimal/skins/minimal_dark/orthographic.png new file mode 100644 index 0000000..1f07ed9 Binary files /dev/null and b/minimal/skins/minimal_dark/orthographic.png differ diff --git a/minimal/skins/minimal_dark/perspective.png b/minimal/skins/minimal_dark/perspective.png new file mode 100644 index 0000000..4ea1b1f Binary files /dev/null and b/minimal/skins/minimal_dark/perspective.png differ diff --git a/minimal/skins/minimal_light/light_off.png b/minimal/skins/minimal_light/light_off.png new file mode 100644 index 0000000..1971a81 Binary files /dev/null and b/minimal/skins/minimal_light/light_off.png differ diff --git a/minimal/skins/minimal_light/lightcontrol.png b/minimal/skins/minimal_light/lightcontrol.png new file mode 100644 index 0000000..3567244 Binary files /dev/null and b/minimal/skins/minimal_light/lightcontrol.png differ diff --git a/minimal/skins/minimal_light/lightcontrol_on.png b/minimal/skins/minimal_light/lightcontrol_on.png new file mode 100644 index 0000000..4b63fce Binary files /dev/null and b/minimal/skins/minimal_light/lightcontrol_on.png differ diff --git a/minimal/skins/minimal_light/lighting.png b/minimal/skins/minimal_light/lighting.png new file mode 100644 index 0000000..5996246 Binary files /dev/null and b/minimal/skins/minimal_light/lighting.png differ diff --git a/minimal/skins/minimal_light/lighting_off.png b/minimal/skins/minimal_light/lighting_off.png new file mode 100644 index 0000000..9ac9788 Binary files /dev/null and b/minimal/skins/minimal_light/lighting_off.png differ diff --git a/minimal/skins/minimal_light/orthographic.png b/minimal/skins/minimal_light/orthographic.png new file mode 100644 index 0000000..3160ffa Binary files /dev/null and b/minimal/skins/minimal_light/orthographic.png differ diff --git a/minimal/skins/minimal_light/perspective.png b/minimal/skins/minimal_light/perspective.png new file mode 100644 index 0000000..5e4985b Binary files /dev/null and b/minimal/skins/minimal_light/perspective.png differ diff --git a/minimal/skins/transparent_dark/light_off.png b/minimal/skins/transparent_dark/light_off.png new file mode 100644 index 0000000..09adde1 Binary files /dev/null and b/minimal/skins/transparent_dark/light_off.png differ diff --git a/minimal/skins/transparent_dark/lightcontrol.png b/minimal/skins/transparent_dark/lightcontrol.png new file mode 100644 index 0000000..00631fa Binary files /dev/null and b/minimal/skins/transparent_dark/lightcontrol.png differ diff --git a/minimal/skins/transparent_dark/lightcontrol_on.png b/minimal/skins/transparent_dark/lightcontrol_on.png new file mode 100644 index 0000000..77b5ae9 Binary files /dev/null and b/minimal/skins/transparent_dark/lightcontrol_on.png differ diff --git a/minimal/skins/transparent_dark/lighting.png b/minimal/skins/transparent_dark/lighting.png new file mode 100644 index 0000000..0568133 Binary files /dev/null and b/minimal/skins/transparent_dark/lighting.png differ diff --git a/minimal/skins/transparent_dark/lighting_off.png b/minimal/skins/transparent_dark/lighting_off.png new file mode 100644 index 0000000..40308f2 Binary files /dev/null and b/minimal/skins/transparent_dark/lighting_off.png differ diff --git a/minimal/skins/transparent_dark/orthographic.png b/minimal/skins/transparent_dark/orthographic.png new file mode 100644 index 0000000..c1504a2 Binary files /dev/null and b/minimal/skins/transparent_dark/orthographic.png differ diff --git a/minimal/skins/transparent_dark/perspective.png b/minimal/skins/transparent_dark/perspective.png new file mode 100644 index 0000000..09e893f Binary files /dev/null and b/minimal/skins/transparent_dark/perspective.png differ diff --git a/minimal/skins/transparent_light/light_off.png b/minimal/skins/transparent_light/light_off.png new file mode 100644 index 0000000..c0ff3e4 Binary files /dev/null and b/minimal/skins/transparent_light/light_off.png differ diff --git a/minimal/skins/transparent_light/lightcontrol.png b/minimal/skins/transparent_light/lightcontrol.png new file mode 100644 index 0000000..c37eaf2 Binary files /dev/null and b/minimal/skins/transparent_light/lightcontrol.png differ diff --git a/minimal/skins/transparent_light/lightcontrol_on.png b/minimal/skins/transparent_light/lightcontrol_on.png new file mode 100644 index 0000000..1c340d5 Binary files /dev/null and b/minimal/skins/transparent_light/lightcontrol_on.png differ diff --git a/minimal/skins/transparent_light/lighting.png b/minimal/skins/transparent_light/lighting.png new file mode 100644 index 0000000..3096058 Binary files /dev/null and b/minimal/skins/transparent_light/lighting.png differ diff --git a/minimal/skins/transparent_light/lighting_off.png b/minimal/skins/transparent_light/lighting_off.png new file mode 100644 index 0000000..9eee289 Binary files /dev/null and b/minimal/skins/transparent_light/lighting_off.png differ diff --git a/minimal/skins/transparent_light/orthographic.png b/minimal/skins/transparent_light/orthographic.png new file mode 100644 index 0000000..49ceab9 Binary files /dev/null and b/minimal/skins/transparent_light/orthographic.png differ diff --git a/minimal/skins/transparent_light/perspective.png b/minimal/skins/transparent_light/perspective.png new file mode 100644 index 0000000..cce2428 Binary files /dev/null and b/minimal/skins/transparent_light/perspective.png differ diff --git a/minimal/stylesheet/3DHpanels.css b/minimal/stylesheet/3DHpanels.css index c25d7a7..e1e6c4c 100644 --- a/minimal/stylesheet/3DHpanels.css +++ b/minimal/stylesheet/3DHpanels.css @@ -1,7 +1,7 @@ /* 3DHOP - 3D Heritage Online Presenter -Copyright (c) 2014-2017, Visual Computing Lab, ISTI - CNR -All rights reserved. +Copyright (c) 2014-2018, Visual Computing Lab, ISTI - CNR +All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by diff --git a/minimal/stylesheet/3dhop.css b/minimal/stylesheet/3dhop.css index 757c7bc..43907a0 100644 --- a/minimal/stylesheet/3dhop.css +++ b/minimal/stylesheet/3dhop.css @@ -1,7 +1,7 @@ /* 3DHOP - 3D Heritage Online Presenter -Copyright (c) 2014-2017, Visual Computing Lab, ISTI - CNR -All rights reserved. +Copyright (c) 2014-2018, Visual Computing Lab, ISTI - CNR +All rights reserved. This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by