# JSXGraph 1.7.0 Reference

## JavaScript must be enabled in order for you to use JSXGraph and JSXGraph reference. However, it seems JavaScript is either disabled or not supported by your browser.

Class Index | File Index

Elements

Classes

- _global_
- Angle
- Arc
- Arrow
- Arrowparallel
- Axis
- Bisector
- Bisectorlines
- Boxplot
- Button
- Cardinalspline
- Chart
- Checkbox
- Circle
- Circumcenter
- Circumcircle
- CircumcircleArc
- CircumcircleSector
- Comb
- Conic
- Curve
- Curve3D
- CurveDifference
- CurveIntersection
- CurveUnion
- Derivative
- Ellipse
- ForeignObject
- Functiongraph
- Functiongraph3D
- Glider
- Grid
- Group
- Hatch
- Hyperbola
- Image
- ImplicitCurve
- Incenter
- Incircle
- Inequality
- Input
- Integral
- Intersection
- JXG
- JXG.AbstractRenderer
- JXG.Board
- JXG.Board.infobox
- JXG.C
- JXG.CA
- JXG.CanvasRenderer
- JXG.Chart
- JXG.Circle
- JXG.Complex
- JXG.Composition
- JXG.Coords
- JXG.CoordsElement
- JXG.Curve
- JXG.Curve3D
- JXG.Dump
- JXG.EventEmitter
- JXG.Expect
- JXG.ForeignObject
- JXG.GeometryElement
- JXG.GeometryElement3D
- JXG.GeonextParser
- JXG.Group
- JXG.Image
- JXG.JessieCode
- JXG.JSXGraph
- JXG.Legend
- JXG.Line
- JXG.Line3D
- JXG.Math
- JXG.Math.BoxQuadtree
- JXG.Math.Clip
- JXG.Math.Extrapolate
- JXG.Math.Geometry
- JXG.Math.ImplicitPlot
- JXG.Math.IntervalArithmetic
- JXG.Math.Metapost
- JXG.Math.Nlp
- JXG.Math.Numerics
- JXG.Math.Plot
- JXG.Math.Poly
- JXG.Math.Poly.Monomial
- JXG.Math.Poly.Polynomial
- JXG.Math.Poly.Ring
- JXG.Math.ProbFuncs
- JXG.Math.Quadtree
- JXG.Math.Statistics
- JXG.Math.Symbolic
- JXG.NoRenderer
- JXG.Options
- JXG.Plane3D
- JXG.Point
- JXG.Point3D
- JXG.Polygon
- JXG.PrefixParser
- JXG.Server
- JXG.Server.modules
- JXG.Surface3D
- JXG.SVGRenderer
- JXG.Text
- JXG.Ticks
- JXG.Transformation
- JXG.Turtle
- JXG.Util
- JXG.Util.Base64
- JXG.Util.Unzip
- JXG.Util.UTF8
- JXG.View3D
- JXG.VMLRenderer
- JXG.XML
- Label
- Legend
- Line
- Line3D
- Locus
- MajorArc
- MajorSector
- Measurement
- Metapostspline
- Midpoint
- MinorArc
- MinorSector
- mirrorelement
- Mirrorpoint
- NonReflexAngle
- Normal
- Orthogonalprojection
- OtherIntersection
- Parabola
- Parallel
- Parallelogram
- Parallelpoint
- ParametricSurface3D
- Perpendicular
- PerpendicularPoint
- PerpendicularSegment
- Point
- Point3D
- PolarLine
- PolePoint
- Polygon
- PolygonalChain
- RadicalAxis
- Reflection
- ReflexAngle
- RegularPolygon
- Riemannsum
- Sector
- Segment
- Semicircle
- Slider
- Slopefield
- Slopetriangle
- Smartlabel
- Spline
- Stepfunction
- Tangent
- Tapemeasure
- Text
- Ticks
- Tracecurve
- Transformation
- Turtle
- Vectorfield
- Vectorfield3D
- View3D

