Home |All Classes |Grouped Classes |Index |Search

Class CL_GraphicContext

Interface to drawing graphics. More...

Derived from:

None

Derived by:

None

Group:

Display (Display)

#include <ClanLib/display.h>

Class Members:

Construction:

CL_GraphicContext

Constructs a graphic context.


Attributes:

get_texture

Returns the currently selected texture for the specified index.

get_blend_mode

Returns the blending mode description.

get_buffer_control

Returns the buffer control description.

get_polygon_rasterizer

Returns the polygon rasterizer setup.

get_pen

Returns the currently selected pen.

get_font

Returns the currently selected font.

get_font_metrics

Retrieves font metrics description for the selected font.

get_width

Returns the current width of the context.

get_height

Returns the current height of the context.

get_cliprect

Returns the current clipping rectangle used on the graphic context.

get_modelview

Returns the current effective modelview matrix.

get_max_texture_size

Returns the maximum size of a texture this graphic context supports.

get_provider

Returns the provider for this graphic context.


Operations:

create_worker_gc

Creates a new additional graphic context.

get_pixeldata

Return the content of the draw buffer into a pixel buffer.

set_frame_buffer

Sets the current frame buffer.

reset_frame_buffer

Resets the current frame buffer to be the initial frame buffer.

set_texture

Select texture into index.

reset_texture

Remove texture from index.

push_texture_matrix

Push current texture matrix onto the texture matrix of the specified unit.

set_texture_matrix

Set the texture matrix of the specified unit.

pop_texture_matrix

Pop current texture matrix from the texture matrix of the specified unit.

set_program_object

Set active program object.

reset_program_object

Remove active program object.

set_blend_mode

Set blending modes.

reset_blend_mode

Reset blending to the default.

set_buffer_control

Set buffer control states.

reset_buffer_control

Set default buffer control states.

set_pen

Select pen.

reset_pen

Reset pen settings to defaults.

set_polygon_rasterizer

Set polygon rasterizer settings.

reset_polygon_rasterizer

Reset polygon rasterizer settings to defaults.

register_font

Registers a font for lookup when creating fonts.

set_font

Select font.

draw_primitives

Draw primitives on gc.

set_primitives_array

Set the primitives array on the gc.

draw_primitives_array

Draws primitives from the current assigned primitives array.

draw_primitives_elements

reset_primitives_array

Reset the primitives arrays.

draw_pixels

Draw pixel buffer on gc.

draw_text

Print text on gc.

get_text_size

Calculate size of text string.

clear

Clears the whole context using the specified color.

clear_stencil

Clear the stencil buffer.

clear_depth

Clear the depth buffer.

set_cliprect

Set the current clipping rectangle.

push_cliprect

Push current clipping rectangle to stack.

pop_cliprect

Pop current clipping rectangle from the stack.

reset_cliprect

Removes the set clipping rectangle and empties the cliprect stack.

set_map_mode

Set the projection mapping mode.

set_viewport

Set the viewport to be used in user projection map mode.

set_projection

Set the projection matrix to be used in user projection map mode.

set_modelview

Sets the model view matrix to a new matrix.

mult_modelview

Multiplies the passed matrix onto the model view matrix.

push_modelview

Pushes current model view matrix onto the model view stack.

set_translate

Sets a translate offset matrix, ignoring any earlier model view settings.

mult_translate

Adds the translate offset.

push_translate

Push translation offset onto model view stack.

set_rotate

Sets a rotation matrix, ignoring any earlier model view settings.

mult_rotate

Adds a rotation matrix to existing model view.

push_rotate

Pushes a rotation matrix onto model view stack.

set_scale

Sets a scale matrix, ignoring any earlier model view settings.

mult_scale

Adds a scale matrix to existing model view.

push_scale

Pushes a scale matrix onto model view stack.

pop_modelview

Pops last pushed model view matrix off the stack and makes it the active one.