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 | Events
VisimBox.Renderer.RenderContext Class Reference

Rendering context for renderer - either standalone renderer window or embedded renderingguicontrol. More...

Inheritance diagram for VisimBox.Renderer.RenderContext:

List of all members.

## Public Member Functions
| RenderContext (IRenderer ren)
| RenderContext (IRenderer ren, RenderContextSettings rs)
ICamera | CreateDefaultCamera ()
| Creates default camera.
virtual void | Dispose ()
virtual System.Drawing.Bitmap | GetScreenShot ()
| Grabs actual content of the render context and converts it to bitmap.
System.Drawing.Imaging.ImageFormat | GetFormatType (string extension)
string | GetExtension (string filename)
virtual void | SaveScreenShot (string filename=null, string extension=null)
| Saves screenshot with specified name, uses GetScreenShot()
virtual void | StartFrame ()
| Starts rendering frame.
virtual void | EndFrame ()
| Finished rendering frame and shows it.
virtual void | RenderFrame ()
| Renders frame in standard way (StartFrame and then EndFrame with associated callbacks)
abstract void | DrawSkybox (ref SkyboxData skybox)
| Draws simple skybox.
void | RenderNodes (VisimBox.Scene.Node scene)
| Renders spefified node hierarchy.
virtual void | AddRenderItem (RenderBufferItem item)
| Adds render item to the renderer queue.
virtual void | ClearRenderingQueue ()
| Clears rendering queue.
virtual void | StartRenderingQueue ()
| Starts rendering queue (allows adding new items to render queue. If renderer uses multithreading, queue will be rendered as soon as some queue item will be added, except alpha values.
virtual void | FinishRenderQueue ()
| Finishes rendering queue (renders all remaining items in the queue including sorted alpha items)
void | SetColor (ColorByte col)
| Sets main rendering color (especially for 2d rendering)
abstract void | SetColor (ref ColorByte col)
| Sets main rendering color (especially for 2d rendering)
void | SetColor (System.Drawing.Color col)
| Sets main rendering color (especially for 2d rendering)
abstract void | SetTransformation (ref Matrix4 mat)
| Sets model transformation (without camera transformation)
virtual void | SetTransformation (Matrix4 mat)
| Sets model transformation (without camera transformation)
abstract void | DrawPoint3D (IVertex point)
| Draws one vertex as a point.
virtual void | DrawPoint3D (ref Vector3 vec)
| Draws one vector as a point.
virtual void | DrawPoint3D (Vector3 vec)
| Draws one vector as a point.
abstract void | DrawLine3D (IVertex first, IVertex second)
| Draws single line from first to second.
virtual void | DrawLine3D (ref Vector3 first, ref Vector3 second)
| Draws single line from first to second.
virtual void | DrawLine3D (Vector3 first, Vector3 second)
| Draws single line from first to second.
abstract void | DrawTriangle3D (IVertex first, IVertex second, IVertex third)
| Draws single triangle specified by three vertices.
virtual void | DrawTriangle3D (ref Vector3 first, ref Vector3 second, ref Vector3 third)
| Draws single triangle specified by three vertices.
virtual void | DrawTriangle3D (Vector3 first, Vector3 second, Vector3 third)
| Draws single triangle specified by three vertices.
abstract void | DrawQuad3D (IVertex first, IVertex second, IVertex third, IVertex fourth)
| Draws single quad specified by four vertices.
virtual void | DrawQuad3D (ref Vector3 first, ref Vector3 second, ref Vector3 third, ref Vector3 fourth)
| Draws single quad specified by four vertices.
virtual void | DrawQuad3D (Vector3 first, Vector3 second, Vector3 third, Vector3 fourth)
| Draws single quad specified by four vertices.
abstract void | RenderPoints (IVertexArray varray, int startindex=0, int count=0)
| Renders points from vertex array.
abstract void | RenderLines (IVertexArray varray, int startindex=0, int count=0)
| Renders lines from vertex array.
abstract void | RenderLine (IVertexArray varray, int startindex=0, int count=0)
| Renders polyline from vertex array.
abstract void | RenderTriangles (IVertexArray varray, int startindex=0, int count=0)
| Renders triangles from vertex array.
abstract void | RenderQuads (IVertexArray varray, int startindex=0, int count=0)
| Renders quads from vertex array.
abstract void | RenderPoly (IVertexArray varray, int startindex=0, int count=0)
| Renders polygon from vertex array.
abstract void | RenderIndexedMesh (IVertexArray varray, int[] indices, PrimitiveTypes type, int startindex=0, int count=0)
| Renders indexed mesh from vertex array.
virtual void | RenderGeometry (Point3DList geo)
| Renders geometry object - List of points.
virtual void | RenderGeometry (LineList geo)
| Renders geometry object - List of lines.
virtual void | RenderGeometry (PolyLine geo)
| Renders geometry object - PolyLine.
virtual void | RenderGeometry (TriangleList geo)
| Renders geometry object - List of triangles.
virtual void | RenderGeometry (QuadList geo)
| Renders geometry object - List of quads.
virtual void | RenderGeometry (IndexedGeo geo, int subset=-1)
| Renders geometry object - generic indexed geometry.
virtual void | RenderGeometry (IndexedMesh geo, int subset=-1)
| Renders geometry object - Indexed triangle mesh.
virtual void | RenderGeometry (IndexedQuads geo, int subset=-1)
| Renders geometry object - Indexed quad mesh.
virtual void | RenderGeometry (IndexedLines geo, int subset=-1)
| Renders geometry object - Indexed list of points.
virtual void | RenderGeometry (IGeometry geometry)
| Renders generic geometry object - uses conversion routines from the object, will be very slow if overused!
abstract void | RenderVertexBuffer (IVertexBuffer vertices, PrimitiveTypes type, int startindex=0, int count=0)
| Render vertex buffer as specified type of primitive (can't be used for indexed meshes!)
abstract void | RenderIndexedMesh (IVertexBuffer vertices, int[] indices, PrimitiveTypes type, int startindex=0, int count=0)
| Renders indexed mesh from vertex and index buffer.
abstract void | RenderIndexedMesh (IVertexBuffer vertices, IIndexBuffer indices, PrimitiveTypes type, int startindex=0, int count=0)
| Renders indexed mesh from vertex and index buffer.
abstract void | Start2DRender ()
| Sets renderer to 2d context, all 2d rendering calls should be done after this call!
abstract void | Stop2DRender ()
| Returns renderer to previous (3d) rendering state from the 2d renderer.
abstract void | DrawPoint (int x, int y)
| Draw point in screen coordinates with currently selected color.
void | DrawPoint (int x, int y, ColorByte Color)
| Draw point in screen coordinates.
void | DrawPoint (int x, int y, System.Drawing.Color Color)
| Draw point in screen coordinates.
abstract void | DrawLine (int x1, int y1, int x2, int y2)
| Draw line in screen coordinates with currently selected color.
void | DrawLine (int x1, int y1, int x2, int y2, ColorByte Color)
| Draw line in screen coordinates.
void | DrawLine (int x1, int y1, int x2, int y2, System.Drawing.Color Color)
| Draw line in screen coordinates.
abstract void | DrawRectangle (int x1, int y1, int width, int height)
| Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height, using current color.
void | DrawRectangle (int x1, int y1, int width, int height, ColorByte color)
| Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height.
void | DrawRectangle (int x1, int y1, int width, int height, System.Drawing.Color color)
| Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height.
void | DrawRectangle (System.Drawing.Rectangle rect)
| Draws outlined 2d rectangle with current color.
void | DrawRectangle (System.Drawing.Rectangle rect, ColorByte Color)
| Draws outlined 2d rectangle.
void | DrawRectangle (System.Drawing.Rectangle rect, System.Drawing.Color Color)
| Draws outlined 2d rectangle.
abstract void | DrawFilledRectangle (int x1, int y1, int width, int height)
| Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height, using current color.
void | DrawFilledRectangle (int x1, int y1, int width, int height, ColorByte color)
| Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height.
void | DrawFilledRectangle (int x1, int y1, int width, int height, System.Drawing.Color color)
| Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height.
void | DrawFilledRectangle (System.Drawing.Rectangle rect)
| Draws filled 2d rectangle with current color.
void | DrawFilledRectangle (System.Drawing.Rectangle rect, ColorByte Color)
| Draws filled 2d rectangle.
void | DrawFilledRectangle (System.Drawing.Rectangle rect, System.Drawing.Color Color)
| Draws filled 2d rectangle.
void | ChangeFont (string fontname)
| Changes current font of the context to specified font (from font manager)
void | ChangeFont (Render2D.Font font)
| Changes current font of the context to the font.
void | DrawText (int x, int y, string text)
| Simple text drawing on selected coordinate. Uses currently selected font.
void | DrawText (int x, int y, string text, ColorByte color)
| Simple text drawing on selected coordinate. Uses currently selected font.
void | DrawText (int x, int y, string text, System.Drawing.Color color)
| Simple text drawing on selected coordinate. Uses currently selected font.
void | DrawText (int x, int y, int maxwidth, int maxheight, string text)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
void | DrawText (int x, int y, int maxwidth, int maxheight, string text, ColorByte color)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
void | DrawText (int x, int y, int maxwidth, int maxheight, string text, System.Drawing.Color color)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
void | DrawText (System.Drawing.Rectangle rect, string text)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
void | DrawText (System.Drawing.Rectangle rect, string text, ColorByte color)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
void | DrawText (System.Drawing.Rectangle rect, string text, System.Drawing.Color color)
| Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.
abstract void | DrawImage (int x, int y)
| Draws currently selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.
void | DrawImage (int x, int y, string texture)
| Draws selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.
void | DrawImage (int x, int y, Texture tex)
| Draws selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.
abstract void | DrawImage (int x, int y, int width, int height)
| Draws currently selected texture scaled to specified width and height.
void | DrawImage (int x, int y, int width, int height, string texture)
| Draws selected texture scaled to specified width and height.
void | DrawImage (int x, int y, int width, int height, Texture tex)
| Draws selected texture scaled to specified width and height.
void | DrawImage (System.Drawing.Rectangle rect)
| Draws currently selected texture scaled to specified rectangle.
void | DrawImage (System.Drawing.Rectangle rect, string texture)
| Draws currently selected texture scaled to specified rectangle.
void | DrawImage (System.Drawing.Rectangle rect, Texture tex)
| Draws currently selected texture scaled to specified rectangle.
void | DrawImagePart (int x, int y, int sourcex, int sourcey, int sourcewidth, int sourceheight)
| Draws unscaled part of the currently selected texture on the screen.
void | DrawImagePart (int x, int y, int sourcex, int sourcey, int sourcewidth, int sourceheight, string texture)
| Draws unscaled part of the selected texture on the screen.
void | DrawImagePart (int x, int y, int sourcex, int sourcey, int sourcewidth, int sourceheight, Texture tex)
| Draws unscaled part of the selected texture on the screen.
void | DrawImagePart (int x, int y, System.Drawing.Rectangle source)
| Draws unscaled part of the currently selected texture on the screen.
void | DrawImagePart (int x, int y, System.Drawing.Rectangle source, string texture)
| Draws unscaled part of the selected texture on the screen.
void | DrawImagePart (int x, int y, System.Drawing.Rectangle source, Texture tex)
| Draws unscaled part of the selected texture on the screen.
abstract void | DrawImagePart (int x, int y, int width, int height, int sourcex, int sourcey, int sourcewidth, int sourceheight)
| Draws scaled part of the currently selected texture on the screen.
void | DrawImagePart (int x, int y, int width, int height, int sourcex, int sourcey, int sourcewidth, int sourceheight, string texture)
| Draws scaled part of the selected texture on the screen.
void | DrawImagePart (int x, int y, int width, int height, int sourcex, int sourcey, int sourcewidth, int sourceheight, Texture tex)
| Draws scaled part of the selected texture on the screen.
void | DrawImagePart (System.Drawing.Rectangle target, System.Drawing.Rectangle source)
| Draws scaled part of the currently selected texture on the screen.
void | DrawImagePart (System.Drawing.Rectangle target, System.Drawing.Rectangle source, string texture)
| Draws scaled part of the selected texture on the screen.
void | DrawImagePart (System.Drawing.Rectangle target, System.Drawing.Rectangle source, Texture tex)
| Draws scaled part of the selected texture on the screen.
abstract void | DrawSprite (int x, int y, ref Render2D.SpriteInfo sprite)
| Draws sprite with currently selected texture.
void | DrawSprite (int x, int y, Render2D.SpriteInfo sprite)
| Draws sprite with currently selected texture.
void | DrawSprite (int x, int y, Render2D.SpriteInfo sprite, string texture)
| Draws sprite with currently selected texture.
void | DrawSprite (int x, int y, Render2D.SpriteInfo sprite, Texture tex)
| Draws sprite with currently selected texture.
abstract void | DrawSprites (int x, int y, Render2D.SpriteInfo[] sprites)
| Draws array of sprites with currently selected texture.
void | DrawSprites (int x, int y, Render2D.SpriteInfo[] sprites, string texture)
| Draws array of sprites with currently selected texture.
void | DrawSprites (int x, int y, Render2D.SpriteInfo[] sprites, Texture tex)
| Draws array of sprites with currently selected texture.
void | DrawSprites (int x, int y, Render2D.SpriteBatch sprites)
| Draws batch of sprites.
void | DrawSprites (int x, int y, ref Render2D.SpriteBatch sprites)
| Draws batch of sprites.
abstract void | Draw2DArray (int x, int y, Render2D.Vertex2D[] vertices)
| Draws array of 2D vertices.
## Protected Member Functions
virtual void | ChangeSettings (ref RenderContextSettings setts)
## Protected Attributes
RenderContextSettings | settings
| settings for the context
IRenderer | renderer
| Renderer associated to the render context.
Viewport | mainViewport
| main "fullscreen" viewport encompassing the whole area
Dictionary< string, Viewport > | viewports = new Dictionary<string,Viewport>()
| List containing all other viewports.
int | fps
System.Diagnostics.Stopwatch | RenderTimer
Render2D.Font | _CurrentFont
Texture | _CurrentTexture
bool | _showFPS = false
bool | _zBuffer = true
RenderQueue | Queue
## Properties
IRenderer | Renderer`[get]`
| Main renderer for this context.
ICamera | MainCamera`[get, set]`
| Returns pointer to the main camera (camera in main viewport)
int | CurrentFPS`[get]`
| Returns current rendering frames per second for this context.
bool | ShowFPS`[get, set]`
| Show fps on screen?
virtual Texture | CurrentTexture`[get, set]`
| Currently selected texture.
RenderContextSettings | Settings`[get, set]`
| Settings of the render context.
Vector3 | DebugPoint`[get, set]`
Vector3 | DebugLine1`[get, set]`
Vector3 | DebugLine2`[get, set]`
abstract bool | Fog`[get, set]`
| Enables / disables fog drawing.
abstract ColorByte | FogColor`[get, set]`
| Color of the fog.
abstract float | FogDensity`[get, set]`
| Density of the fog.
virtual bool | ZBufferUsing`[get, set]`
| Use to directly change using of the zbuffer.
## Events
RendererEvent | FrameStart
| Called on the framestart before any rendering starts.
RendererEvent | FrameEnd
| Called on the end of the frame before showing results of the rendering.

## Detailed Description

Rendering context for renderer - either standalone renderer window or embedded renderingguicontrol.

## Constructor & Destructor Documentation

VisimBox.Renderer.RenderContext.RenderContext | ( | IRenderer | ren | ) |

VisimBox.Renderer.RenderContext.RenderContext | ( | IRenderer | ren,
|  | RenderContextSettings | rs
| ) |  |

## Member Function Documentation

virtual void VisimBox.Renderer.RenderContext.AddRenderItem | ( | RenderBufferItem | item | ) | `[virtual]`

Adds render item to the renderer queue.

Parameters:

  item | Render buffer item

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.ChangeFont | ( | string | fontname | ) |

Changes current font of the context to specified font (from font manager)

Parameters:

  fontname | Name of the font in the font manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.ChangeFont | ( | Render2D.Font | font | ) |

Changes current font of the context to the font.

Parameters:

  font | Rendering font

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.ChangeSettings | ( | ref RenderContextSettings | setts | ) | `[protected, virtual]`

virtual void VisimBox.Renderer.RenderContext.ClearRenderingQueue | ( |  | ) | `[virtual]`

Clears rendering queue.

Implements VisimBox.Renderer.IRenderContext.

ICamera VisimBox.Renderer.RenderContext.CreateDefaultCamera | ( |  | ) |

Creates default camera.

Returns:
  New default camera

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.Dispose | ( |  | ) | `[virtual]`

abstract void VisimBox.Renderer.RenderContext.Draw2DArray | ( | int | x,
|  | int | y,
|  | Render2D.Vertex2D[] | vertices
| ) |  | `[pure virtual]`

Draws array of 2D vertices.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  vertices |

void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height,
|  | ColorByte | color
| ) |  |

Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height
  color | Color of the outline

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height,
|  | System.Drawing.Color | color
| ) |  |

Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height
  color | Color of the outline

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | System.Drawing.Rectangle | rect | ) |

