Jump to content
  • Advertisement
Sign in to follow this  

ogre question

This topic is 4726 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

I see renderable class have many interface. and the frustum class derive from renderable class. so frustum is renderable? look some member of frustum
 Frustum () 
virtual  ~Frustum () 
virtual void  setFOVy (const Radian &fovy) 
  Sets the Y-dimension Field Of View (FOV) of the frustum. 

 
virtual const Radian &  getFOVy (void) const  
  Retrieves the frustums Y-dimension Field Of View (FOV). 

 
virtual void  setNearClipDistance (Real nearDist) 
  Sets the position of the near clipping plane. 

 
virtual Real  getNearClipDistance (void) const  
  Sets the position of the near clipping plane. 

 
virtual void  setFarClipDistance (Real farDist) 
  Sets the distance to the far clipping plane. 

 
virtual Real  getFarClipDistance (void) const  
  Retrieves the distance from the frustum to the far clipping plane. 

 
virtual void  setAspectRatio (Real ratio) 
  Sets the aspect ratio for the frustum viewport. 

 
virtual Real  getAspectRatio (void) const  
  Retreives the current aspect ratio. 

 
virtual const Matrix4 &  getProjectionMatrix (void) const  
  Gets the projection matrix for this frustum. 

 
virtual const Matrix4 &  getStandardProjectionMatrix (void) const  
  Gets the 'standard' projection matrix for this frustum, ie the projection matrix which conforms to standard right-handed rules. 

 
virtual const Matrix4 &  getViewMatrix (void) const  
  Gets the view matrix for this frustum. 

 
virtual const Plane &  getFrustumPlane (unsigned short plane) const  
  Retrieves a specified plane of the frustum. 

 
virtual bool  isVisible (const AxisAlignedBox &bound, FrustumPlane *culledBy=0) const  
  Tests whether the given container is visible in the Frustum. 

 
virtual bool  isVisible (const Sphere &bound, FrustumPlane *culledBy=0) const  
  Tests whether the given container is visible in the Frustum. 

 
virtual bool  isVisible (const Vector3 &vert, FrustumPlane *culledBy=0) const  
  Tests whether the given vertex is visible in the Frustum. 

 
const AxisAlignedBox &  getBoundingBox (void) const  
  Overridden from MovableObject. 

 
Real  getBoundingRadius (void) const  
  Overridden from MovableObject. 

 
void  _updateRenderQueue (RenderQueue *queue) 
  Overridden from MovableObject. 

 
const String &  getMovableType (void) const  
  Overridden from MovableObject. 

 
const String &  getName (void) const  
  Overridden from MovableObject. 

 
void  _notifyCurrentCamera (Camera *cam) 
  Overridden from MovableObject. 

 
const MaterialPtr &  getMaterial (void) const  
  Overridden from Renderable. 

 
void  getRenderOperation (RenderOperation &op) 
  Overridden from Renderable. 

 
void  getWorldTransforms (Matrix4 *xform) const  
  Overridden from Renderable. 

 
const Quaternion &  getWorldOrientation (void) const  
  Overridden from Renderable. 

 
const Vector3 &  getWorldPosition (void) const  
  Overridden from Renderable. 

 
Real  getSquaredViewDepth (const Camera *cam) const  
  Overridden from Renderable. 

 
const LightList &  getLights (void) const  
  Overridden from Renderable. 

 
virtual const Vector3 *  getWorldSpaceCorners (void) const  
  Gets the world space corners of the frustum. 

 
virtual void  setProjectionType (ProjectionType pt) 
  Sets the type of projection to use (orthographic or perspective). 

 
virtual ProjectionType  getProjectionType (void) const  
  Retrieves info on the type of projection used (orthographic or perspective). 

 
virtual void  enableReflection (const Plane &p) 
  Modifies this frustum so it always renders from the reflection of itself through the plane specified. 

 
virtual void  enableReflection (const MovablePlane *p) 
  Modifies this frustum so it always renders from the reflection of itself through the plane specified. 

 
virtual void  disableReflection (void) 
  Disables reflection modification previously turned on with enableReflection. 

 
virtual bool  isReflected (void) const  
  Returns whether this frustum is being reflected. 

 
virtual const Matrix4 &  getReflectionMatrix (void) const  
  Returns the reflection matrix of the frustum if appropriate. 

 
virtual const Plane &  getReflectionPlane (void) const  
  Returns the reflection plane of the frustum if appropriate. 

 
virtual bool  projectSphere (const Sphere &sphere, Real *left, Real *top, Real *right, Real *bottom) const  
  Project a sphere onto the near plane and get the bounding rectangle. 

 
virtual void  enableCustomNearClipPlane (const MovablePlane *plane) 
  Links the frustum to a custom near clip plane, which can be used to clip geometry in a custom manner without using user clip planes. 

 
virtual void  enableCustomNearClipPlane (const Plane &plane) 
  Links the frustum to a custom near clip plane, which can be used to clip geometry in a custom manner without using user clip planes. 

 
virtual void  disableCustomNearClipPlane (void) 
  Disables any custom near clip plane. 

 
virtual Node *  getParentNode (void) const  
  Returns the node to which this object is attached. 

 
virtual SceneNode *  getParentSceneNode (void) const  
  Returns the scene node to which this object is attached. 

 
virtual void  _notifyAttached (Node *parent, bool isTagPoint=false) 
  Internal method called to notify the object that it has been attached to a node. 

 
virtual bool  isAttached (void) const  
  Returns true if this object is attached to a SceneNode or TagPoint. 

 
