Package com.aspose.threed
Class Camera
- java.lang.Object
-
- com.aspose.threed.A3DObject
-
- com.aspose.threed.SceneObject
-
- com.aspose.threed.Entity
-
- com.aspose.threed.Frustum
-
- com.aspose.threed.Camera
-
- All Implemented Interfaces:
INamedObject,IOrientable
public class Camera extends Frustum implements IOrientable
The camera describes the eye point of the viewer looking at the scene.
-
-
Field Summary
-
Fields inherited from class com.aspose.threed.A3DObject
name, properties
-
-
Constructor Summary
Constructors Constructor Description Camera()Initializes a new instance of theCameraclass.Camera(ProjectionType projectionType)Initializes a new instance of theCameraclass.Camera(java.lang.String name)Initializes a new instance of theCameraclass.Camera(java.lang.String name, ProjectionType projectionType)Initializes a new instance of theCameraclass.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ApertureModegetApertureMode()Gets the camera's aperture modedoublegetAspectRatio()Gets the view plane aspect ratio.doublegetFieldOfView()Gets the camera's field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZONTALorApertureMode.VERTICALdoublegetFieldOfViewX()Gets the camera's horizontal field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERTdoublegetFieldOfViewY()Gets the camera's vertical field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERTdoublegetHeight()Gets the view plane's height measured in inchesVector2getMagnification()Gets the magnification used in orthographic cameraProjectionTypegetProjectionType()Gets the camera's projection type.doublegetWidth()Gets the view plane's width measured in inchesvoidmoveForward(double distance)Move camera forward towards its direction or target.voidsetApertureMode(ApertureMode value)Sets the camera's aperture modevoidsetAspectRatio(double value)Sets the view plane aspect ratio.voidsetFieldOfView(double value)Sets the camera's field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZONTALorApertureMode.VERTICALvoidsetFieldOfViewX(double value)Sets the camera's horizontal field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERTvoidsetFieldOfViewY(double value)Sets the camera's vertical field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERTvoidsetHeight(double value)Sets the view plane's height measured in inchesvoidsetMagnification(Vector2 value)Sets the magnification used in orthographic cameravoidsetProjectionType(ProjectionType value)Sets the camera's projection type.voidsetWidth(double value)Sets the view plane's width measured in inches-
Methods inherited from class com.aspose.threed.Frustum
getAspect, getDirection, getFarPlane, getLookAt, getNearPlane, getOrthoHeight, getRotationMode, getTarget, getUp, setAspect, setDirection, setFarPlane, setLookAt, setNearPlane, setOrthoHeight, setRotationMode, setTarget, setUp
-
Methods inherited from class com.aspose.threed.Entity
getBoundingBox, getEntityRendererKey, getExcluded, getParentNode, getParentNodes, setExcluded, setParentNode
-
Methods inherited from class com.aspose.threed.SceneObject
getScene
-
Methods inherited from class com.aspose.threed.A3DObject
findProperty, getName, getProperties, getProperty, removeProperty, removeProperty, setName, setProperty
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface com.aspose.threed.IOrientable
getDirection, getTarget, setDirection, setTarget
-
-
-
-
Constructor Detail
-
Camera
public Camera()
Initializes a new instance of theCameraclass.
-
Camera
public Camera(ProjectionType projectionType)
Initializes a new instance of theCameraclass.- Parameters:
projectionType- Projection type.
-
Camera
public Camera(java.lang.String name)
Initializes a new instance of theCameraclass.- Parameters:
name- Name.
-
Camera
public Camera(java.lang.String name, ProjectionType projectionType)Initializes a new instance of theCameraclass.- Parameters:
name- Name.projectionType- Projection type.
-
-
Method Detail
-
getApertureMode
public ApertureMode getApertureMode()
Gets the camera's aperture mode
-
setApertureMode
public void setApertureMode(ApertureMode value)
Sets the camera's aperture mode- Parameters:
value- New value
-
getFieldOfView
public double getFieldOfView()
Gets the camera's field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZONTALorApertureMode.VERTICAL
-
setFieldOfView
public void setFieldOfView(double value)
Sets the camera's field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZONTALorApertureMode.VERTICAL- Parameters:
value- New value
-
getFieldOfViewX
public double getFieldOfViewX()
Gets the camera's horizontal field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERT
-
setFieldOfViewX
public void setFieldOfViewX(double value)
Sets the camera's horizontal field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERT- Parameters:
value- New value
-
getFieldOfViewY
public double getFieldOfViewY()
Gets the camera's vertical field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERT
-
setFieldOfViewY
public void setFieldOfViewY(double value)
Sets the camera's vertical field of view in degrees, this property is used only when ApertureMode isApertureMode.HORIZ_AND_VERT- Parameters:
value- New value
-
getWidth
public double getWidth()
Gets the view plane's width measured in inches
-
setWidth
public void setWidth(double value)
Sets the view plane's width measured in inches- Parameters:
value- New value
-
getHeight
public double getHeight()
Gets the view plane's height measured in inches
-
setHeight
public void setHeight(double value)
Sets the view plane's height measured in inches- Parameters:
value- New value
-
getAspectRatio
public double getAspectRatio()
Gets the view plane aspect ratio.
-
setAspectRatio
public void setAspectRatio(double value)
Sets the view plane aspect ratio.- Parameters:
value- New value
-
getMagnification
public Vector2 getMagnification()
Gets the magnification used in orthographic camera
-
setMagnification
public void setMagnification(Vector2 value)
Sets the magnification used in orthographic camera- Parameters:
value- New value
-
getProjectionType
public ProjectionType getProjectionType()
Gets the camera's projection type. By default the perspective projection is used.
-
setProjectionType
public void setProjectionType(ProjectionType value)
Sets the camera's projection type. By default the perspective projection is used.- Parameters:
value- New value
-
moveForward
public void moveForward(double distance)
Move camera forward towards its direction or target.- Parameters:
distance- How long to move forward
-
-