Draws filled 2d rectangle with current color.

Parameters:

  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height
| ) |  | `[pure virtual]`

Draws filled 2d rectangle with x1 and y1 coordinates of top left and width and height, using current color.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | System.Drawing.Rectangle | rect,
|  | ColorByte | Color
| ) |  |

Draws filled 2d rectangle.

Parameters:

  Color | Color of the outline
  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawFilledRectangle | ( | System.Drawing.Rectangle | rect,
|  | System.Drawing.Color | Color
| ) |  |

Draws filled 2d rectangle.

Parameters:

  Color | Color of the outline
  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y
| ) |  | `[pure virtual]`

Draws currently selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y,
|  | string | texture
| ) |  |

Draws selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y,
|  | Texture | tex
| ) |  |

Draws selected texture in real size to specified place on screen. NOTE - uses current color, don't forget to set it to white unless you want colored image.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height
| ) |  | `[pure virtual]`

Draws currently selected texture scaled to specified width and height.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height,
|  | string | texture
| ) |  |

Draws selected texture scaled to specified width and height.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height,
|  | Texture | tex
| ) |  |

Draws selected texture scaled to specified width and height.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | System.Drawing.Rectangle | rect | ) |

Draws currently selected texture scaled to specified rectangle.

Parameters:

  rect | Rectangle on screen

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | System.Drawing.Rectangle | rect,
|  | string | texture
| ) |  |

Draws currently selected texture scaled to specified rectangle.

Parameters:

  rect | Rectangle on screen
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImage | ( | System.Drawing.Rectangle | rect,
|  | Texture | tex
| ) |  |

Draws currently selected texture scaled to specified rectangle.

Parameters:

  rect | Rectangle on screen
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | System.Drawing.Rectangle | target,
|  | System.Drawing.Rectangle | source
| ) |  |

Draws scaled part of the currently selected texture on the screen.

Parameters:

  target | Target rectangle on the screen
  source | Source rectangle in the texture

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight
| ) |  |

Draws unscaled part of the currently selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight,
|  | string | texture
| ) |  |

Draws unscaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight,
|  | Texture | tex
| ) |  |

Draws unscaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | System.Drawing.Rectangle | source
| ) |  |

Draws unscaled part of the currently selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  source | Source rectangle in the texture

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | System.Drawing.Rectangle | source,
|  | string | texture
| ) |  |

Draws unscaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  source | Source rectangle in the texture
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | System.Drawing.Rectangle | source,
|  | Texture | tex
| ) |  |

Draws unscaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  source | Source rectangle in the texture
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight
| ) |  | `[pure virtual]`

Draws scaled part of the currently selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight,
|  | string | texture
| ) |  |

Draws scaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | int | x,
|  | int | y,
|  | int | width,
|  | int | height,
|  | int | sourcex,
|  | int | sourcey,
|  | int | sourcewidth,
|  | int | sourceheight,
|  | Texture | tex
| ) |  |

Draws scaled part of the selected texture on the screen.

Parameters:

  x | X coordinate of top left corner
  y | Y coordinate of top left corner
  width | Width of the drawn image
  height | Height of the drawn image
  sourcex | X coordinate of top left corner inside the texture
  sourcey | Y coordinate of top left corner inside the texture
  sourcewidth | Width of the texture part
  sourceheight | Height of the texture part
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | System.Drawing.Rectangle | target,
|  | System.Drawing.Rectangle | source,
|  | string | texture
| ) |  |

Draws scaled part of the selected texture on the screen.

Parameters:

  target | Target rectangle on the screen
  source | Source rectangle in the texture
  texture | Name of the texture in the texture manager

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawImagePart | ( | System.Drawing.Rectangle | target,
|  | System.Drawing.Rectangle | source,
|  | Texture | tex
| ) |  |

Draws scaled part of the selected texture on the screen.

Parameters:

  target | Target rectangle on the screen
  source | Source rectangle in the texture
  tex | Texture to be set

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawLine | ( | int | x1,
|  | int | y1,
|  | int | x2,
|  | int | y2
| ) |  | `[pure virtual]`

