|
| virtual scene_ptr_type | make_scene () override |
| | makes a scene
|
| virtual screen_camera_ptr_type | make_camera () override |
| | makes a camera that draws to the screen
|
| virtual texture_camera_ptr_type | make_texture_camera () override |
| | makes a texture_camera drawing into textures 1024 texels square
|
| virtual texture_camera_ptr_type | make_texture_camera (const intvector2_type &aSize) override |
| | makes a texture_camera drawing into textures aSize texels across
|
| virtual entity_ptr_type | make_entity (const const_model_ptr_type pModel, const const_material_ptr_type pMaterial) override |
| | make an entity
|
| virtual model_ptr_type | make_model () override |
| | make an empty model
|
| virtual model_ptr_type | make_model (const gdk::graphics::model::usage_hint, const model_data &aModelData) override |
| | make a model
|
| virtual material_ptr_type | make_material (const const_shader_ptr_type pShader, const material::render_mode aRenderMode, const material::face_culling_mode aFaceCullingMode) override |
| | make a material.
|
| virtual material_ptr_type | make_material (const const_material_ptr_type &aPrototype) override |
| | make a material that starts as a copy of another
|
| virtual texture_ptr_type | make_texture (const texture_data::view &aTextureDataView, const texture::wrap_mode aWrapModeU, const texture::wrap_mode aWrapModeV, const texture::filter_mode aFilterMode) override |
| | make a texture
|
| virtual texture_ptr_type | make_texture () override |
| | make an empty texture
|
|
std::size_t | texture_count () const |
| virtual model_ptr_type | make_cube_model () const override |
| | a 1x1x1 cube model
|
| virtual model_ptr_type | make_sphere_model () const override |
| virtual shader_ptr_type | make_alpha_cutoff_shader () const override |
| | Basic unlit forward renderer program: Attributes:
|
| virtual shader_ptr_type | make_alpha_blend_shader () const override |
| | a shader that keeps the texel's alpha, for the blender to use.
|
| virtual graphics::limits | limits () const override |
| | the limits of the device, narrowed to the context's profile when it was given one
|
|
shader_ptr_type | make_shader (const std::string_view aVertexSource, const std::string_view aFragmentSource) |
|
std::size_t | resources_made () const |
|
material_ptr_type | make_material (const const_shader_ptr_type pShader, const material::render_mode aRenderMode) |
| | make a material that culls no faces
|
|
material_ptr_type | make_material (const const_shader_ptr_type pShader) |
| | make an opaque material that culls no faces
|
|
texture_ptr_type | make_texture (const texture_data::view &aTextureDataView, const texture::wrap_mode aWrapModeU, const texture::wrap_mode aWrapModeV) |
| | make a sharp texture
|
|
texture_ptr_type | make_texture (const texture_data::view &aTextureDataView) |
| | make a sharp texture that repeats
|
|
material_ptr_type | make_material (const const_shader_ptr_type pShader, const material::render_mode aRenderMode) |
| | make a material that culls no faces
|
|
material_ptr_type | make_material (const const_shader_ptr_type pShader) |
| | make an opaque material that culls no faces
|
|
texture_ptr_type | make_texture (const texture_data::view &aTextureDataView, const texture::wrap_mode aWrapModeU, const texture::wrap_mode aWrapModeV) |
| | make a sharp texture
|
|
texture_ptr_type | make_texture (const texture_data::view &aTextureDataView) |
| | make a sharp texture that repeats
|
|
virtual | ~context ()=default |
| | virtual destructor
|
the limits of the device, narrowed to the context's profile when it was given one
What an implementation offers beyond this interface, shaders made from source in its own language say, is on its own context type, which its make returns.
Implements gdk::graphics::context.
| virtual shader_ptr_type gdk::graphics::null_context::make_alpha_cutoff_shader |
( |
| ) |
const |
|
nodiscardoverridevirtual |
Basic unlit forward renderer program: Attributes:
- vec3 pos
- vec2 uv Uniforms:
- _MVP: model-view-projection matrix
- _Texture: used to color frags Vertex shader behavior:
- multiply position by mvp Fragment shader behavior:
- sample _Texture, if alpha is 0, discard frag, otherwise write frag to color buffer
Both built-in shaders multiply the texel by _Color, a vec4 the material may set: a tint, a fade, a dim. A material starts with it white, so nothing changes until it is set.
Implements gdk::graphics::context.