|
|
|
A GraphicsStateGuardian for rendering into DirectX9 contexts.
More...
#include "dxGraphicsStateGuardian9.h"
List of all members.
Classes |
| struct | TextureRenderStates |
| struct | TextureStageStates |
Public Member Functions |
|
| DXGraphicsStateGuardian9 (GraphicsEngine *engine, GraphicsPipe *pipe) |
|
virtual void | apply_fog (Fog *fog) |
| bool | apply_index_buffer (IndexBufferContext *ibc, const GeomPrimitivePipelineReader *reader, bool force) |
| | Updates the index buffer with the current data, and makes it the current index buffer for rendering.
|
| void | apply_texture (int i, TextureContext *tc) |
| | Makes the texture the currently available texture for rendering on the ith stage.
|
|
bool | apply_vertex_buffer (VertexBufferContext *vbc, const GeomVertexArrayDataHandle *reader, bool force) |
| virtual bool | begin_draw_primitives (const GeomPipelineReader *geom_reader, const GeomMunger *munger, const GeomVertexDataPipelineReader *data_reader, bool force) |
| | Called before a sequence of draw_primitive() functions are called, this should prepare the vertex data for rendering.
|
| virtual bool | begin_frame (Thread *current_thread) |
| | Called before each frame is rendered, to allow the GSG a chance to do any internal cleanup before beginning the frame.
|
| virtual void | begin_occlusion_query () |
| | Begins a new occlusion query.
|
| virtual bool | begin_scene () |
| | Called between begin_frame() and end_frame() to mark the beginning of drawing commands for a "scene" (usually a particular DisplayRegion) within a frame.
|
| virtual void | bind_light (PointLight *light_obj, const NodePath &light, int light_id) |
| | Called the first time a particular light has been bound to a given id within a frame, this should set up the associated hardware light with the light's properties.
|
| virtual void | bind_light (DirectionalLight *light_obj, const NodePath &light, int light_id) |
| | Called the first time a particular light has been bound to a given id within a frame, this should set up the associated hardware light with the light's properties.
|
| virtual void | bind_light (Spotlight *light_obj, const NodePath &light, int light_id) |
| | Called the first time a particular light has been bound to a given id within a frame, this should set up the associated hardware light with the light's properties.
|
| FrameBufferProperties | calc_fb_properties (DWORD cformat, DWORD dformat, DWORD multisampletype, DWORD multisamplequality) |
| | Convert DirectX framebuffer format ids into a FrameBufferProperties structure.
|
| bool | check_dx_allocation (HRESULT result, int allocation_size, int attempts) |
| | This function is called after the creation of textures, vertex buffers, and index buffers to check if DirectX is out of memory.
|
| virtual void | clear (DrawableRegion *clearable) |
| | Clears all of the indicated buffers to their assigned colors.
|
|
virtual | CPT (TransformState) calc_projection_mat(const Lens *lens) |
| bool | do_framebuffer_copy_to_ram (Texture *tex, int z, const DisplayRegion *dr, const RenderBuffer &rb, bool inverted) |
| | This is the implementation of framebuffer_copy_to_ram(); it adds one additional parameter, which should be true if the framebuffer is to be inverted during the copy (as in the same way it copies to texture memory).
|
| virtual bool | draw_lines (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of disconnected line segments.
|
| virtual bool | draw_linestrips (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of line strips.
|
| virtual bool | draw_points (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of disconnected points.
|
| virtual bool | draw_triangles (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of disconnected triangles.
|
| virtual bool | draw_trifans (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of triangle fans.
|
| virtual bool | draw_tristrips (const GeomPrimitivePipelineReader *reader, bool force) |
| | Draws a series of triangle strips.
|
| virtual void | end_draw_primitives () |
| | Called after a sequence of draw_primitive() functions are called, this should do whatever cleanup is appropriate.
|
| virtual void | end_frame (Thread *current_thread) |
| | Called after each frame is rendered, to allow the GSG a chance to do any internal cleanup after rendering the frame, and before the window flips.
|
| virtual void | end_scene () |
| | Called between begin_frame() and end_frame() to mark the end of drawing commands for a "scene" (usually a particular DisplayRegion) within a frame.
|
| virtual bool | extract_texture_data (Texture *tex) |
| | This method should only be called by the GraphicsEngine.
|
|
virtual TypeHandle | force_init_type () |
| virtual bool | framebuffer_copy_to_ram (Texture *tex, int z, const DisplayRegion *dr, const RenderBuffer &rb) |
| | Copy the pixels within the indicated display region from the framebuffer into system memory, not texture memory.
|
| virtual bool | framebuffer_copy_to_texture (Texture *tex, int z, const DisplayRegion *dr, const RenderBuffer &rb) |
| | Copy the pixels within the indicated display region from the framebuffer into texture memory.
|
| virtual bool | get_supports_cg_profile (const string &name) const |
| | Returns true if this particular GSG supports the specified Cg Shader Profile.
|
| bool | get_supports_render_texture () const |
| | Returns true if this particular GSG can render from a wdxGraphicsBuffer9 directly into a texture, or false if it must always copy-to-texture at the end of each frame to achieve this effect.
|
|
virtual TypeHandle | get_type () const |
| virtual void | prepare_display_region (DisplayRegionPipelineReader *dr) |
| | Prepare a display region for rendering (set up scissor region and viewport)
|
| virtual IndexBufferContext * | prepare_index_buffer (GeomPrimitive *data) |
| | Creates a new retained-mode representation of the given data, and returns a newly-allocated IndexBufferContext pointer to reference it.
|
| virtual bool | prepare_lens () |
| | Makes the current lens (whichever lens was most recently specified with set_scene()) active, so that it will transform future rendered geometry.
|
| ShaderContext * | prepare_shader (Shader *se) |
| | Compile a vertex/fragment shader body.
|
| virtual TextureContext * | prepare_texture (Texture *tex, int view) |
| | Creates a new retained-mode representation of the given texture, and returns a newly-allocated TextureContext pointer to reference it.
|
| virtual VertexBufferContext * | prepare_vertex_buffer (GeomVertexArrayData *data) |
| | Prepares the indicated buffer for retained-mode rendering.
|
|
virtual | PT (OcclusionQueryContext) end_occlusion_query() |
|
virtual | PT (GeomMunger) make_geom_munger(const RenderState *state |
| virtual void | release_index_buffer (IndexBufferContext *ibc) |
| | Frees the GL resources previously allocated for the data.
|
| void | release_shader (ShaderContext *sc) |
| | Releases the resources allocated by prepare_shader.
|
| virtual void | release_texture (TextureContext *tc) |
| | Frees the GL resources previously allocated for the texture.
|
| virtual void | release_vertex_buffer (VertexBufferContext *vbc) |
| | Frees the resources previously allocated via a call to prepare_data(), including deleting the VertexBufferContext itself, if necessary.
|
| virtual void | reset () |
| | Resets all internal state as if the gsg were newly created.
|
|
void | reset_render_states (void) |
| void | restore_gamma () |
| | Restore original gamma.
|
| bool | set_gamma (PN_stdfloat gamma) |
| | Non static version of setting gamma.
|
| HRESULT | set_render_state (D3DRENDERSTATETYPE state, DWORD value) |
| | This function creates a common layer between DX and Panda for SetRenderState.
|
| HRESULT | set_sampler_state (DWORD sampler, D3DSAMPLERSTATETYPE type, DWORD value) |
| | This function creates a common layer between DX and Panda.
|
| virtual void | set_state_and_transform (const RenderState *state, const TransformState *transform) |
| | Simultaneously resets the render state and the transform state.
|
| HRESULT | set_texture_stage_state (DWORD stage, D3DTEXTURESTAGESTATETYPE type, DWORD value) |
| | This function creates a common layer between DX and Panda.
|
|
bool | setup_array_data (CLP(VertexBufferContext)*&vbc, const GeomVertexArrayDataHandle *data, bool force) |
| virtual bool | update_texture (TextureContext *tc, bool force) |
| | Ensures that the current Texture data is refreshed onto the GSG.
|
| bool | upload_texture (DXTextureContext9 *dtc, bool force) |
| | Creates a texture surface on the graphics card and fills it with its pixel data.
|
Static Public Member Functions |
| static void | atexit_function (void) |
| | This function is passed to the atexit function.
|
|
static TypeHandle | get_class_type () |
| static bool | get_gamma_table (void) |
| | Static function for getting the original gamma.
|
| static D3DFORMAT | get_index_type (Geom::NumericType numeric_type) |
| | Maps from the Geom's internal numeric type symbols to DirectX's.
|
|
static void | init_type () |
| static DWORD | LColor_to_D3DCOLOR (const LColor &cLColor) |
| | Converts Panda's floating-point LColor structure to DirectX's D3DCOLOR packed structure.
|
| static void | set_cg_device (LPDIRECT3DDEVICE9 cg_device) |
| | Sets the global Cg device pointer.
|
| static bool | static_set_gamma (bool restore, PN_stdfloat gamma) |
| | Static function for setting gamma which is needed for atexit.
|
Public Attributes |
|
DXScreenData * | _screen |
|
virtual Thread * | current_thread |
Protected Types |
|
typedef pmap< NodePath, D3DLIGHT9 > | DirectionalLights |
| enum | DxgsgFogType { None,
PerVertexFog = D3DRS_FOGVERTEXMODE,
PerPixelFog = D3DRS_FOGTABLEMODE
} |
Protected Member Functions |
| virtual void | bind_clip_plane (const NodePath &plane, int plane_id) |
| | Called the first time a particular clip_plane has been bound to a given id within a frame, this should set up the associated hardware clip_plane with the clip_plane's properties.
|
|
bool | check_cooperative_level () |
| virtual void | close_gsg () |
| | This is called by the associated GraphicsWindow when close_window() is called.
|
|
| CLP (ShaderContext)*_current_shader_context |
|
| CLP (ShaderContext)*_vertex_array_shader_context |
|
| CLP (ShaderContext)*_texture_binding_shader_context |
| void | copy_pres_reset (DXScreenData *new_context) |
| | copies the PresReset from passed DXScreenData
|
|
bool | create_swap_chain (DXScreenData *new_context) |
|
void | disable_standard_texture_bindings () |
|
void | disable_standard_vertex_arrays () |
| void | do_auto_rescale_normal () |
| | Issues the appropriate DX commands to either rescale or normalize the normals according to the current transform.
|
|
void | do_issue_alpha_test () |
| void | do_issue_blending () |
| | Called after any of the things that might change blending state have changed, this function is responsible for setting the appropriate color blending mode based on the current properties.
|
|
void | do_issue_color_write () |
|
void | do_issue_cull_face () |
|
void | do_issue_depth_offset () |
|
void | do_issue_depth_test () |
|
void | do_issue_depth_write () |
|
void | do_issue_fog () |
|
void | do_issue_material () |
|
void | do_issue_render_mode () |
|
void | do_issue_rescale_normal () |
|
void | do_issue_scissor () |
|
void | do_issue_shade_model () |
|
void | do_issue_shader () |
| void | do_issue_stencil () |
| | Set stencil render states.
|
|
void | do_issue_tex_gen () |
|
void | do_issue_texture () |
| void | do_issue_transform () |
| | Sends the indicated transform matrix to the graphics API to be applied to future vertices.
|
| void | draw_indexed_primitive_up (D3DPRIMITIVETYPE primitive_type, unsigned int min_index, unsigned int max_index, unsigned int num_primitives, const unsigned char *index_data, D3DFORMAT index_type, const unsigned char *buffer, size_t stride) |
| | Issues the DrawIndexedPrimitiveUP call to draw the indicated primitive_type from the given buffer.
|
| void | draw_primitive_up (D3DPRIMITIVETYPE primitive_type, unsigned int primitive_count, unsigned int first_vertex, unsigned int num_vertices, const unsigned char *buffer, size_t stride) |
| | Issues the DrawPrimitiveUP call to draw the indicated primitive_type from the given buffer.
|
| void | dx_cleanup () |
| | Clean up the DirectX environment, accounting for exit()
|
| virtual void | enable_clip_plane (int plane_id, bool enable) |
| | Intended to be overridden by a derived class to enable the indicated clip_plane id.
|
| virtual void | enable_light (int light_id, bool enable) |
| | Intended to be overridden by a derived class to enable the indicated light id.
|
| virtual void | enable_lighting (bool enable) |
| | Intended to be overridden by a derived class to enable or disable the use of lighting overall.
|
| void | free_d3d_device () |
| | setup for re-calling dx_init(), this is not the final exit cleanup routine (see dx_cleanup)
|
| void | free_nondx_resources () |
| | Frees some memory that was explicitly allocated within the dxgsg.
|
| const D3DCOLORVALUE & | get_light_color (Light *light) const |
| | Returns the array of four floats that should be issued as the light's color, as scaled by the current value of _light_color_scale, in the case of color_scale_via_lighting.
|
| DWORD | get_texture_argument (TextureStage::CombineSource source, TextureStage::CombineOperand operand) const |
| | Returns the D3DTA value corresponding to the indicated TextureStage::CombineSource and TextureStage::CombineOperand enumerated types.
|
|
| PT (Shader) _current_shader |
|
| PT (Shader) _vertex_array_shader |
|
| PT (Shader) _texture_binding_shader |
| virtual void | reissue_transforms () |
| | Called by clear_state_and_transform() to ensure that the current modelview and projection matrices are properly loaded in the graphics state, after a callback might have mucked them up.
|
| bool | release_swap_chain (DXScreenData *new_context) |
| | Release the swap chain on this DXScreenData.
|
| void | report_texmgr_stats () |
| | Reports the DX texture manager's activity to PStats.
|
| HRESULT | reset_d3d_device (D3DPRESENT_PARAMETERS *p_presentation_params, DXScreenData **screen=NULL) |
| | This function checks current device's framebuffer dimension against passed p_presentation_params backbuffer dimension to determine a device reset if there is only one window or it is the main window or fullscreen mode then, it resets the device.
|
| virtual void | set_ambient_light (const LColor &color) |
| | Intended to be overridden by a derived class to indicate the color of the ambient light that should be in effect.
|
|
void | set_context (DXScreenData *new_context) |
| void | set_draw_buffer (const RenderBuffer &rb) |
| | Sets up the glDrawBuffer to render into the buffer indicated by the RenderBuffer object.
|
| void | set_read_buffer (const RenderBuffer &rb) |
| | Vestigial analog of glReadBuffer.
|
| void | set_render_target () |
| | Set render target to the backbuffer of current swap chain.
|
|
void | set_texture_blend_mode (int i, const TextureStage *stage) |
| void | show_frame () |
| | redraw primary buffer
|
|
void | update_standard_texture_bindings () |
|
bool | update_standard_vertex_arrays (bool force) |
Static Protected Member Functions |
| static D3DBLEND | get_blend_func (ColorBlendAttrib::Operand operand) |
| | Maps from ColorBlendAttrib::Operand to D3DBLEND value.
|
|
static D3DTEXTUREFILTERTYPE | get_d3d_min_type (Texture::FilterType filter_type) |
|
static D3DTEXTUREFILTERTYPE | get_d3d_mip_type (Texture::FilterType filter_type) |
| static D3DFOGMODE | get_fog_mode_type (Fog::Mode m) |
| | Maps from the fog types to gl version.
|
| static unsigned char * | get_safe_buffer_start () |
| | Returns the address of a 64K buffer that is allocated at the beginning of a 64K block.
|
| static D3DTRANSFORMSTATETYPE | get_tex_mat_sym (int stage_index) |
| | Returns the nth D3DTS_TEXTURE(n) constant.
|
| static DWORD | get_texture_argument_modifier (TextureStage::CombineOperand operand) |
| | Returns the extra bits that modify the D3DTA argument, according to the indicated TextureStage::CombineOperand enumerated type.
|
| static D3DTEXTUREOP | get_texture_operation (TextureStage::CombineMode mode, int scale) |
| | Returns the D3DTEXTUREOP value corresponding to the indicated TextureStage::CombineMode enumerated type.
|
| static D3DTEXTUREADDRESS | get_texture_wrap_mode (Texture::WrapMode wm) |
| | Maps from the Texture's internal wrap mode symbols to GL's.
|
Protected Attributes |
|
const DXIndexBufferContext9 * | _active_ibuffer |
|
bool | _auto_rescale_normal |
|
UINT | _available_texture_memory |
|
DWORD | _clip_plane_bits |
|
DWORD | _constant_color_operand |
|
CullFaceAttrib::Mode | _cull_face_mode |
|
RenderBuffer::Type | _cur_read_pixel_buffer |
|
RenderModeAttrib::Mode | _current_fill_mode |
|
D3DVIEWPORT9 | _current_viewport |
|
LPDIRECT3DDEVICE9 | _d3d_device |
|
DirectionalLights | _dlights |
|
DxgsgFogType | _do_fog_type |
|
bool | _dx_is_ready |
|
list< wdxGraphicsBuffer9 ** > | _graphics_buffer_list |
|
int | _gsg_managed_index_buffers |
|
int | _gsg_managed_textures |
|
int | _gsg_managed_vertex_buffers |
|
DWORD | _last_fvf |
|
HRESULT | _last_testcooplevel_result |
|
PN_stdfloat | _material_ambient |
|
PN_stdfloat | _material_diffuse |
|
PN_stdfloat | _material_emission |
|
PN_stdfloat | _material_shininess |
|
PN_stdfloat | _material_specular |
|
int | _num_active_texture_stages |
|
int | _num_bound_streams |
|
bool | _overlay_windows_supported |
|
char * | _pixel_shader_profile |
|
int | _pixel_shader_version_major |
|
int | _pixel_shader_version_minor |
|
D3DPRESENT_PARAMETERS | _presentation_reset |
|
DWORD | _render_state_array [256] |
|
bool | _supports_depth_bias |
|
int | _supports_gamma_calibration |
|
bool | _supports_render_texture |
|
bool | _supports_stream_offset |
|
bool | _supports_texture_constant_color |
|
IDirect3DSwapChain9 * | _swap_chain |
|
bool | _tex_stats_retrieval_impossible |
|
TextureRenderStates | _texture_render_states_array [16] |
|
TextureStageStates | _texture_stage_states_array [D3D_MAXTEXTURESTAGES] |
|
bool | _vertex_blending_enabled |
|
int | _vertex_shader_maximum_constants |
|
char * | _vertex_shader_profile |
|
int | _vertex_shader_version_major |
|
int | _vertex_shader_version_minor |
Static Protected Attributes |
|
static LPDIRECT3DDEVICE9 | _cg_device = NULL |
|
static D3DMATRIX | _d3d_ident_mat |
|
static unsigned char * | _safe_buffer_start = NULL |
|
static unsigned char * | _temp_buffer = NULL |
Friends |
|
class | DXIndexBufferContext9 |
|
class | DXShaderContext9 |
|
class | DXTextureContext9 |
|
class | DXVertexBufferContext9 |
|
class | wdxGraphicsBuffer9 |
|
class | wdxGraphicsPipe9 |
|
class | wdxGraphicsWindow9 |
|
class | wdxGraphicsWindowGroup9 |
Detailed Description
A GraphicsStateGuardian for rendering into DirectX9 contexts.
Definition at line 60 of file dxGraphicsStateGuardian9.h.
Member Function Documentation
Updates the index buffer with the current data, and makes it the current index buffer for rendering.
Definition at line 657 of file dxGraphicsStateGuardian9.cxx.
References IndexBufferContext::changed_size(), DXIndexBufferContext9::create_ibuffer(), AdaptiveLruPage::enqueue_lru(), IndexBufferContext::mark_loaded(), BufferContext::set_active(), DXIndexBufferContext9::upload_data(), and IndexBufferContext::was_modified().
Referenced by draw_lines(), draw_triangles(), draw_trifans(), and draw_tristrips().
Makes the texture the currently available texture for rendering on the ith stage.
Definition at line 209 of file dxGraphicsStateGuardian9.cxx.
References Texture::get_border_color(), DXTextureContext9::get_d3d_texture(), Texture::get_effective_anisotropic_degree(), Texture::get_effective_magfilter(), Texture::get_effective_minfilter(), TextureContext::get_texture(), get_texture_wrap_mode(), Texture::get_wrap_u(), Texture::get_wrap_v(), Texture::get_wrap_w(), DXTextureContext9::has_mipmaps(), LColor_to_D3DCOLOR(), Texture::might_have_ram_image(), BufferContext::set_active(), set_sampler_state(), set_texture_stage_state(), and update_texture().
Called before a sequence of draw_primitive() functions are called, this should prepare the vertex data for rendering.
It returns true if the vertices are ok, false to abort this group of primitives.
Reimplemented from GraphicsStateGuardian.
Definition at line 1201 of file dxGraphicsStateGuardian9.cxx.
References GraphicsStateGuardian::begin_draw_primitives(), GeomVertexFormat::get_animation(), GeomVertexAnimationSpec::get_animation_type(), LMatrix4f::get_data(), GeomVertexAnimationSpec::get_indexed_transforms(), GeomVertexAnimationSpec::get_num_transforms(), TransformTable::get_num_transforms(), TransformTable::get_transform(), VertexTransform::mult_matrix(), and set_render_state().
Called before each frame is rendered, to allow the GSG a chance to do any internal cleanup before beginning the frame.
The return value is true if successful (in which case the frame will be drawn and end_frame() will be called later), or false if unsuccessful (in which case nothing will be drawn and end_frame() will not be called).
Reimplemented from GraphicsStateGuardian.
Definition at line 1013 of file dxGraphicsStateGuardian9.cxx.
Called the first time a particular light has been bound to a given id within a frame, this should set up the associated hardware light with the light's properties.
Reimplemented from GraphicsStateGuardian.
Definition at line 3492 of file dxGraphicsStateGuardian9.cxx.
References LMatrix4f::convert_mat(), Spotlight::get_attenuation(), LVecBase3f::get_data(), LVecBase4f::get_data(), Spotlight::get_exponent(), Lens::get_hfov(), LensNode::get_lens(), get_light_color(), Lens::get_nodal_point(), Spotlight::get_specular_color(), NodePath::get_transform(), and Lens::get_view_vector().
This function is called after the creation of textures, vertex buffers, and index buffers to check if DirectX is out of memory.
If DirectX is out of memory and the LRU is being used, then page out some memory. This function is a fail-safe just in case another process allocates video memory, DirectX is fragmented, or there are some borderline memory allocation cases, ...
Definition at line 5207 of file dxGraphicsStateGuardian9.cxx.
This is the implementation of framebuffer_copy_to_ram(); it adds one additional parameter, which should be true if the framebuffer is to be inverted during the copy (as in the same way it copies to texture memory).
Definition at line 2056 of file dxGraphicsStateGuardian9.cxx.
References DXTextureContext9::d3d_surface_to_texture(), Texture::get_component_type(), Texture::get_format(), DisplayRegion::get_region_pixels_i(), Texture::get_texture_type(), Texture::get_x_size(), Texture::get_y_size(), Texture::get_z_size(), Texture::has_ram_image(), set_read_buffer(), and Texture::setup_texture().
Referenced by framebuffer_copy_to_ram(), and framebuffer_copy_to_texture().
| void DXGraphicsStateGuardian9::draw_indexed_primitive_up |
( |
D3DPRIMITIVETYPE |
primitive_type, |
|
|
unsigned int |
min_index, |
|
|
unsigned int |
max_index, |
|
|
unsigned int |
num_primitives, |
|
|
const unsigned char * |
index_data, |
|
|
D3DFORMAT |
index_type, |
|
|
const unsigned char * |
buffer, |
|
|
size_t |
stride |
|
) |
| [protected] |
| void DXGraphicsStateGuardian9::draw_primitive_up |
( |
D3DPRIMITIVETYPE |
primitive_type, |
|
|
unsigned int |
primitive_count, |
|
|
unsigned int |
first_vertex, |
|
|
unsigned int |
num_vertices, |
|
|
const unsigned char * |
buffer, |
|
|
size_t |
stride |
|
) |
| [protected] |
Copy the pixels within the indicated display region from the framebuffer into texture memory.
If z > -1, it is the cube map index into which to copy.
Reimplemented from GraphicsStateGuardian.
Definition at line 1890 of file dxGraphicsStateGuardian9.cxx.
References DXTextureContext9::create_texture(), do_framebuffer_copy_to_ram(), AdaptiveLruPage::enqueue_lru(), DXTextureContext9::get_d3d_2d_texture(), GraphicsStateGuardian::get_prepared_objects(), DisplayRegion::get_region_pixels_i(), DisplayRegion::get_tex_view_offset(), TextureContext::get_texture(), Texture::get_texture_type(), Texture::get_x_size(), Texture::get_y_size(), TextureContext::mark_loaded(), Texture::prepare_now(), set_read_buffer(), Texture::set_render_to_texture(), and Texture::set_size_padded().
Returns true if this particular GSG can render from a wdxGraphicsBuffer9 directly into a texture, or false if it must always copy-to-texture at the end of each frame to achieve this effect.
Definition at line 226 of file dxGraphicsStateGuardian9.I.
Returns the D3DTEXTUREOP value corresponding to the indicated TextureStage::CombineMode enumerated type.
Definition at line 4995 of file dxGraphicsStateGuardian9.cxx.
Frees the GL resources previously allocated for the data.
This function should never be called directly; instead, call Data::release() (or simply let the Data destruct).
Reimplemented from GraphicsStateGuardian.
Definition at line 716 of file dxGraphicsStateGuardian9.cxx.
Sets up the glDrawBuffer to render into the buffer indicated by the RenderBuffer object.
This only sets up the color bits; it does not affect the depth, stencil, accum layers.
Definition at line 4198 of file dxGraphicsStateGuardian9.cxx.
Simultaneously resets the render state and the transform state.
This transform specified is the "internal" net transform, already converted into the GSG's internal coordinate space by composing it to get_cs_transform(). (Previously, this used to be the "external" net transform, with the assumption that that GSG would convert it internally, but that is no longer the case.)
Special case: if (state==NULL), then the target state is already stored in _target.
Reimplemented from GraphicsStateGuardian.
Definition at line 3162 of file dxGraphicsStateGuardian9.cxx.
References BitMask< WType, nbits >::clear_bit(), GraphicsStateGuardian::determine_target_texture(), do_issue_blending(), GraphicsStateGuardian::do_issue_clip_plane(), GraphicsStateGuardian::do_issue_color(), GraphicsStateGuardian::do_issue_light(), do_issue_stencil(), do_issue_transform(), BitMask< WType, nbits >::get_bit(), and BitMask< WType, nbits >::set_bit().
Creates a texture surface on the graphics card and fills it with its pixel data.
Definition at line 345 of file dxGraphicsStateGuardian9.cxx.
References GraphicsStateGuardian::async_reload_texture(), DXTextureContext9::create_texture(), DXTextureContext9::delete_texture(), Texture::get_ram_image_compression(), GraphicsStateGuardian::get_supports_compressed_texture_format(), TextureContext::get_texture(), Texture::has_ram_image(), Texture::has_simple_ram_image(), Texture::has_uncompressed_ram_image(), TextureContext::mark_unloaded(), Texture::might_have_ram_image(), TextureContext::update_data_size_bytes(), and TextureContext::was_simple_image_modified().
Referenced by update_texture().
The documentation for this class was generated from the following files:
| | |