Draw line in screen coordinates with currently selected color.

Parameters:

  x1 | x of the start of the line
  y1 | y of the start of the line
  x2 | X of the end of the line
  y2 | y of the end of the line

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawLine | ( | int | x1,
|  | int | y1,
|  | int | x2,
|  | int | y2,
|  | ColorByte | Color
| ) |  |

Draw line in screen coordinates.

Parameters:

  x1 | x of the start of the line
  y1 | y of the start of the line
  x2 | X of the end of the line
  y2 | y of the end of the line
  Color | Color of the line

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawLine | ( | int | x1,
|  | int | y1,
|  | int | x2,
|  | int | y2,
|  | System.Drawing.Color | Color
| ) |  |

Draw line in screen coordinates.

Parameters:

  x1 | x of the start of the line
  y1 | y of the start of the line
  x2 | X of the end of the line
  y2 | y of the end of the line
  Color | Color of the line

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawLine3D | ( | IVertex | first,
|  | IVertex | second
| ) |  | `[pure virtual]`

Draws single line from first to second.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawLine3D | ( | ref Vector3 | first,
|  | ref Vector3 | second
| ) |  | `[virtual]`

Draws single line from first to second.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawLine3D | ( | Vector3 | first,
|  | Vector3 | second
| ) |  | `[virtual]`

Draws single line from first to second.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawPoint | ( | int | x,
|  | int | y,
|  | ColorByte | Color
| ) |  |

Draw point in screen coordinates.

Parameters:

  x | X position
  y | Y position
  Color | Color of the pixel

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawPoint | ( | int | x,
|  | int | y
| ) |  | `[pure virtual]`

Draw point in screen coordinates with currently selected color.

Parameters:

  x | X position
  y | Y position

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawPoint | ( | int | x,
|  | int | y,
|  | System.Drawing.Color | Color
| ) |  |

Draw point in screen coordinates.

Parameters:

  x | X position
  y | Y position
  Color | Color of the pixel

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawPoint3D | ( | IVertex | point | ) | `[pure virtual]`

Draws one vertex as a point.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawPoint3D | ( | ref Vector3 | vec | ) | `[virtual]`

Draws one vector as a point.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawPoint3D | ( | Vector3 | vec | ) | `[virtual]`

Draws one vector as a point.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawQuad3D | ( | Vector3 | first,
|  | Vector3 | second,
|  | Vector3 | third,
|  | Vector3 | fourth
| ) |  | `[virtual]`

Draws single quad specified by four vertices.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawQuad3D | ( | ref Vector3 | first,
|  | ref Vector3 | second,
|  | ref Vector3 | third,
|  | ref Vector3 | fourth
| ) |  | `[virtual]`

Draws single quad specified by four vertices.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawQuad3D | ( | IVertex | first,
|  | IVertex | second,
|  | IVertex | third,
|  | IVertex | fourth
| ) |  | `[pure virtual]`

Draws single quad specified by four vertices.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height,
|  | System.Drawing.Color | color
| ) |  |

Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height
  color | Color of the outline

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawRectangle | ( | System.Drawing.Rectangle | rect | ) |

Draws outlined 2d rectangle with current color.

Parameters:

  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawRectangle | ( | System.Drawing.Rectangle | rect,
|  | ColorByte | Color
| ) |  |

