15 #ifndef ROCKET_RENDER_INTERFACE_H
16 #define ROCKET_RENDER_INTERFACE_H
18 #include "config_rocket.h"
19 #include "cullTraverser.h"
20 #include "cullTraverserData.h"
22 #include "renderState.h"
23 #include "transformState.h"
25 #include <Rocket/Core/RenderInterface.h>
37 struct CompiledGeometry {
42 PT(
Geom) make_geom(Rocket::Core::Vertex* vertices,
43 int num_vertices,
int* indices,
int num_indices,
44 GeomEnums::UsageHint uh,
const LVecBase2 &tex_scale);
45 void render_geom(
const Geom* geom,
const RenderState* state,
const Rocket::Core::Vector2f& translation);
47 void RenderGeometry(Rocket::Core::Vertex* vertices,
int num_vertices,
int* indices,
int num_indices, Rocket::Core::TextureHandle texture,
const Rocket::Core::Vector2f& translation);
48 Rocket::Core::CompiledGeometryHandle CompileGeometry(Rocket::Core::Vertex* vertices,
int num_vertices,
int* indices,
int num_indices, Rocket::Core::TextureHandle texture);
49 void RenderCompiledGeometry(Rocket::Core::CompiledGeometryHandle geometry,
const Rocket::Core::Vector2f& translation);
50 void ReleaseCompiledGeometry(Rocket::Core::CompiledGeometryHandle geometry);
52 bool LoadTexture(Rocket::Core::TextureHandle& texture_handle,
53 Rocket::Core::Vector2i& texture_dimensions,
54 const Rocket::Core::String& source);
55 bool GenerateTexture(Rocket::Core::TextureHandle& texture_handle,
56 const Rocket::Core::byte* source,
57 const Rocket::Core::Vector2i& source_dimensions);
58 void ReleaseTexture(Rocket::Core::TextureHandle texture_handle);
60 void EnableScissorRegion(
bool enable);
61 void SetScissorRegion(
int x,
int y,
int width,
int height);
72 CPT(TransformState) _net_transform;
74 Rocket::Core::Vector2i _dimensions;
A standard mutex, or mutual exclusion lock.
void render(Rocket::Core::Context *context, CullTraverser *trav)
Called by RocketNode in cull_callback.
A container for geometry primitives.
This is the base class for all two-component vectors and points.
This represents a unique collection of RenderAttrib objects that correspond to a particular renderabl...
This is the base class for all three-component vectors and points.
Class that provides the main render interface for libRocket integration.
This object performs a depth-first traversal of the scene graph, with optional view-frustum culling...