# Class View3D

JXG.GeometryElement
↳ JXG.View3D
↳ View3D

This element creates a 3D view.
Defined in: view3d.js.
Extends JXG.View3D.

Class Summary
Constructor Attributes | Constructor Name and Description
--- | ---
| View3D(lower,dim,cube) A View3D element provides the container and the methods to create and display 3D elements.

Fields borrowed from class JXG.View3D:
  az_slide, bbox3D, defaultAxes, el_slide, elementsByName, llftCorner, matrix3D, objects, r, size
Fields borrowed from class JXG.GeometryElement:
  _org_type, _pos, ancestors, baseElement, board, childElements, dash, dashScale, descendants, draft, dragToTopOfLayer, dump, elementClass, elType, fillColor, fillOpacity, fixed, frozen, gradient, gradientAngle, gradientCX, gradientCY, gradientEndOffset, gradientFR, gradientFX, gradientFY, gradientR, gradientSecondColor, gradientSecondOpacity, gradientStartOffset, hasLabel, highlight, highlighted, highlightFillColor, highlightFillOpacity, highlightStrokeColor, highlightStrokeOpacity, highlightStrokeWidth, id, inherits, isDraggable, isLabel, isReal, lastDragTime, layer, lineCap, methodMap, mouseover, name, needsRegularUpdate, needsUpdate, notExistingParents, numTraces, parents, precision, priv, quadraticform, rendNode, rotatable, scalable, shadow, snapToGrid, stdform, strokeColor, strokeOpacity, strokeWidth, subs, symbolic, tabindex, trace, traceAttributes, traces, transformations, transitionDuration, transitionProperties, type, viewport, visible, visProp, visPropCalc, withLabel

Field Summary
Field Attributes | Field Name and Description
--- | ---
| axesPosition Position of the main axes in a View3D element.
| verticalDrag Allow vertical dragging of objects, i.e.
| xAxis Attributes of the 3D x-axis.
| xPlaneFront Attributes of the 3D plane orthogonal to the x-axis at the "front" of the cube.
| xPlaneFrontYAxis Attributes of the 3D y-axis on the 3D plane orthogonal to the x-axis at the "front" of the cube.
| xPlaneFrontZAxis Attributes of the 3D z-axis on the 3D plane orthogonal to the x-axis at the "front" of the cube.
| xPlaneRear Attributes of the 3D plane orthogonal to the x-axis at the "rear" of the cube.
| xPlaneRearYAxis Attributes of the 3D y-axis on the 3D plane orthogonal to the x-axis at the "rear" of the cube.
| xPlaneRearZAxis Attributes of the 3D z-axis on the 3D plane orthogonal to the x-axis at the "rear" of the cube.
| yAxis Attributes of the 3D y-axis.
| yPlaneFront Attributes of the 3D plane orthogonal to the y-axis at the "front" of the cube.
| yPlaneFrontXAxis Attributes of the 3D x-axis on the 3D plane orthogonal to the y-axis at the "front" of the cube.
| yPlaneFrontZAxis Attributes of the 3D z-axis on the 3D plane orthogonal to the y-axis at the "front" of the cube.
| yPlaneRear Attributes of the 3D plane orthogonal to the y-axis at the "rear" of the cube.
| yPlaneRearXAxis Attributes of the 3D x-axis on the 3D plane orthogonal to the y-axis at the "rear" of the cube.
| yPlaneRearZAxis Attributes of the 3D z-axis on the 3D plane orthogonal to the y-axis at the "rear" of the cube.
| zAxis Attributes of the 3D z-axis.
| zPlaneFront Attributes of the 3D plane orthogonal to the z-axis at the "front" of the cube.
| zPlaneFrontXAxis Attributes of the 3D x-axis on the 3D plane orthogonal to the z-axis at the "front" of the cube.
| zPlaneFrontYAxis Attributes of the 3D y-axis on the 3D plane orthogonal to the z-axis at the "front" of the cube.
| zPlaneRear Attributes of the 3D plane orthogonal to the z-axis at the "rear" of the cube.
| zPlaneRearXAxis Attributes of the 3D x-axis on the 3D plane orthogonal to the z-axis at the "rear" of the cube.
| zPlaneRearYAxis Attributes of the 3D y-axis on the 3D plane orthogonal to the z-axis at the "rear" of the cube.