virtual bool  isInScene (void) const  
  Returns true if this object is attached to a SceneNode or TagPoint, and this SceneNode / TagPoint is currently in an active part of the scene graph. 

 
virtual const AxisAlignedBox &  getWorldBoundingBox (bool derive=false) const  
  Retrieves the axis-aligned bounding box for this object in world coordinates. 

 
virtual const Sphere &  getWorldBoundingSphere (bool derive=false) const  
  Retrieves the worldspace bounding sphere for this object. 

 
virtual void  setVisible (bool visible) 
  Tells this object whether to be visible or not, if it has a renderable component. 

 
virtual bool  isVisible (void) const  
  Returns whether or not this object is supposed to be visible or not. 

 
virtual void  setUserObject (UserDefinedObject *obj) 
  Call this to associate your own custom user object instance with this MovableObject. 

 
virtual UserDefinedObject *  getUserObject (void) 
  Retrieves a pointer to a custom application object associated with this movable by an earlier call to setUserObject. 

 
virtual void  setRenderQueueGroup (RenderQueueGroupID queueID) 
  Sets the render queue group this entity will be rendered through. 

 
virtual RenderQueueGroupID  getRenderQueueGroup (void) const  
  Gets the queue group for this entity, see setRenderQueueGroup for full details. 

 
virtual Matrix4  _getParentNodeFullTransform (void) const  
  return the full transformation of the parent sceneNode or the attachingPoint node 

 
virtual void  setQueryFlags (unsigned long flags) 
  Sets the query flags for this object. 

 
virtual void  addQueryFlags (unsigned long flags) 
  As setQueryFlags, except the flags passed as parameters are appended to the existing flags on this object. 

 
virtual void  removeQueryFlags (unsigned long flags) 
  As setQueryFlags, except the flags passed as parameters are removed from the existing flags on this object. 

 
virtual unsigned long  getQueryFlags (void) const  
  Returns the query flags relevant for this object. 

 
EdgeData *  getEdgeList (void) 
  Define a default implementation of method from ShadowCaster which implements no shadows. 

 
ShadowRenderableListIterator  getShadowVolumeRenderableIterator (ShadowTechnique shadowTechnique, const Light *light, HardwareIndexBufferSharedPtr *indexBuffer, bool extrudeVertices, Real extrusionDist, unsigned long flags=0) 
  Define a default implementation of method from ShadowCaster which implements no shadows. 

 
const AxisAlignedBox &  getLightCapBounds (void) const  
  Overridden member from ShadowCaster. 

 
const AxisAlignedBox &  getDarkCapBounds (const Light &light, Real dirLightExtrusionDist) const  
  Overridden member from ShadowCaster. 

 
void  setCastShadows (bool enabled) 
  Sets whether or not this object will cast shadows. 

 
bool  getCastShadows (void) const  
  Returns whether shadow casting is enabled for this object. 

 
Real  getPointExtrusionDistance (const Light *l) const  
  Get the distance to extrude for a point/spot light. 

 
virtual Technique *  getTechnique (void) const  
  Retrieves a pointer to the Material Technique this renderable object uses. 

 
virtual unsigned short  getNumWorldTransforms (void) const  
  Returns the number of world transform matrices this renderable requires. 

 
virtual bool  useIdentityProjection (void) const  
  Returns whether or not to use an 'identity' projection. 

 
virtual bool  useIdentityView (void) const  
  Returns whether or not to use an 'identity' projection. 

 
virtual SceneDetailLevel  getRenderDetail () const  
  Returns the preferred rasterisation mode of this renderable. 

 
virtual bool  getNormaliseNormals (void) const  
  Returns whether or not this Renderable wishes the hardware to normalise normals. 

 
virtual const PlaneList &  getClipPlanes () const  
virtual bool  getCastsShadows (void) const  
  Method which reports whether this renderable would normally cast a shadow. 

 
void  setCustomParameter (size_t index, const Vector4 &value) 
  Sets a custom parameter for this Renderable, which may be used to drive calculations for this specific Renderable, like GPU program parameters. 

 
const Vector4 &  getCustomParameter (size_t index) const  
  Gets the custom value associated with this Renderable at the given index. 

 
virtual void  _updateCustomGpuParameter (const GpuProgramParameters::AutoConstantEntry &constantEntry, GpuProgramParameters *params) const  
  Update a custom GpuProgramParameters constant which is derived from information only this Renderable knows. 
 


and the frustum need the material ?need the isvisible ?need the castShadows?...

Share this post


Link to post
Share on other sites
Advertisement
and the same situation is node class.node class just a position and rotation.

under a node ,there are many entitis.
so it is renderable?

the entity should be renderable other than node.

Share this post


Link to post
Share on other sites
and another question.

I find ogre is somwhat logically chaos .

for example:shadowCaster <- movableObject <- TerrainRenderable.

I cannot find relation between shadowcaster and movableObject.
why shadow is base.and movableObjec is child.
in real world ,moveable base on shadow ? I am confused.

Share this post


Link to post
Share on other sites
Perhaps a better place to get these questions answered would be in the Ogre forums. I doubt if anyone here is going to take the time to defend/explain design decisions made by the Ogre team.

Share this post


Link to post
Share on other sites
Sign in to follow this  

  • Advertisement
×

Important Information

By using GameDev.net, you agree to our community Guidelines, Terms of Use, and Privacy Policy.

Participate in the game development conversation and more when you create an account on GameDev.net!

Sign me up!