|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectraytracer.Camera
public class Camera
Constructor Summary | |
---|---|
Camera(Point3D eyepoint_,
Vector3D direction_,
Vector3D up_,
double fov_)
constructor |
Method Summary | |
---|---|
Ray |
generateRay(double i,
double j)
generates a ray from the eyepoint through the pixel coordinates i,j |
int |
getDimX()
|
int |
getDimY()
|
Point3D |
getEyePoint()
|
void |
move(Vector3D v)
translate the object with vector v |
void |
rotate(Vector3D v,
double alpha)
rotate around vector v with angle alpha |
void |
rotateAroundX(double alpha)
rotate around the x axis with angle alpha |
void |
rotateAroundY(double beta)
rotate around the y axis with angle beta |
void |
rotateAroundZ(double gamma)
rotate around the z axis with angle gamma |
void |
setResolution(int dimx_,
int dimy_)
|
void |
transform(TransformationMatrix4x4 tm)
transforms the camera |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public Camera(Point3D eyepoint_, Vector3D direction_, Vector3D up_, double fov_)
eyepoint_
- the point, the camera is locateddirection_
- the camera points into that directionup_
- the vector pointing upwardsfov_
- field of viewMethod Detail |
---|
public void setResolution(int dimx_, int dimy_)
dimx_
- the x dimensiondimy_
- the y dimensionpublic int getDimX()
public int getDimY()
public void transform(TransformationMatrix4x4 tm)
tm
- transformation matrixpublic Ray generateRay(double i, double j)
i
- the horizontal pixel coordinatej
- the vertical pixel coordinate
public Point3D getEyePoint()
public void move(Vector3D v)
v
- translation vectorpublic void rotate(Vector3D v, double alpha)
v
- vectoralpha
- anglepublic void rotateAroundX(double alpha)
alpha
- anglepublic void rotateAroundY(double beta)
beta
- anglepublic void rotateAroundZ(double gamma)
gamma
- angle
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |