VisimBox 1.0 VisimBox 3d simulation and visualisation ToolBox

- Main Page
- Packages
- Classes
- Files

- Class List
- Class Index
- Class Hierarchy
- Class Members

Public Member Functions | Protected Member Functions | Protected Attributes | Properties
VisimBox.Scene.RenderableNode Class Reference

Renderable node implementing IRenderable. More...

Inheritance diagram for VisimBox.Scene.RenderableNode:

List of all members.

## Public Member Functions
| RenderableNode ()
| Constructs parentless renderable node.
| RenderableNode (Node parent)
| Constructs node with specified parent (and automatically saves itselfs to parents children)
| RenderableNode (System.Xml.XmlReader reader)
| XML reader constructor.
virtual void | OnRender (RendererEventArgs args)
| Called by the renderer when rendering hiearchy of elements. Object must either perform complete render (set transformation, material and use direct rendering calls) or feed renderbuffer of the context with correct data.
virtual void | CreateRenderBuffer ()
| Creates render buffer item.
virtual void | UpdateRenderBuffer (RendererEventArgs args)
| Updates render buffer with current transformation and other data.
abstract void | RenderGeometry (RendererEventArgs args)
| Feed geometry to the renderer (all other settings should be already set)
virtual IGeometry | GetBoundingObject ()
| Returns bounding object of the renderable item (for lights etc). Should be simplest possible (box)
virtual Vector3 | GetCenter ()
| Fallback function if GetBoundingObject returns null.
override bool | ReadInternalData (System.Xml.XmlReader reader)
| Reads one item of internal data. Should return true if recognized value (for overloading)
override void | WriteInternalData (System.Xml.XmlWriter writer)
| Write internal data of the node to XML, without subnodes (called from WriteXML)
## Protected Member Functions
override bool | PickNode (ref NodeIntersectionInfo intersinfo)
| Checks node and it's hierarchy for intersection with ray. If node contains some closer object then already found, it returns true and modifies structure.
virtual bool | PickNodeInternal (ref NodeIntersectionInfo intersinfo)
| Internal picking, expects ray already transformed!
override void | CopyData (Node targetNode)
## Protected Attributes
RenderBufferItem | BufferedItem
| Buffered item.
LineList | BoundingObjectWireFrame
## Properties
IGeometry | BoundingObject`[get, set]`
| Bounding object of the geometry.
bool | RenderBoundObject`[get, set]`
| If set to true, Bounding object will be rendered around as wireframe (with zbuffer off)
override RenderFlags | DefaultRenderFlags`[get]`
| Default render flags for the node (node will be rendered only if flags are correct)

## Detailed Description

Renderable node implementing IRenderable.

## Constructor & Destructor Documentation

VisimBox.Scene.RenderableNode.RenderableNode | ( |  | ) |

Constructs parentless renderable node.

VisimBox.Scene.RenderableNode.RenderableNode | ( | Node | parent | ) |

Constructs node with specified parent (and automatically saves itselfs to parents children)

Parameters:

  parent | Parent node

VisimBox.Scene.RenderableNode.RenderableNode | ( | System.Xml.XmlReader | reader | ) |

XML reader constructor.

Parameters:

  reader | XML reader

## Member Function Documentation

override void VisimBox.Scene.RenderableNode.CopyData | ( | Node | targetNode | ) | `[protected, virtual]`

Reimplemented from VisimBox.Scene.Node.

Reimplemented in VisimBox.Physics.PhysNode, VisimBox.Physics.RigidBody, VisimBox.Physics.StaticCollision, VisimBox.Scene.CameraNode, VisimBox.Scene.GeometryNode, VisimBox.Scene.ImportedNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

virtual void VisimBox.Scene.RenderableNode.CreateRenderBuffer | ( |  | ) | `[virtual]`

Creates render buffer item.

Reimplemented in VisimBox.Scene.CameraNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

virtual IGeometry VisimBox.Scene.RenderableNode.GetBoundingObject | ( |  | ) | `[virtual]`

Returns bounding object of the renderable item (for lights etc). Should be simplest possible (box)

Returns:
  Bounding object or null if not using one

Implements VisimBox.Renderer.RenderObjects.IRenderable.

virtual Vector3 VisimBox.Scene.RenderableNode.GetCenter | ( |  | ) | `[virtual]`

Fallback function if GetBoundingObject returns null.

Returns:
  Center of the object

Implements VisimBox.Renderer.RenderObjects.IRenderable.