Draws outlined 2d rectangle.

Parameters:

  Color | Color of the outline
  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawRectangle | ( | System.Drawing.Rectangle | rect,
|  | System.Drawing.Color | Color
| ) |  |

Draws outlined 2d rectangle.

Parameters:

  Color | Color of the outline
  rect | Rectangle

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height
| ) |  | `[pure virtual]`

Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height, using current color.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawRectangle | ( | int | x1,
|  | int | y1,
|  | int | width,
|  | int | height,
|  | ColorByte | color
| ) |  |

Draws outlined 2d rectangle with x1 and y1 coordinates of top left and width and height.

Parameters:

  x1 | left upper corner
  y1 | left upper corner
  width | width
  height | height
  color | Color of the outline

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawSkybox | ( | ref SkyboxData | skybox | ) | `[pure virtual]`

Draws simple skybox.

Parameters:

  skybox | Skybox data (note, textures in skybox must be initialized!)

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprite | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo | sprite
| ) |  |

Draws sprite with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprite | Sprite information

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprite | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo | sprite,
|  | Texture | tex
| ) |  |

Draws sprite with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  tex | Texture to be set
  sprite | Sprite information

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawSprite | ( | int | x,
|  | int | y,
|  | ref Render2D.SpriteInfo | sprite
| ) |  | `[pure virtual]`

Draws sprite with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprite | Sprite information

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprite | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo | sprite,
|  | string | texture
| ) |  |

Draws sprite with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  texture | Texture name
  sprite | Sprite information

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprites | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo[] | sprites,
|  | string | texture
| ) |  |

Draws array of sprites with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprites | Sprite information
  texture | Texture name

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprites | ( | int | x,
|  | int | y,
|  | ref Render2D.SpriteBatch | sprites
| ) |  |

Draws batch of sprites.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprites | SpriteBatch (should contain valid texture!)

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawSprites | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo[] | sprites
| ) |  | `[pure virtual]`

Draws array of sprites with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprites | Sprite information

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprites | ( | int | x,
|  | int | y,
|  | Render2D.SpriteInfo[] | sprites,
|  | Texture | tex
| ) |  |

Draws array of sprites with currently selected texture.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  tex | Texture to be set
  sprites | Sprite information

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawSprites | ( | int | x,
|  | int | y,
|  | Render2D.SpriteBatch | sprites
| ) |  |

Draws batch of sprites.

Parameters:

  x | X position (screen coords) for the sprite
  y | Y position (screen coords) for the sprite
  sprites | SpriteBatch (should contain valid texture!)

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | string | text
| ) |  |

Simple text drawing on selected coordinate. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  text | text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | string | text,
|  | ColorByte | color
| ) |  |

Simple text drawing on selected coordinate. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | string | text,
|  | System.Drawing.Color | color
| ) |  |

Simple text drawing on selected coordinate. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | int | maxwidth,
|  | int | maxheight,
|  | string | text,
|  | System.Drawing.Color | color
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  maxheight | Maximal height of the text block
  maxwidth | Maximal width of the text block
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | System.Drawing.Rectangle | rect,
|  | string | text
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  rect | Rectangle to write text to
  text | text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | System.Drawing.Rectangle | rect,
|  | string | text,
|  | ColorByte | color
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  rect | Rectangle to write text to
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | System.Drawing.Rectangle | rect,
|  | string | text,
|  | System.Drawing.Color | color
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  rect | Rectangle to write text to
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | int | maxwidth,
|  | int | maxheight,
|  | string | text,
|  | ColorByte | color
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  maxheight | Maximal height of the text block
  maxwidth | Maximal width of the text block
  text | text
  color | Color of the text

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.DrawText | ( | int | x,
|  | int | y,
|  | int | maxwidth,
|  | int | maxheight,
|  | string | text
| ) |  |

Draw text on selected coordinate with specified max size of the text block. Uses currently selected font.

Parameters:

  x | X coordinate
  y | Y coordinate
  maxheight | Maximal height of the text block
  maxwidth | Maximal width of the text block
  text | text

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.DrawTriangle3D | ( | IVertex | first,
|  | IVertex | second,
|  | IVertex | third
| ) |  | `[pure virtual]`

Draws single triangle specified by three vertices.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawTriangle3D | ( | ref Vector3 | first,
|  | ref Vector3 | second,
|  | ref Vector3 | third
| ) |  | `[virtual]`

Draws single triangle specified by three vertices.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.DrawTriangle3D | ( | Vector3 | first,
|  | Vector3 | second,
|  | Vector3 | third
| ) |  | `[virtual]`

Draws single triangle specified by three vertices.

This is slow, use only in special circumstances (debug rendering)

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.EndFrame | ( |  | ) | `[virtual]`

Finished rendering frame and shows it.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.FinishRenderQueue | ( |  | ) | `[virtual]`

Finishes rendering queue (renders all remaining items in the queue including sorted alpha items)

Implements VisimBox.Renderer.IRenderContext.