Fields borrowed from class JXG.View3D:
  az_slide, bbox3D, defaultAxes, el_slide, elementsByName, llftCorner, matrix3D, objects, r, size
Fields borrowed from class JXG.GeometryElement:
  _org_type, _pos, ancestors, baseElement, board, childElements, dash, dashScale, descendants, draft, dragToTopOfLayer, dump, elementClass, elType, fillColor, fillOpacity, fixed, frozen, gradient, gradientAngle, gradientCX, gradientCY, gradientEndOffset, gradientFR, gradientFX, gradientFY, gradientR, gradientSecondColor, gradientSecondOpacity, gradientStartOffset, hasLabel, highlight, highlighted, highlightFillColor, highlightFillOpacity, highlightStrokeColor, highlightStrokeOpacity, highlightStrokeWidth, id, inherits, isDraggable, isLabel, isReal, lastDragTime, layer, lineCap, methodMap, mouseover, name, needsRegularUpdate, needsUpdate, notExistingParents, numTraces, parents, precision, priv, quadraticform, rendNode, rotatable, scalable, shadow, snapToGrid, stdform, strokeColor, strokeOpacity, strokeWidth, subs, symbolic, tabindex, trace, traceAttributes, traces, transformations, transitionDuration, transitionProperties, type, viewport, visible, visProp, visPropCalc, withLabel

Methods borrowed from class JXG.View3D:
  animateAzimuth, create, getMesh, intersectionLineCube, intersectionPlanePlane, isInCube, isVerticalDrag, project2DTo3DPlane, project2DTo3DVertical, project3DTo2D, project3DToCube, select, stopAzimuth
Methods borrowed from class JXG.GeometryElement:
  _set, addChild, addDescendants, addParents, addParentsFromJCFunctions, addRotation, addTicks, addTransform, animate, bounds, clearTrace, cloneToBackground, countChildren, createGradient, createLabel, draggable, formatNumberLocale, fullUpdate, generatePolynomial, getAttribute, getAttributes, getLabelAnchor, getName, getParents, getProperty, getSnapSizes, getTextAnchor, getType, handleSnapToGrid, hasPoint, hide, hideElement, noHighlight, normalize, prepareUpdate, remove, removeAllTicks, removeChild, removeDescendants, removeTicks, resolveShortcuts, setArrow, setAttribute, setDash, setDisplayRendNode, setLabel, setLabelText, setName, setParents, setPosition, setPositionDirectly, setProperty, show, showElement, snapToPoints, update, updateRenderer, updateVisibility, useLocale

Events borrowed from class JXG.GeometryElement:
  attribute, attribute:key, down, drag, keydrag, mousedown, mousedrag, mousemove, mouseout, mouseover, mouseup, move, out, over, pendown, pendrag, penup, touchdown, touchdrag, touchup, up

Class Detail
View3D(lower,dim,cube)
A View3D element provides the container and the methods to create and display 3D elements. It is contained in a JSXGraph board.

Parameters:
{Array_Array_Array} lower,dim,cube
  Here, lower is an array of the form [x, y] and dim is an array of the form [w, h]. The arrays [x, y] and [w, h] define the 2D frame into which the 3D cube is (roughly) projected. If the view's azimuth=0 and elevation=0, the 3D view will cover a rectangle with lower left corner [x,y] and side lengths [w, h] of the board. The array 'cube' is of the form [[x1, x2], [y1, y2], [z1, z2]] which determines the coordinate ranges of the 3D cube.

Throws:
{Exception}
  If the element cannot be constructed with the given parent objects an exception is thrown.