virtual void VisimBox.Scene.RenderableNode.OnRender | ( | RendererEventArgs | args | ) | `[virtual]`

Called by the renderer when rendering hiearchy of elements. Object must either perform complete render (set transformation, material and use direct rendering calls) or feed renderbuffer of the context with correct data.

Parameters:

  args | Rendering events - pointer to rendering context and renderer

Direct rendering should be done only in special cases in this call as it removes any rendering optimalizations performed on the render buffer. This is important especially for any objects using alpha transparency, which could create visual artefacts unless rendered in sorter back to front order.

Implements VisimBox.Renderer.RenderObjects.IRenderable.

Reimplemented in VisimBox.Scene.CameraNode.

override bool VisimBox.Scene.RenderableNode.PickNode | ( | ref NodeIntersectionInfo | intersinfo | ) | `[protected, virtual]`

Checks node and it's hierarchy for intersection with ray. If node contains some closer object then already found, it returns true and modifies structure.

Parameters:

  intersinfo | Intersection info

Returns:
  True if ray hits something closer

Reimplemented from VisimBox.Scene.Node.

virtual bool VisimBox.Scene.RenderableNode.PickNodeInternal | ( | ref NodeIntersectionInfo | intersinfo | ) | `[protected, virtual]`

Internal picking, expects ray already transformed!

Parameters:

  intersinfo |

Returns:

Reimplemented in VisimBox.Scene.CameraNode, and VisimBox.Scene.GeometryNode.

override bool VisimBox.Scene.RenderableNode.ReadInternalData | ( | System.Xml.XmlReader | reader | ) | `[virtual]`

Reads one item of internal data. Should return true if recognized value (for overloading)

Parameters:

  reader | Reader to read from

Returns:
  True if value was handled, false if not

Reimplemented from VisimBox.Scene.Node.

Reimplemented in VisimBox.Physics.RigidBody, VisimBox.Scene.CameraNode, VisimBox.Scene.GeometryNode, VisimBox.Scene.ImportedNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

abstract void VisimBox.Scene.RenderableNode.RenderGeometry | ( | RendererEventArgs | args | ) | `[pure virtual]`

Feed geometry to the renderer (all other settings should be already set)

Parameters:

  args | Rendering events - pointer to rendering context and renderer

Used when rendering from the renderbuffer

Implements VisimBox.Renderer.RenderObjects.IRenderable.

Implemented in VisimBox.Scene.CameraNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

virtual void VisimBox.Scene.RenderableNode.UpdateRenderBuffer | ( | RendererEventArgs | args | ) | `[virtual]`

Updates render buffer with current transformation and other data.

Reimplemented in VisimBox.Scene.GeometryNode.

override void VisimBox.Scene.RenderableNode.WriteInternalData | ( | System.Xml.XmlWriter | writer | ) | `[virtual]`

Write internal data of the node to XML, without subnodes (called from WriteXML)

Parameters:

  writer | XML Writer

Reimplemented from VisimBox.Scene.Node.

Reimplemented in VisimBox.Physics.RigidBody, VisimBox.Scene.CameraNode, VisimBox.Scene.GeometryNode, VisimBox.Scene.ImportedNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

## Member Data Documentation

LineList VisimBox.Scene.RenderableNode.BoundingObjectWireFrame`[protected]`

RenderBufferItem VisimBox.Scene.RenderableNode.BufferedItem`[protected]`

Buffered item.

## Property Documentation

IGeometry VisimBox.Scene.RenderableNode.BoundingObject`[get, set]`

Bounding object of the geometry.

override RenderFlags VisimBox.Scene.RenderableNode.DefaultRenderFlags`[get]`

Default render flags for the node (node will be rendered only if flags are correct)

Reimplemented from VisimBox.Scene.Node.

Reimplemented in VisimBox.Physics.PhysNode, VisimBox.Physics.RigidBody, VisimBox.Physics.StaticCollision, VisimBox.Scene.CameraNode, VisimBox.Scene.GeometryNode, VisimBox.Scene.ImportedNode, VisimBox.Scene.LightNode, and VisimBox.Scene.NodeMesh.

bool VisimBox.Scene.RenderableNode.RenderBoundObject`[get, set]`

If set to true, Bounding object will be rendered around as wireframe (with zbuffer off)

The documentation for this class was generated from the following file:

- RenderableNode.cs

All Classes Namespaces Files Functions Variables Enumerations Properties Events