string VisimBox.Renderer.RenderContext.GetExtension | ( | string | filename | ) |

System.Drawing.Imaging.ImageFormat VisimBox.Renderer.RenderContext.GetFormatType | ( | string | extension | ) |

virtual System.Drawing.Bitmap VisimBox.Renderer.RenderContext.GetScreenShot | ( |  | ) | `[virtual]`

Grabs actual content of the render context and converts it to bitmap.

Returns:
  BMP containg current output on the render context

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderFrame | ( |  | ) | `[virtual]`

Renders frame in standard way (StartFrame and then EndFrame with associated callbacks)

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | IndexedMesh | geo,
|  | int | subset = `-1`
| ) |  | `[virtual]`

Renders geometry object - Indexed triangle mesh.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | IndexedLines | geo,
|  | int | subset = `-1`
| ) |  | `[virtual]`

Renders geometry object - Indexed list of points.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | IndexedQuads | geo,
|  | int | subset = `-1`
| ) |  | `[virtual]`

Renders geometry object - Indexed quad mesh.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | IGeometry | geometry | ) | `[virtual]`

Renders generic geometry object - uses conversion routines from the object, will be very slow if overused!

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | IndexedGeo | geo,
|  | int | subset = `-1`
| ) |  | `[virtual]`

Renders geometry object - generic indexed geometry.

Parameters:

  geo | Geometry object
  subset | Subset to render. -1 means current

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | QuadList | geo | ) | `[virtual]`

Renders geometry object - List of quads.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | PolyLine | geo | ) | `[virtual]`

Renders geometry object - PolyLine.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | TriangleList | geo | ) | `[virtual]`

Renders geometry object - List of triangles.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | LineList | geo | ) | `[virtual]`

Renders geometry object - List of lines.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.RenderGeometry | ( | Point3DList | geo | ) | `[virtual]`

Renders geometry object - List of points.

Parameters:

  geo | Geometry object