Examples:

     var bound = [-5, 5];
     var view = board.create('view3d',
         [[-6, -3],
          [8, 8],
          [bound, bound, bound]],
         {
             // Main axes
             axesPosition: 'center',
             xAxis: { strokeColor: 'blue', strokeWidth: 3},

             // Planes
             xPlaneRear: { fillColor: 'yellow',  mesh3d: {visible: false}},
             yPlaneFront: { visible: true, fillColor: 'blue'},

             // Axes on planes
             xPlaneRearYAxis: {strokeColor: 'red'},
             xPlaneRearZAxis: {strokeColor: 'red'},

             yPlaneFrontXAxis: {strokeColor: 'blue'},
             yPlaneFrontZAxis: {strokeColor: 'blue'},

             zPlaneFrontXAxis: {visible: false},
             zPlaneFrontYAxis: {visible: false}
         });

Field Detail
{String} axesPosition
Position of the main axes in a View3D element. Possible values are 'center' and 'border'.
Defined in: options3d.js.

Default Value:
  'center'

{Object} verticalDrag
Allow vertical dragging of objects, i.e. in direction of the z-axis. Subobjects are

- enabled: true
- key: 'shift'

Possible values for attribute key: 'shift' or 'ctrl'.
Defined in: options3d.js.

{Line3D} xAxis
Attributes of the 3D x-axis.
Defined in: options3d.js.

{Plane3D} xPlaneFront
Attributes of the 3D plane orthogonal to the x-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} xPlaneFrontYAxis
Attributes of the 3D y-axis on the 3D plane orthogonal to the x-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} xPlaneFrontZAxis
Attributes of the 3D z-axis on the 3D plane orthogonal to the x-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} xPlaneRear
Attributes of the 3D plane orthogonal to the x-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} xPlaneRearYAxis
Attributes of the 3D y-axis on the 3D plane orthogonal to the x-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} xPlaneRearZAxis
Attributes of the 3D z-axis on the 3D plane orthogonal to the x-axis at the "rear" of the cube.
Defined in: options3d.js.

{Line3D} yAxis
Attributes of the 3D y-axis.
Defined in: options3d.js.

{Plane3D} yPlaneFront
Attributes of the 3D plane orthogonal to the y-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} yPlaneFrontXAxis
Attributes of the 3D x-axis on the 3D plane orthogonal to the y-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} yPlaneFrontZAxis
Attributes of the 3D z-axis on the 3D plane orthogonal to the y-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} yPlaneRear
Attributes of the 3D plane orthogonal to the y-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} yPlaneRearXAxis
Attributes of the 3D x-axis on the 3D plane orthogonal to the y-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} yPlaneRearZAxis
Attributes of the 3D z-axis on the 3D plane orthogonal to the y-axis at the "rear" of the cube.
Defined in: options3d.js.

{Line3D} zAxis
Attributes of the 3D z-axis.
Defined in: options3d.js.

{Plane3D} zPlaneFront
Attributes of the 3D plane orthogonal to the z-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} zPlaneFrontXAxis
Attributes of the 3D x-axis on the 3D plane orthogonal to the z-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} zPlaneFrontYAxis
Attributes of the 3D y-axis on the 3D plane orthogonal to the z-axis at the "front" of the cube.
Defined in: options3d.js.

{Plane3D} zPlaneRear
Attributes of the 3D plane orthogonal to the z-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} zPlaneRearXAxis
Attributes of the 3D x-axis on the 3D plane orthogonal to the z-axis at the "rear" of the cube.
Defined in: options3d.js.

{Plane3D} zPlaneRearYAxis
Attributes of the 3D y-axis on the 3D plane orthogonal to the z-axis at the "rear" of the cube.
Defined in: options3d.js.

Documentation generated by JsDoc Toolkit 2.4.0 on Wed Feb 14 2024 15:53:30 GMT+0100 (heure normale d’Europe centrale)