cgv
|
namespace for api independent GPU programming More...
Namespaces | |
gl | |
namespace for opengl specific GPU programming | |
Classes | |
struct | arrow_render_style |
class | arrow_renderer |
renderer that supports point splatting More... | |
class | attribute_array_binding |
class | attribute_array_binding_base |
base class for attribute_array_bindings More... | |
class | attribute_array_manager |
attribute array manager used to upload arrays to gpu More... | |
struct | box_render_style |
boxes use surface render styles More... | |
class | box_renderer |
renderer that supports point splatting More... | |
struct | box_wire_render_style |
box wires extend line render styles More... | |
class | box_wire_renderer |
renderer that supports point splatting More... | |
struct | callback_drawable |
class | clipped_view |
class | context |
struct | context_config |
class | drawable |
class | frame_buffer |
class | frame_buffer_base |
base interface for framebuffer More... | |
struct | group_render_style |
class | group_renderer |
abstract renderer class that provides functionality for grouping primitives More... | |
struct | line_render_style |
class | line_renderer |
renderer that supports point splatting More... | |
class | mesh_render_info |
class | multi_pass_drawable |
class | normal_renderer |
renderer that supports rendering point normals More... | |
class | performance_monitor |
struct | point_render_style |
class | point_renderer |
renderer that supports point splatting More... | |
class | rectangle_renderer |
renderer that supports plane rendering More... | |
class | render_buffer |
class | render_component |
base interface for all render components More... | |
struct | render_config |
class | render_info |
struct | render_style |
base class for all render styles More... | |
class | renderer |
abstract base class for all renderers that handles a shader program and position / color attribute More... | |
class | rounded_cone_renderer |
renderer that supports raycasting of rounded cones More... | |
class | shader_code |
struct | shader_config |
class | shader_program |
class | shader_program_base |
base interface for shader programs More... | |
struct | slab_render_style |
class | slab_renderer |
renderer that supports point splatting More... | |
struct | sphere_render_style |
class | sphere_renderer |
renderer that supports splatting of spheres More... | |
class | spline_tube_renderer |
renderer that supports point splatting More... | |
class | stereo_view |
struct | surface_render_style |
class | surface_renderer |
base classes for renderers that support surface rendering More... | |
struct | surfel_render_style |
class | surfel_renderer |
renderer that supports point splatting More... | |
class | texture |
class | texture_base |
base interface for a texture More... | |
class | textured_material |
class that extends obj_material with the management of textures More... | |
struct | textured_rectangle |
simple helper class to store rectangles with texture coordinates More... | |
struct | type_descriptor |
compact type description of data that can be sent to the context; convertible to int More... | |
class | vertex_buffer |
class | vertex_buffer_base |
base interface for a vertex buffer More... | |
class | view |
struct | volume_render_style |
class | volume_renderer |
renderer that supports point splatting More... | |
struct | window_transformation |
parameters necessary to define window transformation More... | |
Typedefs | |
typedef cgv::data::ref_ptr< context_config > | context_config_ptr |
type of ref counted pointer to context creation configuration | |
typedef cgv::data::ref_ptr< render_config > | render_config_ptr |
type of ref counted pointer to render configuration | |
typedef cgv::data::ref_ptr< shader_config > | shader_config_ptr |
type of ref counted pointer to shader configuration | |
Enumerations | |
enum | ElementType |
different compond types for data elements | |
enum | RenderAPI |
enumeration of rendering APIs which can be queried from the context | |
enum | RenderPass { , RP_STEREO, RP_SHADOW_MAP, RP_SHADOW_VOLUME, RP_OPAQUE_SURFACES, RP_TRANSPARENT_SURFACES, RP_PICK, RP_USER_DEFINED } |
enumeration of different render passes, which can be queried from the context and used to specify a new render pass More... | |
enum | RenderPassFlags |
available flags that can be queried from the context and set for a new render pass | |
enum | MaterialSide |
different sides of a material | |
enum | IlluminationMode |
different illumination modes | |
enum | CullingMode |
different culling modes | |
enum | TextureWrap |
different texture wrap modes | |
enum | TextureFilter |
different texture filter | |
enum | TextureType |
different texture types | |
enum | TextureCubeSides |
the six different sides of a cube | |
enum | PrimitiveType |
different primitive types | |
enum | TextureSampling { , TS_VERTEX = 1 } |
different sampling strategies for rendering to textures that steer the computation of the tex_coord input to the fragment shader More... | |
enum | CompareFunction |
different sampling strategies for rendering to textures that steer the computation of the tex_coord input to the fragment shader | |
enum | TextAlignment |
different text alignments | |
enum | VertexBufferType |
different vertex buffer types | |
enum | VertexBufferUsage |
different vertex buffer usages as defined in OpenGL | |
enum | ShaderType |
different shader types | |
enum | FrameBufferType |
different frame buffer types which can be combined together with or | |
enum | ContextIntegerConstant |
integer constants that can be queried from context | |
enum | PerformanceMonitoringBar |
different items that can be shown in the long bar | |
enum | ColorMapping |
color and opacity can be mapped independently to surface material | |
enum | InterpolationMode |
volume texture can have different interpolation methods | |
Functions | |
void | configure_color_scale (cgv::render::context &ctx, cgv::render::shader_program &prog, cgv::media::ColorScale cs, float window_zero_position=0.5f) |
convenience function to configure a shader that uses color_scale.glsl with a single color scale More... | |
void | configure_color_scale (cgv::render::context &ctx, cgv::render::shader_program &prog, cgv::media::ColorScale cs[2], float window_zero_position[2]) |
convenience function to configure a shader that uses color_scale.glsl with two color scales More... | |
render_config_ptr | get_render_config () |
return a pointer to the current shader configuration | |
std::string | get_render_pass_name (RenderPass rp) |
convert render pass type into string More... | |
std::string | to_string (TextureWrap wrap) |
convert texture wrap to string | |
std::string | to_string (TextureType tt) |
convert texture type to string | |
std::string | to_string (TextureCubeSides tcs) |
convert texture cube side to string | |
std::string | to_string (PrimitiveType pt) |
convert primitive type to string | |
std::string | to_string (TextureFilter filter_type) |
convert texture filter to string | |
void | tesselate_unit_dodecahedron_or_icosahedron (context &c, bool dual, bool flip_normals, bool edges) |
render an icosahedron at a given center. | |
void | register_context_factory (context_creation_function_type fp) |
registration context creation functions | |
context * | create_context (RenderAPI api, unsigned int w, unsigned int h, const std::string &title, bool show) |
shader_config_ptr | get_shader_config () |
return a reference to the current shader configuration More... | |
arrow_renderer & | ref_arrow_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton surfel renderer that can be shared among drawables More... | |
box_renderer & | ref_box_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton box renderer that is shared among drawables More... | |
box_wire_renderer & | ref_box_wire_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton box_wire renderer that can be shared among drawables More... | |
void | extract_additional_information (const fx::gltf::Document &doc, cgv::render::render_types::box3 &box, size_t &vertex_count) |
extract bounding box and vertex count from gltf document | |
bool | build_render_info (const std::string &file_name, const fx::gltf::Document &doc, cgv::render::context &ctx, cgv::render::render_info &R) |
construct render info from gltf document | |
void | extract_mesh (const std::string &file_name, const fx::gltf::Document &doc, cgv::media::mesh::simple_mesh< float > &mesh, int mesh_index=-1, int primitive_index=-1) |
extract simple mesh form gltf document More... | |
bool | write_gltf (const std::string &file_name, const cgv::render::render_info &R) |
NOT IMPLEMENTED YET. | |
normal_renderer & | ref_normal_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton normal renderer that can be shared among drawables More... | |
point_renderer & | ref_point_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton point renderer that can be shared among drawables More... | |
rectangle_renderer & | ref_rectangle_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton plane renderer that can be shared among drawables More... | |
rounded_cone_renderer & | ref_rounded_cone_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton rounded cone renderer that is shared among drawables More... | |
slab_renderer & | ref_slab_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton slab renderer that is shared among drawables More... | |
sphere_renderer & | ref_sphere_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton sphere renderer that can be shared among drawables More... | |
spline_tube_renderer & | ref_spline_tube_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton spline tube renderer that is shared among drawables More... | |
surfel_renderer & | ref_surfel_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton surfel renderer that can be shared among drawables More... | |
volume_renderer & | ref_volume_renderer (context &ctx, int ref_count_change=0) |
reference to a singleton volume renderer that is shared among drawables More... | |
namespace for api independent GPU programming
enumeration of different render passes, which can be queried from the context and used to specify a new render pass
CGV_API void cgv::render::configure_color_scale | ( | cgv::render::context & | ctx, |
cgv::render::shader_program & | prog, | ||
cgv::media::ColorScale | cs, | ||
float | window_zero_position = 0.5f |
||
) |
convenience function to configure a shader that uses color_scale.glsl with a single color scale
ctx | render context |
prog | shader program using the color scale |
cs | color scale index that can surpass cgv::media::CS_NAMED to index named color scales |
window_zero_position | window_zero_position which is mapped to center of a bipolar color scale |
CGV_API void cgv::render::configure_color_scale | ( | cgv::render::context & | ctx, |
cgv::render::shader_program & | prog, | ||
cgv::media::ColorScale | cs[2], | ||
float | window_zero_position[2] | ||
) |
convenience function to configure a shader that uses color_scale.glsl with two color scales
ctx | render context |
prog | shader program using the color scales |
cs | color scale indices that can surpass cgv::media::CS_NAMED to index named color scales |
window_zero_position | window space positions of attribute value zero which is mapped to center of a bipolar color scale |
CGV_API context * cgv::render::create_context | ( | RenderAPI | api, |
unsigned int | w, | ||
unsigned int | h, | ||
const std::string & | title, | ||
bool | show | ||
) |
construct a context of the given size. This is primarily used to create a context without a window for console applications that render into a frame buffer object only. After usage you need to delete the context by hand.
construct a context of the given size. This is primarily used to create a context without a window for console applications that render into a frame buffer object only. The newly created context will be current right after creation. After usage you need to delete the context by hand.
CGV_API void cgv::render::extract_mesh | ( | const std::string & | file_name, |
const fx::gltf::Document & | doc, | ||
cgv::media::mesh::simple_mesh< float > & | mesh, | ||
int | mesh_index = -1 , |
||
int | primitive_index = -1 |
||
) |
extract simple mesh form gltf document
extraction can be restricted to a mesh and within the mesh to a primitive by specifying the corresponsing indices as parameters to this function. The number of meshes can be extracted from the gltf document via doc.meshes.size() and the number of primitives for a given mesh with doc.meshes[mesh_index].primitives.size(). CAREFULL: works only in cases were all meshes and primitives have same vertex attribute configuration.
CGV_API std::string cgv::render::get_render_pass_name | ( | RenderPass | rp | ) |
convert render pass type into string
the main rendering pass triggered by the redraw event
rendering of second eye
construction of shadow map
construction of shadow map
opaque surface rendering using z-Buffer
transparent surface rendering using depth peeling
in picking pass a small rectangle around the mouse is rendered
CGV_API shader_config_ptr cgv::render::get_shader_config | ( | ) |
return a reference to the current shader configuration
return a pointer to the current shader configuration
CGV_API arrow_renderer & cgv::render::ref_arrow_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton surfel renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API box_renderer & cgv::render::ref_box_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton box renderer that is shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API box_wire_renderer & cgv::render::ref_box_wire_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton box_wire renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API normal_renderer & cgv::render::ref_normal_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton normal renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API point_renderer & cgv::render::ref_point_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton point renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API rectangle_renderer & cgv::render::ref_rectangle_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton plane renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API rounded_cone_renderer & cgv::render::ref_rounded_cone_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton rounded cone renderer that is shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API slab_renderer & cgv::render::ref_slab_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton slab renderer that is shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API sphere_renderer & cgv::render::ref_sphere_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton sphere renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API spline_tube_renderer & cgv::render::ref_spline_tube_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton spline tube renderer that is shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API surfel_renderer & cgv::render::ref_surfel_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton surfel renderer that can be shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.
CGV_API volume_renderer & cgv::render::ref_volume_renderer | ( | context & | ctx, |
int | ref_count_change = 0 |
||
) |
reference to a singleton volume renderer that is shared among drawables
the second parameter is used for reference counting. Use +1 in your init method, -1 in your clear method and default 0 argument otherwise. If internal reference counter decreases to 0, singelton renderer is destructed.