Renders from the vertexarray, might be much faster then direct rendering, but still slower then using vertex buffers

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderIndexedMesh | ( | IVertexBuffer | vertices,
|  | int[] | indices,
|  | PrimitiveTypes | type,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders indexed mesh from vertex and index buffer.

Parameters:

  vertices | Vertex buffer
  indices | Index buffer
  type | Primitive type
  startindex | starting index
  count | Number of elements

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderIndexedMesh | ( | IVertexArray | varray,
|  | int[] | indices,
|  | PrimitiveTypes | type,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders indexed mesh from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  indices | Indices for elements
  type | Type of primitive in indexed mesh (valid are Poins, Lines, Triangles and Quads)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderIndexedMesh | ( | IVertexBuffer | vertices,
|  | IIndexBuffer | indices,
|  | PrimitiveTypes | type,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders indexed mesh from vertex and index buffer.

Parameters:

  vertices | Vertex buffer
  indices | Index buffer
  type | Primitive type
  startindex | starting index
  count | Number of elements

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderLine | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders polyline from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderLines | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders lines from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.RenderNodes | ( | VisimBox.Scene.Node | scene | ) |

Renders spefified node hierarchy.

Parameters:

  scene | Nodes to render

abstract void VisimBox.Renderer.RenderContext.RenderPoints | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders points from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderPoly | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders polygon from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderQuads | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders quads from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderTriangles | ( | IVertexArray | varray,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Renders triangles from vertex array.

Parameters:

  varray | Vertex array with vertices (should be VertexArray, not VertexList)
  startindex | Starting index of elements
  count | Count of elements (if zero, all remaining elements from starting index will be drawn

Rendering from system memory is (depending on the implementation, applies for openGL) much faster then direct rendering, but still slower then vertex buffers.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.RenderVertexBuffer | ( | IVertexBuffer | vertices,
|  | PrimitiveTypes | type,
|  | int | startindex = `0`,
|  | int | count = `0`
| ) |  | `[pure virtual]`

Render vertex buffer as specified type of primitive (can't be used for indexed meshes!)

Parameters:

  vertices | Vertex buffer
  type | Primitive type
  startindex | starting index
  count | Number of elements

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.SaveScreenShot | ( | string | filename = `null`,
|  | string | extension = `null`
| ) |  | `[virtual]`

Saves screenshot with specified name, uses GetScreenShot()

Parameters:

  filename | filename to save, if null, creates file ScreenshotDATE-TIME.jpg

Implements VisimBox.Renderer.IRenderContext.

void VisimBox.Renderer.RenderContext.SetColor | ( | ColorByte | col | ) |

Sets main rendering color (especially for 2d rendering)

Parameters:

  col | Color

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.SetColor | ( | ref ColorByte | col | ) | `[pure virtual]`

Sets main rendering color (especially for 2d rendering)

Parameters:

  col | Color

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

void VisimBox.Renderer.RenderContext.SetColor | ( | System.Drawing.Color | col | ) |

Sets main rendering color (especially for 2d rendering)

Parameters:

  col | Color

Implements VisimBox.Renderer.IRenderContext.

virtual void VisimBox.Renderer.RenderContext.SetTransformation | ( | Matrix4 | mat | ) | `[virtual]`

Sets model transformation (without camera transformation)

Parameters:

  mat |

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.SetTransformation | ( | ref Matrix4 | mat | ) | `[pure virtual]`

Sets model transformation (without camera transformation)

Parameters:

  mat |

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

abstract void VisimBox.Renderer.RenderContext.Start2DRender | ( |  | ) | `[pure virtual]`

Sets renderer to 2d context, all 2d rendering calls should be done after this call!

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.StartFrame | ( |  | ) | `[virtual]`

Starts rendering frame.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

virtual void VisimBox.Renderer.RenderContext.StartRenderingQueue | ( |  | ) | `[virtual]`

Starts rendering queue (allows adding new items to render queue. If renderer uses multithreading, queue will be rendered as soon as some queue item will be added, except alpha values.

Implements VisimBox.Renderer.IRenderContext.

abstract void VisimBox.Renderer.RenderContext.Stop2DRender | ( |  | ) | `[pure virtual]`

Returns renderer to previous (3d) rendering state from the 2d renderer.

Implements VisimBox.Renderer.IRenderContext.

Implemented in VisimRenderGL.GLRenderContext.

## Member Data Documentation

Render2D.Font VisimBox.Renderer.RenderContext._CurrentFont`[protected]`

Texture VisimBox.Renderer.RenderContext._CurrentTexture`[protected]`

bool VisimBox.Renderer.RenderContext._showFPS = false`[protected]`

bool VisimBox.Renderer.RenderContext._zBuffer = true`[protected]`

int VisimBox.Renderer.RenderContext.fps`[protected]`

Viewport VisimBox.Renderer.RenderContext.mainViewport`[protected]`

main "fullscreen" viewport encompassing the whole area

RenderQueue VisimBox.Renderer.RenderContext.Queue`[protected]`

IRenderer VisimBox.Renderer.RenderContext.renderer`[protected]`

Renderer associated to the render context.

System.Diagnostics.Stopwatch VisimBox.Renderer.RenderContext.RenderTimer`[protected]`

RenderContextSettings VisimBox.Renderer.RenderContext.settings`[protected]`

settings for the context

Dictionary<string, Viewport> VisimBox.Renderer.RenderContext.viewports = new Dictionary<string,Viewport>()`[protected]`

List containing all other viewports.

## Property Documentation

int VisimBox.Renderer.RenderContext.CurrentFPS`[get]`

Returns current rendering frames per second for this context.

Implements VisimBox.Renderer.IRenderContext.

virtual Texture VisimBox.Renderer.RenderContext.CurrentTexture`[get, set]`

Currently selected texture.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

Vector3 VisimBox.Renderer.RenderContext.DebugLine1`[get, set]`

Implements VisimBox.Renderer.IRenderContext.

Vector3 VisimBox.Renderer.RenderContext.DebugLine2`[get, set]`

Implements VisimBox.Renderer.IRenderContext.

Vector3 VisimBox.Renderer.RenderContext.DebugPoint`[get, set]`

Implements VisimBox.Renderer.IRenderContext.

abstract bool VisimBox.Renderer.RenderContext.Fog`[get, set]`

Enables / disables fog drawing.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

abstract ColorByte VisimBox.Renderer.RenderContext.FogColor`[get, set]`

Color of the fog.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

abstract float VisimBox.Renderer.RenderContext.FogDensity`[get, set]`

Density of the fog.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

ICamera VisimBox.Renderer.RenderContext.MainCamera`[get, set]`

Returns pointer to the main camera (camera in main viewport)

Implements VisimBox.Renderer.IRenderContext.

IRenderer VisimBox.Renderer.RenderContext.Renderer`[get]`

Main renderer for this context.

Implements VisimBox.Renderer.IRenderContext.

RenderContextSettings VisimBox.Renderer.RenderContext.Settings`[get, set]`

Settings of the render context.

Implements VisimBox.Renderer.IRenderContext.

bool VisimBox.Renderer.RenderContext.ShowFPS`[get, set]`

Show fps on screen?

Implements VisimBox.Renderer.IRenderContext.

virtual bool VisimBox.Renderer.RenderContext.ZBufferUsing`[get, set]`

Use to directly change using of the zbuffer.

Implements VisimBox.Renderer.IRenderContext.

Reimplemented in VisimRenderGL.GLRenderContext.

## Event Documentation

RendererEvent VisimBox.Renderer.RenderContext.FrameEnd

Called on the end of the frame before showing results of the rendering.

Implements VisimBox.Renderer.IRenderContext.

RendererEvent VisimBox.Renderer.RenderContext.FrameStart

Called on the framestart before any rendering starts.

Implements VisimBox.Renderer.IRenderContext.

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

- RenderContext.cs

All Classes Namespaces Files Functions Variables Enumerations Properties Events