96 void SetCamera(
const std::string& cameraName);
167 double maxX,
double maxY,
double maxZ);
198 void Pick(
int x,
int y, std::list<GraphicObj*>* resultListPtr);
223 std::list<Camera*>::const_iterator currentCamera;
225 std::string description;
228 #endif // VART_SCENE_H
SceneNode * GetObject(const std::string &objectName) const
Searches an object by its description.
SceneNode * GetObjectRec(const std::string &objectName) const
Recursively searches an object by its description.
Base class for objects that compose a scene graph.
std::list< SceneNode * > GetObjects()
void SetDescription(const std::string &newDescr)
Sets the scene description.
void ToggleBBoxVisibility()
Toggles the bounding box visibility.
Camera * GetCurrentCamera() const
Returns the current camera in the scene or NULL if no camera exists.
bool visible
Indicates wether the bounding box is visible.
std::list< SceneNode * > GetAllSceneJoints()
Get all scenenodes of type 'joint' in the scene.
const std::string & GetDescription()
Returns the scene description.
Header file for V-ART class "Camera".
bool DrawLightsOGL() const
Set lights using OpenGL commands.
void SetAllCamerasAspectRatio(float newAspectRatio)
Set the aspect ratio of all cameras.
const Camera * GetCamera(const std::string &cameraName)
Finds an camera by its description.
RGBA color representation.
Axis aligned bounding box.
std::list< SceneNode * > GetAllSceneTypeObject(SceneNode::TypeID type)
Get all scenenodes of type 'type' in the scene.
const Camera * UsePreviousCamera()
const Color & GetBackgroundColor()
Returns the background color.
void AddCamera(Camera *newCamera)
Add a camera to the list of cameras.
std::list< Camera * > cameras
void ChangeAllCamerasViewVolume(float horScale, float verScale)
Changes the view volume of all cameras.
Header file for V-ART class "Light".
virtual ~Scene()
Destructor.
void SetBoundingBox(double minX, double minY, double minZ, double maxX, double maxY, double maxZ)
Sets the bounding box.
const Camera * UseNextCamera()
void AddLight(Light *newLight)
Adds a light to the list of lights.
A set of objects, lights and cameras.
std::list< const Light * > lights
Separate lights (not treated as common objects)
const Light * GetLight(const std::string &lightName)
Finds a light by its name.
std::list< Camera * > GetCameras()
Returns a list of cameras.
An scene node that is associated with a shape.
bool ComputeBoundingBox()
Computes the axis aligned bounding box of all objects.
Header file for V-ART class "BoundingBox".
const BoundingBox & GetBoundingBox() const
Returns the scene bounding box. Attention: uses the ComputeBoundingBox method to refresh value of bou...
Header file for V-ART class "Color".
size_t GetNumLights() const
Returns the number of light in the scene.
void AddObject(SceneNode *newObjectPtr)
Add a object to the scene.
void XmlPrintOn(std::ostream &os) const
Outputs XML representation of the scene.
void Pick(int x, int y, std::list< GraphicObj * > *resultListPtr)
Picks objects from viewport coordinates.
virtual bool DrawOGL(Camera *cameraPtr=NULL) const
Sets projection and draws graphics objects using OpenGL commands.
void MakeCameraViewAll()
Fits the whole scene to drawing region.
void SetCamerasAspectRatio(const std::string &cameraDescription, float newAspectRatio)
Set the aspect ratio of camera by its description.
void SetCamera(const std::string &cameraName)
Sets the current camera by its description.
void SetBackgroundColor(Color color)
Sets the background color.
std::list< SceneNode * > objects
void SetBBoxVisibility(bool value)
Sets the bounding box visibility.
std::list< const Light * > GetLights()
void Unreference(const SceneNode *sceneNodePtr)
Removes an object from scene graph.
Represents a light source.