ReactOS 0.4.15-dev-7788-g1ad9096
wined3d.h File Reference
#include "wine/list.h"
Include dependency graph for wined3d.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  wined3d_query_data_timestamp_disjoint
 
struct  wined3d_query_data_so_statistics
 
struct  wined3d_query_data_pipeline_statistics
 
struct  wined3d_display_mode
 
struct  wined3d_color
 
struct  wined3d_vec3
 
struct  wined3d_vec4
 
struct  wined3d_dvec4
 
struct  wined3d_ivec4
 
struct  wined3d_uvec4
 
struct  wined3d_matrix
 
struct  wined3d_light
 
struct  wined3d_material
 
struct  wined3d_viewport
 
struct  wined3d_gamma_ramp
 
struct  wined3d_line_pattern
 
struct  wined3d_rect_patch_info
 
struct  wined3d_tri_patch_info
 
struct  wined3d_adapter_identifier
 
struct  wined3d_swapchain_desc
 
struct  wined3d_resource_desc
 
struct  wined3d_sub_resource_desc
 
struct  wined3d_clip_status
 
struct  wined3d_vertex_element
 
struct  wined3d_device_creation_parameters
 
struct  wined3d_raster_status
 
struct  wined3d_map_desc
 
struct  wined3d_map_info
 
struct  wined3d_sub_resource_data
 
struct  wined3d_box
 
struct  wined3d_vertex_shader_caps
 
struct  wined3d_pixel_shader_caps
 
struct  wined3d_ddraw_caps
 
struct  _WINED3DCAPS
 
struct  wined3d_color_key
 
struct  wined3d_blt_fx
 
struct  wined3d_buffer_desc
 
struct  wined3d_blend_state_desc
 
struct  wined3d_rasterizer_state_desc
 
struct  wined3d_sampler_desc
 
struct  wined3d_shader_signature_element
 
struct  wined3d_shader_signature
 
struct  wined3d_shader_desc
 
struct  wined3d_stream_output_element
 
struct  wined3d_stream_output_desc
 
struct  wined3d_view_desc
 
struct  wined3d_output_desc
 
struct  wined3d_parent_ops
 
struct  wined3d_device_parent
 
struct  wined3d_device_parent_ops
 
struct  wined3d_private_store
 
struct  wined3d_private_data
 

Macros

#define WINED3D_OK   S_OK
 
#define _FACWINED3D   0x876
 
#define MAKE_WINED3DSTATUS(code)   MAKE_HRESULT(0, _FACWINED3D, code)
 
#define WINED3DOK_NOMIPGEN   MAKE_WINED3DSTATUS(2159)
 
#define MAKE_WINED3DHRESULT(code)   MAKE_HRESULT(1, _FACWINED3D, code)
 
#define WINED3DERR_CONFLICTINGRENDERSTATE   MAKE_WINED3DHRESULT(2081)
 
#define WINED3DERR_UNSUPPORTEDTEXTUREFILTER   MAKE_WINED3DHRESULT(2082)
 
#define WINED3DERR_NOTAVAILABLE   MAKE_WINED3DHRESULT(2154)
 
#define WINED3DERR_OUTOFVIDEOMEMORY   MAKE_WINED3DHRESULT(380)
 
#define WINED3DERR_INVALIDCALL   MAKE_WINED3DHRESULT(2156)
 
#define WINEDDERR_NOTAOVERLAYSURFACE   MAKE_WINED3DHRESULT(580)
 
#define WINEDDERR_NOTLOCKED   MAKE_WINED3DHRESULT(584)
 
#define WINEDDERR_SURFACEBUSY   MAKE_WINED3DHRESULT(430)
 
#define WINEDDERR_INVALIDRECT   MAKE_WINED3DHRESULT(150)
 
#define WINEDDERR_OVERLAYNOTVISIBLE   MAKE_WINED3DHRESULT(577)
 
#define WINED3D_RESOURCE_ACCESS_GPU   0x1u
 
#define WINED3D_RESOURCE_ACCESS_CPU   0x2u
 
#define WINED3D_RESOURCE_ACCESS_MAP_R   0x4u
 
#define WINED3D_RESOURCE_ACCESS_MAP_W   0x8u
 
#define WINEMAKEFOURCC(ch0, ch1, ch2, ch3)
 
#define WINEHIGHEST_RENDER_STATE   WINED3D_RS_COLORWRITEENABLE7
 
#define WINED3D_HIGHEST_SAMPLER_STATE   WINED3D_SAMP_DMAP_OFFSET
 
#define WINED3D_HIGHEST_TEXTURE_STATE   WINED3D_TSS_CONSTANT
 
#define WINED3D_TS_WORLD_MATRIX(index)   (enum wined3d_transform_state)(index + 256)
 
#define WINED3DISSUE_BEGIN   (1u << 1)
 
#define WINED3DISSUE_END   (1u << 0)
 
#define WINED3DGETDATA_FLUSH   (1u << 0)
 
#define WINED3DCOLORWRITEENABLE_RED   (1u << 0)
 
#define WINED3DCOLORWRITEENABLE_GREEN   (1u << 1)
 
#define WINED3DCOLORWRITEENABLE_BLUE   (1u << 2)
 
#define WINED3DCOLORWRITEENABLE_ALPHA   (1u << 3)
 
#define WINED3DADAPTER_DEFAULT   0
 
#define WINED3DENUM_NO_WHQL_LEVEL   2
 
#define WINED3DTSS_TCI_PASSTHRU   0x00000
 
#define WINED3DTSS_TCI_CAMERASPACENORMAL   0x10000
 
#define WINED3DTSS_TCI_CAMERASPACEPOSITION   0x20000
 
#define WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR   0x30000
 
#define WINED3DTSS_TCI_SPHEREMAP   0x40000
 
#define WINED3DTA_SELECTMASK   0x0000000f
 
#define WINED3DTA_DIFFUSE   0x00000000
 
#define WINED3DTA_CURRENT   0x00000001
 
#define WINED3DTA_TEXTURE   0x00000002
 
#define WINED3DTA_TFACTOR   0x00000003
 
#define WINED3DTA_SPECULAR   0x00000004
 
#define WINED3DTA_TEMP   0x00000005
 
#define WINED3DTA_CONSTANT   0x00000006
 
#define WINED3DTA_COMPLEMENT   0x00000010
 
#define WINED3DTA_ALPHAREPLICATE   0x00000020
 
#define WINED3D_SWAPCHAIN_LOCKABLE_BACKBUFFER   0x00000001u
 
#define WINED3D_SWAPCHAIN_DISCARD_DEPTHSTENCIL   0x00000002u
 
#define WINED3D_SWAPCHAIN_DEVICECLIP   0x00000004u
 
#define WINED3D_SWAPCHAIN_VIDEO   0x00000010u
 
#define WINED3D_SWAPCHAIN_NOAUTOROTATE   0x00000020u
 
#define WINED3D_SWAPCHAIN_UNPRUNEDMODE   0x00000040u
 
#define WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH   0x00001000u
 
#define WINED3D_SWAPCHAIN_USE_CLOSEST_MATCHING_MODE   0x00002000u
 
#define WINED3D_SWAPCHAIN_RESTORE_WINDOW_RECT   0x00004000u
 
#define WINED3D_SWAPCHAIN_GDI_COMPATIBLE   0x00008000u
 
#define WINED3DDP_MAXTEXCOORD   8
 
#define WINED3D_BIND_VERTEX_BUFFER   0x00000001
 
#define WINED3D_BIND_INDEX_BUFFER   0x00000002
 
#define WINED3D_BIND_CONSTANT_BUFFER   0x00000004
 
#define WINED3D_BIND_SHADER_RESOURCE   0x00000008
 
#define WINED3D_BIND_STREAM_OUTPUT   0x00000010
 
#define WINED3D_BIND_RENDER_TARGET   0x00000020
 
#define WINED3D_BIND_DEPTH_STENCIL   0x00000040
 
#define WINED3D_BIND_UNORDERED_ACCESS   0x00000080
 
#define WINED3DUSAGE_RENDERTARGET   0x00000001
 
#define WINED3DUSAGE_DEPTHSTENCIL   0x00000002
 
#define WINED3DUSAGE_WRITEONLY   0x00000008
 
#define WINED3DUSAGE_SOFTWAREPROCESSING   0x00000010
 
#define WINED3DUSAGE_DONOTCLIP   0x00000020
 
#define WINED3DUSAGE_POINTS   0x00000040
 
#define WINED3DUSAGE_RTPATCHES   0x00000080
 
#define WINED3DUSAGE_NPATCHES   0x00000100
 
#define WINED3DUSAGE_DYNAMIC   0x00000200
 
#define WINED3DUSAGE_RESTRICTED_CONTENT   0x00000800
 
#define WINED3DUSAGE_RESTRICT_SHARED_RESOURCE_DRIVER   0x00001000
 
#define WINED3DUSAGE_RESTRICT_SHARED_RESOURCE   0x00002000
 
#define WINED3DUSAGE_DMAP   0x00004000
 
#define WINED3DUSAGE_TEXTAPI   0x10000000
 
#define WINED3DUSAGE_MASK   0x10007bff
 
#define WINED3DUSAGE_SCRATCH   0x00200000
 
#define WINED3DUSAGE_PRIVATE   0x00400000
 
#define WINED3DUSAGE_LEGACY_CUBEMAP   0x00800000
 
#define WINED3DUSAGE_TEXTURE   0x01000000
 
#define WINED3DUSAGE_OWNDC   0x02000000
 
#define WINED3DUSAGE_STATICDECL   0x04000000
 
#define WINED3DUSAGE_OVERLAY   0x08000000
 
#define WINED3DUSAGE_QUERY_GENMIPMAP   0x00000400
 
#define WINED3DUSAGE_QUERY_LEGACYBUMPMAP   0x00008000
 
#define WINED3DUSAGE_QUERY_FILTER   0x00020000
 
#define WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING   0x00080000
 
#define WINED3DUSAGE_QUERY_SRGBREAD   0x00010000
 
#define WINED3DUSAGE_QUERY_SRGBWRITE   0x00040000
 
#define WINED3DUSAGE_QUERY_VERTEXTEXTURE   0x00100000
 
#define WINED3DUSAGE_QUERY_WRAPANDMIP   0x00200000
 
#define WINED3DUSAGE_QUERY_MASK   0x003f8400
 
#define WINED3D_MAP_NOSYSLOCK   0x00000800
 
#define WINED3D_MAP_NOOVERWRITE   0x00001000
 
#define WINED3D_MAP_DISCARD   0x00002000
 
#define WINED3D_MAP_DONOTWAIT   0x00004000
 
#define WINED3D_MAP_NO_DIRTY_UPDATE   0x00008000
 
#define WINED3D_MAP_WRITE   0x40000000
 
#define WINED3D_MAP_READ   0x80000000
 
#define WINED3DPRESENT_RATE_DEFAULT   0x00000000
 
#define WINED3DPRESENT_INTERVAL_DEFAULT   0x00000000
 
#define WINED3DPRESENT_INTERVAL_ONE   0x00000001
 
#define WINED3DPRESENT_INTERVAL_TWO   0x00000002
 
#define WINED3DPRESENT_INTERVAL_THREE   0x00000004
 
#define WINED3DPRESENT_INTERVAL_FOUR   0x00000008
 
#define WINED3DPRESENT_INTERVAL_IMMEDIATE   0x80000000
 
#define WINED3DCLIPPLANE0   (1u << 0)
 
#define WINED3DCLIPPLANE1   (1u << 1)
 
#define WINED3DCLIPPLANE2   (1u << 2)
 
#define WINED3DCLIPPLANE3   (1u << 3)
 
#define WINED3DCLIPPLANE4   (1u << 4)
 
#define WINED3DCLIPPLANE5   (1u << 5)
 
#define WINED3DFVF_RESERVED0   0x0001
 
#define WINED3DFVF_POSITION_MASK   0x400e
 
#define WINED3DFVF_XYZ   0x0002
 
#define WINED3DFVF_XYZRHW   0x0004
 
#define WINED3DFVF_XYZB1   0x0006
 
#define WINED3DFVF_XYZB2   0x0008
 
#define WINED3DFVF_XYZB3   0x000a
 
#define WINED3DFVF_XYZB4   0x000c
 
#define WINED3DFVF_XYZB5   0x000e
 
#define WINED3DFVF_XYZW   0x4002
 
#define WINED3DFVF_NORMAL   0x0010
 
#define WINED3DFVF_PSIZE   0x0020
 
#define WINED3DFVF_DIFFUSE   0x0040
 
#define WINED3DFVF_SPECULAR   0x0080
 
#define WINED3DFVF_TEXCOUNT_MASK   0x0f00
 
#define WINED3DFVF_TEXCOUNT_SHIFT   8
 
#define WINED3DFVF_TEX0   0x0000
 
#define WINED3DFVF_TEX1   0x0100
 
#define WINED3DFVF_TEX2   0x0200
 
#define WINED3DFVF_TEX3   0x0300
 
#define WINED3DFVF_TEX4   0x0400
 
#define WINED3DFVF_TEX5   0x0500
 
#define WINED3DFVF_TEX6   0x0600
 
#define WINED3DFVF_TEX7   0x0700
 
#define WINED3DFVF_TEX8   0x0800
 
#define WINED3DFVF_LASTBETA_UBYTE4   0x1000
 
#define WINED3DFVF_LASTBETA_D3DCOLOR   0x8000
 
#define WINED3DFVF_RESERVED2   0x6000
 
#define WINED3DFVF_TEXTUREFORMAT1   3u
 
#define WINED3DFVF_TEXTUREFORMAT2   0u
 
#define WINED3DFVF_TEXTUREFORMAT3   1u
 
#define WINED3DFVF_TEXTUREFORMAT4   2u
 
#define WINED3DFVF_TEXCOORDSIZE1(idx)   (WINED3DFVF_TEXTUREFORMAT1 << (idx * 2 + 16))
 
#define WINED3DFVF_TEXCOORDSIZE2(idx)   (WINED3DFVF_TEXTUREFORMAT2 << (idx * 2 + 16))
 
#define WINED3DFVF_TEXCOORDSIZE3(idx)   (WINED3DFVF_TEXTUREFORMAT3 << (idx * 2 + 16))
 
#define WINED3DFVF_TEXCOORDSIZE4(idx)   (WINED3DFVF_TEXTUREFORMAT4 << (idx * 2 + 16))
 
#define WINED3DCLEAR_TARGET   0x00000001
 
#define WINED3DCLEAR_ZBUFFER   0x00000002
 
#define WINED3DCLEAR_STENCIL   0x00000004
 
#define WINED3DSTREAMSOURCE_INDEXEDDATA   (1u << 30)
 
#define WINED3DSTREAMSOURCE_INSTANCEDATA   (2u << 30)
 
#define WINED3DSPD_IUNKNOWN   0x00000001
 
#define WINED3DCREATE_FPU_PRESERVE   0x00000002
 
#define WINED3DCREATE_PUREDEVICE   0x00000010
 
#define WINED3DCREATE_SOFTWARE_VERTEXPROCESSING   0x00000020
 
#define WINED3DCREATE_HARDWARE_VERTEXPROCESSING   0x00000040
 
#define WINED3DCREATE_MIXED_VERTEXPROCESSING   0x00000080
 
#define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT   0x00000100
 
#define WINED3DCREATE_ADAPTERGROUP_DEVICE   0x00000200
 
#define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT_EX   0x00000400
 
#define WINED3DCREATE_NOWINDOWCHANGES   0x00000800
 
#define WINED3DCREATE_DISABLE_PSGP_THREADING   0x00002000
 
#define WINED3DCREATE_ENABLE_PRESENTSTATS   0x00004000
 
#define WINED3DCREATE_DISABLE_PRINTSCREEN   0x00008000
 
#define WINED3DCREATE_SCREENSAVER   0x10000000
 
#define WINED3DDMAPSAMPLER   0x100
 
#define WINED3DVERTEXTEXTURESAMPLER0   (WINED3DDMAPSAMPLER + 1)
 
#define WINED3DVERTEXTEXTURESAMPLER1   (WINED3DDMAPSAMPLER + 2)
 
#define WINED3DVERTEXTEXTURESAMPLER2   (WINED3DDMAPSAMPLER + 3)
 
#define WINED3DVERTEXTEXTURESAMPLER3   (WINED3DDMAPSAMPLER + 4)
 
#define WINED3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD   0x00000020
 
#define WINED3DCAPS3_LINEAR_TO_SRGB_PRESENTATION   0x00000080
 
#define WINED3DCAPS3_COPY_TO_VIDMEM   0x00000100
 
#define WINED3DCAPS3_COPY_TO_SYSTEMMEM   0x00000200
 
#define WINED3DCAPS3_RESERVED   0x8000001f
 
#define WINED3DDEVCAPS2_STREAMOFFSET   0x00000001
 
#define WINED3DDEVCAPS2_DMAPNPATCH   0x00000002
 
#define WINED3DDEVCAPS2_ADAPTIVETESSRTPATCH   0x00000004
 
#define WINED3DDEVCAPS2_ADAPTIVETESSNPATCH   0x00000008
 
#define WINED3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES   0x00000010
 
#define WINED3DDEVCAPS2_PRESAMPLEDDMAPNPATCH   0x00000020
 
#define WINED3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET   0x00000040
 
#define WINED3DDTCAPS_UBYTE4   0x00000001
 
#define WINED3DDTCAPS_UBYTE4N   0x00000002
 
#define WINED3DDTCAPS_SHORT2N   0x00000004
 
#define WINED3DDTCAPS_SHORT4N   0x00000008
 
#define WINED3DDTCAPS_USHORT2N   0x00000010
 
#define WINED3DDTCAPS_USHORT4N   0x00000020
 
#define WINED3DDTCAPS_UDEC3   0x00000040
 
#define WINED3DDTCAPS_DEC3N   0x00000080
 
#define WINED3DDTCAPS_FLOAT16_2   0x00000100
 
#define WINED3DDTCAPS_FLOAT16_4   0x00000200
 
#define WINED3DFVFCAPS_TEXCOORDCOUNTMASK   0x0000ffff
 
#define WINED3DFVFCAPS_DONOTSTRIPELEMENTS   0x00080000
 
#define WINED3DFVFCAPS_PSIZE   0x00100000
 
#define WINED3DLINECAPS_TEXTURE   0x00000001
 
#define WINED3DLINECAPS_ZTEST   0x00000002
 
#define WINED3DLINECAPS_BLEND   0x00000004
 
#define WINED3DLINECAPS_ALPHACMP   0x00000008
 
#define WINED3DLINECAPS_FOG   0x00000010
 
#define WINED3DLINECAPS_ANTIALIAS   0x00000020
 
#define WINED3DMAX30SHADERINSTRUCTIONS   32768
 
#define WINED3DMIN30SHADERINSTRUCTIONS   512
 
#define WINED3DPBLENDCAPS_ZERO   0x00000001
 
#define WINED3DPBLENDCAPS_ONE   0x00000002
 
#define WINED3DPBLENDCAPS_SRCCOLOR   0x00000004
 
#define WINED3DPBLENDCAPS_INVSRCCOLOR   0x00000008
 
#define WINED3DPBLENDCAPS_SRCALPHA   0x00000010
 
#define WINED3DPBLENDCAPS_INVSRCALPHA   0x00000020
 
#define WINED3DPBLENDCAPS_DESTALPHA   0x00000040
 
#define WINED3DPBLENDCAPS_INVDESTALPHA   0x00000080
 
#define WINED3DPBLENDCAPS_DESTCOLOR   0x00000100
 
#define WINED3DPBLENDCAPS_INVDESTCOLOR   0x00000200
 
#define WINED3DPBLENDCAPS_SRCALPHASAT   0x00000400
 
#define WINED3DPBLENDCAPS_BOTHSRCALPHA   0x00000800
 
#define WINED3DPBLENDCAPS_BOTHINVSRCALPHA   0x00001000
 
#define WINED3DPBLENDCAPS_BLENDFACTOR   0x00002000
 
#define WINED3DPCMPCAPS_NEVER   0x00000001
 
#define WINED3DPCMPCAPS_LESS   0x00000002
 
#define WINED3DPCMPCAPS_EQUAL   0x00000004
 
#define WINED3DPCMPCAPS_LESSEQUAL   0x00000008
 
#define WINED3DPCMPCAPS_GREATER   0x00000010
 
#define WINED3DPCMPCAPS_NOTEQUAL   0x00000020
 
#define WINED3DPCMPCAPS_GREATEREQUAL   0x00000040
 
#define WINED3DPCMPCAPS_ALWAYS   0x00000080
 
#define WINED3DPMISCCAPS_MASKZ   0x00000002
 
#define WINED3DPMISCCAPS_LINEPATTERNREP   0x00000004
 
#define WINED3DPMISCCAPS_CULLNONE   0x00000010
 
#define WINED3DPMISCCAPS_CULLCW   0x00000020
 
#define WINED3DPMISCCAPS_CULLCCW   0x00000040
 
#define WINED3DPMISCCAPS_COLORWRITEENABLE   0x00000080
 
#define WINED3DPMISCCAPS_CLIPPLANESCALEDPOINTS   0x00000100
 
#define WINED3DPMISCCAPS_CLIPTLVERTS   0x00000200
 
#define WINED3DPMISCCAPS_TSSARGTEMP   0x00000400
 
#define WINED3DPMISCCAPS_BLENDOP   0x00000800
 
#define WINED3DPMISCCAPS_NULLREFERENCE   0x00001000
 
#define WINED3DPMISCCAPS_INDEPENDENTWRITEMASKS   0x00004000
 
#define WINED3DPMISCCAPS_PERSTAGECONSTANT   0x00008000
 
#define WINED3DPMISCCAPS_FOGANDSPECULARALPHA   0x00010000
 
#define WINED3DPMISCCAPS_SEPARATEALPHABLEND   0x00020000
 
#define WINED3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS   0x00040000
 
#define WINED3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING   0x00080000
 
#define WINED3DPMISCCAPS_FOGVERTEXCLAMPED   0x00100000
 
#define WINED3DPMISCCAPS_POSTBLENDSRGBCONVERT   0x00200000
 
#define WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH   24
 
#define WINED3DPS20_MIN_DYNAMICFLOWCONTROLDEPTH   0
 
#define WINED3DPS20_MAX_NUMTEMPS   32
 
#define WINED3DPS20_MIN_NUMTEMPS   12
 
#define WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH   4
 
#define WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH   0
 
#define WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS   512
 
#define WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS   96
 
#define WINED3DPS20CAPS_ARBITRARYSWIZZLE   0x00000001
 
#define WINED3DPS20CAPS_GRADIENTINSTRUCTIONS   0x00000002
 
#define WINED3DPS20CAPS_PREDICATION   0x00000004
 
#define WINED3DPS20CAPS_NODEPENDENTREADLIMIT   0x00000008
 
#define WINED3DPS20CAPS_NOTEXINSTRUCTIONLIMIT   0x00000010
 
#define WINED3DPTADDRESSCAPS_WRAP   0x00000001
 
#define WINED3DPTADDRESSCAPS_MIRROR   0x00000002
 
#define WINED3DPTADDRESSCAPS_CLAMP   0x00000004
 
#define WINED3DPTADDRESSCAPS_BORDER   0x00000008
 
#define WINED3DPTADDRESSCAPS_INDEPENDENTUV   0x00000010
 
#define WINED3DPTADDRESSCAPS_MIRRORONCE   0x00000020
 
#define WINED3DSTENCILCAPS_KEEP   0x00000001
 
#define WINED3DSTENCILCAPS_ZERO   0x00000002
 
#define WINED3DSTENCILCAPS_REPLACE   0x00000004
 
#define WINED3DSTENCILCAPS_INCRSAT   0x00000008
 
#define WINED3DSTENCILCAPS_DECRSAT   0x00000010
 
#define WINED3DSTENCILCAPS_INVERT   0x00000020
 
#define WINED3DSTENCILCAPS_INCR   0x00000040
 
#define WINED3DSTENCILCAPS_DECR   0x00000080
 
#define WINED3DSTENCILCAPS_TWOSIDED   0x00000100
 
#define WINED3DTEXOPCAPS_DISABLE   0x00000001
 
#define WINED3DTEXOPCAPS_SELECTARG1   0x00000002
 
#define WINED3DTEXOPCAPS_SELECTARG2   0x00000004
 
#define WINED3DTEXOPCAPS_MODULATE   0x00000008
 
#define WINED3DTEXOPCAPS_MODULATE2X   0x00000010
 
#define WINED3DTEXOPCAPS_MODULATE4X   0x00000020
 
#define WINED3DTEXOPCAPS_ADD   0x00000040
 
#define WINED3DTEXOPCAPS_ADDSIGNED   0x00000080
 
#define WINED3DTEXOPCAPS_ADDSIGNED2X   0x00000100
 
#define WINED3DTEXOPCAPS_SUBTRACT   0x00000200
 
#define WINED3DTEXOPCAPS_ADDSMOOTH   0x00000400
 
#define WINED3DTEXOPCAPS_BLENDDIFFUSEALPHA   0x00000800
 
#define WINED3DTEXOPCAPS_BLENDTEXTUREALPHA   0x00001000
 
#define WINED3DTEXOPCAPS_BLENDFACTORALPHA   0x00002000
 
#define WINED3DTEXOPCAPS_BLENDTEXTUREALPHAPM   0x00004000
 
#define WINED3DTEXOPCAPS_BLENDCURRENTALPHA   0x00008000
 
#define WINED3DTEXOPCAPS_PREMODULATE   0x00010000
 
#define WINED3DTEXOPCAPS_MODULATEALPHA_ADDCOLOR   0x00020000
 
#define WINED3DTEXOPCAPS_MODULATECOLOR_ADDALPHA   0x00040000
 
#define WINED3DTEXOPCAPS_MODULATEINVALPHA_ADDCOLOR   0x00080000
 
#define WINED3DTEXOPCAPS_MODULATEINVCOLOR_ADDALPHA   0x00100000
 
#define WINED3DTEXOPCAPS_BUMPENVMAP   0x00200000
 
#define WINED3DTEXOPCAPS_BUMPENVMAPLUMINANCE   0x00400000
 
#define WINED3DTEXOPCAPS_DOTPRODUCT3   0x00800000
 
#define WINED3DTEXOPCAPS_MULTIPLYADD   0x01000000
 
#define WINED3DTEXOPCAPS_LERP   0x02000000
 
#define WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH   24
 
#define WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH   0
 
#define WINED3DVS20_MAX_NUMTEMPS   32
 
#define WINED3DVS20_MIN_NUMTEMPS   12
 
#define WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH   4
 
#define WINED3DVS20_MIN_STATICFLOWCONTROLDEPTH   1
 
#define WINED3DVS20CAPS_PREDICATION   0x00000001
 
#define WINED3DCAPS2_NO2DDURING3DSCENE   0x00000002
 
#define WINED3DCAPS2_FULLSCREENGAMMA   0x00020000
 
#define WINED3DCAPS2_CANRENDERWINDOWED   0x00080000
 
#define WINED3DCAPS2_CANCALIBRATEGAMMA   0x00100000
 
#define WINED3DCAPS2_RESERVED   0x02000000
 
#define WINED3DCAPS2_CANMANAGERESOURCE   0x10000000
 
#define WINED3DCAPS2_DYNAMICTEXTURES   0x20000000
 
#define WINED3DCAPS2_CANGENMIPMAP   0x40000000
 
#define WINED3DPRASTERCAPS_DITHER   0x00000001
 
#define WINED3DPRASTERCAPS_ROP2   0x00000002
 
#define WINED3DPRASTERCAPS_XOR   0x00000004
 
#define WINED3DPRASTERCAPS_PAT   0x00000008
 
#define WINED3DPRASTERCAPS_ZTEST   0x00000010
 
#define WINED3DPRASTERCAPS_SUBPIXEL   0x00000020
 
#define WINED3DPRASTERCAPS_SUBPIXELX   0x00000040
 
#define WINED3DPRASTERCAPS_FOGVERTEX   0x00000080
 
#define WINED3DPRASTERCAPS_FOGTABLE   0x00000100
 
#define WINED3DPRASTERCAPS_STIPPLE   0x00000200
 
#define WINED3DPRASTERCAPS_ANTIALIASSORTDEPENDENT   0x00000400
 
#define WINED3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT   0x00000800
 
#define WINED3DPRASTERCAPS_ANTIALIASEDGES   0x00001000
 
#define WINED3DPRASTERCAPS_MIPMAPLODBIAS   0x00002000
 
#define WINED3DPRASTERCAPS_ZBIAS   0x00004000
 
#define WINED3DPRASTERCAPS_ZBUFFERLESSHSR   0x00008000
 
#define WINED3DPRASTERCAPS_FOGRANGE   0x00010000
 
#define WINED3DPRASTERCAPS_ANISOTROPY   0x00020000
 
#define WINED3DPRASTERCAPS_WBUFFER   0x00040000
 
#define WINED3DPRASTERCAPS_TRANSLUCENTSORTINDEPENDENT   0x00080000
 
#define WINED3DPRASTERCAPS_WFOG   0x00100000
 
#define WINED3DPRASTERCAPS_ZFOG   0x00200000
 
#define WINED3DPRASTERCAPS_COLORPERSPECTIVE   0x00400000
 
#define WINED3DPRASTERCAPS_SCISSORTEST   0x01000000
 
#define WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS   0x02000000
 
#define WINED3DPRASTERCAPS_DEPTHBIAS   0x04000000
 
#define WINED3DPRASTERCAPS_MULTISAMPLE_TOGGLE   0x08000000
 
#define WINED3DPSHADECAPS_COLORFLATMONO   0x00000001
 
#define WINED3DPSHADECAPS_COLORFLATRGB   0x00000002
 
#define WINED3DPSHADECAPS_COLORGOURAUDMONO   0x00000004
 
#define WINED3DPSHADECAPS_COLORGOURAUDRGB   0x00000008
 
#define WINED3DPSHADECAPS_COLORPHONGMONO   0x00000010
 
#define WINED3DPSHADECAPS_COLORPHONGRGB   0x00000020
 
#define WINED3DPSHADECAPS_SPECULARFLATMONO   0x00000040
 
#define WINED3DPSHADECAPS_SPECULARFLATRGB   0x00000080
 
#define WINED3DPSHADECAPS_SPECULARGOURAUDMONO   0x00000100
 
#define WINED3DPSHADECAPS_SPECULARGOURAUDRGB   0x00000200
 
#define WINED3DPSHADECAPS_SPECULARPHONGMONO   0x00000400
 
#define WINED3DPSHADECAPS_SPECULARPHONGRGB   0x00000800
 
#define WINED3DPSHADECAPS_ALPHAFLATBLEND   0x00001000
 
#define WINED3DPSHADECAPS_ALPHAFLATSTIPPLED   0x00002000
 
#define WINED3DPSHADECAPS_ALPHAGOURAUDBLEND   0x00004000
 
#define WINED3DPSHADECAPS_ALPHAGOURAUDSTIPPLED   0x00008000
 
#define WINED3DPSHADECAPS_ALPHAPHONGBLEND   0x00010000
 
#define WINED3DPSHADECAPS_ALPHAPHONGSTIPPLED   0x00020000
 
#define WINED3DPSHADECAPS_FOGFLAT   0x00040000
 
#define WINED3DPSHADECAPS_FOGGOURAUD   0x00080000
 
#define WINED3DPSHADECAPS_FOGPHONG   0x00100000
 
#define WINED3DPTEXTURECAPS_PERSPECTIVE   0x00000001
 
#define WINED3DPTEXTURECAPS_POW2   0x00000002
 
#define WINED3DPTEXTURECAPS_ALPHA   0x00000004
 
#define WINED3DPTEXTURECAPS_TRANSPARENCY   0x00000008
 
#define WINED3DPTEXTURECAPS_BORDER   0x00000010
 
#define WINED3DPTEXTURECAPS_SQUAREONLY   0x00000020
 
#define WINED3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE   0x00000040
 
#define WINED3DPTEXTURECAPS_ALPHAPALETTE   0x00000080
 
#define WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL   0x00000100
 
#define WINED3DPTEXTURECAPS_PROJECTED   0x00000400
 
#define WINED3DPTEXTURECAPS_CUBEMAP   0x00000800
 
#define WINED3DPTEXTURECAPS_COLORKEYBLEND   0x00001000
 
#define WINED3DPTEXTURECAPS_VOLUMEMAP   0x00002000
 
#define WINED3DPTEXTURECAPS_MIPMAP   0x00004000
 
#define WINED3DPTEXTURECAPS_MIPVOLUMEMAP   0x00008000
 
#define WINED3DPTEXTURECAPS_MIPCUBEMAP   0x00010000
 
#define WINED3DPTEXTURECAPS_CUBEMAP_POW2   0x00020000
 
#define WINED3DPTEXTURECAPS_VOLUMEMAP_POW2   0x00040000
 
#define WINED3DPTEXTURECAPS_NOPROJECTEDBUMPENV   0x00200000
 
#define WINED3DPTFILTERCAPS_NEAREST   0x00000001
 
#define WINED3DPTFILTERCAPS_LINEAR   0x00000002
 
#define WINED3DPTFILTERCAPS_MIPNEAREST   0x00000004
 
#define WINED3DPTFILTERCAPS_MIPLINEAR   0x00000008
 
#define WINED3DPTFILTERCAPS_LINEARMIPNEAREST   0x00000010
 
#define WINED3DPTFILTERCAPS_LINEARMIPLINEAR   0x00000020
 
#define WINED3DPTFILTERCAPS_MINFPOINT   0x00000100
 
#define WINED3DPTFILTERCAPS_MINFLINEAR   0x00000200
 
#define WINED3DPTFILTERCAPS_MINFANISOTROPIC   0x00000400
 
#define WINED3DPTFILTERCAPS_MIPFPOINT   0x00010000
 
#define WINED3DPTFILTERCAPS_MIPFLINEAR   0x00020000
 
#define WINED3DPTFILTERCAPS_MAGFPOINT   0x01000000
 
#define WINED3DPTFILTERCAPS_MAGFLINEAR   0x02000000
 
#define WINED3DPTFILTERCAPS_MAGFANISOTROPIC   0x04000000
 
#define WINED3DPTFILTERCAPS_MAGFPYRAMIDALQUAD   0x08000000
 
#define WINED3DPTFILTERCAPS_MAGFGAUSSIANQUAD   0x10000000
 
#define WINED3DVTXPCAPS_TEXGEN   0x00000001
 
#define WINED3DVTXPCAPS_MATERIALSOURCE7   0x00000002
 
#define WINED3DVTXPCAPS_VERTEXFOG   0x00000004
 
#define WINED3DVTXPCAPS_DIRECTIONALLIGHTS   0x00000008
 
#define WINED3DVTXPCAPS_POSITIONALLIGHTS   0x00000010
 
#define WINED3DVTXPCAPS_LOCALVIEWER   0x00000020
 
#define WINED3DVTXPCAPS_TWEENING   0x00000040
 
#define WINED3DVTXPCAPS_TEXGEN_SPHEREMAP   0x00000100
 
#define WINED3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER   0x00000200
 
#define WINED3DCURSORCAPS_COLOR   0x00000001
 
#define WINED3DCURSORCAPS_LOWRES   0x00000002
 
#define WINED3DDEVCAPS_FLOATTLVERTEX   0x00000001
 
#define WINED3DDEVCAPS_SORTINCREASINGZ   0x00000002
 
#define WINED3DDEVCAPS_SORTDECREASINGZ   0X00000004
 
#define WINED3DDEVCAPS_SORTEXACT   0x00000008
 
#define WINED3DDEVCAPS_EXECUTESYSTEMMEMORY   0x00000010
 
#define WINED3DDEVCAPS_EXECUTEVIDEOMEMORY   0x00000020
 
#define WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY   0x00000040
 
#define WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY   0x00000080
 
#define WINED3DDEVCAPS_TEXTURESYSTEMMEMORY   0x00000100
 
#define WINED3DDEVCAPS_TEXTUREVIDEOMEMORY   0x00000200
 
#define WINED3DDEVCAPS_DRAWPRIMTLVERTEX   0x00000400
 
#define WINED3DDEVCAPS_CANRENDERAFTERFLIP   0x00000800
 
#define WINED3DDEVCAPS_TEXTURENONLOCALVIDMEM   0x00001000
 
#define WINED3DDEVCAPS_DRAWPRIMITIVES2   0x00002000
 
#define WINED3DDEVCAPS_SEPARATETEXTUREMEMORIES   0x00004000
 
#define WINED3DDEVCAPS_DRAWPRIMITIVES2EX   0x00008000
 
#define WINED3DDEVCAPS_HWTRANSFORMANDLIGHT   0x00010000
 
#define WINED3DDEVCAPS_CANBLTSYSTONONLOCAL   0x00020000
 
#define WINED3DDEVCAPS_HWRASTERIZATION   0x00080000
 
#define WINED3DDEVCAPS_PUREDEVICE   0x00100000
 
#define WINED3DDEVCAPS_QUINTICRTPATCHES   0x00200000
 
#define WINED3DDEVCAPS_RTPATCHES   0x00400000
 
#define WINED3DDEVCAPS_RTPATCHHANDLEZERO   0x00800000
 
#define WINED3DDEVCAPS_NPATCHES   0x01000000
 
#define WINED3D_LEGACY_DEPTH_BIAS   0x00000001
 
#define WINED3D_NO3D   0x00000002
 
#define WINED3D_VIDMEM_ACCOUNTING   0x00000004
 
#define WINED3D_PRESENT_CONVERSION   0x00000008
 
#define WINED3D_RESTORE_MODE_ON_ACTIVATE   0x00000010
 
#define WINED3D_FOCUS_MESSAGES   0x00000020
 
#define WINED3D_HANDLE_RESTORE   0x00000040
 
#define WINED3D_PIXEL_CENTER_INTEGER   0x00000080
 
#define WINED3D_LEGACY_FFP_LIGHTING   0x00000100
 
#define WINED3D_SRGB_READ_WRITE_CONTROL   0x00000200
 
#define WINED3D_LEGACY_UNBOUND_RESOURCE_COLOR   0x00000400
 
#define WINED3D_NO_PRIMITIVE_RESTART   0x00000800
 
#define WINED3D_LEGACY_CUBEMAP_FILTERING   0x00001000
 
#define WINED3D_NORMALIZED_DEPTH_BIAS   0x00002000
 
#define WINED3D_REQUEST_D3D10   0x00004000
 
#define WINED3D_LIMIT_VIEWPORT   0x00008000
 
#define WINED3D_RESZ_CODE   0x7fa05000
 
#define WINED3D_CKEY_DST_BLT   0x00000002
 
#define WINED3D_CKEY_DST_OVERLAY   0x00000004
 
#define WINED3D_CKEY_SRC_BLT   0x00000008
 
#define WINED3D_CKEY_SRC_OVERLAY   0x00000010
 
#define WINEDDBLTFX_ARITHSTRETCHY   0x00000001
 
#define WINEDDBLTFX_MIRRORLEFTRIGHT   0x00000002
 
#define WINEDDBLTFX_MIRRORUPDOWN   0x00000004
 
#define WINEDDBLTFX_NOTEARING   0x00000008
 
#define WINEDDBLTFX_ROTATE180   0x00000010
 
#define WINEDDBLTFX_ROTATE270   0x00000020
 
#define WINEDDBLTFX_ROTATE90   0x00000040
 
#define WINEDDBLTFX_ZBUFFERRANGE   0x00000080
 
#define WINEDDBLTFX_ZBUFFERBASEDEST   0x00000100
 
#define WINED3D_BLT_FX   0x00000800
 
#define WINED3D_BLT_DST_CKEY   0x00002000
 
#define WINED3D_BLT_DST_CKEY_OVERRIDE   0x00004000
 
#define WINED3D_BLT_SRC_CKEY   0x00008000
 
#define WINED3D_BLT_SRC_CKEY_OVERRIDE   0x00010000
 
#define WINED3D_BLT_WAIT   0x01000000
 
#define WINED3D_BLT_DO_NOT_WAIT   0x08000000
 
#define WINED3D_BLT_RAW   0x20000000
 
#define WINED3D_BLT_SYNCHRONOUS   0x40000000
 
#define WINED3D_BLT_ALPHA_TEST   0x80000000
 
#define WINED3D_BLT_MASK   0x0901e800
 
#define WINEDDGBS_CANBLT   0x00000001
 
#define WINEDDGBS_ISBLTDONE   0x00000002
 
#define WINEDDGFS_CANFLIP   0x00000001
 
#define WINEDDGFS_ISFLIPDONE   0x00000002
 
#define WINEDDFLIP_WAIT   0x00000001
 
#define WINEDDFLIP_EVEN   0x00000002 /* only valid for overlay */
 
#define WINEDDFLIP_ODD   0x00000004 /* only valid for overlay */
 
#define WINEDDFLIP_NOVSYNC   0x00000008
 
#define WINEDDFLIP_STEREO   0x00000010
 
#define WINEDDFLIP_DONOTWAIT   0x00000020
 
#define WINEDDFLIP_INTERVAL2   0x02000000
 
#define WINEDDFLIP_INTERVAL3   0x03000000
 
#define WINEDDFLIP_INTERVAL4   0x04000000
 
#define WINEDDOVER_ALPHADEST   0x00000001
 
#define WINEDDOVER_ALPHADESTCONSTOVERRIDE   0x00000002
 
#define WINEDDOVER_ALPHADESTNEG   0x00000004
 
#define WINEDDOVER_ALPHADESTSURFACEOVERRIDE   0x00000008
 
#define WINEDDOVER_ALPHAEDGEBLEND   0x00000010
 
#define WINEDDOVER_ALPHASRC   0x00000020
 
#define WINEDDOVER_ALPHASRCCONSTOVERRIDE   0x00000040
 
#define WINEDDOVER_ALPHASRCNEG   0x00000080
 
#define WINEDDOVER_ALPHASRCSURFACEOVERRIDE   0x00000100
 
#define WINEDDOVER_HIDE   0x00000200
 
#define WINEDDOVER_KEYDEST   0x00000400
 
#define WINEDDOVER_KEYDESTOVERRIDE   0x00000800
 
#define WINEDDOVER_KEYSRC   0x00001000
 
#define WINEDDOVER_KEYSRCOVERRIDE   0x00002000
 
#define WINEDDOVER_SHOW   0x00004000
 
#define WINEDDOVER_ADDDIRTYRECT   0x00008000
 
#define WINEDDOVER_REFRESHDIRTYRECTS   0x00010000
 
#define WINEDDOVER_REFRESHALL   0x00020000
 
#define WINEDDOVER_DDFX   0x00080000
 
#define WINEDDOVER_AUTOFLIP   0x00100000
 
#define WINEDDOVER_BOB   0x00200000
 
#define WINEDDOVER_OVERRIDEBOBWEAVE   0x00400000
 
#define WINEDDOVER_INTERLEAVED   0x00800000
 
#define WINEDDSCAPS_RESERVED1   0x00000001
 
#define WINEDDSCAPS_ALPHA   0x00000002
 
#define WINEDDSCAPS_BACKBUFFER   0x00000004
 
#define WINEDDSCAPS_COMPLEX   0x00000008
 
#define WINEDDSCAPS_FLIP   0x00000010
 
#define WINEDDSCAPS_FRONTBUFFER   0x00000020
 
#define WINEDDSCAPS_OFFSCREENPLAIN   0x00000040
 
#define WINEDDSCAPS_OVERLAY   0x00000080
 
#define WINEDDSCAPS_PALETTE   0x00000100
 
#define WINEDDSCAPS_PRIMARYSURFACE   0x00000200
 
#define WINEDDSCAPS_PRIMARYSURFACELEFT   0x00000400
 
#define WINEDDSCAPS_SYSTEMMEMORY   0x00000800
 
#define WINEDDSCAPS_TEXTURE   0x00001000
 
#define WINEDDSCAPS_3DDEVICE   0x00002000
 
#define WINEDDSCAPS_VIDEOMEMORY   0x00004000
 
#define WINEDDSCAPS_VISIBLE   0x00008000
 
#define WINEDDSCAPS_WRITEONLY   0x00010000
 
#define WINEDDSCAPS_ZBUFFER   0x00020000
 
#define WINEDDSCAPS_OWNDC   0x00040000
 
#define WINEDDSCAPS_LIVEVIDEO   0x00080000
 
#define WINEDDSCAPS_HWCODEC   0x00100000
 
#define WINEDDSCAPS_MODEX   0x00200000
 
#define WINEDDSCAPS_MIPMAP   0x00400000
 
#define WINEDDSCAPS_RESERVED2   0x00800000
 
#define WINEDDSCAPS_ALLOCONLOAD   0x04000000
 
#define WINEDDSCAPS_VIDEOPORT   0x08000000
 
#define WINEDDSCAPS_LOCALVIDMEM   0x10000000
 
#define WINEDDSCAPS_NONLOCALVIDMEM   0x20000000
 
#define WINEDDSCAPS_STANDARDVGAMODE   0x40000000
 
#define WINEDDSCAPS_OPTIMIZED   0x80000000
 
#define WINEDDCKEYCAPS_DESTBLT   0x00000001
 
#define WINEDDCKEYCAPS_DESTBLTCLRSPACE   0x00000002
 
#define WINEDDCKEYCAPS_DESTBLTCLRSPACEYUV   0x00000004
 
#define WINEDDCKEYCAPS_DESTBLTYUV   0x00000008
 
#define WINEDDCKEYCAPS_DESTOVERLAY   0x00000010
 
#define WINEDDCKEYCAPS_DESTOVERLAYCLRSPACE   0x00000020
 
#define WINEDDCKEYCAPS_DESTOVERLAYCLRSPACEYUV   0x00000040
 
#define WINEDDCKEYCAPS_DESTOVERLAYONEACTIVE   0x00000080
 
#define WINEDDCKEYCAPS_DESTOVERLAYYUV   0x00000100
 
#define WINEDDCKEYCAPS_SRCBLT   0x00000200
 
#define WINEDDCKEYCAPS_SRCBLTCLRSPACE   0x00000400
 
#define WINEDDCKEYCAPS_SRCBLTCLRSPACEYUV   0x00000800
 
#define WINEDDCKEYCAPS_SRCBLTYUV   0x00001000
 
#define WINEDDCKEYCAPS_SRCOVERLAY   0x00002000
 
#define WINEDDCKEYCAPS_SRCOVERLAYCLRSPACE   0x00004000
 
#define WINEDDCKEYCAPS_SRCOVERLAYCLRSPACEYUV   0x00008000
 
#define WINEDDCKEYCAPS_SRCOVERLAYONEACTIVE   0x00010000
 
#define WINEDDCKEYCAPS_SRCOVERLAYYUV   0x00020000
 
#define WINEDDCKEYCAPS_NOCOSTOVERLAY   0x00040000
 
#define WINEDDFXCAPS_BLTALPHA   0x00000001
 
#define WINEDDFXCAPS_OVERLAYALPHA   0x00000004
 
#define WINEDDFXCAPS_BLTARITHSTRETCHYN   0x00000010
 
#define WINEDDFXCAPS_BLTARITHSTRETCHY   0x00000020
 
#define WINEDDFXCAPS_BLTMIRRORLEFTRIGHT   0x00000040
 
#define WINEDDFXCAPS_BLTMIRRORUPDOWN   0x00000080
 
#define WINEDDFXCAPS_BLTROTATION   0x00000100
 
#define WINEDDFXCAPS_BLTROTATION90   0x00000200
 
#define WINEDDFXCAPS_BLTSHRINKX   0x00000400
 
#define WINEDDFXCAPS_BLTSHRINKXN   0x00000800
 
#define WINEDDFXCAPS_BLTSHRINKY   0x00001000
 
#define WINEDDFXCAPS_BLTSHRINKYN   0x00002000
 
#define WINEDDFXCAPS_BLTSTRETCHX   0x00004000
 
#define WINEDDFXCAPS_BLTSTRETCHXN   0x00008000
 
#define WINEDDFXCAPS_BLTSTRETCHY   0x00010000
 
#define WINEDDFXCAPS_BLTSTRETCHYN   0x00020000
 
#define WINEDDFXCAPS_OVERLAYARITHSTRETCHY   0x00040000
 
#define WINEDDFXCAPS_OVERLAYARITHSTRETCHYN   0x00000008
 
#define WINEDDFXCAPS_OVERLAYSHRINKX   0x00080000
 
#define WINEDDFXCAPS_OVERLAYSHRINKXN   0x00100000
 
#define WINEDDFXCAPS_OVERLAYSHRINKY   0x00200000
 
#define WINEDDFXCAPS_OVERLAYSHRINKYN   0x00400000
 
#define WINEDDFXCAPS_OVERLAYSTRETCHX   0x00800000
 
#define WINEDDFXCAPS_OVERLAYSTRETCHXN   0x01000000
 
#define WINEDDFXCAPS_OVERLAYSTRETCHY   0x02000000
 
#define WINEDDFXCAPS_OVERLAYSTRETCHYN   0x04000000
 
#define WINEDDFXCAPS_OVERLAYMIRRORLEFTRIGHT   0x08000000
 
#define WINEDDFXCAPS_OVERLAYMIRRORUPDOWN   0x10000000
 
#define WINEDDCAPS_3D   0x00000001
 
#define WINEDDCAPS_ALIGNBOUNDARYDEST   0x00000002
 
#define WINEDDCAPS_ALIGNSIZEDEST   0x00000004
 
#define WINEDDCAPS_ALIGNBOUNDARYSRC   0x00000008
 
#define WINEDDCAPS_ALIGNSIZESRC   0x00000010
 
#define WINEDDCAPS_ALIGNSTRIDE   0x00000020
 
#define WINEDDCAPS_BLT   0x00000040
 
#define WINEDDCAPS_BLTQUEUE   0x00000080
 
#define WINEDDCAPS_BLTFOURCC   0x00000100
 
#define WINEDDCAPS_BLTSTRETCH   0x00000200
 
#define WINEDDCAPS_GDI   0x00000400
 
#define WINEDDCAPS_OVERLAY   0x00000800
 
#define WINEDDCAPS_OVERLAYCANTCLIP   0x00001000
 
#define WINEDDCAPS_OVERLAYFOURCC   0x00002000
 
#define WINEDDCAPS_OVERLAYSTRETCH   0x00004000
 
#define WINEDDCAPS_PALETTE   0x00008000
 
#define WINEDDCAPS_PALETTEVSYNC   0x00010000
 
#define WINEDDCAPS_READSCANLINE   0x00020000
 
#define WINEDDCAPS_STEREOVIEW   0x00040000
 
#define WINEDDCAPS_VBI   0x00080000
 
#define WINEDDCAPS_ZBLTS   0x00100000
 
#define WINEDDCAPS_ZOVERLAYS   0x00200000
 
#define WINEDDCAPS_COLORKEY   0x00400000
 
#define WINEDDCAPS_ALPHA   0x00800000
 
#define WINEDDCAPS_COLORKEYHWASSIST   0x01000000
 
#define WINEDDCAPS_NOHARDWARE   0x02000000
 
#define WINEDDCAPS_BLTCOLORFILL   0x04000000
 
#define WINEDDCAPS_BANKSWITCHED   0x08000000
 
#define WINEDDCAPS_BLTDEPTHFILL   0x10000000
 
#define WINEDDCAPS_CANCLIP   0x20000000
 
#define WINEDDCAPS_CANCLIPSTRETCHED   0x40000000
 
#define WINEDDCAPS_CANBLTSYSMEM   0x80000000
 
#define WINEDDCAPS2_CERTIFIED   0x00000001
 
#define WINEDDCAPS2_NO2DDURING3DSCENE   0x00000002
 
#define WINEDDCAPS2_VIDEOPORT   0x00000004
 
#define WINEDDCAPS2_AUTOFLIPOVERLAY   0x00000008
 
#define WINEDDCAPS2_CANBOBINTERLEAVED   0x00000010
 
#define WINEDDCAPS2_CANBOBNONINTERLEAVED   0x00000020
 
#define WINEDDCAPS2_COLORCONTROLOVERLAY   0x00000040
 
#define WINEDDCAPS2_COLORCONTROLPRIMARY   0x00000080
 
#define WINEDDCAPS2_CANDROPZ16BIT   0x00000100
 
#define WINEDDCAPS2_NONLOCALVIDMEM   0x00000200
 
#define WINEDDCAPS2_NONLOCALVIDMEMCAPS   0x00000400
 
#define WINEDDCAPS2_NOPAGELOCKREQUIRED   0x00000800
 
#define WINEDDCAPS2_WIDESURFACES   0x00001000
 
#define WINEDDCAPS2_CANFLIPODDEVEN   0x00002000
 
#define WINEDDCAPS2_CANBOBHARDWARE   0x00004000
 
#define WINEDDCAPS2_COPYFOURCC   0x00008000
 
#define WINEDDCAPS2_PRIMARYGAMMA   0x00020000
 
#define WINEDDCAPS2_CANRENDERWINDOWED   0x00080000
 
#define WINEDDCAPS2_CANCALIBRATEGAMMA   0x00100000
 
#define WINEDDCAPS2_FLIPINTERVAL   0x00200000
 
#define WINEDDCAPS2_FLIPNOVSYNC   0x00400000
 
#define WINEDDCAPS2_CANMANAGETEXTURE   0x00800000
 
#define WINEDDCAPS2_TEXMANINNONLOCALVIDMEM   0x01000000
 
#define WINEDDCAPS2_STEREO   0x02000000
 
#define WINEDDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL   0x04000000
 
#define WINED3D_PALETTE_8BIT_ENTRIES   0x00000001
 
#define WINED3D_PALETTE_ALLOW_256   0x00000002
 
#define WINED3D_PALETTE_ALPHA   0x00000004
 
#define WINED3D_TEXTURE_CREATE_MAPPABLE   0x00000001
 
#define WINED3D_TEXTURE_CREATE_DISCARD   0x00000002
 
#define WINED3D_TEXTURE_CREATE_GET_DC_LENIENT   0x00000004
 
#define WINED3D_TEXTURE_CREATE_GET_DC   0x00000008
 
#define WINED3D_TEXTURE_CREATE_GENERATE_MIPMAPS   0x00000010
 
#define WINED3D_APPEND_ALIGNED_ELEMENT   0xffffffff
 
#define WINED3D_OUTPUT_SLOT_SEMANTIC   0xffffffff
 
#define WINED3D_OUTPUT_SLOT_UNUSED   0xfffffffe
 
#define WINED3D_MAX_STREAM_OUTPUT_BUFFERS   4
 
#define WINED3D_STREAM_OUTPUT_GAP   0xffffffff
 
#define WINED3D_NO_RASTERIZER_STREAM   0xffffffff
 
#define WINED3D_VIEW_BUFFER_RAW   0x00000001
 
#define WINED3D_VIEW_BUFFER_APPEND   0x00000002
 
#define WINED3D_VIEW_BUFFER_COUNTER   0x00000004
 
#define WINED3D_VIEW_TEXTURE_CUBE   0x00000008
 
#define WINED3D_VIEW_TEXTURE_ARRAY   0x00000010
 

Typedefs

typedef struct _WINED3DCAPS WINED3DCAPS
 
typedef HRESULT(CDECLwined3d_device_reset_cb) (struct wined3d_resource *resource)
 

Enumerations

enum  wined3d_light_type {
  WINED3D_LIGHT_POINT = 1 , WINED3D_LIGHT_SPOT = 2 , WINED3D_LIGHT_DIRECTIONAL = 3 , WINED3D_LIGHT_PARALLELPOINT = 4 ,
  WINED3D_LIGHT_GLSPOT = 5
}
 
enum  wined3d_primitive_type {
  WINED3D_PT_UNDEFINED = 0 , WINED3D_PT_POINTLIST = 1 , WINED3D_PT_LINELIST = 2 , WINED3D_PT_LINESTRIP = 3 ,
  WINED3D_PT_TRIANGLELIST = 4 , WINED3D_PT_TRIANGLESTRIP = 5 , WINED3D_PT_TRIANGLEFAN = 6 , WINED3D_PT_LINELIST_ADJ = 10 ,
  WINED3D_PT_LINESTRIP_ADJ = 11 , WINED3D_PT_TRIANGLELIST_ADJ = 12 , WINED3D_PT_TRIANGLESTRIP_ADJ = 13 , WINED3D_PT_PATCH = 14
}
 
enum  wined3d_device_type { WINED3D_DEVICE_TYPE_HAL = 1 , WINED3D_DEVICE_TYPE_REF = 2 , WINED3D_DEVICE_TYPE_SW = 3 , WINED3D_DEVICE_TYPE_NULLREF = 4 }
 
enum  wined3d_degree_type { WINED3D_DEGREE_LINEAR = 1 , WINED3D_DEGREE_QUADRATIC = 2 , WINED3D_DEGREE_CUBIC = 3 , WINED3D_DEGREE_QUINTIC = 5 }
 
enum  wined3d_format_id {
  WINED3DFMT_UNKNOWN , WINED3DFMT_B8G8R8_UNORM , WINED3DFMT_B5G5R5X1_UNORM , WINED3DFMT_B4G4R4A4_UNORM ,
  WINED3DFMT_B2G3R3_UNORM , WINED3DFMT_B2G3R3A8_UNORM , WINED3DFMT_B4G4R4X4_UNORM , WINED3DFMT_R8G8B8X8_UNORM ,
  WINED3DFMT_B10G10R10A2_UNORM , WINED3DFMT_P8_UINT_A8_UNORM , WINED3DFMT_P8_UINT , WINED3DFMT_L8_UNORM ,
  WINED3DFMT_L8A8_UNORM , WINED3DFMT_L4A4_UNORM , WINED3DFMT_R5G5_SNORM_L6_UNORM , WINED3DFMT_R8G8_SNORM_L8X8_UNORM ,
  WINED3DFMT_R10G11B11_SNORM , WINED3DFMT_R10G10B10X2_UINT , WINED3DFMT_R10G10B10X2_SNORM , WINED3DFMT_R10G10B10_SNORM_A2_UNORM ,
  WINED3DFMT_D16_LOCKABLE , WINED3DFMT_D32_UNORM , WINED3DFMT_S1_UINT_D15_UNORM , WINED3DFMT_X8D24_UNORM ,
  WINED3DFMT_S4X4_UINT_D24_UNORM , WINED3DFMT_L16_UNORM , WINED3DFMT_S8_UINT_D24_FLOAT , WINED3DFMT_R8G8_SNORM_Cx ,
  WINED3DFMT_R32G32B32A32_TYPELESS , WINED3DFMT_R32G32B32A32_FLOAT , WINED3DFMT_R32G32B32A32_UINT , WINED3DFMT_R32G32B32A32_SINT ,
  WINED3DFMT_R32G32B32_TYPELESS , WINED3DFMT_R32G32B32_FLOAT , WINED3DFMT_R32G32B32_UINT , WINED3DFMT_R32G32B32_SINT ,
  WINED3DFMT_R16G16B16A16_TYPELESS , WINED3DFMT_R16G16B16A16_FLOAT , WINED3DFMT_R16G16B16A16_UNORM , WINED3DFMT_R16G16B16A16_UINT ,
  WINED3DFMT_R16G16B16A16_SNORM , WINED3DFMT_R16G16B16A16_SINT , WINED3DFMT_R32G32_TYPELESS , WINED3DFMT_R32G32_FLOAT ,
  WINED3DFMT_R32G32_UINT , WINED3DFMT_R32G32_SINT , WINED3DFMT_R32G8X24_TYPELESS , WINED3DFMT_D32_FLOAT_S8X24_UINT ,
  WINED3DFMT_R32_FLOAT_X8X24_TYPELESS , WINED3DFMT_X32_TYPELESS_G8X24_UINT , WINED3DFMT_R10G10B10A2_TYPELESS , WINED3DFMT_R10G10B10A2_UNORM ,
  WINED3DFMT_R10G10B10A2_UINT , WINED3DFMT_R10G10B10A2_SNORM , WINED3DFMT_R10G10B10_XR_BIAS_A2_UNORM , WINED3DFMT_R11G11B10_FLOAT ,
  WINED3DFMT_R8G8B8A8_TYPELESS , WINED3DFMT_R8G8B8A8_UNORM , WINED3DFMT_R8G8B8A8_UNORM_SRGB , WINED3DFMT_R8G8B8A8_UINT ,
  WINED3DFMT_R8G8B8A8_SNORM , WINED3DFMT_R8G8B8A8_SINT , WINED3DFMT_R16G16_TYPELESS , WINED3DFMT_R16G16_FLOAT ,
  WINED3DFMT_R16G16_UNORM , WINED3DFMT_R16G16_UINT , WINED3DFMT_R16G16_SNORM , WINED3DFMT_R16G16_SINT ,
  WINED3DFMT_R32_TYPELESS , WINED3DFMT_D32_FLOAT , WINED3DFMT_R32_FLOAT , WINED3DFMT_R32_UINT ,
  WINED3DFMT_R32_SINT , WINED3DFMT_R24G8_TYPELESS , WINED3DFMT_D24_UNORM_S8_UINT , WINED3DFMT_R24_UNORM_X8_TYPELESS ,
  WINED3DFMT_X24_TYPELESS_G8_UINT , WINED3DFMT_R8G8_TYPELESS , WINED3DFMT_R8G8_UNORM , WINED3DFMT_R8G8_UINT ,
  WINED3DFMT_R8G8_SNORM , WINED3DFMT_R8G8_SINT , WINED3DFMT_R16_TYPELESS , WINED3DFMT_R16_FLOAT ,
  WINED3DFMT_D16_UNORM , WINED3DFMT_R16_UNORM , WINED3DFMT_R16_UINT , WINED3DFMT_R16_SNORM ,
  WINED3DFMT_R16_SINT , WINED3DFMT_R8_TYPELESS , WINED3DFMT_R8_UNORM , WINED3DFMT_R8_UINT ,
  WINED3DFMT_R8_SNORM , WINED3DFMT_R8_SINT , WINED3DFMT_A8_UNORM , WINED3DFMT_R1_UNORM ,
  WINED3DFMT_R9G9B9E5_SHAREDEXP , WINED3DFMT_R8G8_B8G8_UNORM , WINED3DFMT_G8R8_G8B8_UNORM , WINED3DFMT_BC1_TYPELESS ,
  WINED3DFMT_BC1_UNORM , WINED3DFMT_BC1_UNORM_SRGB , WINED3DFMT_BC2_TYPELESS , WINED3DFMT_BC2_UNORM ,
  WINED3DFMT_BC2_UNORM_SRGB , WINED3DFMT_BC3_TYPELESS , WINED3DFMT_BC3_UNORM , WINED3DFMT_BC3_UNORM_SRGB ,
  WINED3DFMT_BC4_TYPELESS , WINED3DFMT_BC4_UNORM , WINED3DFMT_BC4_SNORM , WINED3DFMT_BC5_TYPELESS ,
  WINED3DFMT_BC5_UNORM , WINED3DFMT_BC5_SNORM , WINED3DFMT_B5G6R5_UNORM , WINED3DFMT_B5G5R5A1_UNORM ,
  WINED3DFMT_B8G8R8A8_UNORM , WINED3DFMT_B8G8R8X8_UNORM , WINED3DFMT_B8G8R8A8_TYPELESS , WINED3DFMT_B8G8R8A8_UNORM_SRGB ,
  WINED3DFMT_B8G8R8X8_TYPELESS , WINED3DFMT_B8G8R8X8_UNORM_SRGB , WINED3DFMT_BC6H_TYPELESS , WINED3DFMT_BC6H_UF16 ,
  WINED3DFMT_BC6H_SF16 , WINED3DFMT_BC7_TYPELESS , WINED3DFMT_BC7_UNORM , WINED3DFMT_BC7_UNORM_SRGB ,
  WINED3DFMT_UYVY = WINEMAKEFOURCC('U','Y','V','Y') , WINED3DFMT_YUY2 = WINEMAKEFOURCC('Y','U','Y','2') , WINED3DFMT_YV12 = WINEMAKEFOURCC('Y','V','1','2') , WINED3DFMT_DXT1 = WINEMAKEFOURCC('D','X','T','1') ,
  WINED3DFMT_DXT2 = WINEMAKEFOURCC('D','X','T','2') , WINED3DFMT_DXT3 = WINEMAKEFOURCC('D','X','T','3') , WINED3DFMT_DXT4 = WINEMAKEFOURCC('D','X','T','4') , WINED3DFMT_DXT5 = WINEMAKEFOURCC('D','X','T','5') ,
  WINED3DFMT_MULTI2_ARGB8 = WINEMAKEFOURCC('M','E','T','1') , WINED3DFMT_G8R8_G8B8 = WINEMAKEFOURCC('G','R','G','B') , WINED3DFMT_R8G8_B8G8 = WINEMAKEFOURCC('R','G','B','G') , WINED3DFMT_ATI1N = WINEMAKEFOURCC('A','T','I','1') ,
  WINED3DFMT_ATI2N = WINEMAKEFOURCC('A','T','I','2') , WINED3DFMT_INST = WINEMAKEFOURCC('I','N','S','T') , WINED3DFMT_NVDB = WINEMAKEFOURCC('N','V','D','B') , WINED3DFMT_NVHU = WINEMAKEFOURCC('N','V','H','U') ,
  WINED3DFMT_NVHS = WINEMAKEFOURCC('N','V','H','S') , WINED3DFMT_INTZ = WINEMAKEFOURCC('I','N','T','Z') , WINED3DFMT_RESZ = WINEMAKEFOURCC('R','E','S','Z') , WINED3DFMT_NULL = WINEMAKEFOURCC('N','U','L','L') ,
  WINED3DFMT_R16 = WINEMAKEFOURCC(' ','R','1','6') , WINED3DFMT_AL16 = WINEMAKEFOURCC('A','L','1','6') , WINED3DFMT_NV12 = WINEMAKEFOURCC('N','V','1','2') , WINED3DFMT_FORCE_DWORD = 0xffffffff
}
 
enum  wined3d_render_state {
  WINED3D_RS_ANTIALIAS = 2 , WINED3D_RS_TEXTUREPERSPECTIVE = 4 , WINED3D_RS_WRAPU = 5 , WINED3D_RS_WRAPV = 6 ,
  WINED3D_RS_ZENABLE = 7 , WINED3D_RS_FILLMODE = 8 , WINED3D_RS_SHADEMODE = 9 , WINED3D_RS_LINEPATTERN = 10 ,
  WINED3D_RS_MONOENABLE = 11 , WINED3D_RS_ROP2 = 12 , WINED3D_RS_PLANEMASK = 13 , WINED3D_RS_ZWRITEENABLE = 14 ,
  WINED3D_RS_ALPHATESTENABLE = 15 , WINED3D_RS_LASTPIXEL = 16 , WINED3D_RS_SRCBLEND = 19 , WINED3D_RS_DESTBLEND = 20 ,
  WINED3D_RS_CULLMODE = 22 , WINED3D_RS_ZFUNC = 23 , WINED3D_RS_ALPHAREF = 24 , WINED3D_RS_ALPHAFUNC = 25 ,
  WINED3D_RS_DITHERENABLE = 26 , WINED3D_RS_ALPHABLENDENABLE = 27 , WINED3D_RS_FOGENABLE = 28 , WINED3D_RS_SPECULARENABLE = 29 ,
  WINED3D_RS_ZVISIBLE = 30 , WINED3D_RS_SUBPIXEL = 31 , WINED3D_RS_SUBPIXELX = 32 , WINED3D_RS_STIPPLEDALPHA = 33 ,
  WINED3D_RS_FOGCOLOR = 34 , WINED3D_RS_FOGTABLEMODE = 35 , WINED3D_RS_FOGSTART = 36 , WINED3D_RS_FOGEND = 37 ,
  WINED3D_RS_FOGDENSITY = 38 , WINED3D_RS_STIPPLEENABLE = 39 , WINED3D_RS_EDGEANTIALIAS = 40 , WINED3D_RS_COLORKEYENABLE = 41 ,
  WINED3D_RS_MIPMAPLODBIAS = 46 , WINED3D_RS_RANGEFOGENABLE = 48 , WINED3D_RS_ANISOTROPY = 49 , WINED3D_RS_FLUSHBATCH = 50 ,
  WINED3D_RS_TRANSLUCENTSORTINDEPENDENT = 51 , WINED3D_RS_STENCILENABLE = 52 , WINED3D_RS_STENCILFAIL = 53 , WINED3D_RS_STENCILZFAIL = 54 ,
  WINED3D_RS_STENCILPASS = 55 , WINED3D_RS_STENCILFUNC = 56 , WINED3D_RS_STENCILREF = 57 , WINED3D_RS_STENCILMASK = 58 ,
  WINED3D_RS_STENCILWRITEMASK = 59 , WINED3D_RS_TEXTUREFACTOR = 60 , WINED3D_RS_WRAP0 = 128 , WINED3D_RS_WRAP1 = 129 ,
  WINED3D_RS_WRAP2 = 130 , WINED3D_RS_WRAP3 = 131 , WINED3D_RS_WRAP4 = 132 , WINED3D_RS_WRAP5 = 133 ,
  WINED3D_RS_WRAP6 = 134 , WINED3D_RS_WRAP7 = 135 , WINED3D_RS_CLIPPING = 136 , WINED3D_RS_LIGHTING = 137 ,
  WINED3D_RS_EXTENTS = 138 , WINED3D_RS_AMBIENT = 139 , WINED3D_RS_FOGVERTEXMODE = 140 , WINED3D_RS_COLORVERTEX = 141 ,
  WINED3D_RS_LOCALVIEWER = 142 , WINED3D_RS_NORMALIZENORMALS = 143 , WINED3D_RS_COLORKEYBLENDENABLE = 144 , WINED3D_RS_DIFFUSEMATERIALSOURCE = 145 ,
  WINED3D_RS_SPECULARMATERIALSOURCE = 146 , WINED3D_RS_AMBIENTMATERIALSOURCE = 147 , WINED3D_RS_EMISSIVEMATERIALSOURCE = 148 , WINED3D_RS_VERTEXBLEND = 151 ,
  WINED3D_RS_CLIPPLANEENABLE = 152 , WINED3D_RS_SOFTWAREVERTEXPROCESSING = 153 , WINED3D_RS_POINTSIZE = 154 , WINED3D_RS_POINTSIZE_MIN = 155 ,
  WINED3D_RS_POINTSPRITEENABLE = 156 , WINED3D_RS_POINTSCALEENABLE = 157 , WINED3D_RS_POINTSCALE_A = 158 , WINED3D_RS_POINTSCALE_B = 159 ,
  WINED3D_RS_POINTSCALE_C = 160 , WINED3D_RS_MULTISAMPLEANTIALIAS = 161 , WINED3D_RS_MULTISAMPLEMASK = 162 , WINED3D_RS_PATCHEDGESTYLE = 163 ,
  WINED3D_RS_PATCHSEGMENTS = 164 , WINED3D_RS_DEBUGMONITORTOKEN = 165 , WINED3D_RS_POINTSIZE_MAX = 166 , WINED3D_RS_INDEXEDVERTEXBLENDENABLE = 167 ,
  WINED3D_RS_COLORWRITEENABLE = 168 , WINED3D_RS_TWEENFACTOR = 170 , WINED3D_RS_BLENDOP = 171 , WINED3D_RS_POSITIONDEGREE = 172 ,
  WINED3D_RS_NORMALDEGREE = 173 , WINED3D_RS_SCISSORTESTENABLE = 174 , WINED3D_RS_SLOPESCALEDEPTHBIAS = 175 , WINED3D_RS_ANTIALIASEDLINEENABLE = 176 ,
  WINED3D_RS_MINTESSELLATIONLEVEL = 178 , WINED3D_RS_MAXTESSELLATIONLEVEL = 179 , WINED3D_RS_ADAPTIVETESS_X = 180 , WINED3D_RS_ADAPTIVETESS_Y = 181 ,
  WINED3D_RS_ADAPTIVETESS_Z = 182 , WINED3D_RS_ADAPTIVETESS_W = 183 , WINED3D_RS_ENABLEADAPTIVETESSELLATION = 184 , WINED3D_RS_TWOSIDEDSTENCILMODE = 185 ,
  WINED3D_RS_BACK_STENCILFAIL = 186 , WINED3D_RS_BACK_STENCILZFAIL = 187 , WINED3D_RS_BACK_STENCILPASS = 188 , WINED3D_RS_BACK_STENCILFUNC = 189 ,
  WINED3D_RS_COLORWRITEENABLE1 = 190 , WINED3D_RS_COLORWRITEENABLE2 = 191 , WINED3D_RS_COLORWRITEENABLE3 = 192 , WINED3D_RS_BLENDFACTOR = 193 ,
  WINED3D_RS_SRGBWRITEENABLE = 194 , WINED3D_RS_DEPTHBIAS = 195 , WINED3D_RS_WRAP8 = 198 , WINED3D_RS_WRAP9 = 199 ,
  WINED3D_RS_WRAP10 = 200 , WINED3D_RS_WRAP11 = 201 , WINED3D_RS_WRAP12 = 202 , WINED3D_RS_WRAP13 = 203 ,
  WINED3D_RS_WRAP14 = 204 , WINED3D_RS_WRAP15 = 205 , WINED3D_RS_SEPARATEALPHABLENDENABLE = 206 , WINED3D_RS_SRCBLENDALPHA = 207 ,
  WINED3D_RS_DESTBLENDALPHA = 208 , WINED3D_RS_BLENDOPALPHA = 209 , WINED3D_RS_DEPTHCLIP = 210 , WINED3D_RS_DEPTHBIASCLAMP = 211 ,
  WINED3D_RS_COLORWRITEENABLE4 = 212 , WINED3D_RS_COLORWRITEENABLE5 = 213 , WINED3D_RS_COLORWRITEENABLE6 = 214 , WINED3D_RS_COLORWRITEENABLE7 = 215
}
 
enum  wined3d_blend {
  WINED3D_BLEND_ZERO = 1 , WINED3D_BLEND_ONE = 2 , WINED3D_BLEND_SRCCOLOR = 3 , WINED3D_BLEND_INVSRCCOLOR = 4 ,
  WINED3D_BLEND_SRCALPHA = 5 , WINED3D_BLEND_INVSRCALPHA = 6 , WINED3D_BLEND_DESTALPHA = 7 , WINED3D_BLEND_INVDESTALPHA = 8 ,
  WINED3D_BLEND_DESTCOLOR = 9 , WINED3D_BLEND_INVDESTCOLOR = 10 , WINED3D_BLEND_SRCALPHASAT = 11 , WINED3D_BLEND_BOTHSRCALPHA = 12 ,
  WINED3D_BLEND_BOTHINVSRCALPHA = 13 , WINED3D_BLEND_BLENDFACTOR = 14 , WINED3D_BLEND_INVBLENDFACTOR = 15 , WINED3D_BLEND_SRC1COLOR = 16 ,
  WINED3D_BLEND_INVSRC1COLOR = 17 , WINED3D_BLEND_SRC1ALPHA = 18 , WINED3D_BLEND_INVSRC1ALPHA = 19
}
 
enum  wined3d_blend_op {
  WINED3D_BLEND_OP_ADD = 1 , WINED3D_BLEND_OP_SUBTRACT = 2 , WINED3D_BLEND_OP_REVSUBTRACT = 3 , WINED3D_BLEND_OP_MIN = 4 ,
  WINED3D_BLEND_OP_MAX = 5
}
 
enum  wined3d_vertex_blend_flags {
  WINED3D_VBF_DISABLE = 0 , WINED3D_VBF_1WEIGHTS = 1 , WINED3D_VBF_2WEIGHTS = 2 , WINED3D_VBF_3WEIGHTS = 3 ,
  WINED3D_VBF_TWEENING = 255 , WINED3D_VBF_0WEIGHTS = 256
}
 
enum  wined3d_cmp_func {
  WINED3D_CMP_NEVER = 1 , WINED3D_CMP_LESS = 2 , WINED3D_CMP_EQUAL = 3 , WINED3D_CMP_LESSEQUAL = 4 ,
  WINED3D_CMP_GREATER = 5 , WINED3D_CMP_NOTEQUAL = 6 , WINED3D_CMP_GREATEREQUAL = 7 , WINED3D_CMP_ALWAYS = 8
}
 
enum  wined3d_depth_buffer_type { WINED3D_ZB_FALSE = 0 , WINED3D_ZB_TRUE = 1 , WINED3D_ZB_USEW = 2 }
 
enum  wined3d_fog_mode { WINED3D_FOG_NONE = 0 , WINED3D_FOG_EXP = 1 , WINED3D_FOG_EXP2 = 2 , WINED3D_FOG_LINEAR = 3 }
 
enum  wined3d_shade_mode { WINED3D_SHADE_FLAT = 1 , WINED3D_SHADE_GOURAUD = 2 , WINED3D_SHADE_PHONG = 3 }
 
enum  wined3d_fill_mode { WINED3D_FILL_POINT = 1 , WINED3D_FILL_WIREFRAME = 2 , WINED3D_FILL_SOLID = 3 }
 
enum  wined3d_cull { WINED3D_CULL_NONE = 1 , WINED3D_CULL_FRONT = 2 , WINED3D_CULL_BACK = 3 }
 
enum  wined3d_stencil_op {
  WINED3D_STENCIL_OP_KEEP = 1 , WINED3D_STENCIL_OP_ZERO = 2 , WINED3D_STENCIL_OP_REPLACE = 3 , WINED3D_STENCIL_OP_INCR_SAT = 4 ,
  WINED3D_STENCIL_OP_DECR_SAT = 5 , WINED3D_STENCIL_OP_INVERT = 6 , WINED3D_STENCIL_OP_INCR = 7 , WINED3D_STENCIL_OP_DECR = 8
}
 
enum  wined3d_material_color_source { WINED3D_MCS_MATERIAL = 0 , WINED3D_MCS_COLOR1 = 1 , WINED3D_MCS_COLOR2 = 2 }
 
enum  wined3d_patch_edge_style { WINED3D_PATCH_EDGE_DISCRETE = 0 , WINED3D_PATCH_EDGE_CONTINUOUS = 1 }
 
enum  wined3d_swap_effect {
  WINED3D_SWAP_EFFECT_DISCARD , WINED3D_SWAP_EFFECT_SEQUENTIAL , WINED3D_SWAP_EFFECT_FLIP_DISCARD , WINED3D_SWAP_EFFECT_FLIP_SEQUENTIAL ,
  WINED3D_SWAP_EFFECT_COPY , WINED3D_SWAP_EFFECT_COPY_VSYNC , WINED3D_SWAP_EFFECT_OVERLAY
}
 
enum  wined3d_sampler_state {
  WINED3D_SAMP_ADDRESS_U = 1 , WINED3D_SAMP_ADDRESS_V = 2 , WINED3D_SAMP_ADDRESS_W = 3 , WINED3D_SAMP_BORDER_COLOR = 4 ,
  WINED3D_SAMP_MAG_FILTER = 5 , WINED3D_SAMP_MIN_FILTER = 6 , WINED3D_SAMP_MIP_FILTER = 7 , WINED3D_SAMP_MIPMAP_LOD_BIAS = 8 ,
  WINED3D_SAMP_MAX_MIP_LEVEL = 9 , WINED3D_SAMP_MAX_ANISOTROPY = 10 , WINED3D_SAMP_SRGB_TEXTURE = 11 , WINED3D_SAMP_ELEMENT_INDEX = 12 ,
  WINED3D_SAMP_DMAP_OFFSET = 13
}
 
enum  wined3d_multisample_type {
  WINED3D_MULTISAMPLE_NONE = 0 , WINED3D_MULTISAMPLE_NON_MASKABLE = 1 , WINED3D_MULTISAMPLE_2_SAMPLES = 2 , WINED3D_MULTISAMPLE_3_SAMPLES = 3 ,
  WINED3D_MULTISAMPLE_4_SAMPLES = 4 , WINED3D_MULTISAMPLE_5_SAMPLES = 5 , WINED3D_MULTISAMPLE_6_SAMPLES = 6 , WINED3D_MULTISAMPLE_7_SAMPLES = 7 ,
  WINED3D_MULTISAMPLE_8_SAMPLES = 8 , WINED3D_MULTISAMPLE_9_SAMPLES = 9 , WINED3D_MULTISAMPLE_10_SAMPLES = 10 , WINED3D_MULTISAMPLE_11_SAMPLES = 11 ,
  WINED3D_MULTISAMPLE_12_SAMPLES = 12 , WINED3D_MULTISAMPLE_13_SAMPLES = 13 , WINED3D_MULTISAMPLE_14_SAMPLES = 14 , WINED3D_MULTISAMPLE_15_SAMPLES = 15 ,
  WINED3D_MULTISAMPLE_16_SAMPLES = 16
}
 
enum  wined3d_texture_stage_state {
  WINED3D_TSS_COLOR_OP = 0 , WINED3D_TSS_COLOR_ARG1 = 1 , WINED3D_TSS_COLOR_ARG2 = 2 , WINED3D_TSS_ALPHA_OP = 3 ,
  WINED3D_TSS_ALPHA_ARG1 = 4 , WINED3D_TSS_ALPHA_ARG2 = 5 , WINED3D_TSS_BUMPENV_MAT00 = 6 , WINED3D_TSS_BUMPENV_MAT01 = 7 ,
  WINED3D_TSS_BUMPENV_MAT10 = 8 , WINED3D_TSS_BUMPENV_MAT11 = 9 , WINED3D_TSS_TEXCOORD_INDEX = 10 , WINED3D_TSS_BUMPENV_LSCALE = 11 ,
  WINED3D_TSS_BUMPENV_LOFFSET = 12 , WINED3D_TSS_TEXTURE_TRANSFORM_FLAGS = 13 , WINED3D_TSS_COLOR_ARG0 = 14 , WINED3D_TSS_ALPHA_ARG0 = 15 ,
  WINED3D_TSS_RESULT_ARG = 16 , WINED3D_TSS_CONSTANT = 17 , WINED3D_TSS_INVALID = ~0U
}
 
enum  wined3d_texture_transform_flags {
  WINED3D_TTFF_DISABLE = 0 , WINED3D_TTFF_COUNT1 = 1 , WINED3D_TTFF_COUNT2 = 2 , WINED3D_TTFF_COUNT3 = 3 ,
  WINED3D_TTFF_COUNT4 = 4 , WINED3D_TTFF_PROJECTED = 256
}
 
enum  wined3d_texture_op {
  WINED3D_TOP_DISABLE = 1 , WINED3D_TOP_SELECT_ARG1 = 2 , WINED3D_TOP_SELECT_ARG2 = 3 , WINED3D_TOP_MODULATE = 4 ,
  WINED3D_TOP_MODULATE_2X = 5 , WINED3D_TOP_MODULATE_4X = 6 , WINED3D_TOP_ADD = 7 , WINED3D_TOP_ADD_SIGNED = 8 ,
  WINED3D_TOP_ADD_SIGNED_2X = 9 , WINED3D_TOP_SUBTRACT = 10 , WINED3D_TOP_ADD_SMOOTH = 11 , WINED3D_TOP_BLEND_DIFFUSE_ALPHA = 12 ,
  WINED3D_TOP_BLEND_TEXTURE_ALPHA = 13 , WINED3D_TOP_BLEND_FACTOR_ALPHA = 14 , WINED3D_TOP_BLEND_TEXTURE_ALPHA_PM = 15 , WINED3D_TOP_BLEND_CURRENT_ALPHA = 16 ,
  WINED3D_TOP_PREMODULATE = 17 , WINED3D_TOP_MODULATE_ALPHA_ADD_COLOR = 18 , WINED3D_TOP_MODULATE_COLOR_ADD_ALPHA = 19 , WINED3D_TOP_MODULATE_INVALPHA_ADD_COLOR = 20 ,
  WINED3D_TOP_MODULATE_INVCOLOR_ADD_ALPHA = 21 , WINED3D_TOP_BUMPENVMAP = 22 , WINED3D_TOP_BUMPENVMAP_LUMINANCE = 23 , WINED3D_TOP_DOTPRODUCT3 = 24 ,
  WINED3D_TOP_MULTIPLY_ADD = 25 , WINED3D_TOP_LERP = 26
}
 
enum  wined3d_texture_address {
  WINED3D_TADDRESS_WRAP = 1 , WINED3D_TADDRESS_MIRROR = 2 , WINED3D_TADDRESS_CLAMP = 3 , WINED3D_TADDRESS_BORDER = 4 ,
  WINED3D_TADDRESS_MIRROR_ONCE = 5
}
 
enum  wined3d_transform_state {
  WINED3D_TS_VIEW = 2 , WINED3D_TS_PROJECTION = 3 , WINED3D_TS_TEXTURE0 = 16 , WINED3D_TS_TEXTURE1 = 17 ,
  WINED3D_TS_TEXTURE2 = 18 , WINED3D_TS_TEXTURE3 = 19 , WINED3D_TS_TEXTURE4 = 20 , WINED3D_TS_TEXTURE5 = 21 ,
  WINED3D_TS_TEXTURE6 = 22 , WINED3D_TS_TEXTURE7 = 23 , WINED3D_TS_WORLD = 256 , WINED3D_TS_WORLD1 = 257 ,
  WINED3D_TS_WORLD2 = 258 , WINED3D_TS_WORLD3 = 259
}
 
enum  wined3d_basis_type { WINED3D_BASIS_BEZIER = 0 , WINED3D_BASIS_BSPLINE = 1 , WINED3D_BASIS_INTERPOLATE = 2 }
 
enum  wined3d_cubemap_face {
  WINED3D_CUBEMAP_FACE_POSITIVE_X = 0 , WINED3D_CUBEMAP_FACE_NEGATIVE_X = 1 , WINED3D_CUBEMAP_FACE_POSITIVE_Y = 2 , WINED3D_CUBEMAP_FACE_NEGATIVE_Y = 3 ,
  WINED3D_CUBEMAP_FACE_POSITIVE_Z = 4 , WINED3D_CUBEMAP_FACE_NEGATIVE_Z = 5
}
 
enum  wined3d_texture_filter_type {
  WINED3D_TEXF_NONE = 0 , WINED3D_TEXF_POINT = 1 , WINED3D_TEXF_LINEAR = 2 , WINED3D_TEXF_ANISOTROPIC = 3 ,
  WINED3D_TEXF_FLAT_CUBIC = 4 , WINED3D_TEXF_GAUSSIAN_CUBIC = 5 , WINED3D_TEXF_PYRAMIDAL_QUAD = 6 , WINED3D_TEXF_GAUSSIAN_QUAD = 7
}
 
enum  wined3d_resource_type {
  WINED3D_RTYPE_NONE = 0 , WINED3D_RTYPE_BUFFER = 1 , WINED3D_RTYPE_TEXTURE_1D = 2 , WINED3D_RTYPE_TEXTURE_2D = 3 ,
  WINED3D_RTYPE_TEXTURE_3D = 4
}
 
enum  wined3d_query_type {
  WINED3D_QUERY_TYPE_VCACHE = 4 , WINED3D_QUERY_TYPE_RESOURCE_MANAGER = 5 , WINED3D_QUERY_TYPE_VERTEX_STATS = 6 , WINED3D_QUERY_TYPE_EVENT = 8 ,
  WINED3D_QUERY_TYPE_OCCLUSION = 9 , WINED3D_QUERY_TYPE_TIMESTAMP = 10 , WINED3D_QUERY_TYPE_TIMESTAMP_DISJOINT = 11 , WINED3D_QUERY_TYPE_TIMESTAMP_FREQ = 12 ,
  WINED3D_QUERY_TYPE_PIPELINE_TIMINGS = 13 , WINED3D_QUERY_TYPE_INTERFACE_TIMINGS = 14 , WINED3D_QUERY_TYPE_VERTEX_TIMINGS = 15 , WINED3D_QUERY_TYPE_PIXEL_TIMINGS = 16 ,
  WINED3D_QUERY_TYPE_BANDWIDTH_TIMINGS = 17 , WINED3D_QUERY_TYPE_CACHE_UTILIZATION = 18 , WINED3D_QUERY_TYPE_MEMORY_PRESSURE = 19 , WINED3D_QUERY_TYPE_PIPELINE_STATISTICS = 20 ,
  WINED3D_QUERY_TYPE_SO_STATISTICS = 21 , WINED3D_QUERY_TYPE_SO_OVERFLOW = 22 , WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM0 = 23 , WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM1 = 24 ,
  WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM2 = 25 , WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM3 = 26 , WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM0 = 27 , WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM1 = 28 ,
  WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM2 = 29 , WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM3 = 30
}
 
enum  wined3d_stateblock_type { WINED3D_SBT_ALL = 1 , WINED3D_SBT_PIXEL_STATE = 2 , WINED3D_SBT_VERTEX_STATE = 3 , WINED3D_SBT_RECORDED = 4 }
 
enum  wined3d_decl_method {
  WINED3D_DECL_METHOD_DEFAULT = 0 , WINED3D_DECL_METHOD_PARTIAL_U = 1 , WINED3D_DECL_METHOD_PARTIAL_V = 2 , WINED3D_DECL_METHOD_CROSS_UV = 3 ,
  WINED3D_DECL_METHOD_UV = 4 , WINED3D_DECL_METHOD_LOOKUP = 5 , WINED3D_DECL_METHOD_LOOKUP_PRESAMPLED = 6
}
 
enum  wined3d_decl_usage {
  WINED3D_DECL_USAGE_POSITION = 0 , WINED3D_DECL_USAGE_BLEND_WEIGHT = 1 , WINED3D_DECL_USAGE_BLEND_INDICES = 2 , WINED3D_DECL_USAGE_NORMAL = 3 ,
  WINED3D_DECL_USAGE_PSIZE = 4 , WINED3D_DECL_USAGE_TEXCOORD = 5 , WINED3D_DECL_USAGE_TANGENT = 6 , WINED3D_DECL_USAGE_BINORMAL = 7 ,
  WINED3D_DECL_USAGE_TESS_FACTOR = 8 , WINED3D_DECL_USAGE_POSITIONT = 9 , WINED3D_DECL_USAGE_COLOR = 10 , WINED3D_DECL_USAGE_FOG = 11 ,
  WINED3D_DECL_USAGE_DEPTH = 12 , WINED3D_DECL_USAGE_SAMPLE = 13
}
 
enum  wined3d_sysval_semantic {
  WINED3D_SV_POSITION = 1 , WINED3D_SV_CLIP_DISTANCE = 2 , WINED3D_SV_CULL_DISTANCE = 3 , WINED3D_SV_RENDER_TARGET_ARRAY_INDEX = 4 ,
  WINED3D_SV_VIEWPORT_ARRAY_INDEX = 5 , WINED3D_SV_VERTEX_ID = 6 , WINED3D_SV_PRIMITIVE_ID = 7 , WINED3D_SV_INSTANCE_ID = 8 ,
  WINED3D_SV_IS_FRONT_FACE = 9 , WINED3D_SV_SAMPLE_INDEX = 10 , WINED3D_SV_TESS_FACTOR_QUADEDGE = 11 , WINED3D_SV_TESS_FACTOR_QUADINT = 12 ,
  WINED3D_SV_TESS_FACTOR_TRIEDGE = 13 , WINED3D_SV_TESS_FACTOR_TRIINT = 14 , WINED3D_SV_TESS_FACTOR_LINEDET = 15 , WINED3D_SV_TESS_FACTOR_LINEDEN = 16
}
 
enum  wined3d_component_type { WINED3D_TYPE_UNKNOWN = 0 , WINED3D_TYPE_UINT = 1 , WINED3D_TYPE_INT = 2 , WINED3D_TYPE_FLOAT = 3 }
 
enum  wined3d_scanline_ordering { WINED3D_SCANLINE_ORDERING_UNKNOWN = 0 , WINED3D_SCANLINE_ORDERING_PROGRESSIVE = 1 , WINED3D_SCANLINE_ORDERING_INTERLACED = 2 }
 
enum  wined3d_display_rotation {
  WINED3D_DISPLAY_ROTATION_UNSPECIFIED = 0 , WINED3D_DISPLAY_ROTATION_0 = 1 , WINED3D_DISPLAY_ROTATION_90 = 2 , WINED3D_DISPLAY_ROTATION_180 = 3 ,
  WINED3D_DISPLAY_ROTATION_270 = 4
}
 
enum  wined3d_shader_byte_code_format { WINED3D_SHADER_BYTE_CODE_FORMAT_SM1 = 0 , WINED3D_SHADER_BYTE_CODE_FORMAT_SM4 = 1 }
 
enum  wined3d_input_classification { WINED3D_INPUT_PER_VERTEX_DATA , WINED3D_INPUT_PER_INSTANCE_DATA }
 

Functions

 DEFINE_GUID (IID_IWineD3DDevice, 0xd56e2a4c, 0x5127, 0x8437, 0x65, 0x8a, 0x98, 0xc5, 0xbb, 0x78, 0x94, 0x98)
 
static enum wined3d_render_state WINED3D_RS_COLORWRITE (int index)
 
void __stdcall wined3d_mutex_lock (void)
 
void __stdcall wined3d_mutex_unlock (void)
 
UINT __cdecl wined3d_calculate_format_pitch (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_format_id format_id, UINT width)
 
HRESULT __cdecl wined3d_check_depth_stencil_match (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id adapter_format_id, enum wined3d_format_id render_target_format_id, enum wined3d_format_id depth_stencil_format_id)
 
HRESULT __cdecl wined3d_check_device_format (const struct wined3d *wined3d, UINT adaper_idx, enum wined3d_device_type device_type, enum wined3d_format_id adapter_format_id, DWORD usage, enum wined3d_resource_type resource_type, enum wined3d_format_id check_format_id)
 
HRESULT __cdecl wined3d_check_device_format_conversion (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id source_format_id, enum wined3d_format_id target_format_id)
 
HRESULT __cdecl wined3d_check_device_multisample_type (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id surface_format_id, BOOL windowed, enum wined3d_multisample_type multisample_type, DWORD *quality_levels)
 
HRESULT __cdecl wined3d_check_device_type (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id display_format_id, enum wined3d_format_id backbuffer_format_id, BOOL windowed)
 
struct wined3d *__cdecl wined3d_create (DWORD flags)
 
ULONG __cdecl wined3d_decref (struct wined3d *wined3d)
 
HRESULT __cdecl wined3d_enum_adapter_modes (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_format_id format_id, enum wined3d_scanline_ordering scanline_ordering, UINT mode_idx, struct wined3d_display_mode *mode)
 
HRESULT __cdecl wined3d_find_closest_matching_adapter_mode (const struct wined3d *wined3d, unsigned int adapter_idx, struct wined3d_display_mode *mode)
 
UINT __cdecl wined3d_get_adapter_count (const struct wined3d *wined3d)
 
HRESULT __cdecl wined3d_get_adapter_display_mode (const struct wined3d *wined3d, UINT adapter_idx, struct wined3d_display_mode *mode, enum wined3d_display_rotation *rotation)
 
HRESULT __cdecl wined3d_get_adapter_identifier (const struct wined3d *wined3d, UINT adapter_idx, DWORD flags, struct wined3d_adapter_identifier *identifier)
 
UINT __cdecl wined3d_get_adapter_mode_count (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_format_id format_id, enum wined3d_scanline_ordering scanline_ordering)
 
HRESULT __cdecl wined3d_get_adapter_raster_status (const struct wined3d *wined3d, UINT adapter_idx, struct wined3d_raster_status *raster_status)
 
HRESULT __cdecl wined3d_get_device_caps (const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, WINED3DCAPS *caps)
 
HRESULT __cdecl wined3d_get_output_desc (const struct wined3d *wined3d, unsigned int adapter_idx, struct wined3d_output_desc *desc)
 
ULONG __cdecl wined3d_incref (struct wined3d *wined3d)
 
HRESULT __cdecl wined3d_register_software_device (struct wined3d *wined3d, void *init_function)
 
HRESULT __cdecl wined3d_set_adapter_display_mode (struct wined3d *wined3d, UINT adapter_idx, const struct wined3d_display_mode *mode)
 
HRESULT __cdecl wined3d_buffer_create (struct wined3d_device *device, const struct wined3d_buffer_desc *desc, const struct wined3d_sub_resource_data *data, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_buffer **buffer)
 
ULONG __cdecl wined3d_buffer_decref (struct wined3d_buffer *buffer)
 
void *__cdecl wined3d_buffer_get_parent (const struct wined3d_buffer *buffer)
 
struct wined3d_resource *__cdecl wined3d_buffer_get_resource (struct wined3d_buffer *buffer)
 
ULONG __cdecl wined3d_buffer_incref (struct wined3d_buffer *buffer)
 
HRESULT __cdecl wined3d_device_acquire_focus_window (struct wined3d_device *device, HWND window)
 
HRESULT __cdecl wined3d_device_begin_scene (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_begin_stateblock (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_clear (struct wined3d_device *device, DWORD rect_count, const RECT *rects, DWORD flags, const struct wined3d_color *color, float z, DWORD stencil)
 
HRESULT __cdecl wined3d_device_clear_rendertarget_view (struct wined3d_device *device, struct wined3d_rendertarget_view *view, const RECT *rect, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil)
 
void __cdecl wined3d_device_clear_unordered_access_view_uint (struct wined3d_device *device, struct wined3d_unordered_access_view *view, const struct wined3d_uvec4 *clear_value)
 
void __cdecl wined3d_device_copy_resource (struct wined3d_device *device, struct wined3d_resource *dst_resource, struct wined3d_resource *src_resource)
 
HRESULT __cdecl wined3d_device_copy_sub_resource_region (struct wined3d_device *device, struct wined3d_resource *dst_resource, unsigned int dst_sub_resource_idx, unsigned int dst_x, unsigned int dst_y, unsigned int dst_z, struct wined3d_resource *src_resource, unsigned int src_sub_resource_idx, const struct wined3d_box *src_box)
 
void __cdecl wined3d_device_copy_uav_counter (struct wined3d_device *device, struct wined3d_buffer *dst_buffer, unsigned int offset, struct wined3d_unordered_access_view *uav)
 
HRESULT __cdecl wined3d_device_create (struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, HWND focus_window, DWORD behaviour_flags, BYTE surface_alignment, struct wined3d_device_parent *device_parent, struct wined3d_device **device)
 
ULONG __cdecl wined3d_device_decref (struct wined3d_device *device)
 
void __cdecl wined3d_device_dispatch_compute (struct wined3d_device *device, unsigned int group_count_x, unsigned int group_count_y, unsigned int group_count_z)
 
void __cdecl wined3d_device_dispatch_compute_indirect (struct wined3d_device *device, struct wined3d_buffer *buffer, unsigned int offset)
 
HRESULT __cdecl wined3d_device_draw_indexed_primitive (struct wined3d_device *device, UINT start_idx, UINT index_count)
 
void __cdecl wined3d_device_draw_indexed_primitive_instanced (struct wined3d_device *device, UINT start_idx, UINT index_count, UINT start_instance, UINT instance_count)
 
void __cdecl wined3d_device_draw_indexed_primitive_instanced_indirect (struct wined3d_device *device, struct wined3d_buffer *buffer, unsigned int offset)
 
HRESULT __cdecl wined3d_device_draw_primitive (struct wined3d_device *device, UINT start_vertex, UINT vertex_count)
 
void __cdecl wined3d_device_draw_primitive_instanced (struct wined3d_device *device, UINT start_vertex, UINT vertex_count, UINT start_instance, UINT instance_count)
 
void __cdecl wined3d_device_draw_primitive_instanced_indirect (struct wined3d_device *device, struct wined3d_buffer *buffer, unsigned int offset)
 
HRESULT __cdecl wined3d_device_end_scene (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_end_stateblock (struct wined3d_device *device, struct wined3d_stateblock **stateblock)
 
void __cdecl wined3d_device_evict_managed_resources (struct wined3d_device *device)
 
UINT __cdecl wined3d_device_get_available_texture_mem (const struct wined3d_device *device)
 
INT __cdecl wined3d_device_get_base_vertex_index (const struct wined3d_device *device)
 
struct wined3d_blend_state *__cdecl wined3d_device_get_blend_state (const struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_get_clip_plane (const struct wined3d_device *device, UINT plane_idx, struct wined3d_vec4 *plane)
 
HRESULT __cdecl wined3d_device_get_clip_status (const struct wined3d_device *device, struct wined3d_clip_status *clip_status)
 
struct wined3d_shader *__cdecl wined3d_device_get_compute_shader (const struct wined3d_device *device)
 
void __cdecl wined3d_device_get_creation_parameters (const struct wined3d_device *device, struct wined3d_device_creation_parameters *creation_parameters)
 
struct wined3d_buffer *__cdecl wined3d_device_get_cs_cb (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_cs_resource_view (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_cs_sampler (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_unordered_access_view *__cdecl wined3d_device_get_cs_uav (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_rendertarget_view *__cdecl wined3d_device_get_depth_stencil_view (const struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_get_device_caps (const struct wined3d_device *device, WINED3DCAPS *caps)
 
HRESULT __cdecl wined3d_device_get_display_mode (const struct wined3d_device *device, UINT swapchain_idx, struct wined3d_display_mode *mode, enum wined3d_display_rotation *rotation)
 
struct wined3d_shader *__cdecl wined3d_device_get_domain_shader (const struct wined3d_device *device)
 
struct wined3d_buffer *__cdecl wined3d_device_get_ds_cb (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_ds_resource_view (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_ds_sampler (const struct wined3d_device *device, unsigned int idx)
 
void __cdecl wined3d_device_get_gamma_ramp (const struct wined3d_device *device, UINT swapchain_idx, struct wined3d_gamma_ramp *ramp)
 
struct wined3d_shader *__cdecl wined3d_device_get_geometry_shader (const struct wined3d_device *device)
 
struct wined3d_buffer *__cdecl wined3d_device_get_gs_cb (const struct wined3d_device *device, UINT idx)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_gs_resource_view (const struct wined3d_device *device, UINT idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_gs_sampler (const struct wined3d_device *device, UINT idx)
 
struct wined3d_buffer *__cdecl wined3d_device_get_hs_cb (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_hs_resource_view (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_hs_sampler (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_shader *__cdecl wined3d_device_get_hull_shader (const struct wined3d_device *device)
 
struct wined3d_buffer *__cdecl wined3d_device_get_index_buffer (const struct wined3d_device *device, enum wined3d_format_id *format, unsigned int *offset)
 
HRESULT __cdecl wined3d_device_get_light (const struct wined3d_device *device, UINT light_idx, struct wined3d_light *light)
 
HRESULT __cdecl wined3d_device_get_light_enable (const struct wined3d_device *device, UINT light_idx, BOOL *enable)
 
void __cdecl wined3d_device_get_material (const struct wined3d_device *device, struct wined3d_material *material)
 
float __cdecl wined3d_device_get_npatch_mode (const struct wined3d_device *device)
 
struct wined3d_shader *__cdecl wined3d_device_get_pixel_shader (const struct wined3d_device *device)
 
struct wined3d_query *__cdecl wined3d_device_get_predication (struct wined3d_device *device, BOOL *value)
 
void __cdecl wined3d_device_get_primitive_type (const struct wined3d_device *device, enum wined3d_primitive_type *primitive_topology, unsigned int *patch_vertex_count)
 
struct wined3d_buffer *__cdecl wined3d_device_get_ps_cb (const struct wined3d_device *device, UINT idx)
 
HRESULT __cdecl wined3d_device_get_ps_consts_b (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, BOOL *constants)
 
HRESULT __cdecl wined3d_device_get_ps_consts_f (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, struct wined3d_vec4 *constants)
 
HRESULT __cdecl wined3d_device_get_ps_consts_i (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, struct wined3d_ivec4 *constants)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_ps_resource_view (const struct wined3d_device *device, UINT idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_ps_sampler (const struct wined3d_device *device, UINT idx)
 
HRESULT __cdecl wined3d_device_get_raster_status (const struct wined3d_device *device, UINT swapchain_idx, struct wined3d_raster_status *raster_status)
 
struct wined3d_rasterizer_state *__cdecl wined3d_device_get_rasterizer_state (struct wined3d_device *device)
 
DWORD __cdecl wined3d_device_get_render_state (const struct wined3d_device *device, enum wined3d_render_state state)
 
struct wined3d_rendertarget_view *__cdecl wined3d_device_get_rendertarget_view (const struct wined3d_device *device, unsigned int view_idx)
 
DWORD __cdecl wined3d_device_get_sampler_state (const struct wined3d_device *device, UINT sampler_idx, enum wined3d_sampler_state state)
 
void __cdecl wined3d_device_get_scissor_rect (const struct wined3d_device *device, RECT *rect)
 
BOOL __cdecl wined3d_device_get_software_vertex_processing (const struct wined3d_device *device)
 
struct wined3d_buffer *__cdecl wined3d_device_get_stream_output (struct wined3d_device *device, UINT idx, UINT *offset)
 
HRESULT __cdecl wined3d_device_get_stream_source (const struct wined3d_device *device, UINT stream_idx, struct wined3d_buffer **buffer, UINT *offset, UINT *stride)
 
HRESULT __cdecl wined3d_device_get_stream_source_freq (const struct wined3d_device *device, UINT stream_idx, UINT *divider)
 
struct wined3d_swapchain *__cdecl wined3d_device_get_swapchain (const struct wined3d_device *device, UINT swapchain_idx)
 
UINT __cdecl wined3d_device_get_swapchain_count (const struct wined3d_device *device)
 
struct wined3d_texture *__cdecl wined3d_device_get_texture (const struct wined3d_device *device, UINT stage)
 
DWORD __cdecl wined3d_device_get_texture_stage_state (const struct wined3d_device *device, UINT stage, enum wined3d_texture_stage_state state)
 
void __cdecl wined3d_device_get_transform (const struct wined3d_device *device, enum wined3d_transform_state state, struct wined3d_matrix *matrix)
 
struct wined3d_unordered_access_view *__cdecl wined3d_device_get_unordered_access_view (const struct wined3d_device *device, unsigned int idx)
 
struct wined3d_vertex_declaration *__cdecl wined3d_device_get_vertex_declaration (const struct wined3d_device *device)
 
struct wined3d_shader *__cdecl wined3d_device_get_vertex_shader (const struct wined3d_device *device)
 
void __cdecl wined3d_device_get_viewport (const struct wined3d_device *device, struct wined3d_viewport *viewport)
 
struct wined3d_buffer *__cdecl wined3d_device_get_vs_cb (const struct wined3d_device *device, UINT idx)
 
HRESULT __cdecl wined3d_device_get_vs_consts_b (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, BOOL *constants)
 
HRESULT __cdecl wined3d_device_get_vs_consts_f (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, struct wined3d_vec4 *constants)
 
HRESULT __cdecl wined3d_device_get_vs_consts_i (const struct wined3d_device *device, unsigned int start_idx, unsigned int count, struct wined3d_ivec4 *constants)
 
struct wined3d_shader_resource_view *__cdecl wined3d_device_get_vs_resource_view (const struct wined3d_device *device, UINT idx)
 
struct wined3d_sampler *__cdecl wined3d_device_get_vs_sampler (const struct wined3d_device *device, UINT idx)
 
struct wined3d *__cdecl wined3d_device_get_wined3d (const struct wined3d_device *device)
 
ULONG __cdecl wined3d_device_incref (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_init_3d (struct wined3d_device *device, struct wined3d_swapchain_desc *swapchain_desc)
 
HRESULT __cdecl wined3d_device_init_gdi (struct wined3d_device *device, struct wined3d_swapchain_desc *swapchain_desc)
 
void __cdecl wined3d_device_multiply_transform (struct wined3d_device *device, enum wined3d_transform_state state, const struct wined3d_matrix *matrix)
 
HRESULT __cdecl wined3d_device_process_vertices (struct wined3d_device *device, UINT src_start_idx, UINT dst_idx, UINT vertex_count, struct wined3d_buffer *dst_buffer, const struct wined3d_vertex_declaration *declaration, DWORD flags, DWORD dst_fvf)
 
void __cdecl wined3d_device_release_focus_window (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_reset (struct wined3d_device *device, const struct wined3d_swapchain_desc *swapchain_desc, const struct wined3d_display_mode *mode, wined3d_device_reset_cb callback, BOOL reset_state)
 
void __cdecl wined3d_device_resolve_sub_resource (struct wined3d_device *device, struct wined3d_resource *dst_resource, unsigned int dst_sub_resource_idx, struct wined3d_resource *src_resource, unsigned int src_sub_resource_idx, enum wined3d_format_id format_id)
 
void __cdecl wined3d_device_restore_fullscreen_window (struct wined3d_device *device, HWND window, const RECT *window_rect)
 
void __cdecl wined3d_device_set_base_vertex_index (struct wined3d_device *device, INT base_index)
 
void __cdecl wined3d_device_set_blend_state (struct wined3d_device *device, struct wined3d_blend_state *blend_state)
 
HRESULT __cdecl wined3d_device_set_clip_plane (struct wined3d_device *device, UINT plane_idx, const struct wined3d_vec4 *plane)
 
HRESULT __cdecl wined3d_device_set_clip_status (struct wined3d_device *device, const struct wined3d_clip_status *clip_status)
 
void __cdecl wined3d_device_set_compute_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_cs_cb (struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer)
 
void __cdecl wined3d_device_set_cs_resource_view (struct wined3d_device *device, unsigned int idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_cs_sampler (struct wined3d_device *device, unsigned int idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_set_cs_uav (struct wined3d_device *device, unsigned int idx, struct wined3d_unordered_access_view *uav, unsigned int initial_count)
 
void __cdecl wined3d_device_set_cursor_position (struct wined3d_device *device, int x_screen_space, int y_screen_space, DWORD flags)
 
HRESULT __cdecl wined3d_device_set_cursor_properties (struct wined3d_device *device, UINT x_hotspot, UINT y_hotspot, struct wined3d_texture *texture, unsigned int sub_resource_idx)
 
void __cdecl wined3d_device_set_depth_stencil_view (struct wined3d_device *device, struct wined3d_rendertarget_view *view)
 
HRESULT __cdecl wined3d_device_set_dialog_box_mode (struct wined3d_device *device, BOOL enable_dialogs)
 
void __cdecl wined3d_device_set_domain_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_ds_cb (struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer)
 
void __cdecl wined3d_device_set_ds_resource_view (struct wined3d_device *device, unsigned int idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_ds_sampler (struct wined3d_device *device, unsigned int idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_set_gamma_ramp (const struct wined3d_device *device, UINT swapchain_idx, DWORD flags, const struct wined3d_gamma_ramp *ramp)
 
void __cdecl wined3d_device_set_geometry_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_gs_cb (struct wined3d_device *device, UINT idx, struct wined3d_buffer *buffer)
 
void __cdecl wined3d_device_set_gs_resource_view (struct wined3d_device *device, UINT idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_gs_sampler (struct wined3d_device *device, UINT idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_set_hs_cb (struct wined3d_device *device, unsigned int idx, struct wined3d_buffer *buffer)
 
void __cdecl wined3d_device_set_hs_resource_view (struct wined3d_device *device, unsigned int idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_hs_sampler (struct wined3d_device *device, unsigned int idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_set_hull_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_index_buffer (struct wined3d_device *device, struct wined3d_buffer *index_buffer, enum wined3d_format_id format_id, unsigned int offset)
 
HRESULT __cdecl wined3d_device_set_light (struct wined3d_device *device, UINT light_idx, const struct wined3d_light *light)
 
HRESULT __cdecl wined3d_device_set_light_enable (struct wined3d_device *device, UINT light_idx, BOOL enable)
 
void __cdecl wined3d_device_set_material (struct wined3d_device *device, const struct wined3d_material *material)
 
void __cdecl wined3d_device_set_multithreaded (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_set_npatch_mode (struct wined3d_device *device, float segments)
 
void __cdecl wined3d_device_set_pixel_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_predication (struct wined3d_device *device, struct wined3d_query *predicate, BOOL value)
 
void __cdecl wined3d_device_set_primitive_type (struct wined3d_device *device, enum wined3d_primitive_type primitive_topology, unsigned int patch_vertex_count)
 
void __cdecl wined3d_device_set_ps_cb (struct wined3d_device *device, UINT idx, struct wined3d_buffer *buffer)
 
HRESULT __cdecl wined3d_device_set_ps_consts_b (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const BOOL *constants)
 
HRESULT __cdecl wined3d_device_set_ps_consts_f (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants)
 
HRESULT __cdecl wined3d_device_set_ps_consts_i (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_ivec4 *constants)
 
void __cdecl wined3d_device_set_ps_resource_view (struct wined3d_device *device, UINT idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_ps_sampler (struct wined3d_device *device, UINT idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_set_rasterizer_state (struct wined3d_device *device, struct wined3d_rasterizer_state *rasterizer_state)
 
void __cdecl wined3d_device_set_render_state (struct wined3d_device *device, enum wined3d_render_state state, DWORD value)
 
HRESULT __cdecl wined3d_device_set_rendertarget_view (struct wined3d_device *device, unsigned int view_idx, struct wined3d_rendertarget_view *view, BOOL set_viewport)
 
void __cdecl wined3d_device_set_sampler_state (struct wined3d_device *device, UINT sampler_idx, enum wined3d_sampler_state state, DWORD value)
 
void __cdecl wined3d_device_set_scissor_rect (struct wined3d_device *device, const RECT *rect)
 
void __cdecl wined3d_device_set_software_vertex_processing (struct wined3d_device *device, BOOL software)
 
void __cdecl wined3d_device_set_stream_output (struct wined3d_device *device, UINT idx, struct wined3d_buffer *buffer, UINT offset)
 
HRESULT __cdecl wined3d_device_set_stream_source (struct wined3d_device *device, UINT stream_idx, struct wined3d_buffer *buffer, UINT offset, UINT stride)
 
HRESULT __cdecl wined3d_device_set_stream_source_freq (struct wined3d_device *device, UINT stream_idx, UINT divider)
 
HRESULT __cdecl wined3d_device_set_texture (struct wined3d_device *device, UINT stage, struct wined3d_texture *texture)
 
void __cdecl wined3d_device_set_texture_stage_state (struct wined3d_device *device, UINT stage, enum wined3d_texture_stage_state state, DWORD value)
 
void __cdecl wined3d_device_set_transform (struct wined3d_device *device, enum wined3d_transform_state state, const struct wined3d_matrix *matrix)
 
void __cdecl wined3d_device_set_unordered_access_view (struct wined3d_device *device, unsigned int idx, struct wined3d_unordered_access_view *uav, unsigned int initial_count)
 
void __cdecl wined3d_device_set_vertex_declaration (struct wined3d_device *device, struct wined3d_vertex_declaration *declaration)
 
void __cdecl wined3d_device_set_vertex_shader (struct wined3d_device *device, struct wined3d_shader *shader)
 
void __cdecl wined3d_device_set_viewport (struct wined3d_device *device, const struct wined3d_viewport *viewport)
 
void __cdecl wined3d_device_set_vs_cb (struct wined3d_device *device, UINT idx, struct wined3d_buffer *buffer)
 
HRESULT __cdecl wined3d_device_set_vs_consts_b (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const BOOL *constants)
 
HRESULT __cdecl wined3d_device_set_vs_consts_f (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants)
 
HRESULT __cdecl wined3d_device_set_vs_consts_i (struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_ivec4 *constants)
 
void __cdecl wined3d_device_set_vs_resource_view (struct wined3d_device *device, UINT idx, struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_device_set_vs_sampler (struct wined3d_device *device, UINT idx, struct wined3d_sampler *sampler)
 
void __cdecl wined3d_device_setup_fullscreen_window (struct wined3d_device *device, HWND window, UINT w, UINT h)
 
BOOL __cdecl wined3d_device_show_cursor (struct wined3d_device *device, BOOL show)
 
HRESULT __cdecl wined3d_device_uninit_3d (struct wined3d_device *device)
 
HRESULT __cdecl wined3d_device_uninit_gdi (struct wined3d_device *device)
 
void __cdecl wined3d_device_update_sub_resource (struct wined3d_device *device, struct wined3d_resource *resource, unsigned int sub_resource_idx, const struct wined3d_box *box, const void *data, unsigned int row_pitch, unsigned int depth_pitch)
 
HRESULT __cdecl wined3d_device_update_texture (struct wined3d_device *device, struct wined3d_texture *src_texture, struct wined3d_texture *dst_texture)
 
HRESULT __cdecl wined3d_device_validate_device (const struct wined3d_device *device, DWORD *num_passes)
 
HRESULT __cdecl wined3d_palette_create (struct wined3d_device *device, DWORD flags, unsigned int entry_count, const PALETTEENTRY *entries, struct wined3d_palette **palette)
 
ULONG __cdecl wined3d_palette_decref (struct wined3d_palette *palette)
 
HRESULT __cdecl wined3d_palette_get_entries (const struct wined3d_palette *palette, DWORD flags, DWORD start, DWORD count, PALETTEENTRY *entries)
 
void __cdecl wined3d_palette_apply_to_dc (const struct wined3d_palette *palette, HDC dc)
 
ULONG __cdecl wined3d_palette_incref (struct wined3d_palette *palette)
 
HRESULT __cdecl wined3d_palette_set_entries (struct wined3d_palette *palette, DWORD flags, DWORD start, DWORD count, const PALETTEENTRY *entries)
 
HRESULT __cdecl wined3d_query_create (struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
 
ULONG __cdecl wined3d_query_decref (struct wined3d_query *query)
 
HRESULT __cdecl wined3d_query_get_data (struct wined3d_query *query, void *data, UINT data_size, DWORD flags)
 
UINT __cdecl wined3d_query_get_data_size (const struct wined3d_query *query)
 
void *__cdecl wined3d_query_get_parent (const struct wined3d_query *query)
 
enum wined3d_query_type __cdecl wined3d_query_get_type (const struct wined3d_query *query)
 
ULONG __cdecl wined3d_query_incref (struct wined3d_query *query)
 
HRESULT __cdecl wined3d_query_issue (struct wined3d_query *query, DWORD flags)
 
static void wined3d_private_store_init (struct wined3d_private_store *store)
 
static struct wined3d_private_datawined3d_private_store_get_private_data (const struct wined3d_private_store *store, const GUID *tag)
 
static void wined3d_private_store_free_private_data (struct wined3d_private_store *store, struct wined3d_private_data *entry)
 
static void wined3d_private_store_cleanup (struct wined3d_private_store *store)
 
static HRESULT wined3d_private_store_set_private_data (struct wined3d_private_store *store, const GUID *guid, const void *data, DWORD data_size, DWORD flags)
 
HRESULT __cdecl wined3d_blend_state_create (struct wined3d_device *device, const struct wined3d_blend_state_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_blend_state **state)
 
ULONG __cdecl wined3d_blend_state_decref (struct wined3d_blend_state *state)
 
void *__cdecl wined3d_blend_state_get_parent (const struct wined3d_blend_state *state)
 
ULONG __cdecl wined3d_blend_state_incref (struct wined3d_blend_state *state)
 
HRESULT __cdecl wined3d_rasterizer_state_create (struct wined3d_device *device, const struct wined3d_rasterizer_state_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_rasterizer_state **state)
 
ULONG __cdecl wined3d_rasterizer_state_decref (struct wined3d_rasterizer_state *state)
 
void *__cdecl wined3d_rasterizer_state_get_parent (const struct wined3d_rasterizer_state *state)
 
ULONG __cdecl wined3d_rasterizer_state_incref (struct wined3d_rasterizer_state *state)
 
void __cdecl wined3d_resource_get_desc (const struct wined3d_resource *resource, struct wined3d_resource_desc *desc)
 
void *__cdecl wined3d_resource_get_parent (const struct wined3d_resource *resource)
 
DWORD __cdecl wined3d_resource_get_priority (const struct wined3d_resource *resource)
 
HRESULT __cdecl wined3d_resource_map (struct wined3d_resource *resource, unsigned int sub_resource_idx, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags)
 
HRESULT __cdecl wined3d_resource_map_info (struct wined3d_resource *resource, unsigned int sub_resource_idx, struct wined3d_map_info *info, DWORD flags)
 
void __cdecl wined3d_resource_preload (struct wined3d_resource *resource)
 
void __cdecl wined3d_resource_set_parent (struct wined3d_resource *resource, void *parent)
 
DWORD __cdecl wined3d_resource_set_priority (struct wined3d_resource *resource, DWORD priority)
 
HRESULT __cdecl wined3d_resource_unmap (struct wined3d_resource *resource, unsigned int sub_resource_idx)
 
UINT __cdecl wined3d_resource_update_info (struct wined3d_resource *resource, unsigned int sub_resource_idx, const struct wined3d_box *box, unsigned int row_pitch, unsigned int depth_pitch)
 
HRESULT __cdecl wined3d_rendertarget_view_create (const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_rendertarget_view **view)
 
HRESULT __cdecl wined3d_rendertarget_view_create_from_sub_resource (struct wined3d_texture *texture, unsigned int sub_resource_idx, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_rendertarget_view **view)
 
ULONG __cdecl wined3d_rendertarget_view_decref (struct wined3d_rendertarget_view *view)
 
void *__cdecl wined3d_rendertarget_view_get_parent (const struct wined3d_rendertarget_view *view)
 
struct wined3d_resource *__cdecl wined3d_rendertarget_view_get_resource (const struct wined3d_rendertarget_view *view)
 
void *__cdecl wined3d_rendertarget_view_get_sub_resource_parent (const struct wined3d_rendertarget_view *view)
 
ULONG __cdecl wined3d_rendertarget_view_incref (struct wined3d_rendertarget_view *view)
 
void __cdecl wined3d_rendertarget_view_set_parent (struct wined3d_rendertarget_view *view, void *parent)
 
HRESULT __cdecl wined3d_sampler_create (struct wined3d_device *device, const struct wined3d_sampler_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_sampler **sampler)
 
ULONG __cdecl wined3d_sampler_decref (struct wined3d_sampler *sampler)
 
void *__cdecl wined3d_sampler_get_parent (const struct wined3d_sampler *sampler)
 
ULONG __cdecl wined3d_sampler_incref (struct wined3d_sampler *sampler)
 
HRESULT __cdecl wined3d_shader_create_cs (struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
HRESULT __cdecl wined3d_shader_create_ds (struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
HRESULT __cdecl wined3d_shader_create_gs (struct wined3d_device *device, const struct wined3d_shader_desc *desc, const struct wined3d_stream_output_desc *so_desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
HRESULT __cdecl wined3d_shader_create_hs (struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
HRESULT __cdecl wined3d_shader_create_ps (struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
HRESULT __cdecl wined3d_shader_create_vs (struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader **shader)
 
ULONG __cdecl wined3d_shader_decref (struct wined3d_shader *shader)
 
HRESULT __cdecl wined3d_shader_get_byte_code (const struct wined3d_shader *shader, void *byte_code, UINT *byte_code_size)
 
void *__cdecl wined3d_shader_get_parent (const struct wined3d_shader *shader)
 
ULONG __cdecl wined3d_shader_incref (struct wined3d_shader *shader)
 
HRESULT __cdecl wined3d_shader_set_local_constants_float (struct wined3d_shader *shader, UINT start_idx, const float *src_data, UINT vector4f_count)
 
HRESULT __cdecl wined3d_shader_resource_view_create (const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_shader_resource_view **view)
 
ULONG __cdecl wined3d_shader_resource_view_decref (struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_shader_resource_view_generate_mipmaps (struct wined3d_shader_resource_view *view)
 
void *__cdecl wined3d_shader_resource_view_get_parent (const struct wined3d_shader_resource_view *view)
 
ULONG __cdecl wined3d_shader_resource_view_incref (struct wined3d_shader_resource_view *view)
 
void __cdecl wined3d_stateblock_apply (const struct wined3d_stateblock *stateblock)
 
void __cdecl wined3d_stateblock_capture (struct wined3d_stateblock *stateblock)
 
HRESULT __cdecl wined3d_stateblock_create (struct wined3d_device *device, enum wined3d_stateblock_type type, struct wined3d_stateblock **stateblock)
 
ULONG __cdecl wined3d_stateblock_decref (struct wined3d_stateblock *stateblock)
 
ULONG __cdecl wined3d_stateblock_incref (struct wined3d_stateblock *stateblock)
 
HRESULT __cdecl wined3d_swapchain_create (struct wined3d_device *device, struct wined3d_swapchain_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_swapchain **swapchain)
 
ULONG __cdecl wined3d_swapchain_decref (struct wined3d_swapchain *swapchain)
 
struct wined3d_texture *__cdecl wined3d_swapchain_get_back_buffer (const struct wined3d_swapchain *swapchain, UINT backbuffer_idx)
 
struct wined3d_device *__cdecl wined3d_swapchain_get_device (const struct wined3d_swapchain *swapchain)
 
HRESULT __cdecl wined3d_swapchain_get_display_mode (const struct wined3d_swapchain *swapchain, struct wined3d_display_mode *mode, enum wined3d_display_rotation *rotation)
 
HRESULT __cdecl wined3d_swapchain_get_front_buffer_data (const struct wined3d_swapchain *swapchain, struct wined3d_texture *dst_texture, unsigned int sub_resource_idx)
 
HRESULT __cdecl wined3d_swapchain_get_gamma_ramp (const struct wined3d_swapchain *swapchain, struct wined3d_gamma_ramp *ramp)
 
void *__cdecl wined3d_swapchain_get_parent (const struct wined3d_swapchain *swapchain)
 
void __cdecl wined3d_swapchain_get_desc (const struct wined3d_swapchain *swapchain, struct wined3d_swapchain_desc *desc)
 
HRESULT __cdecl wined3d_swapchain_get_raster_status (const struct wined3d_swapchain *swapchain, struct wined3d_raster_status *raster_status)
 
ULONG __cdecl wined3d_swapchain_incref (struct wined3d_swapchain *swapchain)
 
HRESULT __cdecl wined3d_swapchain_present (struct wined3d_swapchain *swapchain, const RECT *src_rect, const RECT *dst_rect, HWND dst_window_override, DWORD swap_interval, DWORD flags)
 
HRESULT __cdecl wined3d_swapchain_resize_buffers (struct wined3d_swapchain *swapchain, unsigned int buffer_count, unsigned int width, unsigned int height, enum wined3d_format_id format_id, enum wined3d_multisample_type multisample_type, unsigned int multisample_quality)
 
HRESULT __cdecl wined3d_swapchain_resize_target (struct wined3d_swapchain *swapchain, const struct wined3d_display_mode *mode)
 
HRESULT __cdecl wined3d_swapchain_set_fullscreen (struct wined3d_swapchain *swapchain, const struct wined3d_swapchain_desc *desc, const struct wined3d_display_mode *mode)
 
HRESULT __cdecl wined3d_swapchain_set_gamma_ramp (const struct wined3d_swapchain *swapchain, DWORD flags, const struct wined3d_gamma_ramp *ramp)
 
void __cdecl wined3d_swapchain_set_palette (struct wined3d_swapchain *swapchain, struct wined3d_palette *palette)
 
void __cdecl wined3d_swapchain_set_window (struct wined3d_swapchain *swapchain, HWND window)
 
HRESULT __cdecl wined3d_texture_add_dirty_region (struct wined3d_texture *texture, UINT layer, const struct wined3d_box *dirty_region)
 
HRESULT __cdecl wined3d_texture_blt (struct wined3d_texture *dst_texture, unsigned int dst_idx, const RECT *dst_rect_in, struct wined3d_texture *src_texture, unsigned int src_idx, const RECT *src_rect_in, DWORD flags, const struct wined3d_blt_fx *fx, enum wined3d_texture_filter_type filter)
 
HRESULT __cdecl wined3d_texture_create (struct wined3d_device *device, const struct wined3d_resource_desc *desc, UINT layer_count, UINT level_count, DWORD flags, const struct wined3d_sub_resource_data *data, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_texture **texture)
 
struct wined3d_texture *__cdecl wined3d_texture_from_resource (struct wined3d_resource *resource)
 
ULONG __cdecl wined3d_texture_decref (struct wined3d_texture *texture)
 
HRESULT __cdecl wined3d_texture_get_dc (struct wined3d_texture *texture, unsigned int sub_resource_idx, HDC *dc)
 
DWORD __cdecl wined3d_texture_get_level_count (const struct wined3d_texture *texture)
 
DWORD __cdecl wined3d_texture_get_lod (const struct wined3d_texture *texture)
 
HRESULT __cdecl wined3d_texture_get_overlay_position (const struct wined3d_texture *texture, unsigned int sub_resource_idx, LONG *x, LONG *y)
 
void *__cdecl wined3d_texture_get_parent (const struct wined3d_texture *texture)
 
void __cdecl wined3d_texture_get_pitch (const struct wined3d_texture *texture, unsigned int level, unsigned int *row_pitch, unsigned int *slice_pitch)
 
struct wined3d_resource *__cdecl wined3d_texture_get_resource (struct wined3d_texture *texture)
 
HRESULT __cdecl wined3d_texture_get_sub_resource_desc (const struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_sub_resource_desc *desc)
 
void *__cdecl wined3d_texture_get_sub_resource_parent (struct wined3d_texture *texture, unsigned int sub_resource_idx)
 
ULONG __cdecl wined3d_texture_incref (struct wined3d_texture *texture)
 
HRESULT __cdecl wined3d_texture_release_dc (struct wined3d_texture *texture, unsigned int sub_resource_idx, HDC dc)
 
HRESULT __cdecl wined3d_texture_set_color_key (struct wined3d_texture *texture, DWORD flags, const struct wined3d_color_key *color_key)
 
DWORD __cdecl wined3d_texture_set_lod (struct wined3d_texture *texture, DWORD lod)
 
HRESULT __cdecl wined3d_texture_set_overlay_position (struct wined3d_texture *texture, unsigned int sub_resource_idx, LONG x, LONG y)
 
void __cdecl wined3d_texture_set_sub_resource_parent (struct wined3d_texture *texture, unsigned int sub_resource_idx, void *parent)
 
HRESULT __cdecl wined3d_texture_update_desc (struct wined3d_texture *texture, UINT width, UINT height, enum wined3d_format_id format_id, enum wined3d_multisample_type multisample_type, UINT multisample_quality, void *mem, UINT pitch)
 
HRESULT __cdecl wined3d_texture_update_overlay (struct wined3d_texture *texture, unsigned int sub_resource_idx, const RECT *src_rect, struct wined3d_texture *dst_texture, unsigned int dst_sub_resource_idx, const RECT *dst_rect, DWORD flags)
 
HRESULT __cdecl wined3d_unordered_access_view_create (const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_unordered_access_view **view)
 
ULONG __cdecl wined3d_unordered_access_view_decref (struct wined3d_unordered_access_view *view)
 
void *__cdecl wined3d_unordered_access_view_get_parent (const struct wined3d_unordered_access_view *view)
 
ULONG __cdecl wined3d_unordered_access_view_incref (struct wined3d_unordered_access_view *view)
 
HRESULT __cdecl wined3d_vertex_declaration_create (struct wined3d_device *device, const struct wined3d_vertex_element *elements, UINT element_count, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_vertex_declaration **declaration)
 
HRESULT __cdecl wined3d_vertex_declaration_create_from_fvf (struct wined3d_device *device, DWORD fvf, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_vertex_declaration **declaration)
 
ULONG __cdecl wined3d_vertex_declaration_decref (struct wined3d_vertex_declaration *declaration)
 
void *__cdecl wined3d_vertex_declaration_get_parent (const struct wined3d_vertex_declaration *declaration)
 
ULONG __cdecl wined3d_vertex_declaration_incref (struct wined3d_vertex_declaration *declaration)
 
static unsigned int wined3d_log2i (unsigned int x)
 
static void wined3d_box_set (struct wined3d_box *box, unsigned int left, unsigned int top, unsigned int right, unsigned int bottom, unsigned int front, unsigned int back)
 
BOOL wined3d_dxt1_decode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxt1_encode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxt3_decode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxt3_encode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxt5_decode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxt5_encode (const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, enum wined3d_format_id format, unsigned int w, unsigned int h)
 
BOOL wined3d_dxtn_supported (void)
 

Macro Definition Documentation

◆ _FACWINED3D

#define _FACWINED3D   0x876

Definition at line 39 of file wined3d.h.

◆ MAKE_WINED3DHRESULT

#define MAKE_WINED3DHRESULT (   code)    MAKE_HRESULT(1, _FACWINED3D, code)

Definition at line 43 of file wined3d.h.

◆ MAKE_WINED3DSTATUS

#define MAKE_WINED3DSTATUS (   code)    MAKE_HRESULT(0, _FACWINED3D, code)

Definition at line 40 of file wined3d.h.

◆ WINED3D_APPEND_ALIGNED_ELEMENT

#define WINED3D_APPEND_ALIGNED_ELEMENT   0xffffffff

Definition at line 1564 of file wined3d.h.

◆ WINED3D_BIND_CONSTANT_BUFFER

#define WINED3D_BIND_CONSTANT_BUFFER   0x00000004

Definition at line 892 of file wined3d.h.

◆ WINED3D_BIND_DEPTH_STENCIL

#define WINED3D_BIND_DEPTH_STENCIL   0x00000040

Definition at line 896 of file wined3d.h.

◆ WINED3D_BIND_INDEX_BUFFER

#define WINED3D_BIND_INDEX_BUFFER   0x00000002

Definition at line 891 of file wined3d.h.

◆ WINED3D_BIND_RENDER_TARGET

#define WINED3D_BIND_RENDER_TARGET   0x00000020

Definition at line 895 of file wined3d.h.

◆ WINED3D_BIND_SHADER_RESOURCE

#define WINED3D_BIND_SHADER_RESOURCE   0x00000008

Definition at line 893 of file wined3d.h.

◆ WINED3D_BIND_STREAM_OUTPUT

#define WINED3D_BIND_STREAM_OUTPUT   0x00000010

Definition at line 894 of file wined3d.h.

◆ WINED3D_BIND_UNORDERED_ACCESS

#define WINED3D_BIND_UNORDERED_ACCESS   0x00000080

Definition at line 897 of file wined3d.h.

◆ WINED3D_BIND_VERTEX_BUFFER

#define WINED3D_BIND_VERTEX_BUFFER   0x00000001

Definition at line 890 of file wined3d.h.

◆ WINED3D_BLT_ALPHA_TEST

#define WINED3D_BLT_ALPHA_TEST   0x80000000

Definition at line 1368 of file wined3d.h.

◆ WINED3D_BLT_DO_NOT_WAIT

#define WINED3D_BLT_DO_NOT_WAIT   0x08000000

Definition at line 1365 of file wined3d.h.

◆ WINED3D_BLT_DST_CKEY

#define WINED3D_BLT_DST_CKEY   0x00002000

Definition at line 1360 of file wined3d.h.

◆ WINED3D_BLT_DST_CKEY_OVERRIDE

#define WINED3D_BLT_DST_CKEY_OVERRIDE   0x00004000

Definition at line 1361 of file wined3d.h.

◆ WINED3D_BLT_FX

#define WINED3D_BLT_FX   0x00000800

Definition at line 1359 of file wined3d.h.

◆ WINED3D_BLT_MASK

#define WINED3D_BLT_MASK   0x0901e800

Definition at line 1369 of file wined3d.h.

◆ WINED3D_BLT_RAW

#define WINED3D_BLT_RAW   0x20000000

Definition at line 1366 of file wined3d.h.

◆ WINED3D_BLT_SRC_CKEY

#define WINED3D_BLT_SRC_CKEY   0x00008000

Definition at line 1362 of file wined3d.h.

◆ WINED3D_BLT_SRC_CKEY_OVERRIDE

#define WINED3D_BLT_SRC_CKEY_OVERRIDE   0x00010000

Definition at line 1363 of file wined3d.h.

◆ WINED3D_BLT_SYNCHRONOUS

#define WINED3D_BLT_SYNCHRONOUS   0x40000000

Definition at line 1367 of file wined3d.h.

◆ WINED3D_BLT_WAIT

#define WINED3D_BLT_WAIT   0x01000000

Definition at line 1364 of file wined3d.h.

◆ WINED3D_CKEY_DST_BLT

#define WINED3D_CKEY_DST_BLT   0x00000002

Definition at line 1334 of file wined3d.h.

◆ WINED3D_CKEY_DST_OVERLAY

#define WINED3D_CKEY_DST_OVERLAY   0x00000004

Definition at line 1335 of file wined3d.h.

◆ WINED3D_CKEY_SRC_BLT

#define WINED3D_CKEY_SRC_BLT   0x00000008

Definition at line 1336 of file wined3d.h.

◆ WINED3D_CKEY_SRC_OVERLAY

#define WINED3D_CKEY_SRC_OVERLAY   0x00000010

Definition at line 1337 of file wined3d.h.

◆ WINED3D_FOCUS_MESSAGES

#define WINED3D_FOCUS_MESSAGES   0x00000020

Definition at line 1320 of file wined3d.h.

◆ WINED3D_HANDLE_RESTORE

#define WINED3D_HANDLE_RESTORE   0x00000040

Definition at line 1321 of file wined3d.h.

◆ WINED3D_HIGHEST_SAMPLER_STATE

#define WINED3D_HIGHEST_SAMPLER_STATE   WINED3D_SAMP_DMAP_OFFSET

Definition at line 550 of file wined3d.h.

◆ WINED3D_HIGHEST_TEXTURE_STATE

#define WINED3D_HIGHEST_TEXTURE_STATE   WINED3D_TSS_CONSTANT

Definition at line 595 of file wined3d.h.

◆ WINED3D_LEGACY_CUBEMAP_FILTERING

#define WINED3D_LEGACY_CUBEMAP_FILTERING   0x00001000

Definition at line 1327 of file wined3d.h.

◆ WINED3D_LEGACY_DEPTH_BIAS

#define WINED3D_LEGACY_DEPTH_BIAS   0x00000001

Definition at line 1315 of file wined3d.h.

◆ WINED3D_LEGACY_FFP_LIGHTING

#define WINED3D_LEGACY_FFP_LIGHTING   0x00000100

Definition at line 1323 of file wined3d.h.

◆ WINED3D_LEGACY_UNBOUND_RESOURCE_COLOR

#define WINED3D_LEGACY_UNBOUND_RESOURCE_COLOR   0x00000400

Definition at line 1325 of file wined3d.h.

◆ WINED3D_LIMIT_VIEWPORT

#define WINED3D_LIMIT_VIEWPORT   0x00008000

Definition at line 1330 of file wined3d.h.

◆ WINED3D_MAP_DISCARD

#define WINED3D_MAP_DISCARD   0x00002000

Definition at line 935 of file wined3d.h.

◆ WINED3D_MAP_DONOTWAIT

#define WINED3D_MAP_DONOTWAIT   0x00004000

Definition at line 936 of file wined3d.h.

◆ WINED3D_MAP_NO_DIRTY_UPDATE

#define WINED3D_MAP_NO_DIRTY_UPDATE   0x00008000

Definition at line 937 of file wined3d.h.

◆ WINED3D_MAP_NOOVERWRITE

#define WINED3D_MAP_NOOVERWRITE   0x00001000

Definition at line 934 of file wined3d.h.

◆ WINED3D_MAP_NOSYSLOCK

#define WINED3D_MAP_NOSYSLOCK   0x00000800

Definition at line 933 of file wined3d.h.

◆ WINED3D_MAP_READ

#define WINED3D_MAP_READ   0x80000000

Definition at line 939 of file wined3d.h.

◆ WINED3D_MAP_WRITE

#define WINED3D_MAP_WRITE   0x40000000

Definition at line 938 of file wined3d.h.

◆ WINED3D_MAX_STREAM_OUTPUT_BUFFERS

#define WINED3D_MAX_STREAM_OUTPUT_BUFFERS   4

Definition at line 1569 of file wined3d.h.

◆ WINED3D_NO3D

#define WINED3D_NO3D   0x00000002

Definition at line 1316 of file wined3d.h.

◆ WINED3D_NO_PRIMITIVE_RESTART

#define WINED3D_NO_PRIMITIVE_RESTART   0x00000800

Definition at line 1326 of file wined3d.h.

◆ WINED3D_NO_RASTERIZER_STREAM

#define WINED3D_NO_RASTERIZER_STREAM   0xffffffff

Definition at line 1571 of file wined3d.h.

◆ WINED3D_NORMALIZED_DEPTH_BIAS

#define WINED3D_NORMALIZED_DEPTH_BIAS   0x00002000

Definition at line 1328 of file wined3d.h.

◆ WINED3D_OK

#define WINED3D_OK   S_OK

Definition at line 37 of file wined3d.h.

◆ WINED3D_OUTPUT_SLOT_SEMANTIC

#define WINED3D_OUTPUT_SLOT_SEMANTIC   0xffffffff

Definition at line 1566 of file wined3d.h.

◆ WINED3D_OUTPUT_SLOT_UNUSED

#define WINED3D_OUTPUT_SLOT_UNUSED   0xfffffffe

Definition at line 1567 of file wined3d.h.

◆ WINED3D_PALETTE_8BIT_ENTRIES

#define WINED3D_PALETTE_8BIT_ENTRIES   0x00000001

Definition at line 1554 of file wined3d.h.

◆ WINED3D_PALETTE_ALLOW_256

#define WINED3D_PALETTE_ALLOW_256   0x00000002

Definition at line 1555 of file wined3d.h.

◆ WINED3D_PALETTE_ALPHA

#define WINED3D_PALETTE_ALPHA   0x00000004

Definition at line 1556 of file wined3d.h.

◆ WINED3D_PIXEL_CENTER_INTEGER

#define WINED3D_PIXEL_CENTER_INTEGER   0x00000080

Definition at line 1322 of file wined3d.h.

◆ WINED3D_PRESENT_CONVERSION

#define WINED3D_PRESENT_CONVERSION   0x00000008

Definition at line 1318 of file wined3d.h.

◆ WINED3D_REQUEST_D3D10

#define WINED3D_REQUEST_D3D10   0x00004000

Definition at line 1329 of file wined3d.h.

◆ WINED3D_RESOURCE_ACCESS_CPU

#define WINED3D_RESOURCE_ACCESS_CPU   0x2u

Definition at line 56 of file wined3d.h.

◆ WINED3D_RESOURCE_ACCESS_GPU

#define WINED3D_RESOURCE_ACCESS_GPU   0x1u

Definition at line 55 of file wined3d.h.

◆ WINED3D_RESOURCE_ACCESS_MAP_R

#define WINED3D_RESOURCE_ACCESS_MAP_R   0x4u

Definition at line 57 of file wined3d.h.

◆ WINED3D_RESOURCE_ACCESS_MAP_W

#define WINED3D_RESOURCE_ACCESS_MAP_W   0x8u

Definition at line 58 of file wined3d.h.

◆ WINED3D_RESTORE_MODE_ON_ACTIVATE

#define WINED3D_RESTORE_MODE_ON_ACTIVATE   0x00000010

Definition at line 1319 of file wined3d.h.

◆ WINED3D_RESZ_CODE

#define WINED3D_RESZ_CODE   0x7fa05000

Definition at line 1332 of file wined3d.h.

◆ WINED3D_SRGB_READ_WRITE_CONTROL

#define WINED3D_SRGB_READ_WRITE_CONTROL   0x00000200

Definition at line 1324 of file wined3d.h.

◆ WINED3D_STREAM_OUTPUT_GAP

#define WINED3D_STREAM_OUTPUT_GAP   0xffffffff

Definition at line 1570 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH

#define WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH   0x00001000u

Definition at line 883 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_DEVICECLIP

#define WINED3D_SWAPCHAIN_DEVICECLIP   0x00000004u

Definition at line 879 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_DISCARD_DEPTHSTENCIL

#define WINED3D_SWAPCHAIN_DISCARD_DEPTHSTENCIL   0x00000002u

Definition at line 878 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_GDI_COMPATIBLE

#define WINED3D_SWAPCHAIN_GDI_COMPATIBLE   0x00008000u

Definition at line 886 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_LOCKABLE_BACKBUFFER

#define WINED3D_SWAPCHAIN_LOCKABLE_BACKBUFFER   0x00000001u

Definition at line 877 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_NOAUTOROTATE

#define WINED3D_SWAPCHAIN_NOAUTOROTATE   0x00000020u

Definition at line 881 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_RESTORE_WINDOW_RECT

#define WINED3D_SWAPCHAIN_RESTORE_WINDOW_RECT   0x00004000u

Definition at line 885 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_UNPRUNEDMODE

#define WINED3D_SWAPCHAIN_UNPRUNEDMODE   0x00000040u

Definition at line 882 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_USE_CLOSEST_MATCHING_MODE

#define WINED3D_SWAPCHAIN_USE_CLOSEST_MATCHING_MODE   0x00002000u

Definition at line 884 of file wined3d.h.

◆ WINED3D_SWAPCHAIN_VIDEO

#define WINED3D_SWAPCHAIN_VIDEO   0x00000010u

Definition at line 880 of file wined3d.h.

◆ WINED3D_TEXTURE_CREATE_DISCARD

#define WINED3D_TEXTURE_CREATE_DISCARD   0x00000002

Definition at line 1559 of file wined3d.h.

◆ WINED3D_TEXTURE_CREATE_GENERATE_MIPMAPS

#define WINED3D_TEXTURE_CREATE_GENERATE_MIPMAPS   0x00000010

Definition at line 1562 of file wined3d.h.

◆ WINED3D_TEXTURE_CREATE_GET_DC

#define WINED3D_TEXTURE_CREATE_GET_DC   0x00000008

Definition at line 1561 of file wined3d.h.

◆ WINED3D_TEXTURE_CREATE_GET_DC_LENIENT

#define WINED3D_TEXTURE_CREATE_GET_DC_LENIENT   0x00000004

Definition at line 1560 of file wined3d.h.

◆ WINED3D_TEXTURE_CREATE_MAPPABLE

#define WINED3D_TEXTURE_CREATE_MAPPABLE   0x00000001

Definition at line 1558 of file wined3d.h.

◆ WINED3D_TS_WORLD_MATRIX

#define WINED3D_TS_WORLD_MATRIX (   index)    (enum wined3d_transform_state)(index + 256)

Definition at line 664 of file wined3d.h.

◆ WINED3D_VIDMEM_ACCOUNTING

#define WINED3D_VIDMEM_ACCOUNTING   0x00000004

Definition at line 1317 of file wined3d.h.

◆ WINED3D_VIEW_BUFFER_APPEND

#define WINED3D_VIEW_BUFFER_APPEND   0x00000002

Definition at line 1574 of file wined3d.h.

◆ WINED3D_VIEW_BUFFER_COUNTER

#define WINED3D_VIEW_BUFFER_COUNTER   0x00000004

Definition at line 1575 of file wined3d.h.

◆ WINED3D_VIEW_BUFFER_RAW

#define WINED3D_VIEW_BUFFER_RAW   0x00000001

Definition at line 1573 of file wined3d.h.

◆ WINED3D_VIEW_TEXTURE_ARRAY

#define WINED3D_VIEW_TEXTURE_ARRAY   0x00000010

Definition at line 1577 of file wined3d.h.

◆ WINED3D_VIEW_TEXTURE_CUBE

#define WINED3D_VIEW_TEXTURE_CUBE   0x00000008

Definition at line 1576 of file wined3d.h.

◆ WINED3DADAPTER_DEFAULT

#define WINED3DADAPTER_DEFAULT   0

Definition at line 857 of file wined3d.h.

◆ WINED3DCAPS2_CANCALIBRATEGAMMA

#define WINED3DCAPS2_CANCALIBRATEGAMMA   0x00100000

Definition at line 1184 of file wined3d.h.

◆ WINED3DCAPS2_CANGENMIPMAP

#define WINED3DCAPS2_CANGENMIPMAP   0x40000000

Definition at line 1188 of file wined3d.h.

◆ WINED3DCAPS2_CANMANAGERESOURCE

#define WINED3DCAPS2_CANMANAGERESOURCE   0x10000000

Definition at line 1186 of file wined3d.h.

◆ WINED3DCAPS2_CANRENDERWINDOWED

#define WINED3DCAPS2_CANRENDERWINDOWED   0x00080000

Definition at line 1183 of file wined3d.h.

◆ WINED3DCAPS2_DYNAMICTEXTURES

#define WINED3DCAPS2_DYNAMICTEXTURES   0x20000000

Definition at line 1187 of file wined3d.h.

◆ WINED3DCAPS2_FULLSCREENGAMMA

#define WINED3DCAPS2_FULLSCREENGAMMA   0x00020000

Definition at line 1182 of file wined3d.h.

◆ WINED3DCAPS2_NO2DDURING3DSCENE

#define WINED3DCAPS2_NO2DDURING3DSCENE   0x00000002

Definition at line 1181 of file wined3d.h.

◆ WINED3DCAPS2_RESERVED

#define WINED3DCAPS2_RESERVED   0x02000000

Definition at line 1185 of file wined3d.h.

◆ WINED3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD

#define WINED3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD   0x00000020

Definition at line 1030 of file wined3d.h.

◆ WINED3DCAPS3_COPY_TO_SYSTEMMEM

#define WINED3DCAPS3_COPY_TO_SYSTEMMEM   0x00000200

Definition at line 1033 of file wined3d.h.

◆ WINED3DCAPS3_COPY_TO_VIDMEM

#define WINED3DCAPS3_COPY_TO_VIDMEM   0x00000100

Definition at line 1032 of file wined3d.h.

◆ WINED3DCAPS3_LINEAR_TO_SRGB_PRESENTATION

#define WINED3DCAPS3_LINEAR_TO_SRGB_PRESENTATION   0x00000080

Definition at line 1031 of file wined3d.h.

◆ WINED3DCAPS3_RESERVED

#define WINED3DCAPS3_RESERVED   0x8000001f

Definition at line 1034 of file wined3d.h.

◆ WINED3DCLEAR_STENCIL

#define WINED3DCLEAR_STENCIL   0x00000004

Definition at line 999 of file wined3d.h.

◆ WINED3DCLEAR_TARGET

#define WINED3DCLEAR_TARGET   0x00000001

Definition at line 997 of file wined3d.h.

◆ WINED3DCLEAR_ZBUFFER

#define WINED3DCLEAR_ZBUFFER   0x00000002

Definition at line 998 of file wined3d.h.

◆ WINED3DCLIPPLANE0

#define WINED3DCLIPPLANE0   (1u << 0)

Definition at line 950 of file wined3d.h.

◆ WINED3DCLIPPLANE1

#define WINED3DCLIPPLANE1   (1u << 1)

Definition at line 951 of file wined3d.h.

◆ WINED3DCLIPPLANE2

#define WINED3DCLIPPLANE2   (1u << 2)

Definition at line 952 of file wined3d.h.

◆ WINED3DCLIPPLANE3

#define WINED3DCLIPPLANE3   (1u << 3)

Definition at line 953 of file wined3d.h.

◆ WINED3DCLIPPLANE4

#define WINED3DCLIPPLANE4   (1u << 4)

Definition at line 954 of file wined3d.h.

◆ WINED3DCLIPPLANE5

#define WINED3DCLIPPLANE5   (1u << 5)

Definition at line 955 of file wined3d.h.

◆ WINED3DCOLORWRITEENABLE_ALPHA

#define WINED3DCOLORWRITEENABLE_ALPHA   (1u << 3)

Definition at line 855 of file wined3d.h.

◆ WINED3DCOLORWRITEENABLE_BLUE

#define WINED3DCOLORWRITEENABLE_BLUE   (1u << 2)

Definition at line 854 of file wined3d.h.

◆ WINED3DCOLORWRITEENABLE_GREEN

#define WINED3DCOLORWRITEENABLE_GREEN   (1u << 1)

Definition at line 853 of file wined3d.h.

◆ WINED3DCOLORWRITEENABLE_RED

#define WINED3DCOLORWRITEENABLE_RED   (1u << 0)

Definition at line 852 of file wined3d.h.

◆ WINED3DCREATE_ADAPTERGROUP_DEVICE

#define WINED3DCREATE_ADAPTERGROUP_DEVICE   0x00000200

Definition at line 1015 of file wined3d.h.

◆ WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT

#define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT   0x00000100

Definition at line 1014 of file wined3d.h.

◆ WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT_EX

#define WINED3DCREATE_DISABLE_DRIVER_MANAGEMENT_EX   0x00000400

Definition at line 1016 of file wined3d.h.

◆ WINED3DCREATE_DISABLE_PRINTSCREEN

#define WINED3DCREATE_DISABLE_PRINTSCREEN   0x00008000

Definition at line 1020 of file wined3d.h.

◆ WINED3DCREATE_DISABLE_PSGP_THREADING

#define WINED3DCREATE_DISABLE_PSGP_THREADING   0x00002000

Definition at line 1018 of file wined3d.h.

◆ WINED3DCREATE_ENABLE_PRESENTSTATS

#define WINED3DCREATE_ENABLE_PRESENTSTATS   0x00004000

Definition at line 1019 of file wined3d.h.

◆ WINED3DCREATE_FPU_PRESERVE

#define WINED3DCREATE_FPU_PRESERVE   0x00000002

Definition at line 1009 of file wined3d.h.

◆ WINED3DCREATE_HARDWARE_VERTEXPROCESSING

#define WINED3DCREATE_HARDWARE_VERTEXPROCESSING   0x00000040

Definition at line 1012 of file wined3d.h.

◆ WINED3DCREATE_MIXED_VERTEXPROCESSING

#define WINED3DCREATE_MIXED_VERTEXPROCESSING   0x00000080

Definition at line 1013 of file wined3d.h.

◆ WINED3DCREATE_NOWINDOWCHANGES

#define WINED3DCREATE_NOWINDOWCHANGES   0x00000800

Definition at line 1017 of file wined3d.h.

◆ WINED3DCREATE_PUREDEVICE

#define WINED3DCREATE_PUREDEVICE   0x00000010

Definition at line 1010 of file wined3d.h.

◆ WINED3DCREATE_SCREENSAVER

#define WINED3DCREATE_SCREENSAVER   0x10000000

Definition at line 1021 of file wined3d.h.

◆ WINED3DCREATE_SOFTWARE_VERTEXPROCESSING

#define WINED3DCREATE_SOFTWARE_VERTEXPROCESSING   0x00000020

Definition at line 1011 of file wined3d.h.

◆ WINED3DCURSORCAPS_COLOR

#define WINED3DCURSORCAPS_COLOR   0x00000001

Definition at line 1287 of file wined3d.h.

◆ WINED3DCURSORCAPS_LOWRES

#define WINED3DCURSORCAPS_LOWRES   0x00000002

Definition at line 1288 of file wined3d.h.

◆ WINED3DDEVCAPS2_ADAPTIVETESSNPATCH

#define WINED3DDEVCAPS2_ADAPTIVETESSNPATCH   0x00000008

Definition at line 1039 of file wined3d.h.

◆ WINED3DDEVCAPS2_ADAPTIVETESSRTPATCH

#define WINED3DDEVCAPS2_ADAPTIVETESSRTPATCH   0x00000004

Definition at line 1038 of file wined3d.h.

◆ WINED3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES

#define WINED3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES   0x00000010

Definition at line 1040 of file wined3d.h.

◆ WINED3DDEVCAPS2_DMAPNPATCH

#define WINED3DDEVCAPS2_DMAPNPATCH   0x00000002

Definition at line 1037 of file wined3d.h.

◆ WINED3DDEVCAPS2_PRESAMPLEDDMAPNPATCH

#define WINED3DDEVCAPS2_PRESAMPLEDDMAPNPATCH   0x00000020

Definition at line 1041 of file wined3d.h.

◆ WINED3DDEVCAPS2_STREAMOFFSET

#define WINED3DDEVCAPS2_STREAMOFFSET   0x00000001

Definition at line 1036 of file wined3d.h.

◆ WINED3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET

#define WINED3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET   0x00000040

Definition at line 1042 of file wined3d.h.

◆ WINED3DDEVCAPS_CANBLTSYSTONONLOCAL

#define WINED3DDEVCAPS_CANBLTSYSTONONLOCAL   0x00020000

Definition at line 1307 of file wined3d.h.

◆ WINED3DDEVCAPS_CANRENDERAFTERFLIP

#define WINED3DDEVCAPS_CANRENDERAFTERFLIP   0x00000800

Definition at line 1301 of file wined3d.h.

◆ WINED3DDEVCAPS_DRAWPRIMITIVES2

#define WINED3DDEVCAPS_DRAWPRIMITIVES2   0x00002000

Definition at line 1303 of file wined3d.h.

◆ WINED3DDEVCAPS_DRAWPRIMITIVES2EX

#define WINED3DDEVCAPS_DRAWPRIMITIVES2EX   0x00008000

Definition at line 1305 of file wined3d.h.

◆ WINED3DDEVCAPS_DRAWPRIMTLVERTEX

#define WINED3DDEVCAPS_DRAWPRIMTLVERTEX   0x00000400

Definition at line 1300 of file wined3d.h.

◆ WINED3DDEVCAPS_EXECUTESYSTEMMEMORY

#define WINED3DDEVCAPS_EXECUTESYSTEMMEMORY   0x00000010

Definition at line 1294 of file wined3d.h.

◆ WINED3DDEVCAPS_EXECUTEVIDEOMEMORY

#define WINED3DDEVCAPS_EXECUTEVIDEOMEMORY   0x00000020

Definition at line 1295 of file wined3d.h.

◆ WINED3DDEVCAPS_FLOATTLVERTEX

#define WINED3DDEVCAPS_FLOATTLVERTEX   0x00000001

Definition at line 1290 of file wined3d.h.

◆ WINED3DDEVCAPS_HWRASTERIZATION

#define WINED3DDEVCAPS_HWRASTERIZATION   0x00080000

Definition at line 1308 of file wined3d.h.

◆ WINED3DDEVCAPS_HWTRANSFORMANDLIGHT

#define WINED3DDEVCAPS_HWTRANSFORMANDLIGHT   0x00010000

Definition at line 1306 of file wined3d.h.

◆ WINED3DDEVCAPS_NPATCHES

#define WINED3DDEVCAPS_NPATCHES   0x01000000

Definition at line 1313 of file wined3d.h.

◆ WINED3DDEVCAPS_PUREDEVICE

#define WINED3DDEVCAPS_PUREDEVICE   0x00100000

Definition at line 1309 of file wined3d.h.

◆ WINED3DDEVCAPS_QUINTICRTPATCHES

#define WINED3DDEVCAPS_QUINTICRTPATCHES   0x00200000

Definition at line 1310 of file wined3d.h.

◆ WINED3DDEVCAPS_RTPATCHES

#define WINED3DDEVCAPS_RTPATCHES   0x00400000

Definition at line 1311 of file wined3d.h.

◆ WINED3DDEVCAPS_RTPATCHHANDLEZERO

#define WINED3DDEVCAPS_RTPATCHHANDLEZERO   0x00800000

Definition at line 1312 of file wined3d.h.

◆ WINED3DDEVCAPS_SEPARATETEXTUREMEMORIES

#define WINED3DDEVCAPS_SEPARATETEXTUREMEMORIES   0x00004000

Definition at line 1304 of file wined3d.h.

◆ WINED3DDEVCAPS_SORTDECREASINGZ

#define WINED3DDEVCAPS_SORTDECREASINGZ   0X00000004

Definition at line 1292 of file wined3d.h.

◆ WINED3DDEVCAPS_SORTEXACT

#define WINED3DDEVCAPS_SORTEXACT   0x00000008

Definition at line 1293 of file wined3d.h.

◆ WINED3DDEVCAPS_SORTINCREASINGZ

#define WINED3DDEVCAPS_SORTINCREASINGZ   0x00000002

Definition at line 1291 of file wined3d.h.

◆ WINED3DDEVCAPS_TEXTURENONLOCALVIDMEM

#define WINED3DDEVCAPS_TEXTURENONLOCALVIDMEM   0x00001000

Definition at line 1302 of file wined3d.h.

◆ WINED3DDEVCAPS_TEXTURESYSTEMMEMORY

#define WINED3DDEVCAPS_TEXTURESYSTEMMEMORY   0x00000100

Definition at line 1298 of file wined3d.h.

◆ WINED3DDEVCAPS_TEXTUREVIDEOMEMORY

#define WINED3DDEVCAPS_TEXTUREVIDEOMEMORY   0x00000200

Definition at line 1299 of file wined3d.h.

◆ WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY

#define WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY   0x00000040

Definition at line 1296 of file wined3d.h.

◆ WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY

#define WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY   0x00000080

Definition at line 1297 of file wined3d.h.

◆ WINED3DDMAPSAMPLER

#define WINED3DDMAPSAMPLER   0x100

Definition at line 1024 of file wined3d.h.

◆ WINED3DDP_MAXTEXCOORD

#define WINED3DDP_MAXTEXCOORD   8

Definition at line 888 of file wined3d.h.

◆ WINED3DDTCAPS_DEC3N

#define WINED3DDTCAPS_DEC3N   0x00000080

Definition at line 1051 of file wined3d.h.

◆ WINED3DDTCAPS_FLOAT16_2

#define WINED3DDTCAPS_FLOAT16_2   0x00000100

Definition at line 1052 of file wined3d.h.

◆ WINED3DDTCAPS_FLOAT16_4

#define WINED3DDTCAPS_FLOAT16_4   0x00000200

Definition at line 1053 of file wined3d.h.

◆ WINED3DDTCAPS_SHORT2N

#define WINED3DDTCAPS_SHORT2N   0x00000004

Definition at line 1046 of file wined3d.h.

◆ WINED3DDTCAPS_SHORT4N

#define WINED3DDTCAPS_SHORT4N   0x00000008

Definition at line 1047 of file wined3d.h.

◆ WINED3DDTCAPS_UBYTE4

#define WINED3DDTCAPS_UBYTE4   0x00000001

Definition at line 1044 of file wined3d.h.

◆ WINED3DDTCAPS_UBYTE4N

#define WINED3DDTCAPS_UBYTE4N   0x00000002

Definition at line 1045 of file wined3d.h.

◆ WINED3DDTCAPS_UDEC3

#define WINED3DDTCAPS_UDEC3   0x00000040

Definition at line 1050 of file wined3d.h.

◆ WINED3DDTCAPS_USHORT2N

#define WINED3DDTCAPS_USHORT2N   0x00000010

Definition at line 1048 of file wined3d.h.

◆ WINED3DDTCAPS_USHORT4N

#define WINED3DDTCAPS_USHORT4N   0x00000020

Definition at line 1049 of file wined3d.h.

◆ WINED3DENUM_NO_WHQL_LEVEL

#define WINED3DENUM_NO_WHQL_LEVEL   2

Definition at line 858 of file wined3d.h.

◆ WINED3DERR_CONFLICTINGRENDERSTATE

#define WINED3DERR_CONFLICTINGRENDERSTATE   MAKE_WINED3DHRESULT(2081)

Definition at line 44 of file wined3d.h.

◆ WINED3DERR_INVALIDCALL

#define WINED3DERR_INVALIDCALL   MAKE_WINED3DHRESULT(2156)

Definition at line 48 of file wined3d.h.

◆ WINED3DERR_NOTAVAILABLE

#define WINED3DERR_NOTAVAILABLE   MAKE_WINED3DHRESULT(2154)

Definition at line 46 of file wined3d.h.

◆ WINED3DERR_OUTOFVIDEOMEMORY

#define WINED3DERR_OUTOFVIDEOMEMORY   MAKE_WINED3DHRESULT(380)

Definition at line 47 of file wined3d.h.

◆ WINED3DERR_UNSUPPORTEDTEXTUREFILTER

#define WINED3DERR_UNSUPPORTEDTEXTUREFILTER   MAKE_WINED3DHRESULT(2082)

Definition at line 45 of file wined3d.h.

◆ WINED3DFVF_DIFFUSE

#define WINED3DFVF_DIFFUSE   0x0040

Definition at line 970 of file wined3d.h.

◆ WINED3DFVF_LASTBETA_D3DCOLOR

#define WINED3DFVF_LASTBETA_D3DCOLOR   0x8000

Definition at line 984 of file wined3d.h.

◆ WINED3DFVF_LASTBETA_UBYTE4

#define WINED3DFVF_LASTBETA_UBYTE4   0x1000

Definition at line 983 of file wined3d.h.

◆ WINED3DFVF_NORMAL

#define WINED3DFVF_NORMAL   0x0010

Definition at line 968 of file wined3d.h.

◆ WINED3DFVF_POSITION_MASK

#define WINED3DFVF_POSITION_MASK   0x400e

Definition at line 959 of file wined3d.h.

◆ WINED3DFVF_PSIZE

#define WINED3DFVF_PSIZE   0x0020

Definition at line 969 of file wined3d.h.

◆ WINED3DFVF_RESERVED0

#define WINED3DFVF_RESERVED0   0x0001

Definition at line 958 of file wined3d.h.

◆ WINED3DFVF_RESERVED2

#define WINED3DFVF_RESERVED2   0x6000

Definition at line 985 of file wined3d.h.

◆ WINED3DFVF_SPECULAR

#define WINED3DFVF_SPECULAR   0x0080

Definition at line 971 of file wined3d.h.

◆ WINED3DFVF_TEX0

#define WINED3DFVF_TEX0   0x0000

Definition at line 974 of file wined3d.h.

◆ WINED3DFVF_TEX1

#define WINED3DFVF_TEX1   0x0100

Definition at line 975 of file wined3d.h.

◆ WINED3DFVF_TEX2

#define WINED3DFVF_TEX2   0x0200

Definition at line 976 of file wined3d.h.

◆ WINED3DFVF_TEX3

#define WINED3DFVF_TEX3   0x0300

Definition at line 977 of file wined3d.h.

◆ WINED3DFVF_TEX4

#define WINED3DFVF_TEX4   0x0400

Definition at line 978 of file wined3d.h.

◆ WINED3DFVF_TEX5

#define WINED3DFVF_TEX5   0x0500

Definition at line 979 of file wined3d.h.

◆ WINED3DFVF_TEX6

#define WINED3DFVF_TEX6   0x0600

Definition at line 980 of file wined3d.h.

◆ WINED3DFVF_TEX7

#define WINED3DFVF_TEX7   0x0700

Definition at line 981 of file wined3d.h.

◆ WINED3DFVF_TEX8

#define WINED3DFVF_TEX8   0x0800

Definition at line 982 of file wined3d.h.

◆ WINED3DFVF_TEXCOORDSIZE1

#define WINED3DFVF_TEXCOORDSIZE1 (   idx)    (WINED3DFVF_TEXTUREFORMAT1 << (idx * 2 + 16))

Definition at line 991 of file wined3d.h.

◆ WINED3DFVF_TEXCOORDSIZE2

#define WINED3DFVF_TEXCOORDSIZE2 (   idx)    (WINED3DFVF_TEXTUREFORMAT2 << (idx * 2 + 16))

Definition at line 992 of file wined3d.h.

◆ WINED3DFVF_TEXCOORDSIZE3

#define WINED3DFVF_TEXCOORDSIZE3 (   idx)    (WINED3DFVF_TEXTUREFORMAT3 << (idx * 2 + 16))

Definition at line 993 of file wined3d.h.

◆ WINED3DFVF_TEXCOORDSIZE4

#define WINED3DFVF_TEXCOORDSIZE4 (   idx)    (WINED3DFVF_TEXTUREFORMAT4 << (idx * 2 + 16))

Definition at line 994 of file wined3d.h.

◆ WINED3DFVF_TEXCOUNT_MASK

#define WINED3DFVF_TEXCOUNT_MASK   0x0f00

Definition at line 972 of file wined3d.h.

◆ WINED3DFVF_TEXCOUNT_SHIFT

#define WINED3DFVF_TEXCOUNT_SHIFT   8

Definition at line 973 of file wined3d.h.

◆ WINED3DFVF_TEXTUREFORMAT1

#define WINED3DFVF_TEXTUREFORMAT1   3u

Definition at line 987 of file wined3d.h.

◆ WINED3DFVF_TEXTUREFORMAT2

#define WINED3DFVF_TEXTUREFORMAT2   0u

Definition at line 988 of file wined3d.h.

◆ WINED3DFVF_TEXTUREFORMAT3

#define WINED3DFVF_TEXTUREFORMAT3   1u

Definition at line 989 of file wined3d.h.

◆ WINED3DFVF_TEXTUREFORMAT4

#define WINED3DFVF_TEXTUREFORMAT4   2u

Definition at line 990 of file wined3d.h.

◆ WINED3DFVF_XYZ

#define WINED3DFVF_XYZ   0x0002

Definition at line 960 of file wined3d.h.

◆ WINED3DFVF_XYZB1

#define WINED3DFVF_XYZB1   0x0006

Definition at line 962 of file wined3d.h.

◆ WINED3DFVF_XYZB2

#define WINED3DFVF_XYZB2   0x0008

Definition at line 963 of file wined3d.h.

◆ WINED3DFVF_XYZB3

#define WINED3DFVF_XYZB3   0x000a

Definition at line 964 of file wined3d.h.

◆ WINED3DFVF_XYZB4

#define WINED3DFVF_XYZB4   0x000c

Definition at line 965 of file wined3d.h.

◆ WINED3DFVF_XYZB5

#define WINED3DFVF_XYZB5   0x000e

Definition at line 966 of file wined3d.h.

◆ WINED3DFVF_XYZRHW

#define WINED3DFVF_XYZRHW   0x0004

Definition at line 961 of file wined3d.h.

◆ WINED3DFVF_XYZW

#define WINED3DFVF_XYZW   0x4002

Definition at line 967 of file wined3d.h.

◆ WINED3DFVFCAPS_DONOTSTRIPELEMENTS

#define WINED3DFVFCAPS_DONOTSTRIPELEMENTS   0x00080000

Definition at line 1056 of file wined3d.h.

◆ WINED3DFVFCAPS_PSIZE

#define WINED3DFVFCAPS_PSIZE   0x00100000

Definition at line 1057 of file wined3d.h.

◆ WINED3DFVFCAPS_TEXCOORDCOUNTMASK

#define WINED3DFVFCAPS_TEXCOORDCOUNTMASK   0x0000ffff

Definition at line 1055 of file wined3d.h.

◆ WINED3DGETDATA_FLUSH

#define WINED3DGETDATA_FLUSH   (1u << 0)

Definition at line 763 of file wined3d.h.

◆ WINED3DISSUE_BEGIN

#define WINED3DISSUE_BEGIN   (1u << 1)

Definition at line 761 of file wined3d.h.

◆ WINED3DISSUE_END

#define WINED3DISSUE_END   (1u << 0)

Definition at line 762 of file wined3d.h.

◆ WINED3DLINECAPS_ALPHACMP

#define WINED3DLINECAPS_ALPHACMP   0x00000008

Definition at line 1062 of file wined3d.h.

◆ WINED3DLINECAPS_ANTIALIAS

#define WINED3DLINECAPS_ANTIALIAS   0x00000020

Definition at line 1064 of file wined3d.h.

◆ WINED3DLINECAPS_BLEND

#define WINED3DLINECAPS_BLEND   0x00000004

Definition at line 1061 of file wined3d.h.

◆ WINED3DLINECAPS_FOG

#define WINED3DLINECAPS_FOG   0x00000010

Definition at line 1063 of file wined3d.h.

◆ WINED3DLINECAPS_TEXTURE

#define WINED3DLINECAPS_TEXTURE   0x00000001

Definition at line 1059 of file wined3d.h.

◆ WINED3DLINECAPS_ZTEST

#define WINED3DLINECAPS_ZTEST   0x00000002

Definition at line 1060 of file wined3d.h.

◆ WINED3DMAX30SHADERINSTRUCTIONS

#define WINED3DMAX30SHADERINSTRUCTIONS   32768

Definition at line 1066 of file wined3d.h.

◆ WINED3DMIN30SHADERINSTRUCTIONS

#define WINED3DMIN30SHADERINSTRUCTIONS   512

Definition at line 1067 of file wined3d.h.

◆ WINED3DOK_NOMIPGEN

#define WINED3DOK_NOMIPGEN   MAKE_WINED3DSTATUS(2159)

Definition at line 41 of file wined3d.h.

◆ WINED3DPBLENDCAPS_BLENDFACTOR

#define WINED3DPBLENDCAPS_BLENDFACTOR   0x00002000

Definition at line 1082 of file wined3d.h.

◆ WINED3DPBLENDCAPS_BOTHINVSRCALPHA

#define WINED3DPBLENDCAPS_BOTHINVSRCALPHA   0x00001000

Definition at line 1081 of file wined3d.h.

◆ WINED3DPBLENDCAPS_BOTHSRCALPHA

#define WINED3DPBLENDCAPS_BOTHSRCALPHA   0x00000800

Definition at line 1080 of file wined3d.h.

◆ WINED3DPBLENDCAPS_DESTALPHA

#define WINED3DPBLENDCAPS_DESTALPHA   0x00000040

Definition at line 1075 of file wined3d.h.

◆ WINED3DPBLENDCAPS_DESTCOLOR

#define WINED3DPBLENDCAPS_DESTCOLOR   0x00000100

Definition at line 1077 of file wined3d.h.

◆ WINED3DPBLENDCAPS_INVDESTALPHA

#define WINED3DPBLENDCAPS_INVDESTALPHA   0x00000080

Definition at line 1076 of file wined3d.h.

◆ WINED3DPBLENDCAPS_INVDESTCOLOR

#define WINED3DPBLENDCAPS_INVDESTCOLOR   0x00000200

Definition at line 1078 of file wined3d.h.

◆ WINED3DPBLENDCAPS_INVSRCALPHA

#define WINED3DPBLENDCAPS_INVSRCALPHA   0x00000020

Definition at line 1074 of file wined3d.h.

◆ WINED3DPBLENDCAPS_INVSRCCOLOR

#define WINED3DPBLENDCAPS_INVSRCCOLOR   0x00000008

Definition at line 1072 of file wined3d.h.

◆ WINED3DPBLENDCAPS_ONE

#define WINED3DPBLENDCAPS_ONE   0x00000002

Definition at line 1070 of file wined3d.h.

◆ WINED3DPBLENDCAPS_SRCALPHA

#define WINED3DPBLENDCAPS_SRCALPHA   0x00000010

Definition at line 1073 of file wined3d.h.

◆ WINED3DPBLENDCAPS_SRCALPHASAT

#define WINED3DPBLENDCAPS_SRCALPHASAT   0x00000400

Definition at line 1079 of file wined3d.h.

◆ WINED3DPBLENDCAPS_SRCCOLOR

#define WINED3DPBLENDCAPS_SRCCOLOR   0x00000004

Definition at line 1071 of file wined3d.h.

◆ WINED3DPBLENDCAPS_ZERO

#define WINED3DPBLENDCAPS_ZERO   0x00000001

Definition at line 1069 of file wined3d.h.

◆ WINED3DPCMPCAPS_ALWAYS

#define WINED3DPCMPCAPS_ALWAYS   0x00000080

Definition at line 1091 of file wined3d.h.

◆ WINED3DPCMPCAPS_EQUAL

#define WINED3DPCMPCAPS_EQUAL   0x00000004

Definition at line 1086 of file wined3d.h.

◆ WINED3DPCMPCAPS_GREATER

#define WINED3DPCMPCAPS_GREATER   0x00000010

Definition at line 1088 of file wined3d.h.

◆ WINED3DPCMPCAPS_GREATEREQUAL

#define WINED3DPCMPCAPS_GREATEREQUAL   0x00000040

Definition at line 1090 of file wined3d.h.

◆ WINED3DPCMPCAPS_LESS

#define WINED3DPCMPCAPS_LESS   0x00000002

Definition at line 1085 of file wined3d.h.

◆ WINED3DPCMPCAPS_LESSEQUAL

#define WINED3DPCMPCAPS_LESSEQUAL   0x00000008

Definition at line 1087 of file wined3d.h.

◆ WINED3DPCMPCAPS_NEVER

#define WINED3DPCMPCAPS_NEVER   0x00000001

Definition at line 1084 of file wined3d.h.

◆ WINED3DPCMPCAPS_NOTEQUAL

#define WINED3DPCMPCAPS_NOTEQUAL   0x00000020

Definition at line 1089 of file wined3d.h.

◆ WINED3DPMISCCAPS_BLENDOP

#define WINED3DPMISCCAPS_BLENDOP   0x00000800

Definition at line 1102 of file wined3d.h.

◆ WINED3DPMISCCAPS_CLIPPLANESCALEDPOINTS

#define WINED3DPMISCCAPS_CLIPPLANESCALEDPOINTS   0x00000100

Definition at line 1099 of file wined3d.h.

◆ WINED3DPMISCCAPS_CLIPTLVERTS

#define WINED3DPMISCCAPS_CLIPTLVERTS   0x00000200

Definition at line 1100 of file wined3d.h.

◆ WINED3DPMISCCAPS_COLORWRITEENABLE

#define WINED3DPMISCCAPS_COLORWRITEENABLE   0x00000080

Definition at line 1098 of file wined3d.h.

◆ WINED3DPMISCCAPS_CULLCCW

#define WINED3DPMISCCAPS_CULLCCW   0x00000040

Definition at line 1097 of file wined3d.h.

◆ WINED3DPMISCCAPS_CULLCW

#define WINED3DPMISCCAPS_CULLCW   0x00000020

Definition at line 1096 of file wined3d.h.

◆ WINED3DPMISCCAPS_CULLNONE

#define WINED3DPMISCCAPS_CULLNONE   0x00000010

Definition at line 1095 of file wined3d.h.

◆ WINED3DPMISCCAPS_FOGANDSPECULARALPHA

#define WINED3DPMISCCAPS_FOGANDSPECULARALPHA   0x00010000

Definition at line 1106 of file wined3d.h.

◆ WINED3DPMISCCAPS_FOGVERTEXCLAMPED

#define WINED3DPMISCCAPS_FOGVERTEXCLAMPED   0x00100000

Definition at line 1110 of file wined3d.h.

◆ WINED3DPMISCCAPS_INDEPENDENTWRITEMASKS

#define WINED3DPMISCCAPS_INDEPENDENTWRITEMASKS   0x00004000

Definition at line 1104 of file wined3d.h.

◆ WINED3DPMISCCAPS_LINEPATTERNREP

#define WINED3DPMISCCAPS_LINEPATTERNREP   0x00000004

Definition at line 1094 of file wined3d.h.

◆ WINED3DPMISCCAPS_MASKZ

#define WINED3DPMISCCAPS_MASKZ   0x00000002

Definition at line 1093 of file wined3d.h.

◆ WINED3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS

#define WINED3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS   0x00040000

Definition at line 1108 of file wined3d.h.

◆ WINED3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING

#define WINED3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING   0x00080000

Definition at line 1109 of file wined3d.h.

◆ WINED3DPMISCCAPS_NULLREFERENCE

#define WINED3DPMISCCAPS_NULLREFERENCE   0x00001000

Definition at line 1103 of file wined3d.h.

◆ WINED3DPMISCCAPS_PERSTAGECONSTANT

#define WINED3DPMISCCAPS_PERSTAGECONSTANT   0x00008000

Definition at line 1105 of file wined3d.h.

◆ WINED3DPMISCCAPS_POSTBLENDSRGBCONVERT

#define WINED3DPMISCCAPS_POSTBLENDSRGBCONVERT   0x00200000

Definition at line 1111 of file wined3d.h.

◆ WINED3DPMISCCAPS_SEPARATEALPHABLEND

#define WINED3DPMISCCAPS_SEPARATEALPHABLEND   0x00020000

Definition at line 1107 of file wined3d.h.

◆ WINED3DPMISCCAPS_TSSARGTEMP

#define WINED3DPMISCCAPS_TSSARGTEMP   0x00000400

Definition at line 1101 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ANISOTROPY

#define WINED3DPRASTERCAPS_ANISOTROPY   0x00020000

Definition at line 1207 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ANTIALIASEDGES

#define WINED3DPRASTERCAPS_ANTIALIASEDGES   0x00001000

Definition at line 1202 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ANTIALIASSORTDEPENDENT

#define WINED3DPRASTERCAPS_ANTIALIASSORTDEPENDENT   0x00000400

Definition at line 1200 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT

#define WINED3DPRASTERCAPS_ANTIALIASSORTINDEPENDENT   0x00000800

Definition at line 1201 of file wined3d.h.

◆ WINED3DPRASTERCAPS_COLORPERSPECTIVE

#define WINED3DPRASTERCAPS_COLORPERSPECTIVE   0x00400000

Definition at line 1212 of file wined3d.h.

◆ WINED3DPRASTERCAPS_DEPTHBIAS

#define WINED3DPRASTERCAPS_DEPTHBIAS   0x04000000

Definition at line 1215 of file wined3d.h.

◆ WINED3DPRASTERCAPS_DITHER

#define WINED3DPRASTERCAPS_DITHER   0x00000001

Definition at line 1190 of file wined3d.h.

◆ WINED3DPRASTERCAPS_FOGRANGE

#define WINED3DPRASTERCAPS_FOGRANGE   0x00010000

Definition at line 1206 of file wined3d.h.

◆ WINED3DPRASTERCAPS_FOGTABLE

#define WINED3DPRASTERCAPS_FOGTABLE   0x00000100

Definition at line 1198 of file wined3d.h.

◆ WINED3DPRASTERCAPS_FOGVERTEX

#define WINED3DPRASTERCAPS_FOGVERTEX   0x00000080

Definition at line 1197 of file wined3d.h.

◆ WINED3DPRASTERCAPS_MIPMAPLODBIAS

#define WINED3DPRASTERCAPS_MIPMAPLODBIAS   0x00002000

Definition at line 1203 of file wined3d.h.

◆ WINED3DPRASTERCAPS_MULTISAMPLE_TOGGLE

#define WINED3DPRASTERCAPS_MULTISAMPLE_TOGGLE   0x08000000

Definition at line 1216 of file wined3d.h.

◆ WINED3DPRASTERCAPS_PAT

#define WINED3DPRASTERCAPS_PAT   0x00000008

Definition at line 1193 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ROP2

#define WINED3DPRASTERCAPS_ROP2   0x00000002

Definition at line 1191 of file wined3d.h.

◆ WINED3DPRASTERCAPS_SCISSORTEST

#define WINED3DPRASTERCAPS_SCISSORTEST   0x01000000

Definition at line 1213 of file wined3d.h.

◆ WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS

#define WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS   0x02000000

Definition at line 1214 of file wined3d.h.

◆ WINED3DPRASTERCAPS_STIPPLE

#define WINED3DPRASTERCAPS_STIPPLE   0x00000200

Definition at line 1199 of file wined3d.h.

◆ WINED3DPRASTERCAPS_SUBPIXEL

#define WINED3DPRASTERCAPS_SUBPIXEL   0x00000020

Definition at line 1195 of file wined3d.h.

◆ WINED3DPRASTERCAPS_SUBPIXELX

#define WINED3DPRASTERCAPS_SUBPIXELX   0x00000040

Definition at line 1196 of file wined3d.h.

◆ WINED3DPRASTERCAPS_TRANSLUCENTSORTINDEPENDENT

#define WINED3DPRASTERCAPS_TRANSLUCENTSORTINDEPENDENT   0x00080000

Definition at line 1209 of file wined3d.h.

◆ WINED3DPRASTERCAPS_WBUFFER

#define WINED3DPRASTERCAPS_WBUFFER   0x00040000

Definition at line 1208 of file wined3d.h.

◆ WINED3DPRASTERCAPS_WFOG

#define WINED3DPRASTERCAPS_WFOG   0x00100000

Definition at line 1210 of file wined3d.h.

◆ WINED3DPRASTERCAPS_XOR

#define WINED3DPRASTERCAPS_XOR   0x00000004

Definition at line 1192 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ZBIAS

#define WINED3DPRASTERCAPS_ZBIAS   0x00004000

Definition at line 1204 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ZBUFFERLESSHSR

#define WINED3DPRASTERCAPS_ZBUFFERLESSHSR   0x00008000

Definition at line 1205 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ZFOG

#define WINED3DPRASTERCAPS_ZFOG   0x00200000

Definition at line 1211 of file wined3d.h.

◆ WINED3DPRASTERCAPS_ZTEST

#define WINED3DPRASTERCAPS_ZTEST   0x00000010

Definition at line 1194 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_DEFAULT

#define WINED3DPRESENT_INTERVAL_DEFAULT   0x00000000

Definition at line 943 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_FOUR

#define WINED3DPRESENT_INTERVAL_FOUR   0x00000008

Definition at line 947 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_IMMEDIATE

#define WINED3DPRESENT_INTERVAL_IMMEDIATE   0x80000000

Definition at line 948 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_ONE

#define WINED3DPRESENT_INTERVAL_ONE   0x00000001

Definition at line 944 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_THREE

#define WINED3DPRESENT_INTERVAL_THREE   0x00000004

Definition at line 946 of file wined3d.h.

◆ WINED3DPRESENT_INTERVAL_TWO

#define WINED3DPRESENT_INTERVAL_TWO   0x00000002

Definition at line 945 of file wined3d.h.

◆ WINED3DPRESENT_RATE_DEFAULT

#define WINED3DPRESENT_RATE_DEFAULT   0x00000000

Definition at line 941 of file wined3d.h.

◆ WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH

#define WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH   24

Definition at line 1113 of file wined3d.h.

◆ WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS

#define WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS   512

Definition at line 1119 of file wined3d.h.

◆ WINED3DPS20_MAX_NUMTEMPS

#define WINED3DPS20_MAX_NUMTEMPS   32

Definition at line 1115 of file wined3d.h.

◆ WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH

#define WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH   4

Definition at line 1117 of file wined3d.h.

◆ WINED3DPS20_MIN_DYNAMICFLOWCONTROLDEPTH

#define WINED3DPS20_MIN_DYNAMICFLOWCONTROLDEPTH   0

Definition at line 1114 of file wined3d.h.

◆ WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS

#define WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS   96

Definition at line 1120 of file wined3d.h.

◆ WINED3DPS20_MIN_NUMTEMPS

#define WINED3DPS20_MIN_NUMTEMPS   12

Definition at line 1116 of file wined3d.h.

◆ WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH

#define WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH   0

Definition at line 1118 of file wined3d.h.

◆ WINED3DPS20CAPS_ARBITRARYSWIZZLE

#define WINED3DPS20CAPS_ARBITRARYSWIZZLE   0x00000001

Definition at line 1122 of file wined3d.h.

◆ WINED3DPS20CAPS_GRADIENTINSTRUCTIONS

#define WINED3DPS20CAPS_GRADIENTINSTRUCTIONS   0x00000002

Definition at line 1123 of file wined3d.h.

◆ WINED3DPS20CAPS_NODEPENDENTREADLIMIT

#define WINED3DPS20CAPS_NODEPENDENTREADLIMIT   0x00000008

Definition at line 1125 of file wined3d.h.

◆ WINED3DPS20CAPS_NOTEXINSTRUCTIONLIMIT

#define WINED3DPS20CAPS_NOTEXINSTRUCTIONLIMIT   0x00000010

Definition at line 1126 of file wined3d.h.

◆ WINED3DPS20CAPS_PREDICATION

#define WINED3DPS20CAPS_PREDICATION   0x00000004

Definition at line 1124 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAFLATBLEND

#define WINED3DPSHADECAPS_ALPHAFLATBLEND   0x00001000

Definition at line 1230 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAFLATSTIPPLED

#define WINED3DPSHADECAPS_ALPHAFLATSTIPPLED   0x00002000

Definition at line 1231 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAGOURAUDBLEND

#define WINED3DPSHADECAPS_ALPHAGOURAUDBLEND   0x00004000

Definition at line 1232 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAGOURAUDSTIPPLED

#define WINED3DPSHADECAPS_ALPHAGOURAUDSTIPPLED   0x00008000

Definition at line 1233 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAPHONGBLEND

#define WINED3DPSHADECAPS_ALPHAPHONGBLEND   0x00010000

Definition at line 1234 of file wined3d.h.

◆ WINED3DPSHADECAPS_ALPHAPHONGSTIPPLED

#define WINED3DPSHADECAPS_ALPHAPHONGSTIPPLED   0x00020000

Definition at line 1235 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORFLATMONO

#define WINED3DPSHADECAPS_COLORFLATMONO   0x00000001

Definition at line 1218 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORFLATRGB

#define WINED3DPSHADECAPS_COLORFLATRGB   0x00000002

Definition at line 1219 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORGOURAUDMONO

#define WINED3DPSHADECAPS_COLORGOURAUDMONO   0x00000004

Definition at line 1220 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORGOURAUDRGB

#define WINED3DPSHADECAPS_COLORGOURAUDRGB   0x00000008

Definition at line 1221 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORPHONGMONO

#define WINED3DPSHADECAPS_COLORPHONGMONO   0x00000010

Definition at line 1222 of file wined3d.h.

◆ WINED3DPSHADECAPS_COLORPHONGRGB

#define WINED3DPSHADECAPS_COLORPHONGRGB   0x00000020

Definition at line 1223 of file wined3d.h.

◆ WINED3DPSHADECAPS_FOGFLAT

#define WINED3DPSHADECAPS_FOGFLAT   0x00040000

Definition at line 1236 of file wined3d.h.

◆ WINED3DPSHADECAPS_FOGGOURAUD

#define WINED3DPSHADECAPS_FOGGOURAUD   0x00080000

Definition at line 1237 of file wined3d.h.

◆ WINED3DPSHADECAPS_FOGPHONG

#define WINED3DPSHADECAPS_FOGPHONG   0x00100000

Definition at line 1238 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARFLATMONO

#define WINED3DPSHADECAPS_SPECULARFLATMONO   0x00000040

Definition at line 1224 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARFLATRGB

#define WINED3DPSHADECAPS_SPECULARFLATRGB   0x00000080

Definition at line 1225 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARGOURAUDMONO

#define WINED3DPSHADECAPS_SPECULARGOURAUDMONO   0x00000100

Definition at line 1226 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARGOURAUDRGB

#define WINED3DPSHADECAPS_SPECULARGOURAUDRGB   0x00000200

Definition at line 1227 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARPHONGMONO

#define WINED3DPSHADECAPS_SPECULARPHONGMONO   0x00000400

Definition at line 1228 of file wined3d.h.

◆ WINED3DPSHADECAPS_SPECULARPHONGRGB

#define WINED3DPSHADECAPS_SPECULARPHONGRGB   0x00000800

Definition at line 1229 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_BORDER

#define WINED3DPTADDRESSCAPS_BORDER   0x00000008

Definition at line 1131 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_CLAMP

#define WINED3DPTADDRESSCAPS_CLAMP   0x00000004

Definition at line 1130 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_INDEPENDENTUV

#define WINED3DPTADDRESSCAPS_INDEPENDENTUV   0x00000010

Definition at line 1132 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_MIRROR

#define WINED3DPTADDRESSCAPS_MIRROR   0x00000002

Definition at line 1129 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_MIRRORONCE

#define WINED3DPTADDRESSCAPS_MIRRORONCE   0x00000020

Definition at line 1133 of file wined3d.h.

◆ WINED3DPTADDRESSCAPS_WRAP

#define WINED3DPTADDRESSCAPS_WRAP   0x00000001

Definition at line 1128 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_ALPHA

#define WINED3DPTEXTURECAPS_ALPHA   0x00000004

Definition at line 1242 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_ALPHAPALETTE

#define WINED3DPTEXTURECAPS_ALPHAPALETTE   0x00000080

Definition at line 1247 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_BORDER

#define WINED3DPTEXTURECAPS_BORDER   0x00000010

Definition at line 1244 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_COLORKEYBLEND

#define WINED3DPTEXTURECAPS_COLORKEYBLEND   0x00001000

Definition at line 1251 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_CUBEMAP

#define WINED3DPTEXTURECAPS_CUBEMAP   0x00000800

Definition at line 1250 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_CUBEMAP_POW2

#define WINED3DPTEXTURECAPS_CUBEMAP_POW2   0x00020000

Definition at line 1256 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_MIPCUBEMAP

#define WINED3DPTEXTURECAPS_MIPCUBEMAP   0x00010000

Definition at line 1255 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_MIPMAP

#define WINED3DPTEXTURECAPS_MIPMAP   0x00004000

Definition at line 1253 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_MIPVOLUMEMAP

#define WINED3DPTEXTURECAPS_MIPVOLUMEMAP   0x00008000

Definition at line 1254 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL

#define WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL   0x00000100

Definition at line 1248 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_NOPROJECTEDBUMPENV

#define WINED3DPTEXTURECAPS_NOPROJECTEDBUMPENV   0x00200000

Definition at line 1258 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_PERSPECTIVE

#define WINED3DPTEXTURECAPS_PERSPECTIVE   0x00000001

Definition at line 1240 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_POW2

#define WINED3DPTEXTURECAPS_POW2   0x00000002

Definition at line 1241 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_PROJECTED

#define WINED3DPTEXTURECAPS_PROJECTED   0x00000400

Definition at line 1249 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_SQUAREONLY

#define WINED3DPTEXTURECAPS_SQUAREONLY   0x00000020

Definition at line 1245 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE

#define WINED3DPTEXTURECAPS_TEXREPEATNOTSCALEDBYSIZE   0x00000040

Definition at line 1246 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_TRANSPARENCY

#define WINED3DPTEXTURECAPS_TRANSPARENCY   0x00000008

Definition at line 1243 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_VOLUMEMAP

#define WINED3DPTEXTURECAPS_VOLUMEMAP   0x00002000

Definition at line 1252 of file wined3d.h.

◆ WINED3DPTEXTURECAPS_VOLUMEMAP_POW2

#define WINED3DPTEXTURECAPS_VOLUMEMAP_POW2   0x00040000

Definition at line 1257 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_LINEAR

#define WINED3DPTFILTERCAPS_LINEAR   0x00000002

Definition at line 1261 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_LINEARMIPLINEAR

#define WINED3DPTFILTERCAPS_LINEARMIPLINEAR   0x00000020

Definition at line 1265 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_LINEARMIPNEAREST

#define WINED3DPTFILTERCAPS_LINEARMIPNEAREST   0x00000010

Definition at line 1264 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MAGFANISOTROPIC

#define WINED3DPTFILTERCAPS_MAGFANISOTROPIC   0x04000000

Definition at line 1273 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MAGFGAUSSIANQUAD

#define WINED3DPTFILTERCAPS_MAGFGAUSSIANQUAD   0x10000000

Definition at line 1275 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MAGFLINEAR

#define WINED3DPTFILTERCAPS_MAGFLINEAR   0x02000000

Definition at line 1272 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MAGFPOINT

#define WINED3DPTFILTERCAPS_MAGFPOINT   0x01000000

Definition at line 1271 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MAGFPYRAMIDALQUAD

#define WINED3DPTFILTERCAPS_MAGFPYRAMIDALQUAD   0x08000000

Definition at line 1274 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MINFANISOTROPIC

#define WINED3DPTFILTERCAPS_MINFANISOTROPIC   0x00000400

Definition at line 1268 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MINFLINEAR

#define WINED3DPTFILTERCAPS_MINFLINEAR   0x00000200

Definition at line 1267 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MINFPOINT

#define WINED3DPTFILTERCAPS_MINFPOINT   0x00000100

Definition at line 1266 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MIPFLINEAR

#define WINED3DPTFILTERCAPS_MIPFLINEAR   0x00020000

Definition at line 1270 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MIPFPOINT

#define WINED3DPTFILTERCAPS_MIPFPOINT   0x00010000

Definition at line 1269 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MIPLINEAR

#define WINED3DPTFILTERCAPS_MIPLINEAR   0x00000008

Definition at line 1263 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_MIPNEAREST

#define WINED3DPTFILTERCAPS_MIPNEAREST   0x00000004

Definition at line 1262 of file wined3d.h.

◆ WINED3DPTFILTERCAPS_NEAREST

#define WINED3DPTFILTERCAPS_NEAREST   0x00000001

Definition at line 1260 of file wined3d.h.

◆ WINED3DSPD_IUNKNOWN

#define WINED3DSPD_IUNKNOWN   0x00000001

Definition at line 1006 of file wined3d.h.

◆ WINED3DSTENCILCAPS_DECR

#define WINED3DSTENCILCAPS_DECR   0x00000080

Definition at line 1142 of file wined3d.h.

◆ WINED3DSTENCILCAPS_DECRSAT

#define WINED3DSTENCILCAPS_DECRSAT   0x00000010

Definition at line 1139 of file wined3d.h.

◆ WINED3DSTENCILCAPS_INCR

#define WINED3DSTENCILCAPS_INCR   0x00000040

Definition at line 1141 of file wined3d.h.

◆ WINED3DSTENCILCAPS_INCRSAT

#define WINED3DSTENCILCAPS_INCRSAT   0x00000008

Definition at line 1138 of file wined3d.h.

◆ WINED3DSTENCILCAPS_INVERT

#define WINED3DSTENCILCAPS_INVERT   0x00000020

Definition at line 1140 of file wined3d.h.

◆ WINED3DSTENCILCAPS_KEEP

#define WINED3DSTENCILCAPS_KEEP   0x00000001

Definition at line 1135 of file wined3d.h.

◆ WINED3DSTENCILCAPS_REPLACE

#define WINED3DSTENCILCAPS_REPLACE   0x00000004

Definition at line 1137 of file wined3d.h.

◆ WINED3DSTENCILCAPS_TWOSIDED

#define WINED3DSTENCILCAPS_TWOSIDED   0x00000100

Definition at line 1143 of file wined3d.h.

◆ WINED3DSTENCILCAPS_ZERO

#define WINED3DSTENCILCAPS_ZERO   0x00000002

Definition at line 1136 of file wined3d.h.

◆ WINED3DSTREAMSOURCE_INDEXEDDATA

#define WINED3DSTREAMSOURCE_INDEXEDDATA   (1u << 30)

Definition at line 1002 of file wined3d.h.

◆ WINED3DSTREAMSOURCE_INSTANCEDATA

#define WINED3DSTREAMSOURCE_INSTANCEDATA   (2u << 30)

Definition at line 1003 of file wined3d.h.

◆ WINED3DTA_ALPHAREPLICATE

#define WINED3DTA_ALPHAREPLICATE   0x00000020

Definition at line 875 of file wined3d.h.

◆ WINED3DTA_COMPLEMENT

#define WINED3DTA_COMPLEMENT   0x00000010

Definition at line 874 of file wined3d.h.

◆ WINED3DTA_CONSTANT

#define WINED3DTA_CONSTANT   0x00000006

Definition at line 873 of file wined3d.h.

◆ WINED3DTA_CURRENT

#define WINED3DTA_CURRENT   0x00000001

Definition at line 868 of file wined3d.h.

◆ WINED3DTA_DIFFUSE

#define WINED3DTA_DIFFUSE   0x00000000

Definition at line 867 of file wined3d.h.

◆ WINED3DTA_SELECTMASK

#define WINED3DTA_SELECTMASK   0x0000000f

Definition at line 866 of file wined3d.h.

◆ WINED3DTA_SPECULAR

#define WINED3DTA_SPECULAR   0x00000004

Definition at line 871 of file wined3d.h.

◆ WINED3DTA_TEMP

#define WINED3DTA_TEMP   0x00000005

Definition at line 872 of file wined3d.h.

◆ WINED3DTA_TEXTURE

#define WINED3DTA_TEXTURE   0x00000002

Definition at line 869 of file wined3d.h.

◆ WINED3DTA_TFACTOR

#define WINED3DTA_TFACTOR   0x00000003

Definition at line 870 of file wined3d.h.

◆ WINED3DTEXOPCAPS_ADD

#define WINED3DTEXOPCAPS_ADD   0x00000040

Definition at line 1151 of file wined3d.h.

◆ WINED3DTEXOPCAPS_ADDSIGNED

#define WINED3DTEXOPCAPS_ADDSIGNED   0x00000080

Definition at line 1152 of file wined3d.h.

◆ WINED3DTEXOPCAPS_ADDSIGNED2X

#define WINED3DTEXOPCAPS_ADDSIGNED2X   0x00000100

Definition at line 1153 of file wined3d.h.

◆ WINED3DTEXOPCAPS_ADDSMOOTH

#define WINED3DTEXOPCAPS_ADDSMOOTH   0x00000400

Definition at line 1155 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BLENDCURRENTALPHA

#define WINED3DTEXOPCAPS_BLENDCURRENTALPHA   0x00008000

Definition at line 1160 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BLENDDIFFUSEALPHA

#define WINED3DTEXOPCAPS_BLENDDIFFUSEALPHA   0x00000800

Definition at line 1156 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BLENDFACTORALPHA

#define WINED3DTEXOPCAPS_BLENDFACTORALPHA   0x00002000

Definition at line 1158 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BLENDTEXTUREALPHA

#define WINED3DTEXOPCAPS_BLENDTEXTUREALPHA   0x00001000

Definition at line 1157 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BLENDTEXTUREALPHAPM

#define WINED3DTEXOPCAPS_BLENDTEXTUREALPHAPM   0x00004000

Definition at line 1159 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BUMPENVMAP

#define WINED3DTEXOPCAPS_BUMPENVMAP   0x00200000

Definition at line 1166 of file wined3d.h.

◆ WINED3DTEXOPCAPS_BUMPENVMAPLUMINANCE

#define WINED3DTEXOPCAPS_BUMPENVMAPLUMINANCE   0x00400000

Definition at line 1167 of file wined3d.h.

◆ WINED3DTEXOPCAPS_DISABLE

#define WINED3DTEXOPCAPS_DISABLE   0x00000001

Definition at line 1145 of file wined3d.h.

◆ WINED3DTEXOPCAPS_DOTPRODUCT3

#define WINED3DTEXOPCAPS_DOTPRODUCT3   0x00800000

Definition at line 1168 of file wined3d.h.

◆ WINED3DTEXOPCAPS_LERP

#define WINED3DTEXOPCAPS_LERP   0x02000000

Definition at line 1170 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATE

#define WINED3DTEXOPCAPS_MODULATE   0x00000008

Definition at line 1148 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATE2X

#define WINED3DTEXOPCAPS_MODULATE2X   0x00000010

Definition at line 1149 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATE4X

#define WINED3DTEXOPCAPS_MODULATE4X   0x00000020

Definition at line 1150 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATEALPHA_ADDCOLOR

#define WINED3DTEXOPCAPS_MODULATEALPHA_ADDCOLOR   0x00020000

Definition at line 1162 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATECOLOR_ADDALPHA

#define WINED3DTEXOPCAPS_MODULATECOLOR_ADDALPHA   0x00040000

Definition at line 1163 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATEINVALPHA_ADDCOLOR

#define WINED3DTEXOPCAPS_MODULATEINVALPHA_ADDCOLOR   0x00080000

Definition at line 1164 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MODULATEINVCOLOR_ADDALPHA

#define WINED3DTEXOPCAPS_MODULATEINVCOLOR_ADDALPHA   0x00100000

Definition at line 1165 of file wined3d.h.

◆ WINED3DTEXOPCAPS_MULTIPLYADD

#define WINED3DTEXOPCAPS_MULTIPLYADD   0x01000000

Definition at line 1169 of file wined3d.h.

◆ WINED3DTEXOPCAPS_PREMODULATE

#define WINED3DTEXOPCAPS_PREMODULATE   0x00010000

Definition at line 1161 of file wined3d.h.

◆ WINED3DTEXOPCAPS_SELECTARG1

#define WINED3DTEXOPCAPS_SELECTARG1   0x00000002

Definition at line 1146 of file wined3d.h.

◆ WINED3DTEXOPCAPS_SELECTARG2

#define WINED3DTEXOPCAPS_SELECTARG2   0x00000004

Definition at line 1147 of file wined3d.h.

◆ WINED3DTEXOPCAPS_SUBTRACT

#define WINED3DTEXOPCAPS_SUBTRACT   0x00000200

Definition at line 1154 of file wined3d.h.

◆ WINED3DTSS_TCI_CAMERASPACENORMAL

#define WINED3DTSS_TCI_CAMERASPACENORMAL   0x10000

Definition at line 861 of file wined3d.h.

◆ WINED3DTSS_TCI_CAMERASPACEPOSITION

#define WINED3DTSS_TCI_CAMERASPACEPOSITION   0x20000

Definition at line 862 of file wined3d.h.

◆ WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR

#define WINED3DTSS_TCI_CAMERASPACEREFLECTIONVECTOR   0x30000

Definition at line 863 of file wined3d.h.

◆ WINED3DTSS_TCI_PASSTHRU

#define WINED3DTSS_TCI_PASSTHRU   0x00000

Definition at line 860 of file wined3d.h.

◆ WINED3DTSS_TCI_SPHEREMAP

#define WINED3DTSS_TCI_SPHEREMAP   0x40000

Definition at line 864 of file wined3d.h.

◆ WINED3DUSAGE_DEPTHSTENCIL

#define WINED3DUSAGE_DEPTHSTENCIL   0x00000002

Definition at line 900 of file wined3d.h.

◆ WINED3DUSAGE_DMAP

#define WINED3DUSAGE_DMAP   0x00004000

Definition at line 911 of file wined3d.h.

◆ WINED3DUSAGE_DONOTCLIP

#define WINED3DUSAGE_DONOTCLIP   0x00000020

Definition at line 903 of file wined3d.h.

◆ WINED3DUSAGE_DYNAMIC

#define WINED3DUSAGE_DYNAMIC   0x00000200

Definition at line 907 of file wined3d.h.

◆ WINED3DUSAGE_LEGACY_CUBEMAP

#define WINED3DUSAGE_LEGACY_CUBEMAP   0x00800000

Definition at line 917 of file wined3d.h.

◆ WINED3DUSAGE_MASK

#define WINED3DUSAGE_MASK   0x10007bff

Definition at line 913 of file wined3d.h.

◆ WINED3DUSAGE_NPATCHES

#define WINED3DUSAGE_NPATCHES   0x00000100

Definition at line 906 of file wined3d.h.

◆ WINED3DUSAGE_OVERLAY

#define WINED3DUSAGE_OVERLAY   0x08000000

Definition at line 921 of file wined3d.h.

◆ WINED3DUSAGE_OWNDC

#define WINED3DUSAGE_OWNDC   0x02000000

Definition at line 919 of file wined3d.h.

◆ WINED3DUSAGE_POINTS

#define WINED3DUSAGE_POINTS   0x00000040

Definition at line 904 of file wined3d.h.

◆ WINED3DUSAGE_PRIVATE

#define WINED3DUSAGE_PRIVATE   0x00400000

Definition at line 916 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_FILTER

#define WINED3DUSAGE_QUERY_FILTER   0x00020000

Definition at line 925 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_GENMIPMAP

#define WINED3DUSAGE_QUERY_GENMIPMAP   0x00000400

Definition at line 923 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_LEGACYBUMPMAP

#define WINED3DUSAGE_QUERY_LEGACYBUMPMAP   0x00008000

Definition at line 924 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_MASK

#define WINED3DUSAGE_QUERY_MASK   0x003f8400

Definition at line 931 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING

#define WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING   0x00080000

Definition at line 926 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_SRGBREAD

#define WINED3DUSAGE_QUERY_SRGBREAD   0x00010000

Definition at line 927 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_SRGBWRITE

#define WINED3DUSAGE_QUERY_SRGBWRITE   0x00040000

Definition at line 928 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_VERTEXTEXTURE

#define WINED3DUSAGE_QUERY_VERTEXTEXTURE   0x00100000

Definition at line 929 of file wined3d.h.

◆ WINED3DUSAGE_QUERY_WRAPANDMIP

#define WINED3DUSAGE_QUERY_WRAPANDMIP   0x00200000

Definition at line 930 of file wined3d.h.

◆ WINED3DUSAGE_RENDERTARGET

#define WINED3DUSAGE_RENDERTARGET   0x00000001

Definition at line 899 of file wined3d.h.

◆ WINED3DUSAGE_RESTRICT_SHARED_RESOURCE

#define WINED3DUSAGE_RESTRICT_SHARED_RESOURCE   0x00002000

Definition at line 910 of file wined3d.h.

◆ WINED3DUSAGE_RESTRICT_SHARED_RESOURCE_DRIVER

#define WINED3DUSAGE_RESTRICT_SHARED_RESOURCE_DRIVER   0x00001000

Definition at line 909 of file wined3d.h.

◆ WINED3DUSAGE_RESTRICTED_CONTENT

#define WINED3DUSAGE_RESTRICTED_CONTENT   0x00000800

Definition at line 908 of file wined3d.h.

◆ WINED3DUSAGE_RTPATCHES

#define WINED3DUSAGE_RTPATCHES   0x00000080

Definition at line 905 of file wined3d.h.

◆ WINED3DUSAGE_SCRATCH

#define WINED3DUSAGE_SCRATCH   0x00200000

Definition at line 915 of file wined3d.h.

◆ WINED3DUSAGE_SOFTWAREPROCESSING

#define WINED3DUSAGE_SOFTWAREPROCESSING   0x00000010

Definition at line 902 of file wined3d.h.

◆ WINED3DUSAGE_STATICDECL

#define WINED3DUSAGE_STATICDECL   0x04000000

Definition at line 920 of file wined3d.h.

◆ WINED3DUSAGE_TEXTAPI

#define WINED3DUSAGE_TEXTAPI   0x10000000

Definition at line 912 of file wined3d.h.

◆ WINED3DUSAGE_TEXTURE

#define WINED3DUSAGE_TEXTURE   0x01000000

Definition at line 918 of file wined3d.h.

◆ WINED3DUSAGE_WRITEONLY

#define WINED3DUSAGE_WRITEONLY   0x00000008

Definition at line 901 of file wined3d.h.

◆ WINED3DVERTEXTEXTURESAMPLER0

#define WINED3DVERTEXTEXTURESAMPLER0   (WINED3DDMAPSAMPLER + 1)

Definition at line 1025 of file wined3d.h.

◆ WINED3DVERTEXTEXTURESAMPLER1

#define WINED3DVERTEXTEXTURESAMPLER1   (WINED3DDMAPSAMPLER + 2)

Definition at line 1026 of file wined3d.h.

◆ WINED3DVERTEXTEXTURESAMPLER2

#define WINED3DVERTEXTEXTURESAMPLER2   (WINED3DDMAPSAMPLER + 3)

Definition at line 1027 of file wined3d.h.

◆ WINED3DVERTEXTEXTURESAMPLER3

#define WINED3DVERTEXTEXTURESAMPLER3   (WINED3DDMAPSAMPLER + 4)

Definition at line 1028 of file wined3d.h.

◆ WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH

#define WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH   24

Definition at line 1172 of file wined3d.h.

◆ WINED3DVS20_MAX_NUMTEMPS

#define WINED3DVS20_MAX_NUMTEMPS   32

Definition at line 1174 of file wined3d.h.

◆ WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH

#define WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH   4

Definition at line 1176 of file wined3d.h.

◆ WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH

#define WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH   0

Definition at line 1173 of file wined3d.h.

◆ WINED3DVS20_MIN_NUMTEMPS

#define WINED3DVS20_MIN_NUMTEMPS   12

Definition at line 1175 of file wined3d.h.

◆ WINED3DVS20_MIN_STATICFLOWCONTROLDEPTH

#define WINED3DVS20_MIN_STATICFLOWCONTROLDEPTH   1

Definition at line 1177 of file wined3d.h.

◆ WINED3DVS20CAPS_PREDICATION

#define WINED3DVS20CAPS_PREDICATION   0x00000001

Definition at line 1179 of file wined3d.h.

◆ WINED3DVTXPCAPS_DIRECTIONALLIGHTS

#define WINED3DVTXPCAPS_DIRECTIONALLIGHTS   0x00000008

Definition at line 1280 of file wined3d.h.

◆ WINED3DVTXPCAPS_LOCALVIEWER

#define WINED3DVTXPCAPS_LOCALVIEWER   0x00000020

Definition at line 1282 of file wined3d.h.

◆ WINED3DVTXPCAPS_MATERIALSOURCE7

#define WINED3DVTXPCAPS_MATERIALSOURCE7   0x00000002

Definition at line 1278 of file wined3d.h.

◆ WINED3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER

#define WINED3DVTXPCAPS_NO_TEXGEN_NONLOCALVIEWER   0x00000200

Definition at line 1285 of file wined3d.h.

◆ WINED3DVTXPCAPS_POSITIONALLIGHTS

#define WINED3DVTXPCAPS_POSITIONALLIGHTS   0x00000010

Definition at line 1281 of file wined3d.h.

◆ WINED3DVTXPCAPS_TEXGEN

#define WINED3DVTXPCAPS_TEXGEN   0x00000001

Definition at line 1277 of file wined3d.h.

◆ WINED3DVTXPCAPS_TEXGEN_SPHEREMAP

#define WINED3DVTXPCAPS_TEXGEN_SPHEREMAP   0x00000100

Definition at line 1284 of file wined3d.h.

◆ WINED3DVTXPCAPS_TWEENING

#define WINED3DVTXPCAPS_TWEENING   0x00000040

Definition at line 1283 of file wined3d.h.

◆ WINED3DVTXPCAPS_VERTEXFOG

#define WINED3DVTXPCAPS_VERTEXFOG   0x00000004

Definition at line 1279 of file wined3d.h.

◆ WINEDDBLTFX_ARITHSTRETCHY

#define WINEDDBLTFX_ARITHSTRETCHY   0x00000001

Definition at line 1341 of file wined3d.h.

◆ WINEDDBLTFX_MIRRORLEFTRIGHT

#define WINEDDBLTFX_MIRRORLEFTRIGHT   0x00000002

Definition at line 1343 of file wined3d.h.

◆ WINEDDBLTFX_MIRRORUPDOWN

#define WINEDDBLTFX_MIRRORUPDOWN   0x00000004

Definition at line 1345 of file wined3d.h.

◆ WINEDDBLTFX_NOTEARING

#define WINEDDBLTFX_NOTEARING   0x00000008

Definition at line 1347 of file wined3d.h.

◆ WINEDDBLTFX_ROTATE180

#define WINEDDBLTFX_ROTATE180   0x00000010

Definition at line 1349 of file wined3d.h.

◆ WINEDDBLTFX_ROTATE270

#define WINEDDBLTFX_ROTATE270   0x00000020

Definition at line 1351 of file wined3d.h.

◆ WINEDDBLTFX_ROTATE90

#define WINEDDBLTFX_ROTATE90   0x00000040

Definition at line 1353 of file wined3d.h.

◆ WINEDDBLTFX_ZBUFFERBASEDEST

#define WINEDDBLTFX_ZBUFFERBASEDEST   0x00000100

Definition at line 1357 of file wined3d.h.

◆ WINEDDBLTFX_ZBUFFERRANGE

#define WINEDDBLTFX_ZBUFFERRANGE   0x00000080

Definition at line 1355 of file wined3d.h.

◆ WINEDDCAPS2_AUTOFLIPOVERLAY

#define WINEDDCAPS2_AUTOFLIPOVERLAY   0x00000008

Definition at line 1531 of file wined3d.h.

◆ WINEDDCAPS2_CANBOBHARDWARE

#define WINEDDCAPS2_CANBOBHARDWARE   0x00004000

Definition at line 1542 of file wined3d.h.

◆ WINEDDCAPS2_CANBOBINTERLEAVED

#define WINEDDCAPS2_CANBOBINTERLEAVED   0x00000010

Definition at line 1532 of file wined3d.h.

◆ WINEDDCAPS2_CANBOBNONINTERLEAVED

#define WINEDDCAPS2_CANBOBNONINTERLEAVED   0x00000020

Definition at line 1533 of file wined3d.h.

◆ WINEDDCAPS2_CANCALIBRATEGAMMA

#define WINEDDCAPS2_CANCALIBRATEGAMMA   0x00100000

Definition at line 1546 of file wined3d.h.

◆ WINEDDCAPS2_CANDROPZ16BIT

#define WINEDDCAPS2_CANDROPZ16BIT   0x00000100

Definition at line 1536 of file wined3d.h.

◆ WINEDDCAPS2_CANFLIPODDEVEN

#define WINEDDCAPS2_CANFLIPODDEVEN   0x00002000

Definition at line 1541 of file wined3d.h.

◆ WINEDDCAPS2_CANMANAGETEXTURE

#define WINEDDCAPS2_CANMANAGETEXTURE   0x00800000

Definition at line 1549 of file wined3d.h.

◆ WINEDDCAPS2_CANRENDERWINDOWED

#define WINEDDCAPS2_CANRENDERWINDOWED   0x00080000

Definition at line 1545 of file wined3d.h.

◆ WINEDDCAPS2_CERTIFIED

#define WINEDDCAPS2_CERTIFIED   0x00000001

Definition at line 1528 of file wined3d.h.

◆ WINEDDCAPS2_COLORCONTROLOVERLAY

#define WINEDDCAPS2_COLORCONTROLOVERLAY   0x00000040

Definition at line 1534 of file wined3d.h.

◆ WINEDDCAPS2_COLORCONTROLPRIMARY

#define WINEDDCAPS2_COLORCONTROLPRIMARY   0x00000080

Definition at line 1535 of file wined3d.h.

◆ WINEDDCAPS2_COPYFOURCC

#define WINEDDCAPS2_COPYFOURCC   0x00008000

Definition at line 1543 of file wined3d.h.

◆ WINEDDCAPS2_FLIPINTERVAL

#define WINEDDCAPS2_FLIPINTERVAL   0x00200000

Definition at line 1547 of file wined3d.h.

◆ WINEDDCAPS2_FLIPNOVSYNC

#define WINEDDCAPS2_FLIPNOVSYNC   0x00400000

Definition at line 1548 of file wined3d.h.

◆ WINEDDCAPS2_NO2DDURING3DSCENE

#define WINEDDCAPS2_NO2DDURING3DSCENE   0x00000002

Definition at line 1529 of file wined3d.h.

◆ WINEDDCAPS2_NONLOCALVIDMEM

#define WINEDDCAPS2_NONLOCALVIDMEM   0x00000200

Definition at line 1537 of file wined3d.h.

◆ WINEDDCAPS2_NONLOCALVIDMEMCAPS

#define WINEDDCAPS2_NONLOCALVIDMEMCAPS   0x00000400

Definition at line 1538 of file wined3d.h.

◆ WINEDDCAPS2_NOPAGELOCKREQUIRED

#define WINEDDCAPS2_NOPAGELOCKREQUIRED   0x00000800

Definition at line 1539 of file wined3d.h.

◆ WINEDDCAPS2_PRIMARYGAMMA

#define WINEDDCAPS2_PRIMARYGAMMA   0x00020000

Definition at line 1544 of file wined3d.h.

◆ WINEDDCAPS2_STEREO

#define WINEDDCAPS2_STEREO   0x02000000

Definition at line 1551 of file wined3d.h.

◆ WINEDDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL

#define WINEDDCAPS2_SYSTONONLOCAL_AS_SYSTOLOCAL   0x04000000

Definition at line 1552 of file wined3d.h.

◆ WINEDDCAPS2_TEXMANINNONLOCALVIDMEM

#define WINEDDCAPS2_TEXMANINNONLOCALVIDMEM   0x01000000

Definition at line 1550 of file wined3d.h.

◆ WINEDDCAPS2_VIDEOPORT

#define WINEDDCAPS2_VIDEOPORT   0x00000004

Definition at line 1530 of file wined3d.h.

◆ WINEDDCAPS2_WIDESURFACES

#define WINEDDCAPS2_WIDESURFACES   0x00001000

Definition at line 1540 of file wined3d.h.

◆ WINEDDCAPS_3D

#define WINEDDCAPS_3D   0x00000001

Definition at line 1495 of file wined3d.h.

◆ WINEDDCAPS_ALIGNBOUNDARYDEST

#define WINEDDCAPS_ALIGNBOUNDARYDEST   0x00000002

Definition at line 1496 of file wined3d.h.

◆ WINEDDCAPS_ALIGNBOUNDARYSRC

#define WINEDDCAPS_ALIGNBOUNDARYSRC   0x00000008

Definition at line 1498 of file wined3d.h.

◆ WINEDDCAPS_ALIGNSIZEDEST

#define WINEDDCAPS_ALIGNSIZEDEST   0x00000004

Definition at line 1497 of file wined3d.h.

◆ WINEDDCAPS_ALIGNSIZESRC

#define WINEDDCAPS_ALIGNSIZESRC   0x00000010

Definition at line 1499 of file wined3d.h.

◆ WINEDDCAPS_ALIGNSTRIDE

#define WINEDDCAPS_ALIGNSTRIDE   0x00000020

Definition at line 1500 of file wined3d.h.

◆ WINEDDCAPS_ALPHA

#define WINEDDCAPS_ALPHA   0x00800000

Definition at line 1518 of file wined3d.h.

◆ WINEDDCAPS_BANKSWITCHED

#define WINEDDCAPS_BANKSWITCHED   0x08000000

Definition at line 1522 of file wined3d.h.

◆ WINEDDCAPS_BLT

#define WINEDDCAPS_BLT   0x00000040

Definition at line 1501 of file wined3d.h.

◆ WINEDDCAPS_BLTCOLORFILL

#define WINEDDCAPS_BLTCOLORFILL   0x04000000

Definition at line 1521 of file wined3d.h.

◆ WINEDDCAPS_BLTDEPTHFILL

#define WINEDDCAPS_BLTDEPTHFILL   0x10000000

Definition at line 1523 of file wined3d.h.

◆ WINEDDCAPS_BLTFOURCC

#define WINEDDCAPS_BLTFOURCC   0x00000100

Definition at line 1503 of file wined3d.h.

◆ WINEDDCAPS_BLTQUEUE

#define WINEDDCAPS_BLTQUEUE   0x00000080

Definition at line 1502 of file wined3d.h.

◆ WINEDDCAPS_BLTSTRETCH

#define WINEDDCAPS_BLTSTRETCH   0x00000200

Definition at line 1504 of file wined3d.h.

◆ WINEDDCAPS_CANBLTSYSMEM

#define WINEDDCAPS_CANBLTSYSMEM   0x80000000

Definition at line 1526 of file wined3d.h.

◆ WINEDDCAPS_CANCLIP

#define WINEDDCAPS_CANCLIP   0x20000000

Definition at line 1524 of file wined3d.h.

◆ WINEDDCAPS_CANCLIPSTRETCHED

#define WINEDDCAPS_CANCLIPSTRETCHED   0x40000000

Definition at line 1525 of file wined3d.h.

◆ WINEDDCAPS_COLORKEY

#define WINEDDCAPS_COLORKEY   0x00400000

Definition at line 1517 of file wined3d.h.

◆ WINEDDCAPS_COLORKEYHWASSIST

#define WINEDDCAPS_COLORKEYHWASSIST   0x01000000

Definition at line 1519 of file wined3d.h.

◆ WINEDDCAPS_GDI

#define WINEDDCAPS_GDI   0x00000400

Definition at line 1505 of file wined3d.h.

◆ WINEDDCAPS_NOHARDWARE

#define WINEDDCAPS_NOHARDWARE   0x02000000

Definition at line 1520 of file wined3d.h.

◆ WINEDDCAPS_OVERLAY

#define WINEDDCAPS_OVERLAY   0x00000800

Definition at line 1506 of file wined3d.h.

◆ WINEDDCAPS_OVERLAYCANTCLIP

#define WINEDDCAPS_OVERLAYCANTCLIP   0x00001000

Definition at line 1507 of file wined3d.h.

◆ WINEDDCAPS_OVERLAYFOURCC

#define WINEDDCAPS_OVERLAYFOURCC   0x00002000

Definition at line 1508 of file wined3d.h.

◆ WINEDDCAPS_OVERLAYSTRETCH

#define WINEDDCAPS_OVERLAYSTRETCH   0x00004000

Definition at line 1509 of file wined3d.h.

◆ WINEDDCAPS_PALETTE

#define WINEDDCAPS_PALETTE   0x00008000

Definition at line 1510 of file wined3d.h.

◆ WINEDDCAPS_PALETTEVSYNC

#define WINEDDCAPS_PALETTEVSYNC   0x00010000

Definition at line 1511 of file wined3d.h.

◆ WINEDDCAPS_READSCANLINE

#define WINEDDCAPS_READSCANLINE   0x00020000

Definition at line 1512 of file wined3d.h.

◆ WINEDDCAPS_STEREOVIEW

#define WINEDDCAPS_STEREOVIEW   0x00040000

Definition at line 1513 of file wined3d.h.

◆ WINEDDCAPS_VBI

#define WINEDDCAPS_VBI   0x00080000

Definition at line 1514 of file wined3d.h.

◆ WINEDDCAPS_ZBLTS

#define WINEDDCAPS_ZBLTS   0x00100000

Definition at line 1515 of file wined3d.h.

◆ WINEDDCAPS_ZOVERLAYS

#define WINEDDCAPS_ZOVERLAYS   0x00200000

Definition at line 1516 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTBLT

#define WINEDDCKEYCAPS_DESTBLT   0x00000001

Definition at line 1446 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTBLTCLRSPACE

#define WINEDDCKEYCAPS_DESTBLTCLRSPACE   0x00000002

Definition at line 1447 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTBLTCLRSPACEYUV

#define WINEDDCKEYCAPS_DESTBLTCLRSPACEYUV   0x00000004

Definition at line 1448 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTBLTYUV

#define WINEDDCKEYCAPS_DESTBLTYUV   0x00000008

Definition at line 1449 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTOVERLAY

#define WINEDDCKEYCAPS_DESTOVERLAY   0x00000010

Definition at line 1450 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTOVERLAYCLRSPACE

#define WINEDDCKEYCAPS_DESTOVERLAYCLRSPACE   0x00000020

Definition at line 1451 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTOVERLAYCLRSPACEYUV

#define WINEDDCKEYCAPS_DESTOVERLAYCLRSPACEYUV   0x00000040

Definition at line 1452 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTOVERLAYONEACTIVE

#define WINEDDCKEYCAPS_DESTOVERLAYONEACTIVE   0x00000080

Definition at line 1453 of file wined3d.h.

◆ WINEDDCKEYCAPS_DESTOVERLAYYUV

#define WINEDDCKEYCAPS_DESTOVERLAYYUV   0x00000100

Definition at line 1454 of file wined3d.h.

◆ WINEDDCKEYCAPS_NOCOSTOVERLAY

#define WINEDDCKEYCAPS_NOCOSTOVERLAY   0x00040000

Definition at line 1464 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCBLT

#define WINEDDCKEYCAPS_SRCBLT   0x00000200

Definition at line 1455 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCBLTCLRSPACE

#define WINEDDCKEYCAPS_SRCBLTCLRSPACE   0x00000400

Definition at line 1456 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCBLTCLRSPACEYUV

#define WINEDDCKEYCAPS_SRCBLTCLRSPACEYUV   0x00000800

Definition at line 1457 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCBLTYUV

#define WINEDDCKEYCAPS_SRCBLTYUV   0x00001000

Definition at line 1458 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCOVERLAY

#define WINEDDCKEYCAPS_SRCOVERLAY   0x00002000

Definition at line 1459 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCOVERLAYCLRSPACE

#define WINEDDCKEYCAPS_SRCOVERLAYCLRSPACE   0x00004000

Definition at line 1460 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCOVERLAYCLRSPACEYUV

#define WINEDDCKEYCAPS_SRCOVERLAYCLRSPACEYUV   0x00008000

Definition at line 1461 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCOVERLAYONEACTIVE

#define WINEDDCKEYCAPS_SRCOVERLAYONEACTIVE   0x00010000

Definition at line 1462 of file wined3d.h.

◆ WINEDDCKEYCAPS_SRCOVERLAYYUV

#define WINEDDCKEYCAPS_SRCOVERLAYYUV   0x00020000

Definition at line 1463 of file wined3d.h.

◆ WINEDDERR_INVALIDRECT

#define WINEDDERR_INVALIDRECT   MAKE_WINED3DHRESULT(150)

Definition at line 52 of file wined3d.h.

◆ WINEDDERR_NOTAOVERLAYSURFACE

#define WINEDDERR_NOTAOVERLAYSURFACE   MAKE_WINED3DHRESULT(580)

Definition at line 49 of file wined3d.h.

◆ WINEDDERR_NOTLOCKED

#define WINEDDERR_NOTLOCKED   MAKE_WINED3DHRESULT(584)

Definition at line 50 of file wined3d.h.

◆ WINEDDERR_OVERLAYNOTVISIBLE

#define WINEDDERR_OVERLAYNOTVISIBLE   MAKE_WINED3DHRESULT(577)

Definition at line 53 of file wined3d.h.

◆ WINEDDERR_SURFACEBUSY

#define WINEDDERR_SURFACEBUSY   MAKE_WINED3DHRESULT(430)

Definition at line 51 of file wined3d.h.

◆ WINEDDFLIP_DONOTWAIT

#define WINEDDFLIP_DONOTWAIT   0x00000020

Definition at line 1385 of file wined3d.h.

◆ WINEDDFLIP_EVEN

#define WINEDDFLIP_EVEN   0x00000002 /* only valid for overlay */

Definition at line 1381 of file wined3d.h.

◆ WINEDDFLIP_INTERVAL2

#define WINEDDFLIP_INTERVAL2   0x02000000

Definition at line 1386 of file wined3d.h.

◆ WINEDDFLIP_INTERVAL3

#define WINEDDFLIP_INTERVAL3   0x03000000

Definition at line 1387 of file wined3d.h.

◆ WINEDDFLIP_INTERVAL4

#define WINEDDFLIP_INTERVAL4   0x04000000

Definition at line 1388 of file wined3d.h.

◆ WINEDDFLIP_NOVSYNC

#define WINEDDFLIP_NOVSYNC   0x00000008

Definition at line 1383 of file wined3d.h.

◆ WINEDDFLIP_ODD

#define WINEDDFLIP_ODD   0x00000004 /* only valid for overlay */

Definition at line 1382 of file wined3d.h.

◆ WINEDDFLIP_STEREO

#define WINEDDFLIP_STEREO   0x00000010

Definition at line 1384 of file wined3d.h.

◆ WINEDDFLIP_WAIT

#define WINEDDFLIP_WAIT   0x00000001

Definition at line 1380 of file wined3d.h.

◆ WINEDDFXCAPS_BLTALPHA

#define WINEDDFXCAPS_BLTALPHA   0x00000001

Definition at line 1466 of file wined3d.h.

◆ WINEDDFXCAPS_BLTARITHSTRETCHY

#define WINEDDFXCAPS_BLTARITHSTRETCHY   0x00000020

Definition at line 1469 of file wined3d.h.

◆ WINEDDFXCAPS_BLTARITHSTRETCHYN

#define WINEDDFXCAPS_BLTARITHSTRETCHYN   0x00000010

Definition at line 1468 of file wined3d.h.

◆ WINEDDFXCAPS_BLTMIRRORLEFTRIGHT

#define WINEDDFXCAPS_BLTMIRRORLEFTRIGHT   0x00000040

Definition at line 1470 of file wined3d.h.

◆ WINEDDFXCAPS_BLTMIRRORUPDOWN

#define WINEDDFXCAPS_BLTMIRRORUPDOWN   0x00000080

Definition at line 1471 of file wined3d.h.

◆ WINEDDFXCAPS_BLTROTATION

#define WINEDDFXCAPS_BLTROTATION   0x00000100

Definition at line 1472 of file wined3d.h.

◆ WINEDDFXCAPS_BLTROTATION90

#define WINEDDFXCAPS_BLTROTATION90   0x00000200

Definition at line 1473 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSHRINKX

#define WINEDDFXCAPS_BLTSHRINKX   0x00000400

Definition at line 1474 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSHRINKXN

#define WINEDDFXCAPS_BLTSHRINKXN   0x00000800

Definition at line 1475 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSHRINKY

#define WINEDDFXCAPS_BLTSHRINKY   0x00001000

Definition at line 1476 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSHRINKYN

#define WINEDDFXCAPS_BLTSHRINKYN   0x00002000

Definition at line 1477 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSTRETCHX

#define WINEDDFXCAPS_BLTSTRETCHX   0x00004000

Definition at line 1478 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSTRETCHXN

#define WINEDDFXCAPS_BLTSTRETCHXN   0x00008000

Definition at line 1479 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSTRETCHY

#define WINEDDFXCAPS_BLTSTRETCHY   0x00010000

Definition at line 1480 of file wined3d.h.

◆ WINEDDFXCAPS_BLTSTRETCHYN

#define WINEDDFXCAPS_BLTSTRETCHYN   0x00020000

Definition at line 1481 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYALPHA

#define WINEDDFXCAPS_OVERLAYALPHA   0x00000004

Definition at line 1467 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYARITHSTRETCHY

#define WINEDDFXCAPS_OVERLAYARITHSTRETCHY   0x00040000

Definition at line 1482 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYARITHSTRETCHYN

#define WINEDDFXCAPS_OVERLAYARITHSTRETCHYN   0x00000008

Definition at line 1483 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYMIRRORLEFTRIGHT

#define WINEDDFXCAPS_OVERLAYMIRRORLEFTRIGHT   0x08000000

Definition at line 1492 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYMIRRORUPDOWN

#define WINEDDFXCAPS_OVERLAYMIRRORUPDOWN   0x10000000

Definition at line 1493 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSHRINKX

#define WINEDDFXCAPS_OVERLAYSHRINKX   0x00080000

Definition at line 1484 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSHRINKXN

#define WINEDDFXCAPS_OVERLAYSHRINKXN   0x00100000

Definition at line 1485 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSHRINKY

#define WINEDDFXCAPS_OVERLAYSHRINKY   0x00200000

Definition at line 1486 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSHRINKYN

#define WINEDDFXCAPS_OVERLAYSHRINKYN   0x00400000

Definition at line 1487 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSTRETCHX

#define WINEDDFXCAPS_OVERLAYSTRETCHX   0x00800000

Definition at line 1488 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSTRETCHXN

#define WINEDDFXCAPS_OVERLAYSTRETCHXN   0x01000000

Definition at line 1489 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSTRETCHY

#define WINEDDFXCAPS_OVERLAYSTRETCHY   0x02000000

Definition at line 1490 of file wined3d.h.

◆ WINEDDFXCAPS_OVERLAYSTRETCHYN

#define WINEDDFXCAPS_OVERLAYSTRETCHYN   0x04000000

Definition at line 1491 of file wined3d.h.

◆ WINEDDGBS_CANBLT

#define WINEDDGBS_CANBLT   0x00000001

Definition at line 1372 of file wined3d.h.

◆ WINEDDGBS_ISBLTDONE

#define WINEDDGBS_ISBLTDONE   0x00000002

Definition at line 1373 of file wined3d.h.

◆ WINEDDGFS_CANFLIP

#define WINEDDGFS_CANFLIP   0x00000001

Definition at line 1376 of file wined3d.h.

◆ WINEDDGFS_ISFLIPDONE

#define WINEDDGFS_ISFLIPDONE   0x00000002

Definition at line 1377 of file wined3d.h.

◆ WINEDDOVER_ADDDIRTYRECT

#define WINEDDOVER_ADDDIRTYRECT   0x00008000

Definition at line 1405 of file wined3d.h.

◆ WINEDDOVER_ALPHADEST

#define WINEDDOVER_ALPHADEST   0x00000001

Definition at line 1390 of file wined3d.h.

◆ WINEDDOVER_ALPHADESTCONSTOVERRIDE

#define WINEDDOVER_ALPHADESTCONSTOVERRIDE   0x00000002

Definition at line 1391 of file wined3d.h.

◆ WINEDDOVER_ALPHADESTNEG

#define WINEDDOVER_ALPHADESTNEG   0x00000004

Definition at line 1392 of file wined3d.h.

◆ WINEDDOVER_ALPHADESTSURFACEOVERRIDE

#define WINEDDOVER_ALPHADESTSURFACEOVERRIDE   0x00000008

Definition at line 1393 of file wined3d.h.

◆ WINEDDOVER_ALPHAEDGEBLEND

#define WINEDDOVER_ALPHAEDGEBLEND   0x00000010

Definition at line 1394 of file wined3d.h.

◆ WINEDDOVER_ALPHASRC

#define WINEDDOVER_ALPHASRC   0x00000020

Definition at line 1395 of file wined3d.h.

◆ WINEDDOVER_ALPHASRCCONSTOVERRIDE

#define WINEDDOVER_ALPHASRCCONSTOVERRIDE   0x00000040

Definition at line 1396 of file wined3d.h.

◆ WINEDDOVER_ALPHASRCNEG

#define WINEDDOVER_ALPHASRCNEG   0x00000080

Definition at line 1397 of file wined3d.h.

◆ WINEDDOVER_ALPHASRCSURFACEOVERRIDE

#define WINEDDOVER_ALPHASRCSURFACEOVERRIDE   0x00000100

Definition at line 1398 of file wined3d.h.

◆ WINEDDOVER_AUTOFLIP

#define WINEDDOVER_AUTOFLIP   0x00100000

Definition at line 1409 of file wined3d.h.

◆ WINEDDOVER_BOB

#define WINEDDOVER_BOB   0x00200000

Definition at line 1410 of file wined3d.h.

◆ WINEDDOVER_DDFX

#define WINEDDOVER_DDFX   0x00080000

Definition at line 1408 of file wined3d.h.

◆ WINEDDOVER_HIDE

#define WINEDDOVER_HIDE   0x00000200

Definition at line 1399 of file wined3d.h.

◆ WINEDDOVER_INTERLEAVED

#define WINEDDOVER_INTERLEAVED   0x00800000

Definition at line 1412 of file wined3d.h.

◆ WINEDDOVER_KEYDEST

#define WINEDDOVER_KEYDEST   0x00000400

Definition at line 1400 of file wined3d.h.

◆ WINEDDOVER_KEYDESTOVERRIDE

#define WINEDDOVER_KEYDESTOVERRIDE   0x00000800

Definition at line 1401 of file wined3d.h.

◆ WINEDDOVER_KEYSRC

#define WINEDDOVER_KEYSRC   0x00001000

Definition at line 1402 of file wined3d.h.

◆ WINEDDOVER_KEYSRCOVERRIDE

#define WINEDDOVER_KEYSRCOVERRIDE   0x00002000

Definition at line 1403 of file wined3d.h.

◆ WINEDDOVER_OVERRIDEBOBWEAVE

#define WINEDDOVER_OVERRIDEBOBWEAVE   0x00400000

Definition at line 1411 of file wined3d.h.

◆ WINEDDOVER_REFRESHALL

#define WINEDDOVER_REFRESHALL   0x00020000

Definition at line 1407 of file wined3d.h.

◆ WINEDDOVER_REFRESHDIRTYRECTS

#define WINEDDOVER_REFRESHDIRTYRECTS   0x00010000

Definition at line 1406 of file wined3d.h.

◆ WINEDDOVER_SHOW

#define WINEDDOVER_SHOW   0x00004000

Definition at line 1404 of file wined3d.h.

◆ WINEDDSCAPS_3DDEVICE

#define WINEDDSCAPS_3DDEVICE   0x00002000

Definition at line 1428 of file wined3d.h.

◆ WINEDDSCAPS_ALLOCONLOAD

#define WINEDDSCAPS_ALLOCONLOAD   0x04000000

Definition at line 1439 of file wined3d.h.

◆ WINEDDSCAPS_ALPHA

#define WINEDDSCAPS_ALPHA   0x00000002

Definition at line 1416 of file wined3d.h.

◆ WINEDDSCAPS_BACKBUFFER

#define WINEDDSCAPS_BACKBUFFER   0x00000004

Definition at line 1417 of file wined3d.h.

◆ WINEDDSCAPS_COMPLEX

#define WINEDDSCAPS_COMPLEX   0x00000008

Definition at line 1418 of file wined3d.h.

◆ WINEDDSCAPS_FLIP

#define WINEDDSCAPS_FLIP   0x00000010

Definition at line 1419 of file wined3d.h.

◆ WINEDDSCAPS_FRONTBUFFER

#define WINEDDSCAPS_FRONTBUFFER   0x00000020

Definition at line 1420 of file wined3d.h.

◆ WINEDDSCAPS_HWCODEC

#define WINEDDSCAPS_HWCODEC   0x00100000

Definition at line 1435 of file wined3d.h.

◆ WINEDDSCAPS_LIVEVIDEO

#define WINEDDSCAPS_LIVEVIDEO   0x00080000

Definition at line 1434 of file wined3d.h.

◆ WINEDDSCAPS_LOCALVIDMEM

#define WINEDDSCAPS_LOCALVIDMEM   0x10000000

Definition at line 1441 of file wined3d.h.

◆ WINEDDSCAPS_MIPMAP

#define WINEDDSCAPS_MIPMAP   0x00400000

Definition at line 1437 of file wined3d.h.

◆ WINEDDSCAPS_MODEX

#define WINEDDSCAPS_MODEX   0x00200000

Definition at line 1436 of file wined3d.h.

◆ WINEDDSCAPS_NONLOCALVIDMEM

#define WINEDDSCAPS_NONLOCALVIDMEM   0x20000000

Definition at line 1442 of file wined3d.h.

◆ WINEDDSCAPS_OFFSCREENPLAIN

#define WINEDDSCAPS_OFFSCREENPLAIN   0x00000040

Definition at line 1421 of file wined3d.h.

◆ WINEDDSCAPS_OPTIMIZED

#define WINEDDSCAPS_OPTIMIZED   0x80000000

Definition at line 1444 of file wined3d.h.

◆ WINEDDSCAPS_OVERLAY

#define WINEDDSCAPS_OVERLAY   0x00000080

Definition at line 1422 of file wined3d.h.

◆ WINEDDSCAPS_OWNDC

#define WINEDDSCAPS_OWNDC   0x00040000

Definition at line 1433 of file wined3d.h.

◆ WINEDDSCAPS_PALETTE

#define WINEDDSCAPS_PALETTE   0x00000100

Definition at line 1423 of file wined3d.h.

◆ WINEDDSCAPS_PRIMARYSURFACE

#define WINEDDSCAPS_PRIMARYSURFACE   0x00000200

Definition at line 1424 of file wined3d.h.

◆ WINEDDSCAPS_PRIMARYSURFACELEFT

#define WINEDDSCAPS_PRIMARYSURFACELEFT   0x00000400

Definition at line 1425 of file wined3d.h.

◆ WINEDDSCAPS_RESERVED1

#define WINEDDSCAPS_RESERVED1   0x00000001

Definition at line 1415 of file wined3d.h.

◆ WINEDDSCAPS_RESERVED2

#define WINEDDSCAPS_RESERVED2   0x00800000

Definition at line 1438 of file wined3d.h.

◆ WINEDDSCAPS_STANDARDVGAMODE

#define WINEDDSCAPS_STANDARDVGAMODE   0x40000000

Definition at line 1443 of file wined3d.h.

◆ WINEDDSCAPS_SYSTEMMEMORY

#define WINEDDSCAPS_SYSTEMMEMORY   0x00000800

Definition at line 1426 of file wined3d.h.

◆ WINEDDSCAPS_TEXTURE

#define WINEDDSCAPS_TEXTURE   0x00001000

Definition at line 1427 of file wined3d.h.

◆ WINEDDSCAPS_VIDEOMEMORY

#define WINEDDSCAPS_VIDEOMEMORY   0x00004000

Definition at line 1429 of file wined3d.h.

◆ WINEDDSCAPS_VIDEOPORT

#define WINEDDSCAPS_VIDEOPORT   0x08000000

Definition at line 1440 of file wined3d.h.

◆ WINEDDSCAPS_VISIBLE

#define WINEDDSCAPS_VISIBLE   0x00008000

Definition at line 1430 of file wined3d.h.

◆ WINEDDSCAPS_WRITEONLY

#define WINEDDSCAPS_WRITEONLY   0x00010000

Definition at line 1431 of file wined3d.h.

◆ WINEDDSCAPS_ZBUFFER

#define WINEDDSCAPS_ZBUFFER   0x00020000

Definition at line 1432 of file wined3d.h.

◆ WINEHIGHEST_RENDER_STATE

#define WINEHIGHEST_RENDER_STATE   WINED3D_RS_COLORWRITEENABLE7

Definition at line 398 of file wined3d.h.

◆ WINEMAKEFOURCC

#define WINEMAKEFOURCC (   ch0,
  ch1,
  ch2,
  ch3 
)
Value:
((DWORD)(BYTE)(ch0) | ((DWORD)(BYTE)(ch1) << 8) | \
((DWORD)(BYTE)(ch2) << 16) | ((DWORD)(BYTE)(ch3) << 24))
unsigned long DWORD
Definition: ntddk_ex.h:95
#define DWORD
Definition: nt_native.h:44
unsigned char BYTE
Definition: xxhash.c:193

Definition at line 101 of file wined3d.h.

Typedef Documentation

◆ wined3d_device_reset_cb

typedef HRESULT(CDECL * wined3d_device_reset_cb) (struct wined3d_resource *resource)

Definition at line 2172 of file wined3d.h.

◆ WINED3DCAPS

Enumeration Type Documentation

◆ wined3d_basis_type

Enumerator
WINED3D_BASIS_BEZIER 
WINED3D_BASIS_BSPLINE 
WINED3D_BASIS_INTERPOLATE 

Definition at line 666 of file wined3d.h.

667{
671};
@ WINED3D_BASIS_INTERPOLATE
Definition: wined3d.h:670
@ WINED3D_BASIS_BSPLINE
Definition: wined3d.h:669
@ WINED3D_BASIS_BEZIER
Definition: wined3d.h:668

◆ wined3d_blend

Enumerator
WINED3D_BLEND_ZERO 
WINED3D_BLEND_ONE 
WINED3D_BLEND_SRCCOLOR 
WINED3D_BLEND_INVSRCCOLOR 
WINED3D_BLEND_SRCALPHA 
WINED3D_BLEND_INVSRCALPHA 
WINED3D_BLEND_DESTALPHA 
WINED3D_BLEND_INVDESTALPHA 
WINED3D_BLEND_DESTCOLOR 
WINED3D_BLEND_INVDESTCOLOR 
WINED3D_BLEND_SRCALPHASAT 
WINED3D_BLEND_BOTHSRCALPHA 
WINED3D_BLEND_BOTHINVSRCALPHA 
WINED3D_BLEND_BLENDFACTOR 
WINED3D_BLEND_INVBLENDFACTOR 
WINED3D_BLEND_SRC1COLOR 
WINED3D_BLEND_INVSRC1COLOR 
WINED3D_BLEND_SRC1ALPHA 
WINED3D_BLEND_INVSRC1ALPHA 

Definition at line 408 of file wined3d.h.

409{
429};
@ WINED3D_BLEND_ONE
Definition: wined3d.h:411
@ WINED3D_BLEND_INVDESTCOLOR
Definition: wined3d.h:419
@ WINED3D_BLEND_DESTCOLOR
Definition: wined3d.h:418
@ WINED3D_BLEND_INVSRCALPHA
Definition: wined3d.h:415
@ WINED3D_BLEND_INVSRCCOLOR
Definition: wined3d.h:413
@ WINED3D_BLEND_INVDESTALPHA
Definition: wined3d.h:417
@ WINED3D_BLEND_INVBLENDFACTOR
Definition: wined3d.h:424
@ WINED3D_BLEND_INVSRC1COLOR
Definition: wined3d.h:426
@ WINED3D_BLEND_SRC1ALPHA
Definition: wined3d.h:427
@ WINED3D_BLEND_ZERO
Definition: wined3d.h:410
@ WINED3D_BLEND_SRC1COLOR
Definition: wined3d.h:425
@ WINED3D_BLEND_BOTHINVSRCALPHA
Definition: wined3d.h:422
@ WINED3D_BLEND_BOTHSRCALPHA
Definition: wined3d.h:421
@ WINED3D_BLEND_SRCALPHA
Definition: wined3d.h:414
@ WINED3D_BLEND_SRCALPHASAT
Definition: wined3d.h:420
@ WINED3D_BLEND_BLENDFACTOR
Definition: wined3d.h:423
@ WINED3D_BLEND_INVSRC1ALPHA
Definition: wined3d.h:428
@ WINED3D_BLEND_SRCCOLOR
Definition: wined3d.h:412
@ WINED3D_BLEND_DESTALPHA
Definition: wined3d.h:416

◆ wined3d_blend_op

Enumerator
WINED3D_BLEND_OP_ADD 
WINED3D_BLEND_OP_SUBTRACT 
WINED3D_BLEND_OP_REVSUBTRACT 
WINED3D_BLEND_OP_MIN 
WINED3D_BLEND_OP_MAX 

Definition at line 431 of file wined3d.h.

432{
438};
@ WINED3D_BLEND_OP_ADD
Definition: wined3d.h:433
@ WINED3D_BLEND_OP_MIN
Definition: wined3d.h:436
@ WINED3D_BLEND_OP_MAX
Definition: wined3d.h:437
@ WINED3D_BLEND_OP_SUBTRACT
Definition: wined3d.h:434
@ WINED3D_BLEND_OP_REVSUBTRACT
Definition: wined3d.h:435

◆ wined3d_cmp_func

Enumerator
WINED3D_CMP_NEVER 
WINED3D_CMP_LESS 
WINED3D_CMP_EQUAL 
WINED3D_CMP_LESSEQUAL 
WINED3D_CMP_GREATER 
WINED3D_CMP_NOTEQUAL 
WINED3D_CMP_GREATEREQUAL 
WINED3D_CMP_ALWAYS 

Definition at line 450 of file wined3d.h.

451{
460};
@ WINED3D_CMP_ALWAYS
Definition: wined3d.h:459
@ WINED3D_CMP_GREATER
Definition: wined3d.h:456
@ WINED3D_CMP_LESSEQUAL
Definition: wined3d.h:455
@ WINED3D_CMP_NOTEQUAL
Definition: wined3d.h:457
@ WINED3D_CMP_LESS
Definition: wined3d.h:453
@ WINED3D_CMP_EQUAL
Definition: wined3d.h:454
@ WINED3D_CMP_GREATEREQUAL
Definition: wined3d.h:458
@ WINED3D_CMP_NEVER
Definition: wined3d.h:452

◆ wined3d_component_type

Enumerator
WINED3D_TYPE_UNKNOWN 
WINED3D_TYPE_UINT 
WINED3D_TYPE_INT 
WINED3D_TYPE_FLOAT 

Definition at line 822 of file wined3d.h.

823{
828};
@ WINED3D_TYPE_UINT
Definition: wined3d.h:825
@ WINED3D_TYPE_UNKNOWN
Definition: wined3d.h:824
@ WINED3D_TYPE_FLOAT
Definition: wined3d.h:827
@ WINED3D_TYPE_INT
Definition: wined3d.h:826

◆ wined3d_cubemap_face

Enumerator
WINED3D_CUBEMAP_FACE_POSITIVE_X 
WINED3D_CUBEMAP_FACE_NEGATIVE_X 
WINED3D_CUBEMAP_FACE_POSITIVE_Y 
WINED3D_CUBEMAP_FACE_NEGATIVE_Y 
WINED3D_CUBEMAP_FACE_POSITIVE_Z 
WINED3D_CUBEMAP_FACE_NEGATIVE_Z 

Definition at line 673 of file wined3d.h.

674{
681};
@ WINED3D_CUBEMAP_FACE_NEGATIVE_Z
Definition: wined3d.h:680
@ WINED3D_CUBEMAP_FACE_NEGATIVE_X
Definition: wined3d.h:676
@ WINED3D_CUBEMAP_FACE_POSITIVE_Z
Definition: wined3d.h:679
@ WINED3D_CUBEMAP_FACE_POSITIVE_X
Definition: wined3d.h:675
@ WINED3D_CUBEMAP_FACE_NEGATIVE_Y
Definition: wined3d.h:678
@ WINED3D_CUBEMAP_FACE_POSITIVE_Y
Definition: wined3d.h:677

◆ wined3d_cull

Enumerator
WINED3D_CULL_NONE 
WINED3D_CULL_FRONT 
WINED3D_CULL_BACK 

Definition at line 491 of file wined3d.h.

492{
496};
@ WINED3D_CULL_NONE
Definition: wined3d.h:493
@ WINED3D_CULL_FRONT
Definition: wined3d.h:494
@ WINED3D_CULL_BACK
Definition: wined3d.h:495

◆ wined3d_decl_method

Enumerator
WINED3D_DECL_METHOD_DEFAULT 
WINED3D_DECL_METHOD_PARTIAL_U 
WINED3D_DECL_METHOD_PARTIAL_V 
WINED3D_DECL_METHOD_CROSS_UV 
WINED3D_DECL_METHOD_UV 
WINED3D_DECL_METHOD_LOOKUP 
WINED3D_DECL_METHOD_LOOKUP_PRESAMPLED 

Definition at line 773 of file wined3d.h.

774{
782};
@ WINED3D_DECL_METHOD_LOOKUP
Definition: wined3d.h:780
@ WINED3D_DECL_METHOD_LOOKUP_PRESAMPLED
Definition: wined3d.h:781
@ WINED3D_DECL_METHOD_PARTIAL_V
Definition: wined3d.h:777
@ WINED3D_DECL_METHOD_CROSS_UV
Definition: wined3d.h:778
@ WINED3D_DECL_METHOD_UV
Definition: wined3d.h:779
@ WINED3D_DECL_METHOD_PARTIAL_U
Definition: wined3d.h:776
@ WINED3D_DECL_METHOD_DEFAULT
Definition: wined3d.h:775

◆ wined3d_decl_usage

Enumerator
WINED3D_DECL_USAGE_POSITION 
WINED3D_DECL_USAGE_BLEND_WEIGHT 
WINED3D_DECL_USAGE_BLEND_INDICES 
WINED3D_DECL_USAGE_NORMAL 
WINED3D_DECL_USAGE_PSIZE 
WINED3D_DECL_USAGE_TEXCOORD 
WINED3D_DECL_USAGE_TANGENT 
WINED3D_DECL_USAGE_BINORMAL 
WINED3D_DECL_USAGE_TESS_FACTOR 
WINED3D_DECL_USAGE_POSITIONT 
WINED3D_DECL_USAGE_COLOR 
WINED3D_DECL_USAGE_FOG 
WINED3D_DECL_USAGE_DEPTH 
WINED3D_DECL_USAGE_SAMPLE 

Definition at line 784 of file wined3d.h.

785{
800};
@ WINED3D_DECL_USAGE_DEPTH
Definition: wined3d.h:798
@ WINED3D_DECL_USAGE_BLEND_INDICES
Definition: wined3d.h:788
@ WINED3D_DECL_USAGE_TESS_FACTOR
Definition: wined3d.h:794
@ WINED3D_DECL_USAGE_NORMAL
Definition: wined3d.h:789
@ WINED3D_DECL_USAGE_PSIZE
Definition: wined3d.h:790
@ WINED3D_DECL_USAGE_BLEND_WEIGHT
Definition: wined3d.h:787
@ WINED3D_DECL_USAGE_SAMPLE
Definition: wined3d.h:799
@ WINED3D_DECL_USAGE_POSITION
Definition: wined3d.h:786
@ WINED3D_DECL_USAGE_BINORMAL
Definition: wined3d.h:793
@ WINED3D_DECL_USAGE_COLOR
Definition: wined3d.h:796
@ WINED3D_DECL_USAGE_POSITIONT
Definition: wined3d.h:795
@ WINED3D_DECL_USAGE_TEXCOORD
Definition: wined3d.h:791
@ WINED3D_DECL_USAGE_TANGENT
Definition: wined3d.h:792
@ WINED3D_DECL_USAGE_FOG
Definition: wined3d.h:797

◆ wined3d_degree_type

Enumerator
WINED3D_DEGREE_LINEAR 
WINED3D_DEGREE_QUADRATIC 
WINED3D_DEGREE_CUBIC 
WINED3D_DEGREE_QUINTIC 

Definition at line 93 of file wined3d.h.

94{
99};
@ WINED3D_DEGREE_LINEAR
Definition: wined3d.h:95
@ WINED3D_DEGREE_QUINTIC
Definition: wined3d.h:98
@ WINED3D_DEGREE_CUBIC
Definition: wined3d.h:97
@ WINED3D_DEGREE_QUADRATIC
Definition: wined3d.h:96

◆ wined3d_depth_buffer_type

Enumerator
WINED3D_ZB_FALSE 
WINED3D_ZB_TRUE 
WINED3D_ZB_USEW 

Definition at line 462 of file wined3d.h.

463{
465 WINED3D_ZB_TRUE = 1,
466 WINED3D_ZB_USEW = 2,
467};
@ WINED3D_ZB_TRUE
Definition: wined3d.h:465
@ WINED3D_ZB_USEW
Definition: wined3d.h:466
@ WINED3D_ZB_FALSE
Definition: wined3d.h:464

◆ wined3d_device_type

Enumerator
WINED3D_DEVICE_TYPE_HAL 
WINED3D_DEVICE_TYPE_REF 
WINED3D_DEVICE_TYPE_SW 
WINED3D_DEVICE_TYPE_NULLREF 

Definition at line 85 of file wined3d.h.

86{
91};
@ WINED3D_DEVICE_TYPE_NULLREF
Definition: wined3d.h:90
@ WINED3D_DEVICE_TYPE_SW
Definition: wined3d.h:89
@ WINED3D_DEVICE_TYPE_HAL
Definition: wined3d.h:87
@ WINED3D_DEVICE_TYPE_REF
Definition: wined3d.h:88

◆ wined3d_display_rotation

Enumerator
WINED3D_DISPLAY_ROTATION_UNSPECIFIED 
WINED3D_DISPLAY_ROTATION_0 
WINED3D_DISPLAY_ROTATION_90 
WINED3D_DISPLAY_ROTATION_180 
WINED3D_DISPLAY_ROTATION_270 

Definition at line 837 of file wined3d.h.

838{
844};
@ WINED3D_DISPLAY_ROTATION_270
Definition: wined3d.h:843
@ WINED3D_DISPLAY_ROTATION_0
Definition: wined3d.h:840
@ WINED3D_DISPLAY_ROTATION_180
Definition: wined3d.h:842
@ WINED3D_DISPLAY_ROTATION_UNSPECIFIED
Definition: wined3d.h:839
@ WINED3D_DISPLAY_ROTATION_90
Definition: wined3d.h:841

◆ wined3d_fill_mode

Enumerator
WINED3D_FILL_POINT 
WINED3D_FILL_WIREFRAME 
WINED3D_FILL_SOLID 

Definition at line 484 of file wined3d.h.

485{
489};
@ WINED3D_FILL_SOLID
Definition: wined3d.h:488
@ WINED3D_FILL_WIREFRAME
Definition: wined3d.h:487
@ WINED3D_FILL_POINT
Definition: wined3d.h:486

◆ wined3d_fog_mode

Enumerator
WINED3D_FOG_NONE 
WINED3D_FOG_EXP 
WINED3D_FOG_EXP2 
WINED3D_FOG_LINEAR 

Definition at line 469 of file wined3d.h.

470{
472 WINED3D_FOG_EXP = 1,
475};
@ WINED3D_FOG_LINEAR
Definition: wined3d.h:474
@ WINED3D_FOG_EXP
Definition: wined3d.h:472
@ WINED3D_FOG_NONE
Definition: wined3d.h:471
@ WINED3D_FOG_EXP2
Definition: wined3d.h:473

◆ wined3d_format_id

Enumerator
WINED3DFMT_UNKNOWN 
WINED3DFMT_B8G8R8_UNORM 
WINED3DFMT_B5G5R5X1_UNORM 
WINED3DFMT_B4G4R4A4_UNORM 
WINED3DFMT_B2G3R3_UNORM 
WINED3DFMT_B2G3R3A8_UNORM 
WINED3DFMT_B4G4R4X4_UNORM 
WINED3DFMT_R8G8B8X8_UNORM 
WINED3DFMT_B10G10R10A2_UNORM 
WINED3DFMT_P8_UINT_A8_UNORM 
WINED3DFMT_P8_UINT 
WINED3DFMT_L8_UNORM 
WINED3DFMT_L8A8_UNORM 
WINED3DFMT_L4A4_UNORM 
WINED3DFMT_R5G5_SNORM_L6_UNORM 
WINED3DFMT_R8G8_SNORM_L8X8_UNORM 
WINED3DFMT_R10G11B11_SNORM 
WINED3DFMT_R10G10B10X2_UINT 
WINED3DFMT_R10G10B10X2_SNORM 
WINED3DFMT_R10G10B10_SNORM_A2_UNORM 
WINED3DFMT_D16_LOCKABLE 
WINED3DFMT_D32_UNORM 
WINED3DFMT_S1_UINT_D15_UNORM 
WINED3DFMT_X8D24_UNORM 
WINED3DFMT_S4X4_UINT_D24_UNORM 
WINED3DFMT_L16_UNORM 
WINED3DFMT_S8_UINT_D24_FLOAT 
WINED3DFMT_R8G8_SNORM_Cx 
WINED3DFMT_R32G32B32A32_TYPELESS 
WINED3DFMT_R32G32B32A32_FLOAT 
WINED3DFMT_R32G32B32A32_UINT 
WINED3DFMT_R32G32B32A32_SINT 
WINED3DFMT_R32G32B32_TYPELESS 
WINED3DFMT_R32G32B32_FLOAT 
WINED3DFMT_R32G32B32_UINT 
WINED3DFMT_R32G32B32_SINT 
WINED3DFMT_R16G16B16A16_TYPELESS 
WINED3DFMT_R16G16B16A16_FLOAT 
WINED3DFMT_R16G16B16A16_UNORM 
WINED3DFMT_R16G16B16A16_UINT 
WINED3DFMT_R16G16B16A16_SNORM 
WINED3DFMT_R16G16B16A16_SINT 
WINED3DFMT_R32G32_TYPELESS 
WINED3DFMT_R32G32_FLOAT 
WINED3DFMT_R32G32_UINT 
WINED3DFMT_R32G32_SINT 
WINED3DFMT_R32G8X24_TYPELESS 
WINED3DFMT_D32_FLOAT_S8X24_UINT 
WINED3DFMT_R32_FLOAT_X8X24_TYPELESS 
WINED3DFMT_X32_TYPELESS_G8X24_UINT 
WINED3DFMT_R10G10B10A2_TYPELESS 
WINED3DFMT_R10G10B10A2_UNORM 
WINED3DFMT_R10G10B10A2_UINT 
WINED3DFMT_R10G10B10A2_SNORM 
WINED3DFMT_R10G10B10_XR_BIAS_A2_UNORM 
WINED3DFMT_R11G11B10_FLOAT 
WINED3DFMT_R8G8B8A8_TYPELESS 
WINED3DFMT_R8G8B8A8_UNORM 
WINED3DFMT_R8G8B8A8_UNORM_SRGB 
WINED3DFMT_R8G8B8A8_UINT 
WINED3DFMT_R8G8B8A8_SNORM 
WINED3DFMT_R8G8B8A8_SINT 
WINED3DFMT_R16G16_TYPELESS 
WINED3DFMT_R16G16_FLOAT 
WINED3DFMT_R16G16_UNORM 
WINED3DFMT_R16G16_UINT 
WINED3DFMT_R16G16_SNORM 
WINED3DFMT_R16G16_SINT 
WINED3DFMT_R32_TYPELESS 
WINED3DFMT_D32_FLOAT 
WINED3DFMT_R32_FLOAT 
WINED3DFMT_R32_UINT 
WINED3DFMT_R32_SINT 
WINED3DFMT_R24G8_TYPELESS 
WINED3DFMT_D24_UNORM_S8_UINT 
WINED3DFMT_R24_UNORM_X8_TYPELESS 
WINED3DFMT_X24_TYPELESS_G8_UINT 
WINED3DFMT_R8G8_TYPELESS 
WINED3DFMT_R8G8_UNORM 
WINED3DFMT_R8G8_UINT 
WINED3DFMT_R8G8_SNORM 
WINED3DFMT_R8G8_SINT 
WINED3DFMT_R16_TYPELESS 
WINED3DFMT_R16_FLOAT 
WINED3DFMT_D16_UNORM 
WINED3DFMT_R16_UNORM 
WINED3DFMT_R16_UINT 
WINED3DFMT_R16_SNORM 
WINED3DFMT_R16_SINT 
WINED3DFMT_R8_TYPELESS 
WINED3DFMT_R8_UNORM 
WINED3DFMT_R8_UINT 
WINED3DFMT_R8_SNORM 
WINED3DFMT_R8_SINT 
WINED3DFMT_A8_UNORM 
WINED3DFMT_R1_UNORM 
WINED3DFMT_R9G9B9E5_SHAREDEXP 
WINED3DFMT_R8G8_B8G8_UNORM 
WINED3DFMT_G8R8_G8B8_UNORM 
WINED3DFMT_BC1_TYPELESS 
WINED3DFMT_BC1_UNORM 
WINED3DFMT_BC1_UNORM_SRGB 
WINED3DFMT_BC2_TYPELESS 
WINED3DFMT_BC2_UNORM 
WINED3DFMT_BC2_UNORM_SRGB 
WINED3DFMT_BC3_TYPELESS 
WINED3DFMT_BC3_UNORM 
WINED3DFMT_BC3_UNORM_SRGB 
WINED3DFMT_BC4_TYPELESS 
WINED3DFMT_BC4_UNORM 
WINED3DFMT_BC4_SNORM 
WINED3DFMT_BC5_TYPELESS 
WINED3DFMT_BC5_UNORM 
WINED3DFMT_BC5_SNORM 
WINED3DFMT_B5G6R5_UNORM 
WINED3DFMT_B5G5R5A1_UNORM 
WINED3DFMT_B8G8R8A8_UNORM 
WINED3DFMT_B8G8R8X8_UNORM 
WINED3DFMT_B8G8R8A8_TYPELESS 
WINED3DFMT_B8G8R8A8_UNORM_SRGB 
WINED3DFMT_B8G8R8X8_TYPELESS 
WINED3DFMT_B8G8R8X8_UNORM_SRGB 
WINED3DFMT_BC6H_TYPELESS 
WINED3DFMT_BC6H_UF16 
WINED3DFMT_BC6H_SF16 
WINED3DFMT_BC7_TYPELESS 
WINED3DFMT_BC7_UNORM 
WINED3DFMT_BC7_UNORM_SRGB 
WINED3DFMT_UYVY 
WINED3DFMT_YUY2 
WINED3DFMT_YV12 
WINED3DFMT_DXT1 
WINED3DFMT_DXT2 
WINED3DFMT_DXT3 
WINED3DFMT_DXT4 
WINED3DFMT_DXT5 
WINED3DFMT_MULTI2_ARGB8 
WINED3DFMT_G8R8_G8B8 
WINED3DFMT_R8G8_B8G8 
WINED3DFMT_ATI1N 
WINED3DFMT_ATI2N 
WINED3DFMT_INST 
WINED3DFMT_NVDB 
WINED3DFMT_NVHU 
WINED3DFMT_NVHS 
WINED3DFMT_INTZ 
WINED3DFMT_RESZ 
WINED3DFMT_NULL 
WINED3DFMT_R16 
WINED3DFMT_AL16 
WINED3DFMT_NV12 
WINED3DFMT_FORCE_DWORD 

Definition at line 105 of file wined3d.h.

106{
235 /* FOURCC formats. */
236 WINED3DFMT_UYVY = WINEMAKEFOURCC('U','Y','V','Y'),
237 WINED3DFMT_YUY2 = WINEMAKEFOURCC('Y','U','Y','2'),
238 WINED3DFMT_YV12 = WINEMAKEFOURCC('Y','V','1','2'),
239 WINED3DFMT_DXT1 = WINEMAKEFOURCC('D','X','T','1'),
240 WINED3DFMT_DXT2 = WINEMAKEFOURCC('D','X','T','2'),
241 WINED3DFMT_DXT3 = WINEMAKEFOURCC('D','X','T','3'),
242 WINED3DFMT_DXT4 = WINEMAKEFOURCC('D','X','T','4'),
243 WINED3DFMT_DXT5 = WINEMAKEFOURCC('D','X','T','5'),
244 WINED3DFMT_MULTI2_ARGB8 = WINEMAKEFOURCC('M','E','T','1'),
245 WINED3DFMT_G8R8_G8B8 = WINEMAKEFOURCC('G','R','G','B'),
246 WINED3DFMT_R8G8_B8G8 = WINEMAKEFOURCC('R','G','B','G'),
247 WINED3DFMT_ATI1N = WINEMAKEFOURCC('A','T','I','1'),
248 WINED3DFMT_ATI2N = WINEMAKEFOURCC('A','T','I','2'),
249 WINED3DFMT_INST = WINEMAKEFOURCC('I','N','S','T'),
250 WINED3DFMT_NVDB = WINEMAKEFOURCC('N','V','D','B'),
251 WINED3DFMT_NVHU = WINEMAKEFOURCC('N','V','H','U'),
252 WINED3DFMT_NVHS = WINEMAKEFOURCC('N','V','H','S'),
253 WINED3DFMT_INTZ = WINEMAKEFOURCC('I','N','T','Z'),
254 WINED3DFMT_RESZ = WINEMAKEFOURCC('R','E','S','Z'),
255 WINED3DFMT_NULL = WINEMAKEFOURCC('N','U','L','L'),
256 WINED3DFMT_R16 = WINEMAKEFOURCC(' ','R','1','6'),
257 WINED3DFMT_AL16 = WINEMAKEFOURCC('A','L','1','6'),
258 WINED3DFMT_NV12 = WINEMAKEFOURCC('N','V','1','2'),
259
260 WINED3DFMT_FORCE_DWORD = 0xffffffff
261};
#define WINEMAKEFOURCC(ch0, ch1, ch2, ch3)
Definition: wined3d.h:101
@ WINED3DFMT_R32G32B32_TYPELESS
Definition: wined3d.h:139
@ WINED3DFMT_RESZ
Definition: wined3d.h:254
@ WINED3DFMT_R8_TYPELESS
Definition: wined3d.h:196
@ WINED3DFMT_B2G3R3_UNORM
Definition: wined3d.h:111
@ WINED3DFMT_BC5_UNORM
Definition: wined3d.h:219
@ WINED3DFMT_R32G32B32_SINT
Definition: wined3d.h:142
@ WINED3DFMT_R8G8_UNORM
Definition: wined3d.h:185
@ WINED3DFMT_BC7_TYPELESS
Definition: wined3d.h:232
@ WINED3DFMT_BC7_UNORM_SRGB
Definition: wined3d.h:234
@ WINED3DFMT_R32G32_SINT
Definition: wined3d.h:152
@ WINED3DFMT_X24_TYPELESS_G8_UINT
Definition: wined3d.h:183
@ WINED3DFMT_BC2_UNORM_SRGB
Definition: wined3d.h:211
@ WINED3DFMT_FORCE_DWORD
Definition: wined3d.h:260
@ WINED3DFMT_INTZ
Definition: wined3d.h:253
@ WINED3DFMT_B4G4R4A4_UNORM
Definition: wined3d.h:110
@ WINED3DFMT_R16G16_UINT
Definition: wined3d.h:172
@ WINED3DFMT_R16G16_UNORM
Definition: wined3d.h:171
@ WINED3DFMT_R8G8_TYPELESS
Definition: wined3d.h:184
@ WINED3DFMT_R10G10B10X2_UINT
Definition: wined3d.h:124
@ WINED3DFMT_X8D24_UNORM
Definition: wined3d.h:130
@ WINED3DFMT_BC5_SNORM
Definition: wined3d.h:220
@ WINED3DFMT_R32_SINT
Definition: wined3d.h:179
@ WINED3DFMT_DXT2
Definition: wined3d.h:240
@ WINED3DFMT_D32_FLOAT
Definition: wined3d.h:176
@ WINED3DFMT_R10G10B10A2_UNORM
Definition: wined3d.h:158
@ WINED3DFMT_R8_UINT
Definition: wined3d.h:198
@ WINED3DFMT_R8G8_SNORM_Cx
Definition: wined3d.h:134
@ WINED3DFMT_R32G32_FLOAT
Definition: wined3d.h:150
@ WINED3DFMT_R16G16_SNORM
Definition: wined3d.h:173
@ WINED3DFMT_B8G8R8A8_UNORM
Definition: wined3d.h:223
@ WINED3DFMT_R16_UNORM
Definition: wined3d.h:192
@ WINED3DFMT_R24G8_TYPELESS
Definition: wined3d.h:180
@ WINED3DFMT_R10G10B10A2_TYPELESS
Definition: wined3d.h:157
@ WINED3DFMT_R32G32_UINT
Definition: wined3d.h:151
@ WINED3DFMT_R32G32B32_UINT
Definition: wined3d.h:141
@ WINED3DFMT_BC4_TYPELESS
Definition: wined3d.h:215
@ WINED3DFMT_ATI1N
Definition: wined3d.h:247
@ WINED3DFMT_BC2_UNORM
Definition: wined3d.h:210
@ WINED3DFMT_R8_UNORM
Definition: wined3d.h:197
@ WINED3DFMT_R8G8B8A8_SNORM
Definition: wined3d.h:167
@ WINED3DFMT_NV12
Definition: wined3d.h:258
@ WINED3DFMT_S8_UINT_D24_FLOAT
Definition: wined3d.h:133
@ WINED3DFMT_R10G10B10_XR_BIAS_A2_UNORM
Definition: wined3d.h:161
@ WINED3DFMT_NULL
Definition: wined3d.h:255
@ WINED3DFMT_R16_TYPELESS
Definition: wined3d.h:189
@ WINED3DFMT_R16G16B16A16_SINT
Definition: wined3d.h:148
@ WINED3DFMT_D16_LOCKABLE
Definition: wined3d.h:127
@ WINED3DFMT_R10G11B11_SNORM
Definition: wined3d.h:123
@ WINED3DFMT_S1_UINT_D15_UNORM
Definition: wined3d.h:129
@ WINED3DFMT_R16_SINT
Definition: wined3d.h:195
@ WINED3DFMT_B2G3R3A8_UNORM
Definition: wined3d.h:112
@ WINED3DFMT_R8G8_B8G8_UNORM
Definition: wined3d.h:204
@ WINED3DFMT_L8A8_UNORM
Definition: wined3d.h:119
@ WINED3DFMT_R32G32B32_FLOAT
Definition: wined3d.h:140
@ WINED3DFMT_L4A4_UNORM
Definition: wined3d.h:120
@ WINED3DFMT_B8G8R8X8_UNORM
Definition: wined3d.h:224
@ WINED3DFMT_R32_FLOAT_X8X24_TYPELESS
Definition: wined3d.h:155
@ WINED3DFMT_R8G8B8X8_UNORM
Definition: wined3d.h:114
@ WINED3DFMT_BC1_UNORM_SRGB
Definition: wined3d.h:208
@ WINED3DFMT_B5G5R5X1_UNORM
Definition: wined3d.h:109
@ WINED3DFMT_B10G10R10A2_UNORM
Definition: wined3d.h:115
@ WINED3DFMT_R16G16B16A16_FLOAT
Definition: wined3d.h:144
@ WINED3DFMT_D16_UNORM
Definition: wined3d.h:191
@ WINED3DFMT_L8_UNORM
Definition: wined3d.h:118
@ WINED3DFMT_NVHS
Definition: wined3d.h:252
@ WINED3DFMT_R8G8_SNORM
Definition: wined3d.h:187
@ WINED3DFMT_UNKNOWN
Definition: wined3d.h:107
@ WINED3DFMT_R5G5_SNORM_L6_UNORM
Definition: wined3d.h:121
@ WINED3DFMT_R8G8B8A8_TYPELESS
Definition: wined3d.h:163
@ WINED3DFMT_R8G8_UINT
Definition: wined3d.h:186
@ WINED3DFMT_BC7_UNORM
Definition: wined3d.h:233
@ WINED3DFMT_B8G8R8_UNORM
Definition: wined3d.h:108
@ WINED3DFMT_INST
Definition: wined3d.h:249
@ WINED3DFMT_DXT1
Definition: wined3d.h:239
@ WINED3DFMT_R8G8B8A8_UNORM_SRGB
Definition: wined3d.h:165
@ WINED3DFMT_R9G9B9E5_SHAREDEXP
Definition: wined3d.h:203
@ WINED3DFMT_NVDB
Definition: wined3d.h:250
@ WINED3DFMT_B8G8R8X8_TYPELESS
Definition: wined3d.h:227
@ WINED3DFMT_R32_UINT
Definition: wined3d.h:178
@ WINED3DFMT_B5G5R5A1_UNORM
Definition: wined3d.h:222
@ WINED3DFMT_R10G10B10_SNORM_A2_UNORM
Definition: wined3d.h:126
@ WINED3DFMT_R16_FLOAT
Definition: wined3d.h:190
@ WINED3DFMT_DXT3
Definition: wined3d.h:241
@ WINED3DFMT_DXT4
Definition: wined3d.h:242
@ WINED3DFMT_D32_UNORM
Definition: wined3d.h:128
@ WINED3DFMT_R8G8B8A8_UNORM
Definition: wined3d.h:164
@ WINED3DFMT_R10G10B10A2_UINT
Definition: wined3d.h:159
@ WINED3DFMT_G8R8_G8B8_UNORM
Definition: wined3d.h:205
@ WINED3DFMT_R32G32B32A32_UINT
Definition: wined3d.h:137
@ WINED3DFMT_R16G16B16A16_UNORM
Definition: wined3d.h:145
@ WINED3DFMT_BC3_UNORM
Definition: wined3d.h:213
@ WINED3DFMT_BC6H_UF16
Definition: wined3d.h:230
@ WINED3DFMT_R16G16B16A16_TYPELESS
Definition: wined3d.h:143
@ WINED3DFMT_R10G10B10A2_SNORM
Definition: wined3d.h:160
@ WINED3DFMT_R24_UNORM_X8_TYPELESS
Definition: wined3d.h:182
@ WINED3DFMT_R16
Definition: wined3d.h:256
@ WINED3DFMT_D32_FLOAT_S8X24_UINT
Definition: wined3d.h:154
@ WINED3DFMT_NVHU
Definition: wined3d.h:251
@ WINED3DFMT_R32_FLOAT
Definition: wined3d.h:177
@ WINED3DFMT_R8G8_SNORM_L8X8_UNORM
Definition: wined3d.h:122
@ WINED3DFMT_X32_TYPELESS_G8X24_UINT
Definition: wined3d.h:156
@ WINED3DFMT_YV12
Definition: wined3d.h:238
@ WINED3DFMT_B5G6R5_UNORM
Definition: wined3d.h:221
@ WINED3DFMT_R16G16B16A16_UINT
Definition: wined3d.h:146
@ WINED3DFMT_S4X4_UINT_D24_UNORM
Definition: wined3d.h:131
@ WINED3DFMT_BC1_TYPELESS
Definition: wined3d.h:206
@ WINED3DFMT_B8G8R8X8_UNORM_SRGB
Definition: wined3d.h:228
@ WINED3DFMT_DXT5
Definition: wined3d.h:243
@ WINED3DFMT_BC4_UNORM
Definition: wined3d.h:216
@ WINED3DFMT_B8G8R8A8_TYPELESS
Definition: wined3d.h:225
@ WINED3DFMT_BC3_TYPELESS
Definition: wined3d.h:212
@ WINED3DFMT_R16G16_TYPELESS
Definition: wined3d.h:169
@ WINED3DFMT_R8_SNORM
Definition: wined3d.h:199
@ WINED3DFMT_YUY2
Definition: wined3d.h:237
@ WINED3DFMT_R16G16_FLOAT
Definition: wined3d.h:170
@ WINED3DFMT_G8R8_G8B8
Definition: wined3d.h:245
@ WINED3DFMT_P8_UINT
Definition: wined3d.h:117
@ WINED3DFMT_R8G8B8A8_UINT
Definition: wined3d.h:166
@ WINED3DFMT_L16_UNORM
Definition: wined3d.h:132
@ WINED3DFMT_R16_SNORM
Definition: wined3d.h:194
@ WINED3DFMT_BC6H_TYPELESS
Definition: wined3d.h:229
@ WINED3DFMT_BC1_UNORM
Definition: wined3d.h:207
@ WINED3DFMT_R32G32B32A32_TYPELESS
Definition: wined3d.h:135
@ WINED3DFMT_R32_TYPELESS
Definition: wined3d.h:175
@ WINED3DFMT_R32G8X24_TYPELESS
Definition: wined3d.h:153
@ WINED3DFMT_R16_UINT
Definition: wined3d.h:193
@ WINED3DFMT_R8_SINT
Definition: wined3d.h:200
@ WINED3DFMT_UYVY
Definition: wined3d.h:236
@ WINED3DFMT_BC5_TYPELESS
Definition: wined3d.h:218
@ WINED3DFMT_R8G8_SINT
Definition: wined3d.h:188
@ WINED3DFMT_R32G32B32A32_SINT
Definition: wined3d.h:138
@ WINED3DFMT_R8G8B8A8_SINT
Definition: wined3d.h:168
@ WINED3DFMT_R10G10B10X2_SNORM
Definition: wined3d.h:125
@ WINED3DFMT_R1_UNORM
Definition: wined3d.h:202
@ WINED3DFMT_R11G11B10_FLOAT
Definition: wined3d.h:162
@ WINED3DFMT_B8G8R8A8_UNORM_SRGB
Definition: wined3d.h:226
@ WINED3DFMT_BC3_UNORM_SRGB
Definition: wined3d.h:214
@ WINED3DFMT_A8_UNORM
Definition: wined3d.h:201
@ WINED3DFMT_R32G32B32A32_FLOAT
Definition: wined3d.h:136
@ WINED3DFMT_BC2_TYPELESS
Definition: wined3d.h:209
@ WINED3DFMT_R8G8_B8G8
Definition: wined3d.h:246
@ WINED3DFMT_BC6H_SF16
Definition: wined3d.h:231
@ WINED3DFMT_ATI2N
Definition: wined3d.h:248
@ WINED3DFMT_B4G4R4X4_UNORM
Definition: wined3d.h:113
@ WINED3DFMT_MULTI2_ARGB8
Definition: wined3d.h:244
@ WINED3DFMT_AL16
Definition: wined3d.h:257
@ WINED3DFMT_D24_UNORM_S8_UINT
Definition: wined3d.h:181
@ WINED3DFMT_P8_UINT_A8_UNORM
Definition: wined3d.h:116
@ WINED3DFMT_R16G16B16A16_SNORM
Definition: wined3d.h:147
@ WINED3DFMT_BC4_SNORM
Definition: wined3d.h:217
@ WINED3DFMT_R16G16_SINT
Definition: wined3d.h:174
@ WINED3DFMT_R32G32_TYPELESS
Definition: wined3d.h:149

◆ wined3d_input_classification

Enumerator
WINED3D_INPUT_PER_VERTEX_DATA 
WINED3D_INPUT_PER_INSTANCE_DATA 

Definition at line 1783 of file wined3d.h.

1784{
1787};
@ WINED3D_INPUT_PER_INSTANCE_DATA
Definition: wined3d.h:1786
@ WINED3D_INPUT_PER_VERTEX_DATA
Definition: wined3d.h:1785

◆ wined3d_light_type

Enumerator
WINED3D_LIGHT_POINT 
WINED3D_LIGHT_SPOT 
WINED3D_LIGHT_DIRECTIONAL 
WINED3D_LIGHT_PARALLELPOINT 
WINED3D_LIGHT_GLSPOT 

Definition at line 60 of file wined3d.h.

61{
65 WINED3D_LIGHT_PARALLELPOINT = 4, /* < D3D7 */
66 WINED3D_LIGHT_GLSPOT = 5, /* < D3D5, not actually usable */
67};
@ WINED3D_LIGHT_SPOT
Definition: wined3d.h:63
@ WINED3D_LIGHT_GLSPOT
Definition: wined3d.h:66
@ WINED3D_LIGHT_PARALLELPOINT
Definition: wined3d.h:65
@ WINED3D_LIGHT_POINT
Definition: wined3d.h:62
@ WINED3D_LIGHT_DIRECTIONAL
Definition: wined3d.h:64

◆ wined3d_material_color_source

Enumerator
WINED3D_MCS_MATERIAL 
WINED3D_MCS_COLOR1 
WINED3D_MCS_COLOR2 

Definition at line 510 of file wined3d.h.

511{
515};
@ WINED3D_MCS_COLOR2
Definition: wined3d.h:514
@ WINED3D_MCS_MATERIAL
Definition: wined3d.h:512
@ WINED3D_MCS_COLOR1
Definition: wined3d.h:513

◆ wined3d_multisample_type

Enumerator
WINED3D_MULTISAMPLE_NONE 
WINED3D_MULTISAMPLE_NON_MASKABLE 
WINED3D_MULTISAMPLE_2_SAMPLES 
WINED3D_MULTISAMPLE_3_SAMPLES 
WINED3D_MULTISAMPLE_4_SAMPLES 
WINED3D_MULTISAMPLE_5_SAMPLES 
WINED3D_MULTISAMPLE_6_SAMPLES 
WINED3D_MULTISAMPLE_7_SAMPLES 
WINED3D_MULTISAMPLE_8_SAMPLES 
WINED3D_MULTISAMPLE_9_SAMPLES 
WINED3D_MULTISAMPLE_10_SAMPLES 
WINED3D_MULTISAMPLE_11_SAMPLES 
WINED3D_MULTISAMPLE_12_SAMPLES 
WINED3D_MULTISAMPLE_13_SAMPLES 
WINED3D_MULTISAMPLE_14_SAMPLES 
WINED3D_MULTISAMPLE_15_SAMPLES 
WINED3D_MULTISAMPLE_16_SAMPLES 

Definition at line 552 of file wined3d.h.

553{
571};
@ WINED3D_MULTISAMPLE_6_SAMPLES
Definition: wined3d.h:560
@ WINED3D_MULTISAMPLE_3_SAMPLES
Definition: wined3d.h:557
@ WINED3D_MULTISAMPLE_13_SAMPLES
Definition: wined3d.h:567
@ WINED3D_MULTISAMPLE_NON_MASKABLE
Definition: wined3d.h:555
@ WINED3D_MULTISAMPLE_14_SAMPLES
Definition: wined3d.h:568
@ WINED3D_MULTISAMPLE_11_SAMPLES
Definition: wined3d.h:565
@ WINED3D_MULTISAMPLE_8_SAMPLES
Definition: wined3d.h:562
@ WINED3D_MULTISAMPLE_16_SAMPLES
Definition: wined3d.h:570
@ WINED3D_MULTISAMPLE_12_SAMPLES
Definition: wined3d.h:566
@ WINED3D_MULTISAMPLE_4_SAMPLES
Definition: wined3d.h:558
@ WINED3D_MULTISAMPLE_10_SAMPLES
Definition: wined3d.h:564
@ WINED3D_MULTISAMPLE_15_SAMPLES
Definition: wined3d.h:569
@ WINED3D_MULTISAMPLE_2_SAMPLES
Definition: wined3d.h:556
@ WINED3D_MULTISAMPLE_7_SAMPLES
Definition: wined3d.h:561
@ WINED3D_MULTISAMPLE_5_SAMPLES
Definition: wined3d.h:559
@ WINED3D_MULTISAMPLE_NONE
Definition: wined3d.h:554
@ WINED3D_MULTISAMPLE_9_SAMPLES
Definition: wined3d.h:563

◆ wined3d_patch_edge_style

Enumerator
WINED3D_PATCH_EDGE_DISCRETE 
WINED3D_PATCH_EDGE_CONTINUOUS 

Definition at line 517 of file wined3d.h.

518{
521};
@ WINED3D_PATCH_EDGE_DISCRETE
Definition: wined3d.h:519
@ WINED3D_PATCH_EDGE_CONTINUOUS
Definition: wined3d.h:520

◆ wined3d_primitive_type

Enumerator
WINED3D_PT_UNDEFINED 
WINED3D_PT_POINTLIST 
WINED3D_PT_LINELIST 
WINED3D_PT_LINESTRIP 
WINED3D_PT_TRIANGLELIST 
WINED3D_PT_TRIANGLESTRIP 
WINED3D_PT_TRIANGLEFAN 
WINED3D_PT_LINELIST_ADJ 
WINED3D_PT_LINESTRIP_ADJ 
WINED3D_PT_TRIANGLELIST_ADJ 
WINED3D_PT_TRIANGLESTRIP_ADJ 
WINED3D_PT_PATCH 

Definition at line 69 of file wined3d.h.

70{
83};
@ WINED3D_PT_LINESTRIP_ADJ
Definition: wined3d.h:79
@ WINED3D_PT_LINELIST
Definition: wined3d.h:73
@ WINED3D_PT_UNDEFINED
Definition: wined3d.h:71
@ WINED3D_PT_PATCH
Definition: wined3d.h:82
@ WINED3D_PT_POINTLIST
Definition: wined3d.h:72
@ WINED3D_PT_TRIANGLELIST_ADJ
Definition: wined3d.h:80
@ WINED3D_PT_LINELIST_ADJ
Definition: wined3d.h:78
@ WINED3D_PT_TRIANGLESTRIP_ADJ
Definition: wined3d.h:81
@ WINED3D_PT_TRIANGLESTRIP
Definition: wined3d.h:76
@ WINED3D_PT_LINESTRIP
Definition: wined3d.h:74
@ WINED3D_PT_TRIANGLELIST
Definition: wined3d.h:75
@ WINED3D_PT_TRIANGLEFAN
Definition: wined3d.h:77

◆ wined3d_query_type

Enumerator
WINED3D_QUERY_TYPE_VCACHE 
WINED3D_QUERY_TYPE_RESOURCE_MANAGER 
WINED3D_QUERY_TYPE_VERTEX_STATS 
WINED3D_QUERY_TYPE_EVENT 
WINED3D_QUERY_TYPE_OCCLUSION 
WINED3D_QUERY_TYPE_TIMESTAMP 
WINED3D_QUERY_TYPE_TIMESTAMP_DISJOINT 
WINED3D_QUERY_TYPE_TIMESTAMP_FREQ 
WINED3D_QUERY_TYPE_PIPELINE_TIMINGS 
WINED3D_QUERY_TYPE_INTERFACE_TIMINGS 
WINED3D_QUERY_TYPE_VERTEX_TIMINGS 
WINED3D_QUERY_TYPE_PIXEL_TIMINGS 
WINED3D_QUERY_TYPE_BANDWIDTH_TIMINGS 
WINED3D_QUERY_TYPE_CACHE_UTILIZATION 
WINED3D_QUERY_TYPE_MEMORY_PRESSURE 
WINED3D_QUERY_TYPE_PIPELINE_STATISTICS 
WINED3D_QUERY_TYPE_SO_STATISTICS 
WINED3D_QUERY_TYPE_SO_OVERFLOW 
WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM0 
WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM1 
WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM2 
WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM3 
WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM0 
WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM1 
WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM2 
WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM3 

Definition at line 704 of file wined3d.h.

705{
732};
@ WINED3D_QUERY_TYPE_RESOURCE_MANAGER
Definition: wined3d.h:707
@ WINED3D_QUERY_TYPE_TIMESTAMP_FREQ
Definition: wined3d.h:713
@ WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM2
Definition: wined3d.h:726
@ WINED3D_QUERY_TYPE_PIXEL_TIMINGS
Definition: wined3d.h:717
@ WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM3
Definition: wined3d.h:731
@ WINED3D_QUERY_TYPE_PIPELINE_TIMINGS
Definition: wined3d.h:714
@ WINED3D_QUERY_TYPE_SO_STATISTICS
Definition: wined3d.h:722
@ WINED3D_QUERY_TYPE_PIPELINE_STATISTICS
Definition: wined3d.h:721
@ WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM2
Definition: wined3d.h:730
@ WINED3D_QUERY_TYPE_VCACHE
Definition: wined3d.h:706
@ WINED3D_QUERY_TYPE_VERTEX_STATS
Definition: wined3d.h:708
@ WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM0
Definition: wined3d.h:724
@ WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM0
Definition: wined3d.h:728
@ WINED3D_QUERY_TYPE_BANDWIDTH_TIMINGS
Definition: wined3d.h:718
@ WINED3D_QUERY_TYPE_CACHE_UTILIZATION
Definition: wined3d.h:719
@ WINED3D_QUERY_TYPE_SO_OVERFLOW_STREAM1
Definition: wined3d.h:729
@ WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM1
Definition: wined3d.h:725
@ WINED3D_QUERY_TYPE_TIMESTAMP
Definition: wined3d.h:711
@ WINED3D_QUERY_TYPE_MEMORY_PRESSURE
Definition: wined3d.h:720
@ WINED3D_QUERY_TYPE_SO_OVERFLOW
Definition: wined3d.h:723
@ WINED3D_QUERY_TYPE_EVENT
Definition: wined3d.h:709
@ WINED3D_QUERY_TYPE_TIMESTAMP_DISJOINT
Definition: wined3d.h:712
@ WINED3D_QUERY_TYPE_INTERFACE_TIMINGS
Definition: wined3d.h:715
@ WINED3D_QUERY_TYPE_OCCLUSION
Definition: wined3d.h:710
@ WINED3D_QUERY_TYPE_VERTEX_TIMINGS
Definition: wined3d.h:716
@ WINED3D_QUERY_TYPE_SO_STATISTICS_STREAM3
Definition: wined3d.h:727

◆ wined3d_render_state

Enumerator
WINED3D_RS_ANTIALIAS 
WINED3D_RS_TEXTUREPERSPECTIVE 
WINED3D_RS_WRAPU 
WINED3D_RS_WRAPV 
WINED3D_RS_ZENABLE 
WINED3D_RS_FILLMODE 
WINED3D_RS_SHADEMODE 
WINED3D_RS_LINEPATTERN 
WINED3D_RS_MONOENABLE 
WINED3D_RS_ROP2 
WINED3D_RS_PLANEMASK 
WINED3D_RS_ZWRITEENABLE 
WINED3D_RS_ALPHATESTENABLE 
WINED3D_RS_LASTPIXEL 
WINED3D_RS_SRCBLEND 
WINED3D_RS_DESTBLEND 
WINED3D_RS_CULLMODE 
WINED3D_RS_ZFUNC 
WINED3D_RS_ALPHAREF 
WINED3D_RS_ALPHAFUNC 
WINED3D_RS_DITHERENABLE 
WINED3D_RS_ALPHABLENDENABLE 
WINED3D_RS_FOGENABLE 
WINED3D_RS_SPECULARENABLE 
WINED3D_RS_ZVISIBLE 
WINED3D_RS_SUBPIXEL 
WINED3D_RS_SUBPIXELX 
WINED3D_RS_STIPPLEDALPHA 
WINED3D_RS_FOGCOLOR 
WINED3D_RS_FOGTABLEMODE 
WINED3D_RS_FOGSTART 
WINED3D_RS_FOGEND 
WINED3D_RS_FOGDENSITY 
WINED3D_RS_STIPPLEENABLE 
WINED3D_RS_EDGEANTIALIAS 
WINED3D_RS_COLORKEYENABLE 
WINED3D_RS_MIPMAPLODBIAS 
WINED3D_RS_RANGEFOGENABLE 
WINED3D_RS_ANISOTROPY 
WINED3D_RS_FLUSHBATCH 
WINED3D_RS_TRANSLUCENTSORTINDEPENDENT 
WINED3D_RS_STENCILENABLE 
WINED3D_RS_STENCILFAIL 
WINED3D_RS_STENCILZFAIL 
WINED3D_RS_STENCILPASS 
WINED3D_RS_STENCILFUNC 
WINED3D_RS_STENCILREF 
WINED3D_RS_STENCILMASK 
WINED3D_RS_STENCILWRITEMASK 
WINED3D_RS_TEXTUREFACTOR 
WINED3D_RS_WRAP0 
WINED3D_RS_WRAP1 
WINED3D_RS_WRAP2 
WINED3D_RS_WRAP3 
WINED3D_RS_WRAP4 
WINED3D_RS_WRAP5 
WINED3D_RS_WRAP6 
WINED3D_RS_WRAP7 
WINED3D_RS_CLIPPING 
WINED3D_RS_LIGHTING 
WINED3D_RS_EXTENTS 
WINED3D_RS_AMBIENT 
WINED3D_RS_FOGVERTEXMODE 
WINED3D_RS_COLORVERTEX 
WINED3D_RS_LOCALVIEWER 
WINED3D_RS_NORMALIZENORMALS 
WINED3D_RS_COLORKEYBLENDENABLE 
WINED3D_RS_DIFFUSEMATERIALSOURCE 
WINED3D_RS_SPECULARMATERIALSOURCE 
WINED3D_RS_AMBIENTMATERIALSOURCE 
WINED3D_RS_EMISSIVEMATERIALSOURCE 
WINED3D_RS_VERTEXBLEND 
WINED3D_RS_CLIPPLANEENABLE 
WINED3D_RS_SOFTWAREVERTEXPROCESSING 
WINED3D_RS_POINTSIZE 
WINED3D_RS_POINTSIZE_MIN 
WINED3D_RS_POINTSPRITEENABLE 
WINED3D_RS_POINTSCALEENABLE 
WINED3D_RS_POINTSCALE_A 
WINED3D_RS_POINTSCALE_B 
WINED3D_RS_POINTSCALE_C 
WINED3D_RS_MULTISAMPLEANTIALIAS 
WINED3D_RS_MULTISAMPLEMASK 
WINED3D_RS_PATCHEDGESTYLE 
WINED3D_RS_PATCHSEGMENTS 
WINED3D_RS_DEBUGMONITORTOKEN 
WINED3D_RS_POINTSIZE_MAX 
WINED3D_RS_INDEXEDVERTEXBLENDENABLE 
WINED3D_RS_COLORWRITEENABLE 
WINED3D_RS_TWEENFACTOR 
WINED3D_RS_BLENDOP 
WINED3D_RS_POSITIONDEGREE 
WINED3D_RS_NORMALDEGREE 
WINED3D_RS_SCISSORTESTENABLE 
WINED3D_RS_SLOPESCALEDEPTHBIAS 
WINED3D_RS_ANTIALIASEDLINEENABLE 
WINED3D_RS_MINTESSELLATIONLEVEL 
WINED3D_RS_MAXTESSELLATIONLEVEL 
WINED3D_RS_ADAPTIVETESS_X 
WINED3D_RS_ADAPTIVETESS_Y 
WINED3D_RS_ADAPTIVETESS_Z 
WINED3D_RS_ADAPTIVETESS_W 
WINED3D_RS_ENABLEADAPTIVETESSELLATION 
WINED3D_RS_TWOSIDEDSTENCILMODE 
WINED3D_RS_BACK_STENCILFAIL 
WINED3D_RS_BACK_STENCILZFAIL 
WINED3D_RS_BACK_STENCILPASS 
WINED3D_RS_BACK_STENCILFUNC 
WINED3D_RS_COLORWRITEENABLE1 
WINED3D_RS_COLORWRITEENABLE2 
WINED3D_RS_COLORWRITEENABLE3 
WINED3D_RS_BLENDFACTOR 
WINED3D_RS_SRGBWRITEENABLE 
WINED3D_RS_DEPTHBIAS 
WINED3D_RS_WRAP8 
WINED3D_RS_WRAP9 
WINED3D_RS_WRAP10 
WINED3D_RS_WRAP11 
WINED3D_RS_WRAP12 
WINED3D_RS_WRAP13 
WINED3D_RS_WRAP14 
WINED3D_RS_WRAP15 
WINED3D_RS_SEPARATEALPHABLENDENABLE 
WINED3D_RS_SRCBLENDALPHA 
WINED3D_RS_DESTBLENDALPHA 
WINED3D_RS_BLENDOPALPHA 
WINED3D_RS_DEPTHCLIP 
WINED3D_RS_DEPTHBIASCLAMP 
WINED3D_RS_COLORWRITEENABLE4 
WINED3D_RS_COLORWRITEENABLE5 
WINED3D_RS_COLORWRITEENABLE6 
WINED3D_RS_COLORWRITEENABLE7 

Definition at line 263 of file wined3d.h.

264{
274 WINED3D_RS_ROP2 = 12,
282 WINED3D_RS_ZFUNC = 23,
315 WINED3D_RS_WRAP0 = 128,
316 WINED3D_RS_WRAP1 = 129,
317 WINED3D_RS_WRAP2 = 130,
318 WINED3D_RS_WRAP3 = 131,
319 WINED3D_RS_WRAP4 = 132,
320 WINED3D_RS_WRAP5 = 133,
321 WINED3D_RS_WRAP6 = 134,
322 WINED3D_RS_WRAP7 = 135,
325 WINED3D_RS_EXTENTS = 138,
326 WINED3D_RS_AMBIENT = 139,
355 WINED3D_RS_BLENDOP = 171,
379 WINED3D_RS_WRAP8 = 198,
380 WINED3D_RS_WRAP9 = 199,
381 WINED3D_RS_WRAP10 = 200,
382 WINED3D_RS_WRAP11 = 201,
383 WINED3D_RS_WRAP12 = 202,
384 WINED3D_RS_WRAP13 = 203,
385 WINED3D_RS_WRAP14 = 204,
386 WINED3D_RS_WRAP15 = 205,
397};
@ WINED3D_RS_TEXTUREFACTOR
Definition: wined3d.h:314
@ WINED3D_RS_COLORKEYENABLE
Definition: wined3d.h:300
@ WINED3D_RS_STENCILFAIL
Definition: wined3d.h:307
@ WINED3D_RS_NORMALDEGREE
Definition: wined3d.h:357
@ WINED3D_RS_WRAP8
Definition: wined3d.h:379
@ WINED3D_RS_LIGHTING
Definition: wined3d.h:324
@ WINED3D_RS_SOFTWAREVERTEXPROCESSING
Definition: wined3d.h:338
@ WINED3D_RS_COLORWRITEENABLE7
Definition: wined3d.h:396
@ WINED3D_RS_STIPPLEDALPHA
Definition: wined3d.h:292
@ WINED3D_RS_COLORWRITEENABLE1
Definition: wined3d.h:373
@ WINED3D_RS_STENCILENABLE
Definition: wined3d.h:306
@ WINED3D_RS_COLORVERTEX
Definition: wined3d.h:328
@ WINED3D_RS_TWEENFACTOR
Definition: wined3d.h:354
@ WINED3D_RS_FOGCOLOR
Definition: wined3d.h:293
@ WINED3D_RS_WRAP4
Definition: wined3d.h:319
@ WINED3D_RS_WRAP15
Definition: wined3d.h:386
@ WINED3D_RS_COLORWRITEENABLE5
Definition: wined3d.h:394
@ WINED3D_RS_ZENABLE
Definition: wined3d.h:269
@ WINED3D_RS_ANTIALIASEDLINEENABLE
Definition: wined3d.h:360
@ WINED3D_RS_SPECULARMATERIALSOURCE
Definition: wined3d.h:333
@ WINED3D_RS_STENCILPASS
Definition: wined3d.h:309
@ WINED3D_RS_WRAP13
Definition: wined3d.h:384
@ WINED3D_RS_DEBUGMONITORTOKEN
Definition: wined3d.h:350
@ WINED3D_RS_WRAP1
Definition: wined3d.h:316
@ WINED3D_RS_WRAP3
Definition: wined3d.h:318
@ WINED3D_RS_DEPTHBIAS
Definition: wined3d.h:378
@ WINED3D_RS_MAXTESSELLATIONLEVEL
Definition: wined3d.h:362
@ WINED3D_RS_DITHERENABLE
Definition: wined3d.h:285
@ WINED3D_RS_SHADEMODE
Definition: wined3d.h:271
@ WINED3D_RS_CULLMODE
Definition: wined3d.h:281
@ WINED3D_RS_BACK_STENCILPASS
Definition: wined3d.h:371
@ WINED3D_RS_WRAPV
Definition: wined3d.h:268
@ WINED3D_RS_COLORWRITEENABLE4
Definition: wined3d.h:393
@ WINED3D_RS_PATCHEDGESTYLE
Definition: wined3d.h:348
@ WINED3D_RS_SCISSORTESTENABLE
Definition: wined3d.h:358
@ WINED3D_RS_LASTPIXEL
Definition: wined3d.h:278
@ WINED3D_RS_VERTEXBLEND
Definition: wined3d.h:336
@ WINED3D_RS_FOGEND
Definition: wined3d.h:296
@ WINED3D_RS_MINTESSELLATIONLEVEL
Definition: wined3d.h:361
@ WINED3D_RS_POINTSCALE_A
Definition: wined3d.h:343
@ WINED3D_RS_MULTISAMPLEMASK
Definition: wined3d.h:347
@ WINED3D_RS_BACK_STENCILFUNC
Definition: wined3d.h:372
@ WINED3D_RS_SRCBLEND
Definition: wined3d.h:279
@ WINED3D_RS_SRGBWRITEENABLE
Definition: wined3d.h:377
@ WINED3D_RS_RANGEFOGENABLE
Definition: wined3d.h:302
@ WINED3D_RS_POINTSIZE_MIN
Definition: wined3d.h:340
@ WINED3D_RS_TEXTUREPERSPECTIVE
Definition: wined3d.h:266
@ WINED3D_RS_DEPTHCLIP
Definition: wined3d.h:391
@ WINED3D_RS_ENABLEADAPTIVETESSELLATION
Definition: wined3d.h:367
@ WINED3D_RS_COLORWRITEENABLE3
Definition: wined3d.h:375
@ WINED3D_RS_ALPHABLENDENABLE
Definition: wined3d.h:286
@ WINED3D_RS_WRAPU
Definition: wined3d.h:267
@ WINED3D_RS_ADAPTIVETESS_X
Definition: wined3d.h:363
@ WINED3D_RS_MONOENABLE
Definition: wined3d.h:273
@ WINED3D_RS_LOCALVIEWER
Definition: wined3d.h:329
@ WINED3D_RS_ADAPTIVETESS_Z
Definition: wined3d.h:365
@ WINED3D_RS_WRAP0
Definition: wined3d.h:315
@ WINED3D_RS_STENCILMASK
Definition: wined3d.h:312
@ WINED3D_RS_COLORWRITEENABLE6
Definition: wined3d.h:395
@ WINED3D_RS_BLENDOP
Definition: wined3d.h:355
@ WINED3D_RS_POINTSCALE_C
Definition: wined3d.h:345
@ WINED3D_RS_FOGSTART
Definition: wined3d.h:295
@ WINED3D_RS_STENCILFUNC
Definition: wined3d.h:310
@ WINED3D_RS_WRAP7
Definition: wined3d.h:322
@ WINED3D_RS_FOGTABLEMODE
Definition: wined3d.h:294
@ WINED3D_RS_POINTSIZE
Definition: wined3d.h:339
@ WINED3D_RS_POINTSIZE_MAX
Definition: wined3d.h:351
@ WINED3D_RS_ZWRITEENABLE
Definition: wined3d.h:276
@ WINED3D_RS_PLANEMASK
Definition: wined3d.h:275
@ WINED3D_RS_SUBPIXELX
Definition: wined3d.h:291
@ WINED3D_RS_CLIPPLANEENABLE
Definition: wined3d.h:337
@ WINED3D_RS_DESTBLEND
Definition: wined3d.h:280
@ WINED3D_RS_AMBIENTMATERIALSOURCE
Definition: wined3d.h:334
@ WINED3D_RS_WRAP6
Definition: wined3d.h:321
@ WINED3D_RS_STENCILREF
Definition: wined3d.h:311
@ WINED3D_RS_FOGENABLE
Definition: wined3d.h:287
@ WINED3D_RS_POINTSPRITEENABLE
Definition: wined3d.h:341
@ WINED3D_RS_FLUSHBATCH
Definition: wined3d.h:304
@ WINED3D_RS_BACK_STENCILZFAIL
Definition: wined3d.h:370
@ WINED3D_RS_ZFUNC
Definition: wined3d.h:282
@ WINED3D_RS_ROP2
Definition: wined3d.h:274
@ WINED3D_RS_POSITIONDEGREE
Definition: wined3d.h:356
@ WINED3D_RS_MULTISAMPLEANTIALIAS
Definition: wined3d.h:346
@ WINED3D_RS_ANTIALIAS
Definition: wined3d.h:265
@ WINED3D_RS_BACK_STENCILFAIL
Definition: wined3d.h:369
@ WINED3D_RS_COLORWRITEENABLE
Definition: wined3d.h:353
@ WINED3D_RS_SLOPESCALEDEPTHBIAS
Definition: wined3d.h:359
@ WINED3D_RS_DIFFUSEMATERIALSOURCE
Definition: wined3d.h:332
@ WINED3D_RS_DEPTHBIASCLAMP
Definition: wined3d.h:392
@ WINED3D_RS_ALPHAREF
Definition: wined3d.h:283
@ WINED3D_RS_NORMALIZENORMALS
Definition: wined3d.h:330
@ WINED3D_RS_ANISOTROPY
Definition: wined3d.h:303
@ WINED3D_RS_TWOSIDEDSTENCILMODE
Definition: wined3d.h:368
@ WINED3D_RS_TRANSLUCENTSORTINDEPENDENT
Definition: wined3d.h:305
@ WINED3D_RS_EMISSIVEMATERIALSOURCE
Definition: wined3d.h:335
@ WINED3D_RS_PATCHSEGMENTS
Definition: wined3d.h:349
@ WINED3D_RS_SPECULARENABLE
Definition: wined3d.h:288
@ WINED3D_RS_WRAP2
Definition: wined3d.h:317
@ WINED3D_RS_ADAPTIVETESS_W
Definition: wined3d.h:366
@ WINED3D_RS_FILLMODE
Definition: wined3d.h:270
@ WINED3D_RS_CLIPPING
Definition: wined3d.h:323
@ WINED3D_RS_WRAP10
Definition: wined3d.h:381
@ WINED3D_RS_SRCBLENDALPHA
Definition: wined3d.h:388
@ WINED3D_RS_COLORKEYBLENDENABLE
Definition: wined3d.h:331
@ WINED3D_RS_COLORWRITEENABLE2
Definition: wined3d.h:374
@ WINED3D_RS_POINTSCALEENABLE
Definition: wined3d.h:342
@ WINED3D_RS_WRAP14
Definition: wined3d.h:385
@ WINED3D_RS_FOGVERTEXMODE
Definition: wined3d.h:327
@ WINED3D_RS_STENCILWRITEMASK
Definition: wined3d.h:313
@ WINED3D_RS_AMBIENT
Definition: wined3d.h:326
@ WINED3D_RS_WRAP11
Definition: wined3d.h:382
@ WINED3D_RS_LINEPATTERN
Definition: wined3d.h:272
@ WINED3D_RS_ZVISIBLE
Definition: wined3d.h:289
@ WINED3D_RS_BLENDFACTOR
Definition: wined3d.h:376
@ WINED3D_RS_EXTENTS
Definition: wined3d.h:325
@ WINED3D_RS_BLENDOPALPHA
Definition: wined3d.h:390
@ WINED3D_RS_DESTBLENDALPHA
Definition: wined3d.h:389
@ WINED3D_RS_FOGDENSITY
Definition: wined3d.h:297
@ WINED3D_RS_STENCILZFAIL
Definition: wined3d.h:308
@ WINED3D_RS_SUBPIXEL
Definition: wined3d.h:290
@ WINED3D_RS_POINTSCALE_B
Definition: wined3d.h:344
@ WINED3D_RS_INDEXEDVERTEXBLENDENABLE
Definition: wined3d.h:352
@ WINED3D_RS_MIPMAPLODBIAS
Definition: wined3d.h:301
@ WINED3D_RS_WRAP9
Definition: wined3d.h:380
@ WINED3D_RS_SEPARATEALPHABLENDENABLE
Definition: wined3d.h:387
@ WINED3D_RS_STIPPLEENABLE
Definition: wined3d.h:298
@ WINED3D_RS_WRAP5
Definition: wined3d.h:320
@ WINED3D_RS_ADAPTIVETESS_Y
Definition: wined3d.h:364
@ WINED3D_RS_ALPHATESTENABLE
Definition: wined3d.h:277
@ WINED3D_RS_ALPHAFUNC
Definition: wined3d.h:284
@ WINED3D_RS_WRAP12
Definition: wined3d.h:383
@ WINED3D_RS_EDGEANTIALIAS
Definition: wined3d.h:299

◆ wined3d_resource_type

Enumerator
WINED3D_RTYPE_NONE 
WINED3D_RTYPE_BUFFER 
WINED3D_RTYPE_TEXTURE_1D 
WINED3D_RTYPE_TEXTURE_2D 
WINED3D_RTYPE_TEXTURE_3D 

Definition at line 695 of file wined3d.h.

696{
702};
@ WINED3D_RTYPE_TEXTURE_2D
Definition: wined3d.h:700
@ WINED3D_RTYPE_TEXTURE_1D
Definition: wined3d.h:699
@ WINED3D_RTYPE_NONE
Definition: wined3d.h:697
@ WINED3D_RTYPE_BUFFER
Definition: wined3d.h:698
@ WINED3D_RTYPE_TEXTURE_3D
Definition: wined3d.h:701

◆ wined3d_sampler_state

Enumerator
WINED3D_SAMP_ADDRESS_U 
WINED3D_SAMP_ADDRESS_V 
WINED3D_SAMP_ADDRESS_W 
WINED3D_SAMP_BORDER_COLOR 
WINED3D_SAMP_MAG_FILTER 
WINED3D_SAMP_MIN_FILTER 
WINED3D_SAMP_MIP_FILTER 
WINED3D_SAMP_MIPMAP_LOD_BIAS 
WINED3D_SAMP_MAX_MIP_LEVEL 
WINED3D_SAMP_MAX_ANISOTROPY 
WINED3D_SAMP_SRGB_TEXTURE 
WINED3D_SAMP_ELEMENT_INDEX 
WINED3D_SAMP_DMAP_OFFSET 

Definition at line 534 of file wined3d.h.

535{
549};
@ WINED3D_SAMP_ELEMENT_INDEX
Definition: wined3d.h:547
@ WINED3D_SAMP_MAX_ANISOTROPY
Definition: wined3d.h:545
@ WINED3D_SAMP_MIPMAP_LOD_BIAS
Definition: wined3d.h:543
@ WINED3D_SAMP_MIN_FILTER
Definition: wined3d.h:541
@ WINED3D_SAMP_SRGB_TEXTURE
Definition: wined3d.h:546
@ WINED3D_SAMP_DMAP_OFFSET
Definition: wined3d.h:548
@ WINED3D_SAMP_MIP_FILTER
Definition: wined3d.h:542
@ WINED3D_SAMP_MAG_FILTER
Definition: wined3d.h:540
@ WINED3D_SAMP_BORDER_COLOR
Definition: wined3d.h:539
@ WINED3D_SAMP_ADDRESS_V
Definition: wined3d.h:537
@ WINED3D_SAMP_ADDRESS_U
Definition: wined3d.h:536
@ WINED3D_SAMP_ADDRESS_W
Definition: wined3d.h:538
@ WINED3D_SAMP_MAX_MIP_LEVEL
Definition: wined3d.h:544

◆ wined3d_scanline_ordering

Enumerator
WINED3D_SCANLINE_ORDERING_UNKNOWN 
WINED3D_SCANLINE_ORDERING_PROGRESSIVE 
WINED3D_SCANLINE_ORDERING_INTERLACED 

Definition at line 830 of file wined3d.h.

831{
835};
@ WINED3D_SCANLINE_ORDERING_UNKNOWN
Definition: wined3d.h:832
@ WINED3D_SCANLINE_ORDERING_INTERLACED
Definition: wined3d.h:834
@ WINED3D_SCANLINE_ORDERING_PROGRESSIVE
Definition: wined3d.h:833

◆ wined3d_shade_mode

Enumerator
WINED3D_SHADE_FLAT 
WINED3D_SHADE_GOURAUD 
WINED3D_SHADE_PHONG 

Definition at line 477 of file wined3d.h.

478{
482};
@ WINED3D_SHADE_GOURAUD
Definition: wined3d.h:480
@ WINED3D_SHADE_PHONG
Definition: wined3d.h:481
@ WINED3D_SHADE_FLAT
Definition: wined3d.h:479

◆ wined3d_shader_byte_code_format

Enumerator
WINED3D_SHADER_BYTE_CODE_FORMAT_SM1 
WINED3D_SHADER_BYTE_CODE_FORMAT_SM4 

Definition at line 846 of file wined3d.h.

847{
850};
@ WINED3D_SHADER_BYTE_CODE_FORMAT_SM1
Definition: wined3d.h:848
@ WINED3D_SHADER_BYTE_CODE_FORMAT_SM4
Definition: wined3d.h:849

◆ wined3d_stateblock_type

Enumerator
WINED3D_SBT_ALL 
WINED3D_SBT_PIXEL_STATE 
WINED3D_SBT_VERTEX_STATE 
WINED3D_SBT_RECORDED 

Definition at line 765 of file wined3d.h.

766{
767 WINED3D_SBT_ALL = 1,
770 WINED3D_SBT_RECORDED = 4, /* WineD3D private */
771};
@ WINED3D_SBT_PIXEL_STATE
Definition: wined3d.h:768
@ WINED3D_SBT_VERTEX_STATE
Definition: wined3d.h:769
@ WINED3D_SBT_ALL
Definition: wined3d.h:767
@ WINED3D_SBT_RECORDED
Definition: wined3d.h:770

◆ wined3d_stencil_op

Enumerator
WINED3D_STENCIL_OP_KEEP 
WINED3D_STENCIL_OP_ZERO 
WINED3D_STENCIL_OP_REPLACE 
WINED3D_STENCIL_OP_INCR_SAT 
WINED3D_STENCIL_OP_DECR_SAT 
WINED3D_STENCIL_OP_INVERT 
WINED3D_STENCIL_OP_INCR 
WINED3D_STENCIL_OP_DECR 

Definition at line 498 of file wined3d.h.

499{
508};
@ WINED3D_STENCIL_OP_INCR
Definition: wined3d.h:506
@ WINED3D_STENCIL_OP_KEEP
Definition: wined3d.h:500
@ WINED3D_STENCIL_OP_REPLACE
Definition: wined3d.h:502
@ WINED3D_STENCIL_OP_INVERT
Definition: wined3d.h:505
@ WINED3D_STENCIL_OP_DECR_SAT
Definition: wined3d.h:504
@ WINED3D_STENCIL_OP_DECR
Definition: wined3d.h:507
@ WINED3D_STENCIL_OP_ZERO
Definition: wined3d.h:501
@ WINED3D_STENCIL_OP_INCR_SAT
Definition: wined3d.h:503

◆ wined3d_swap_effect

Enumerator
WINED3D_SWAP_EFFECT_DISCARD 
WINED3D_SWAP_EFFECT_SEQUENTIAL 
WINED3D_SWAP_EFFECT_FLIP_DISCARD 
WINED3D_SWAP_EFFECT_FLIP_SEQUENTIAL 
WINED3D_SWAP_EFFECT_COPY 
WINED3D_SWAP_EFFECT_COPY_VSYNC 
WINED3D_SWAP_EFFECT_OVERLAY 

Definition at line 523 of file wined3d.h.

524{
532};
@ WINED3D_SWAP_EFFECT_FLIP_DISCARD
Definition: wined3d.h:527
@ WINED3D_SWAP_EFFECT_COPY
Definition: wined3d.h:529
@ WINED3D_SWAP_EFFECT_SEQUENTIAL
Definition: wined3d.h:526
@ WINED3D_SWAP_EFFECT_DISCARD
Definition: wined3d.h:525
@ WINED3D_SWAP_EFFECT_COPY_VSYNC
Definition: wined3d.h:530
@ WINED3D_SWAP_EFFECT_OVERLAY
Definition: wined3d.h:531
@ WINED3D_SWAP_EFFECT_FLIP_SEQUENTIAL
Definition: wined3d.h:528

◆ wined3d_sysval_semantic

Enumerator
WINED3D_SV_POSITION 
WINED3D_SV_CLIP_DISTANCE 
WINED3D_SV_CULL_DISTANCE 
WINED3D_SV_RENDER_TARGET_ARRAY_INDEX 
WINED3D_SV_VIEWPORT_ARRAY_INDEX 
WINED3D_SV_VERTEX_ID 
WINED3D_SV_PRIMITIVE_ID 
WINED3D_SV_INSTANCE_ID 
WINED3D_SV_IS_FRONT_FACE 
WINED3D_SV_SAMPLE_INDEX 
WINED3D_SV_TESS_FACTOR_QUADEDGE 
WINED3D_SV_TESS_FACTOR_QUADINT 
WINED3D_SV_TESS_FACTOR_TRIEDGE 
WINED3D_SV_TESS_FACTOR_TRIINT 
WINED3D_SV_TESS_FACTOR_LINEDET 
WINED3D_SV_TESS_FACTOR_LINEDEN 

Definition at line 802 of file wined3d.h.

803{
820};
@ WINED3D_SV_INSTANCE_ID
Definition: wined3d.h:811
@ WINED3D_SV_CULL_DISTANCE
Definition: wined3d.h:806
@ WINED3D_SV_CLIP_DISTANCE
Definition: wined3d.h:805
@ WINED3D_SV_VIEWPORT_ARRAY_INDEX
Definition: wined3d.h:808
@ WINED3D_SV_TESS_FACTOR_QUADINT
Definition: wined3d.h:815
@ WINED3D_SV_SAMPLE_INDEX
Definition: wined3d.h:813
@ WINED3D_SV_IS_FRONT_FACE
Definition: wined3d.h:812
@ WINED3D_SV_TESS_FACTOR_QUADEDGE
Definition: wined3d.h:814
@ WINED3D_SV_TESS_FACTOR_LINEDET
Definition: wined3d.h:818
@ WINED3D_SV_POSITION
Definition: wined3d.h:804
@ WINED3D_SV_PRIMITIVE_ID
Definition: wined3d.h:810
@ WINED3D_SV_RENDER_TARGET_ARRAY_INDEX
Definition: wined3d.h:807
@ WINED3D_SV_TESS_FACTOR_TRIINT
Definition: wined3d.h:817
@ WINED3D_SV_TESS_FACTOR_TRIEDGE
Definition: wined3d.h:816
@ WINED3D_SV_TESS_FACTOR_LINEDEN
Definition: wined3d.h:819
@ WINED3D_SV_VERTEX_ID
Definition: wined3d.h:809

◆ wined3d_texture_address

Enumerator
WINED3D_TADDRESS_WRAP 
WINED3D_TADDRESS_MIRROR 
WINED3D_TADDRESS_CLAMP 
WINED3D_TADDRESS_BORDER 
WINED3D_TADDRESS_MIRROR_ONCE 

Definition at line 637 of file wined3d.h.

638{
644};
@ WINED3D_TADDRESS_BORDER
Definition: wined3d.h:642
@ WINED3D_TADDRESS_MIRROR_ONCE
Definition: wined3d.h:643
@ WINED3D_TADDRESS_WRAP
Definition: wined3d.h:639
@ WINED3D_TADDRESS_MIRROR
Definition: wined3d.h:640
@ WINED3D_TADDRESS_CLAMP
Definition: wined3d.h:641

◆ wined3d_texture_filter_type

Enumerator
WINED3D_TEXF_NONE 
WINED3D_TEXF_POINT 
WINED3D_TEXF_LINEAR 
WINED3D_TEXF_ANISOTROPIC 
WINED3D_TEXF_FLAT_CUBIC 
WINED3D_TEXF_GAUSSIAN_CUBIC 
WINED3D_TEXF_PYRAMIDAL_QUAD 
WINED3D_TEXF_GAUSSIAN_QUAD 

Definition at line 683 of file wined3d.h.

684{
693};
@ WINED3D_TEXF_GAUSSIAN_CUBIC
Definition: wined3d.h:690
@ WINED3D_TEXF_NONE
Definition: wined3d.h:685
@ WINED3D_TEXF_PYRAMIDAL_QUAD
Definition: wined3d.h:691
@ WINED3D_TEXF_FLAT_CUBIC
Definition: wined3d.h:689
@ WINED3D_TEXF_GAUSSIAN_QUAD
Definition: wined3d.h:692
@ WINED3D_TEXF_POINT
Definition: wined3d.h:686
@ WINED3D_TEXF_ANISOTROPIC
Definition: wined3d.h:688
@ WINED3D_TEXF_LINEAR
Definition: wined3d.h:687

◆ wined3d_texture_op

Enumerator
WINED3D_TOP_DISABLE 
WINED3D_TOP_SELECT_ARG1 
WINED3D_TOP_SELECT_ARG2 
WINED3D_TOP_MODULATE 
WINED3D_TOP_MODULATE_2X 
WINED3D_TOP_MODULATE_4X 
WINED3D_TOP_ADD 
WINED3D_TOP_ADD_SIGNED 
WINED3D_TOP_ADD_SIGNED_2X 
WINED3D_TOP_SUBTRACT 
WINED3D_TOP_ADD_SMOOTH 
WINED3D_TOP_BLEND_DIFFUSE_ALPHA 
WINED3D_TOP_BLEND_TEXTURE_ALPHA 
WINED3D_TOP_BLEND_FACTOR_ALPHA 
WINED3D_TOP_BLEND_TEXTURE_ALPHA_PM 
WINED3D_TOP_BLEND_CURRENT_ALPHA 
WINED3D_TOP_PREMODULATE 
WINED3D_TOP_MODULATE_ALPHA_ADD_COLOR 
WINED3D_TOP_MODULATE_COLOR_ADD_ALPHA 
WINED3D_TOP_MODULATE_INVALPHA_ADD_COLOR 
WINED3D_TOP_MODULATE_INVCOLOR_ADD_ALPHA 
WINED3D_TOP_BUMPENVMAP 
WINED3D_TOP_BUMPENVMAP_LUMINANCE 
WINED3D_TOP_DOTPRODUCT3 
WINED3D_TOP_MULTIPLY_ADD 
WINED3D_TOP_LERP 

Definition at line 607 of file wined3d.h.

608{
615 WINED3D_TOP_ADD = 7,
634 WINED3D_TOP_LERP = 26,
635};
@ WINED3D_TOP_SELECT_ARG1
Definition: wined3d.h:610
@ WINED3D_TOP_DISABLE
Definition: wined3d.h:609
@ WINED3D_TOP_BLEND_DIFFUSE_ALPHA
Definition: wined3d.h:620
@ WINED3D_TOP_ADD
Definition: wined3d.h:615
@ WINED3D_TOP_BLEND_TEXTURE_ALPHA_PM
Definition: wined3d.h:623
@ WINED3D_TOP_BLEND_CURRENT_ALPHA
Definition: wined3d.h:624
@ WINED3D_TOP_ADD_SIGNED_2X
Definition: wined3d.h:617
@ WINED3D_TOP_MODULATE_INVCOLOR_ADD_ALPHA
Definition: wined3d.h:629
@ WINED3D_TOP_MULTIPLY_ADD
Definition: wined3d.h:633
@ WINED3D_TOP_MODULATE_INVALPHA_ADD_COLOR
Definition: wined3d.h:628
@ WINED3D_TOP_SUBTRACT
Definition: wined3d.h:618
@ WINED3D_TOP_BUMPENVMAP_LUMINANCE
Definition: wined3d.h:631
@ WINED3D_TOP_MODULATE_COLOR_ADD_ALPHA
Definition: wined3d.h:627
@ WINED3D_TOP_MODULATE
Definition: wined3d.h:612
@ WINED3D_TOP_BUMPENVMAP
Definition: wined3d.h:630
@ WINED3D_TOP_MODULATE_4X
Definition: wined3d.h:614
@ WINED3D_TOP_SELECT_ARG2
Definition: wined3d.h:611
@ WINED3D_TOP_LERP
Definition: wined3d.h:634
@ WINED3D_TOP_MODULATE_ALPHA_ADD_COLOR
Definition: wined3d.h:626
@ WINED3D_TOP_BLEND_TEXTURE_ALPHA
Definition: wined3d.h:621
@ WINED3D_TOP_ADD_SIGNED
Definition: wined3d.h:616
@ WINED3D_TOP_DOTPRODUCT3
Definition: wined3d.h:632
@ WINED3D_TOP_PREMODULATE
Definition: wined3d.h:625
@ WINED3D_TOP_ADD_SMOOTH
Definition: wined3d.h:619
@ WINED3D_TOP_MODULATE_2X
Definition: wined3d.h:613
@ WINED3D_TOP_BLEND_FACTOR_ALPHA
Definition: wined3d.h:622

◆ wined3d_texture_stage_state

Enumerator
WINED3D_TSS_COLOR_OP 
WINED3D_TSS_COLOR_ARG1 
WINED3D_TSS_COLOR_ARG2 
WINED3D_TSS_ALPHA_OP 
WINED3D_TSS_ALPHA_ARG1 
WINED3D_TSS_ALPHA_ARG2 
WINED3D_TSS_BUMPENV_MAT00 
WINED3D_TSS_BUMPENV_MAT01 
WINED3D_TSS_BUMPENV_MAT10 
WINED3D_TSS_BUMPENV_MAT11 
WINED3D_TSS_TEXCOORD_INDEX 
WINED3D_TSS_BUMPENV_LSCALE 
WINED3D_TSS_BUMPENV_LOFFSET 
WINED3D_TSS_TEXTURE_TRANSFORM_FLAGS 
WINED3D_TSS_COLOR_ARG0 
WINED3D_TSS_ALPHA_ARG0 
WINED3D_TSS_RESULT_ARG 
WINED3D_TSS_CONSTANT 
WINED3D_TSS_INVALID 

Definition at line 573 of file wined3d.h.

574{
594};
#define U(x)
Definition: wordpad.c:45
@ WINED3D_TSS_COLOR_ARG2
Definition: wined3d.h:577
@ WINED3D_TSS_BUMPENV_LOFFSET
Definition: wined3d.h:587
@ WINED3D_TSS_ALPHA_OP
Definition: wined3d.h:578
@ WINED3D_TSS_BUMPENV_MAT11
Definition: wined3d.h:584
@ WINED3D_TSS_COLOR_OP
Definition: wined3d.h:575
@ WINED3D_TSS_INVALID
Definition: wined3d.h:593
@ WINED3D_TSS_BUMPENV_MAT10
Definition: wined3d.h:583
@ WINED3D_TSS_TEXCOORD_INDEX
Definition: wined3d.h:585
@ WINED3D_TSS_ALPHA_ARG2
Definition: wined3d.h:580
@ WINED3D_TSS_CONSTANT
Definition: wined3d.h:592
@ WINED3D_TSS_BUMPENV_MAT01
Definition: wined3d.h:582
@ WINED3D_TSS_ALPHA_ARG0
Definition: wined3d.h:590
@ WINED3D_TSS_BUMPENV_LSCALE
Definition: wined3d.h:586
@ WINED3D_TSS_COLOR_ARG0
Definition: wined3d.h:589
@ WINED3D_TSS_COLOR_ARG1
Definition: wined3d.h:576
@ WINED3D_TSS_ALPHA_ARG1
Definition: wined3d.h:579
@ WINED3D_TSS_RESULT_ARG
Definition: wined3d.h:591
@ WINED3D_TSS_BUMPENV_MAT00
Definition: wined3d.h:581
@ WINED3D_TSS_TEXTURE_TRANSFORM_FLAGS
Definition: wined3d.h:588

◆ wined3d_texture_transform_flags

Enumerator
WINED3D_TTFF_DISABLE 
WINED3D_TTFF_COUNT1 
WINED3D_TTFF_COUNT2 
WINED3D_TTFF_COUNT3 
WINED3D_TTFF_COUNT4 
WINED3D_TTFF_PROJECTED 

Definition at line 597 of file wined3d.h.

598{
605};
@ WINED3D_TTFF_COUNT2
Definition: wined3d.h:601
@ WINED3D_TTFF_COUNT4
Definition: wined3d.h:603
@ WINED3D_TTFF_DISABLE
Definition: wined3d.h:599
@ WINED3D_TTFF_COUNT3
Definition: wined3d.h:602
@ WINED3D_TTFF_COUNT1
Definition: wined3d.h:600
@ WINED3D_TTFF_PROJECTED
Definition: wined3d.h:604

◆ wined3d_transform_state

Enumerator
WINED3D_TS_VIEW 
WINED3D_TS_PROJECTION 
WINED3D_TS_TEXTURE0 
WINED3D_TS_TEXTURE1 
WINED3D_TS_TEXTURE2 
WINED3D_TS_TEXTURE3 
WINED3D_TS_TEXTURE4 
WINED3D_TS_TEXTURE5 
WINED3D_TS_TEXTURE6 
WINED3D_TS_TEXTURE7 
WINED3D_TS_WORLD 
WINED3D_TS_WORLD1 
WINED3D_TS_WORLD2 
WINED3D_TS_WORLD3 

Definition at line 646 of file wined3d.h.

647{
648 WINED3D_TS_VIEW = 2,
658 WINED3D_TS_WORLD = 256, /* WINED3D_TS_WORLD_MATRIX(0) */
659 WINED3D_TS_WORLD1 = 257,
660 WINED3D_TS_WORLD2 = 258,
661 WINED3D_TS_WORLD3 = 259,
662};
@ WINED3D_TS_WORLD2
Definition: wined3d.h:660
@ WINED3D_TS_TEXTURE1
Definition: wined3d.h:651
@ WINED3D_TS_TEXTURE0
Definition: wined3d.h:650
@ WINED3D_TS_TEXTURE2
Definition: wined3d.h:652
@ WINED3D_TS_PROJECTION
Definition: wined3d.h:649
@ WINED3D_TS_VIEW
Definition: wined3d.h:648
@ WINED3D_TS_TEXTURE7
Definition: wined3d.h:657
@ WINED3D_TS_TEXTURE6
Definition: wined3d.h:656
@ WINED3D_TS_TEXTURE4
Definition: wined3d.h:654
@ WINED3D_TS_TEXTURE3
Definition: wined3d.h:653
@ WINED3D_TS_WORLD1
Definition: wined3d.h:659
@ WINED3D_TS_WORLD
Definition: wined3d.h:658
@ WINED3D_TS_WORLD3
Definition: wined3d.h:661
@ WINED3D_TS_TEXTURE5
Definition: wined3d.h:655

◆ wined3d_vertex_blend_flags

Enumerator
WINED3D_VBF_DISABLE 
WINED3D_VBF_1WEIGHTS 
WINED3D_VBF_2WEIGHTS 
WINED3D_VBF_3WEIGHTS 
WINED3D_VBF_TWEENING 
WINED3D_VBF_0WEIGHTS 

Definition at line 440 of file wined3d.h.

441{
448};
@ WINED3D_VBF_TWEENING
Definition: wined3d.h:446
@ WINED3D_VBF_1WEIGHTS
Definition: wined3d.h:443
@ WINED3D_VBF_DISABLE
Definition: wined3d.h:442
@ WINED3D_VBF_3WEIGHTS
Definition: wined3d.h:445
@ WINED3D_VBF_2WEIGHTS
Definition: wined3d.h:444
@ WINED3D_VBF_0WEIGHTS
Definition: wined3d.h:447

Function Documentation

◆ DEFINE_GUID()

DEFINE_GUID ( IID_IWineD3DDevice  ,
0xd56e2a4c  ,
0x5127  ,
0x8437  ,
0x65  ,
0x8a  ,
0x98  ,
0xc5  ,
0xbb  ,
0x78  ,
0x94  ,
0x98   
)

◆ wined3d_blend_state_create()

HRESULT __cdecl wined3d_blend_state_create ( struct wined3d_device device,
const struct wined3d_blend_state_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_blend_state **  state 
)

Definition at line 81 of file state.c.

84{
86
87 TRACE("device %p, desc %p, parent %p, parent_ops %p, state %p.\n",
89
90 if (!(object = heap_alloc_zero(sizeof(*object))))
91 return E_OUTOFMEMORY;
92
93 object->refcount = 1;
94 object->desc = *desc;
95 object->parent = parent;
96 object->parent_ops = parent_ops;
97 object->device = device;
98
99 TRACE("Created blend state %p.\n", object);
100 *state = object;
101
102 return WINED3D_OK;
103}
static int state
Definition: maze.c:121
#define E_OUTOFMEMORY
Definition: ddrawi.h:100
r parent
Definition: btrfs.c:3010
static const WCHAR desc[]
Definition: protectdata.c:36
#define TRACE(s)
Definition: solgame.cpp:4
Definition: devices.h:37
struct wined3d_device * device
const struct wined3d_parent_ops * parent_ops
#define WINED3D_OK
Definition: wined3d.h:37

◆ wined3d_blend_state_decref()

ULONG __cdecl wined3d_blend_state_decref ( struct wined3d_blend_state state)

Definition at line 58 of file state.c.

59{
60 ULONG refcount = InterlockedDecrement(&state->refcount);
61 struct wined3d_device *device = state->device;
62
63 TRACE("%p decreasing refcount to %u.\n", state, refcount);
64
65 if (!refcount)
66 {
67 state->parent_ops->wined3d_object_destroyed(state->parent);
69 }
70
71 return refcount;
72}
#define InterlockedDecrement
Definition: armddk.h:52
void wined3d_cs_destroy_object(struct wined3d_cs *cs, void(*callback)(void *object), void *object)
Definition: cs.c:1885
static void wined3d_blend_state_destroy_object(void *object)
Definition: state.c:53
uint32_t ULONG
Definition: typedefs.h:59

Referenced by wined3d_device_set_blend_state().

◆ wined3d_blend_state_get_parent()

void *__cdecl wined3d_blend_state_get_parent ( const struct wined3d_blend_state state)

Definition at line 74 of file state.c.

75{
76 TRACE("state %p.\n", state);
77
78 return state->parent;
79}

◆ wined3d_blend_state_incref()

ULONG __cdecl wined3d_blend_state_incref ( struct wined3d_blend_state state)

Definition at line 44 of file state.c.

45{
46 ULONG refcount = InterlockedIncrement(&state->refcount);
47
48 TRACE("%p increasing refcount to %u.\n", state, refcount);
49
50 return refcount;
51}
#define InterlockedIncrement
Definition: armddk.h:53

Referenced by wined3d_device_set_blend_state().

◆ wined3d_box_set()

static void wined3d_box_set ( struct wined3d_box box,
unsigned int  left,
unsigned int  top,
unsigned int  right,
unsigned int  bottom,
unsigned int  front,
unsigned int  back 
)
inlinestatic

Definition at line 2789 of file wined3d.h.

2791{
2792 box->left = left;
2793 box->top = top;
2794 box->right = right;
2795 box->bottom = bottom;
2796 box->front = front;
2797 box->back = back;
2798}
GLdouble GLdouble GLdouble GLdouble top
Definition: glext.h:10859
GLdouble GLdouble right
Definition: glext.h:10859
GLint left
Definition: glext.h:7726
GLint GLint bottom
Definition: glext.h:7726
static struct address_cache * front
Definition: rpcb_clnt.c:83
Definition: palette.c:468

Referenced by d3d8_surface_LockRect(), d3d8_texture_2d_AddDirtyRect(), d3d8_texture_cube_AddDirtyRect(), d3d9_device_UpdateSurface(), d3d9_surface_LockRect(), d3d9_texture_2d_AddDirtyRect(), d3d9_texture_cube_AddDirtyRect(), surface_lock(), wined3d_device_copy_resource(), wined3d_device_copy_sub_resource_region(), wined3d_device_update_sub_resource(), wined3d_device_update_texture(), and wined3d_resource_update_info().

◆ wined3d_buffer_create()

HRESULT __cdecl wined3d_buffer_create ( struct wined3d_device device,
const struct wined3d_buffer_desc desc,
const struct wined3d_sub_resource_data data,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_buffer **  buffer 
)

Definition at line 1436 of file buffer.c.

1439{
1440 struct wined3d_buffer *object;
1441 HRESULT hr;
1442
1443 TRACE("device %p, desc %p, data %p, parent %p, parent_ops %p, buffer %p.\n",
1444 device, desc, data, parent, parent_ops, buffer);
1445
1446 if (!(object = heap_alloc_zero(sizeof(*object))))
1447 return E_OUTOFMEMORY;
1448
1449 if (FAILED(hr = buffer_init(object, device, desc->byte_width, desc->usage, WINED3DFMT_UNKNOWN,
1450 desc->access, desc->bind_flags, data, parent, parent_ops)))
1451 {
1452 WARN("Failed to initialize buffer, hr %#x.\n", hr);
1453 heap_free(object);
1454 return hr;
1455 }
1456 object->desc = *desc;
1457
1458 TRACE("Created buffer %p.\n", object);
1459
1460 *buffer = object;
1461
1462 return WINED3D_OK;
1463}
static BOOL heap_free(void *mem)
Definition: appwiz.h:76
#define WARN(fmt,...)
Definition: debug.h:112
GLint GLenum GLsizei GLsizei GLsizei GLint GLsizei const GLvoid * data
Definition: gl.h:1950
GLuint buffer
Definition: glext.h:5915
#define FAILED(hr)
Definition: intsafe.h:51
#define buffer_init
Definition: intsym.h:261
HRESULT hr
Definition: shlfolder.c:183

Referenced by d3d8_device_prepare_index_buffer(), d3d8_device_prepare_vertex_buffer(), d3d9_device_prepare_index_buffer(), d3d9_device_prepare_vertex_buffer(), d3d_device_prepare_index_buffer(), d3d_device_prepare_vertex_buffer(), d3d_execute_buffer_SetExecuteData(), d3d_vertex_buffer_create_wined3d_buffer(), indexbuffer_init(), and vertexbuffer_init().

◆ wined3d_buffer_decref()

ULONG __cdecl wined3d_buffer_decref ( struct wined3d_buffer buffer)

Definition at line 791 of file buffer.c.

792{
793 ULONG refcount = InterlockedDecrement(&buffer->resource.ref);
794
795 TRACE("%p decreasing refcount to %u.\n", buffer, refcount);
796
797 if (!refcount)
798 {
799 buffer->resource.parent_ops->wined3d_object_destroyed(buffer->resource.parent);
800 resource_cleanup(&buffer->resource);
802 }
803
804 return refcount;
805}
static void wined3d_buffer_destroy_object(void *object)
Definition: buffer.c:773
void resource_cleanup(struct wined3d_resource *resource)
Definition: resource.c:237

Referenced by buffer_resource_decref(), d3d8_device_prepare_index_buffer(), d3d8_device_prepare_vertex_buffer(), d3d8_device_Release(), d3d8_device_Reset(), d3d8_indexbuffer_Release(), d3d8_vertexbuffer_Release(), d3d9_device_prepare_index_buffer(), d3d9_device_prepare_vertex_buffer(), d3d9_device_Release(), d3d9_device_reset(), d3d9_indexbuffer_Release(), d3d9_vertexbuffer_Release(), d3d_device_inner_Release(), d3d_device_prepare_index_buffer(), d3d_device_prepare_vertex_buffer(), d3d_execute_buffer_Release(), d3d_execute_buffer_SetExecuteData(), d3d_vertex_buffer7_Lock(), d3d_vertex_buffer7_Release(), d3d_vertex_buffer_create(), state_unbind_resources(), wined3d_device_set_constant_buffer(), wined3d_device_set_index_buffer(), wined3d_device_set_stream_output(), wined3d_device_set_stream_source(), and wined3d_stateblock_capture().

◆ wined3d_buffer_get_parent()

void *__cdecl wined3d_buffer_get_parent ( const struct wined3d_buffer buffer)

Definition at line 807 of file buffer.c.

808{
809 TRACE("buffer %p.\n", buffer);
810
811 return buffer->resource.parent;
812}

Referenced by d3d8_device_GetIndices(), d3d8_device_GetStreamSource(), d3d9_device_GetIndices(), d3d9_device_GetStreamSource(), and wined3d_rendertarget_view_get_sub_resource_parent().

◆ wined3d_buffer_get_resource()

◆ wined3d_buffer_incref()

◆ wined3d_calculate_format_pitch()

UINT __cdecl wined3d_calculate_format_pitch ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_format_id  format_id,
UINT  width 
)

Definition at line 5517 of file directx.c.

5519{
5520 const struct wined3d_gl_info *gl_info;
5521 unsigned int row_pitch, slice_pitch;
5522
5523 TRACE("wined3d %p, adapter_idx %u, format_id %s, width %u.\n",
5524 wined3d, adapter_idx, debug_d3dformat(format_id), width);
5525
5526 if (adapter_idx >= wined3d->adapter_count)
5527 return ~0u;
5528
5529 gl_info = &wined3d->adapters[adapter_idx].gl_info;
5531 1, width, 1, &row_pitch, &slice_pitch);
5532
5533 return row_pitch;
5534}
const struct wined3d_format * wined3d_get_format(const struct wined3d_gl_info *gl_info, enum wined3d_format_id format_id, unsigned int resource_usage)
Definition: utils.c:3831
const char * debug_d3dformat(enum wined3d_format_id format_id)
Definition: utils.c:3980
void wined3d_format_calculate_pitch(const struct wined3d_format *format, unsigned int alignment, unsigned int width, unsigned int height, unsigned int *row_pitch, unsigned int *slice_pitch)
Definition: utils.c:3876
GLint GLint GLsizei width
Definition: gl.h:1546
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble * u
Definition: glfuncs.h:240
static UINT format_id
Definition: clipboard.c:1343
UINT adapter_count
struct wined3d_adapter adapters[1]

Referenced by ddraw7_GetAvailableVidMem(), and ddraw_surface_create().

◆ wined3d_check_depth_stencil_match()

HRESULT __cdecl wined3d_check_depth_stencil_match ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
enum wined3d_format_id  adapter_format_id,
enum wined3d_format_id  render_target_format_id,
enum wined3d_format_id  depth_stencil_format_id 
)

Definition at line 5091 of file directx.c.

5094{
5095 const struct wined3d_format *rt_format;
5096 const struct wined3d_format *ds_format;
5097 const struct wined3d_adapter *adapter;
5098
5099 TRACE("wined3d %p, adapter_idx %u, device_type %s,\n"
5100 "adapter_format %s, render_target_format %s, depth_stencil_format %s.\n",
5101 wined3d, adapter_idx, debug_d3ddevicetype(device_type), debug_d3dformat(adapter_format_id),
5102 debug_d3dformat(render_target_format_id), debug_d3dformat(depth_stencil_format_id));
5103
5104 if (adapter_idx >= wined3d->adapter_count)
5106
5107 adapter = &wined3d->adapters[adapter_idx];
5108 rt_format = wined3d_get_format(&adapter->gl_info, render_target_format_id, WINED3DUSAGE_RENDERTARGET);
5109 ds_format = wined3d_get_format(&adapter->gl_info, depth_stencil_format_id, WINED3DUSAGE_DEPTHSTENCIL);
5111 {
5114 {
5115 TRACE("Formats match.\n");
5116 return WINED3D_OK;
5117 }
5118 }
5119 else
5120 {
5121 const struct wined3d_pixel_format *cfgs;
5122 unsigned int cfg_count;
5123 unsigned int i;
5124
5125 cfgs = adapter->cfgs;
5126 cfg_count = adapter->cfg_count;
5127 for (i = 0; i < cfg_count; ++i)
5128 {
5129 if (wined3d_check_pixel_format_color(&adapter->gl_info, &cfgs[i], rt_format)
5130 && wined3d_check_pixel_format_depth(&adapter->gl_info, &cfgs[i], ds_format))
5131 {
5132 TRACE("Formats match.\n");
5133 return WINED3D_OK;
5134 }
5135 }
5136 }
5137
5138 TRACE("Unsupported format pair: %s and %s.\n",
5139 debug_d3dformat(render_target_format_id),
5140 debug_d3dformat(depth_stencil_format_id));
5141
5143}
device_type
const char * debug_d3ddevicetype(enum wined3d_device_type device_type)
Definition: utils.c:4153
return adapter
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint i
Definition: glfuncs.h:248
unsigned int flags[WINED3D_GL_RES_TYPE_COUNT]
static BOOL wined3d_check_pixel_format_depth(const struct wined3d_gl_info *gl_info, const struct wined3d_pixel_format *cfg, const struct wined3d_format *format)
Definition: directx.c:5061
static BOOL wined3d_check_pixel_format_color(const struct wined3d_gl_info *gl_info, const struct wined3d_pixel_format *cfg, const struct wined3d_format *format)
Definition: directx.c:5041
#define WINED3DERR_NOTAVAILABLE
Definition: wined3d.h:46
#define WINED3DUSAGE_RENDERTARGET
Definition: wined3d.h:899
#define WINED3DERR_INVALIDCALL
Definition: wined3d.h:48
#define WINED3DUSAGE_DEPTHSTENCIL
Definition: wined3d.h:900
#define WINED3DFMT_FLAG_RENDERTARGET
@ WINED3D_GL_RES_TYPE_TEX_2D
#define WINED3DFMT_FLAG_STENCIL
#define ORM_FBO
#define WINED3DFMT_FLAG_DEPTH

Referenced by d3d8_CheckDepthStencilMatch(), and d3d9_CheckDepthStencilMatch().

◆ wined3d_check_device_format()

HRESULT __cdecl wined3d_check_device_format ( const struct wined3d wined3d,
UINT  adaper_idx,
enum wined3d_device_type  device_type,
enum wined3d_format_id  adapter_format_id,
DWORD  usage,
enum wined3d_resource_type  resource_type,
enum wined3d_format_id  check_format_id 
)

Definition at line 5334 of file directx.c.

5337{
5338 const struct wined3d_adapter *adapter = &wined3d->adapters[adapter_idx];
5339 const struct wined3d_gl_info *gl_info = &adapter->gl_info;
5340 const struct wined3d_format *adapter_format, *format;
5341 enum wined3d_gl_resource_type gl_type, gl_type_end;
5342 BOOL mipmap_gen_supported = TRUE;
5343 DWORD format_flags = 0;
5344 DWORD allowed_usage;
5345
5346 TRACE("wined3d %p, adapter_idx %u, device_type %s, adapter_format %s, usage %s, %s, "
5347 "resource_type %s, check_format %s.\n",
5348 wined3d, adapter_idx, debug_d3ddevicetype(device_type), debug_d3dformat(adapter_format_id),
5350 debug_d3dformat(check_format_id));
5351
5352 if (adapter_idx >= wined3d->adapter_count)
5354
5355 adapter_format = wined3d_get_format(gl_info, adapter_format_id, WINED3DUSAGE_RENDERTARGET);
5356 format = wined3d_get_format(gl_info, check_format_id, usage);
5357
5358 switch (resource_type)
5359 {
5360 case WINED3D_RTYPE_NONE:
5361 allowed_usage = WINED3DUSAGE_DEPTHSTENCIL
5364 gl_type_end = WINED3D_GL_RES_TYPE_TEX_3D;
5365 break;
5366
5368 allowed_usage = WINED3DUSAGE_DYNAMIC
5377 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_TEX_1D;
5378 break;
5379
5381 allowed_usage = WINED3DUSAGE_DEPTHSTENCIL
5385 allowed_usage |= WINED3DUSAGE_QUERY_SRGBWRITE;
5386 if (!(usage & WINED3DUSAGE_TEXTURE))
5387 {
5389 {
5390 TRACE("[FAILED] - Not supported for plain surfaces.\n");
5392 }
5393
5394 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_RB;
5395 break;
5396 }
5397 allowed_usage |= WINED3DUSAGE_DYNAMIC
5408 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_TEX_2D;
5410 {
5412 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_TEX_CUBE;
5413 }
5414 else if ((usage & WINED3DUSAGE_DEPTHSTENCIL)
5416 && !gl_info->supported[ARB_SHADOW])
5417 {
5418 TRACE("[FAILED] - No shadow sampler support.\n");
5420 }
5421 break;
5422
5424 allowed_usage = WINED3DUSAGE_DYNAMIC
5433 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_TEX_3D;
5434 break;
5435
5437 allowed_usage = WINED3DUSAGE_DYNAMIC
5439 gl_type = gl_type_end = WINED3D_GL_RES_TYPE_BUFFER;
5440 break;
5441
5442 default:
5443 FIXME("Unhandled resource type %s.\n", debug_d3dresourcetype(resource_type));
5445 }
5446
5447 if ((usage & allowed_usage) != usage)
5448 {
5449 TRACE("Requested usage %#x, but resource type %s only allows %#x.\n",
5450 usage, debug_d3dresourcetype(resource_type), allowed_usage);
5452 }
5453
5455 format_flags |= WINED3DFMT_FLAG_TEXTURE;
5457 format_flags |= WINED3DFMT_FLAG_FILTERING;
5461 format_flags |= WINED3DFMT_FLAG_SRGB_READ;
5463 format_flags |= WINED3DFMT_FLAG_SRGB_WRITE;
5465 format_flags |= WINED3DFMT_FLAG_VTF;
5467 format_flags |= WINED3DFMT_FLAG_BUMPMAP;
5468
5469 if ((format_flags & WINED3DFMT_FLAG_TEXTURE) && (wined3d->flags & WINED3D_NO3D))
5470 {
5471 TRACE("Requested texturing support, but wined3d was created with WINED3D_NO3D.\n");
5473 }
5474
5475 for (; gl_type <= gl_type_end; ++gl_type)
5476 {
5477 if ((format->flags[gl_type] & format_flags) != format_flags)
5478 {
5479 TRACE("Requested format flags %#x, but format %s only has %#x.\n",
5480 format_flags, debug_d3dformat(check_format_id), format->flags[gl_type]);
5482 }
5483
5485 && !CheckRenderTargetCapability(adapter, adapter_format, format, gl_type))
5486 {
5487 TRACE("Requested WINED3DUSAGE_RENDERTARGET, but format %s is not supported for render targets.\n",
5488 debug_d3dformat(check_format_id));
5490 }
5491
5492 /* 3D depth / stencil textures are never supported. */
5494 continue;
5495
5497 && !CheckDepthStencilCapability(adapter, adapter_format, format, gl_type))
5498 {
5499 TRACE("Requested WINED3DUSAGE_DEPTHSTENCIL, but format %s is not supported for depth / stencil buffers.\n",
5500 debug_d3dformat(check_format_id));
5502 }
5503
5504 if (!(format->flags[gl_type] & WINED3DFMT_FLAG_GEN_MIPMAP))
5505 mipmap_gen_supported = FALSE;
5506 }
5507
5508 if ((usage & WINED3DUSAGE_QUERY_GENMIPMAP) && !mipmap_gen_supported)
5509 {
5510 TRACE("No WINED3DUSAGE_AUTOGENMIPMAP support, returning WINED3DOK_NOAUTOGEN.\n");
5511 return WINED3DOK_NOMIPGEN;
5512 }
5513
5514 return WINED3D_OK;
5515}
#define FIXME(fmt,...)
Definition: debug.h:111
#define TRUE
Definition: types.h:120
#define FALSE
Definition: types.h:117
const char * debug_d3dresourcetype(enum wined3d_resource_type resource_type)
Definition: utils.c:4329
const char * debug_d3dusage(DWORD usage)
Definition: utils.c:4217
const char * debug_d3dusagequery(DWORD usage)
Definition: utils.c:4249
unsigned int BOOL
Definition: ntddk_ex.h:94
GLint GLint GLsizei GLsizei GLsizei GLint GLenum format
Definition: gl.h:1546
GLsizeiptr const GLvoid GLenum usage
Definition: glext.h:5919
BOOL supported[WINED3D_GL_EXT_COUNT]
static BOOL wined3d_check_surface_capability(const struct wined3d_format *format, BOOL no3d)
Definition: directx.c:5274
static BOOL CheckRenderTargetCapability(const struct wined3d_adapter *adapter, const struct wined3d_format *adapter_format, const struct wined3d_format *check_format, enum wined3d_gl_resource_type gl_type)
Definition: directx.c:5233
static BOOL CheckDepthStencilCapability(const struct wined3d_adapter *adapter, const struct wined3d_format *display_format, const struct wined3d_format *ds_format, enum wined3d_gl_resource_type gl_type)
Definition: directx.c:5190
#define WINED3DUSAGE_QUERY_LEGACYBUMPMAP
Definition: wined3d.h:924
#define WINED3D_NO3D
Definition: wined3d.h:1316
#define WINED3DUSAGE_LEGACY_CUBEMAP
Definition: wined3d.h:917
#define WINED3DUSAGE_QUERY_SRGBREAD
Definition: wined3d.h:927
#define WINED3DUSAGE_QUERY_FILTER
Definition: wined3d.h:925
#define WINED3DUSAGE_QUERY_WRAPANDMIP
Definition: wined3d.h:930
#define WINED3DUSAGE_QUERY_POSTPIXELSHADER_BLENDING
Definition: wined3d.h:926
#define WINED3DUSAGE_QUERY_VERTEXTEXTURE
Definition: wined3d.h:929
#define WINED3DUSAGE_QUERY_GENMIPMAP
Definition: wined3d.h:923
#define WINED3DUSAGE_DYNAMIC
Definition: wined3d.h:907
#define WINED3DUSAGE_QUERY_SRGBWRITE
Definition: wined3d.h:928
#define WINED3DUSAGE_TEXTURE
Definition: wined3d.h:918
#define WINED3DOK_NOMIPGEN
Definition: wined3d.h:41
#define WINED3DUSAGE_SOFTWAREPROCESSING
Definition: wined3d.h:902
@ ARB_SHADOW
Definition: wined3d_gl.h:103
#define WINED3DFMT_FLAG_BUMPMAP
#define WINED3DFMT_FLAG_SHADOW
#define WINED3DFMT_FLAG_SRGB_WRITE
#define WINED3DFMT_FLAG_VTF
#define WINED3DFMT_FLAG_SRGB_READ
wined3d_gl_resource_type
@ WINED3D_GL_RES_TYPE_TEX_3D
@ WINED3D_GL_RES_TYPE_TEX_CUBE
@ WINED3D_GL_RES_TYPE_BUFFER
@ WINED3D_GL_RES_TYPE_RB
@ WINED3D_GL_RES_TYPE_TEX_1D
#define WINED3DFMT_FLAG_TEXTURE
#define WINED3DFMT_FLAG_FILTERING
#define WINED3DFMT_FLAG_POSTPIXELSHADER_BLENDING
#define WINED3DFMT_FLAG_GEN_MIPMAP

Referenced by d3d7_EnumZBufferFormats(), d3d8_CheckDeviceFormat(), d3d9_CheckDeviceFormat(), d3d_device2_EnumTextureFormats(), d3d_device7_EnumTextureFormats(), ddraw7_GetFourCCCodes(), ddraw_surface_create(), and wined3d_check_device_type().

◆ wined3d_check_device_format_conversion()

HRESULT __cdecl wined3d_check_device_format_conversion ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
enum wined3d_format_id  source_format_id,
enum wined3d_format_id  target_format_id 
)

Definition at line 5536 of file directx.c.

5538{
5539 FIXME("wined3d %p, adapter_idx %u, device_type %s, src_format %s, dst_format %s stub!\n",
5540 wined3d, adapter_idx, debug_d3ddevicetype(device_type), debug_d3dformat(src_format),
5542
5543 return WINED3D_OK;
5544}
static const char * dst_format
Definition: dib.c:1133

Referenced by d3d9_CheckDeviceFormatConversion(), and wined3d_check_device_type().

◆ wined3d_check_device_multisample_type()

HRESULT __cdecl wined3d_check_device_multisample_type ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
enum wined3d_format_id  surface_format_id,
BOOL  windowed,
enum wined3d_multisample_type  multisample_type,
DWORD quality_levels 
)

Definition at line 5145 of file directx.c.

5148{
5149 const struct wined3d_gl_info *gl_info = &wined3d->adapters[adapter_idx].gl_info;
5150 const struct wined3d_format *format = wined3d_get_format(gl_info, surface_format_id, 0);
5152
5153 TRACE("wined3d %p, adapter_idx %u, device_type %s, surface_format %s, "
5154 "windowed %#x, multisample_type %#x, quality_levels %p.\n",
5155 wined3d, adapter_idx, debug_d3ddevicetype(device_type), debug_d3dformat(surface_format_id),
5156 windowed, multisample_type, quality_levels);
5157
5158 if (adapter_idx >= wined3d->adapter_count)
5160 if (surface_format_id == WINED3DFMT_UNKNOWN)
5162 if (multisample_type < WINED3D_MULTISAMPLE_NONE)
5164 if (multisample_type > WINED3D_MULTISAMPLE_16_SAMPLES)
5165 {
5166 FIXME("multisample_type %u not handled yet.\n", multisample_type);
5168 }
5169
5170 if (multisample_type && !(format->multisample_types & 1u << (multisample_type - 1)))
5172
5173 if (SUCCEEDED(hr) || (multisample_type == WINED3D_MULTISAMPLE_NON_MASKABLE && format->multisample_types))
5174 {
5175 if (quality_levels)
5176 {
5177 if (multisample_type == WINED3D_MULTISAMPLE_NON_MASKABLE)
5178 *quality_levels = wined3d_popcount(format->multisample_types);
5179 else
5180 *quality_levels = 1;
5181 }
5182 return WINED3D_OK;
5183 }
5184
5185 TRACE("Returning not supported.\n");
5186 return hr;
5187}
#define SUCCEEDED(hr)
Definition: intsafe.h:50
static unsigned int wined3d_popcount(unsigned int x)

Referenced by d3d8_CheckDeviceMultiSampleType(), and d3d9_CheckDeviceMultiSampleType().

◆ wined3d_check_device_type()

HRESULT __cdecl wined3d_check_device_type ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
enum wined3d_format_id  display_format_id,
enum wined3d_format_id  backbuffer_format_id,
BOOL  windowed 
)

Definition at line 5546 of file directx.c.

5549{
5550 BOOL present_conversion = wined3d->flags & WINED3D_PRESENT_CONVERSION;
5551
5552 TRACE("wined3d %p, adapter_idx %u, device_type %s, display_format %s, backbuffer_format %s, windowed %#x.\n",
5553 wined3d, adapter_idx, debug_d3ddevicetype(device_type), debug_d3dformat(display_format),
5554 debug_d3dformat(backbuffer_format), windowed);
5555
5556 if (adapter_idx >= wined3d->adapter_count)
5558
5559 /* The task of this function is to check whether a certain display / backbuffer format
5560 * combination is available on the given adapter. In fullscreen mode microsoft specified
5561 * that the display format shouldn't provide alpha and that ignoring alpha the backbuffer
5562 * and display format should match exactly.
5563 * In windowed mode format conversion can occur and this depends on the driver. */
5564
5565 /* There are only 4 display formats. */
5566 if (!(display_format == WINED3DFMT_B5G6R5_UNORM
5567 || display_format == WINED3DFMT_B5G5R5X1_UNORM
5568 || display_format == WINED3DFMT_B8G8R8X8_UNORM
5569 || display_format == WINED3DFMT_B10G10R10A2_UNORM))
5570 {
5571 TRACE("Format %s is not supported as display format.\n", debug_d3dformat(display_format));
5573 }
5574
5575 if (!windowed)
5576 {
5577 /* If the requested display format is not available, don't continue. */
5578 if (!wined3d_get_adapter_mode_count(wined3d, adapter_idx,
5579 display_format, WINED3D_SCANLINE_ORDERING_UNKNOWN))
5580 {
5581 TRACE("No available modes for display format %s.\n", debug_d3dformat(display_format));
5583 }
5584
5585 present_conversion = FALSE;
5586 }
5587 else if (display_format == WINED3DFMT_B10G10R10A2_UNORM)
5588 {
5589 /* WINED3DFMT_B10G10R10A2_UNORM is only allowed in fullscreen mode. */
5590 TRACE("Unsupported format combination %s / %s in windowed mode.\n",
5591 debug_d3dformat(display_format), debug_d3dformat(backbuffer_format));
5593 }
5594
5595 if (present_conversion)
5596 {
5597 /* Use the display format as back buffer format if the latter is
5598 * WINED3DFMT_UNKNOWN. */
5599 if (backbuffer_format == WINED3DFMT_UNKNOWN)
5600 backbuffer_format = display_format;
5601
5603 device_type, backbuffer_format, display_format)))
5604 {
5605 TRACE("Format conversion from %s to %s not supported.\n",
5606 debug_d3dformat(backbuffer_format), debug_d3dformat(display_format));
5608 }
5609 }
5610 else
5611 {
5612 /* When format conversion from the back buffer format to the display
5613 * format is not allowed, only a limited number of combinations are
5614 * valid. */
5615
5616 if (display_format == WINED3DFMT_B5G6R5_UNORM && backbuffer_format != WINED3DFMT_B5G6R5_UNORM)
5617 {
5618 TRACE("Unsupported format combination %s / %s.\n",
5619 debug_d3dformat(display_format), debug_d3dformat(backbuffer_format));
5621 }
5622
5623 if (display_format == WINED3DFMT_B5G5R5X1_UNORM
5624 && !(backbuffer_format == WINED3DFMT_B5G5R5X1_UNORM || backbuffer_format == WINED3DFMT_B5G5R5A1_UNORM))
5625 {
5626 TRACE("Unsupported format combination %s / %s.\n",
5627 debug_d3dformat(display_format), debug_d3dformat(backbuffer_format));
5629 }
5630
5631 if (display_format == WINED3DFMT_B8G8R8X8_UNORM
5632 && !(backbuffer_format == WINED3DFMT_B8G8R8X8_UNORM || backbuffer_format == WINED3DFMT_B8G8R8A8_UNORM))
5633 {
5634 TRACE("Unsupported format combination %s / %s.\n",
5635 debug_d3dformat(display_format), debug_d3dformat(backbuffer_format));
5637 }
5638
5639 if (display_format == WINED3DFMT_B10G10R10A2_UNORM
5640 && backbuffer_format != WINED3DFMT_B10G10R10A2_UNORM)
5641 {
5642 TRACE("Unsupported format combination %s / %s.\n",
5643 debug_d3dformat(display_format), debug_d3dformat(backbuffer_format));
5645 }
5646 }
5647
5648 /* Validate that the back buffer format is usable for render targets. */
5649 if (FAILED(wined3d_check_device_format(wined3d, adapter_idx, device_type, display_format,
5651 {
5652 TRACE("Format %s not allowed for render targets.\n", debug_d3dformat(backbuffer_format));
5654 }
5655
5656 return WINED3D_OK;
5657}
HRESULT CDECL wined3d_check_device_format_conversion(const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id src_format, enum wined3d_format_id dst_format)
Definition: directx.c:5536
HRESULT CDECL wined3d_check_device_format(const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, enum wined3d_format_id adapter_format_id, DWORD usage, enum wined3d_resource_type resource_type, enum wined3d_format_id check_format_id)
Definition: directx.c:5334
UINT CDECL wined3d_get_adapter_mode_count(const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_format_id format_id, enum wined3d_scanline_ordering scanline_ordering)
Definition: directx.c:4536
#define WINED3D_PRESENT_CONVERSION
Definition: wined3d.h:1318

Referenced by d3d8_CheckDeviceType(), and d3d9_CheckDeviceType().

◆ wined3d_create()

struct wined3d *__cdecl wined3d_create ( DWORD  flags)

Definition at line 97 of file wined3d_main.c.

98{
99 struct wined3d *object;
100 HRESULT hr;
101
102 if (!(object = heap_alloc_zero(FIELD_OFFSET(struct wined3d, adapters[1]))))
103 {
104 ERR("Failed to allocate wined3d object memory.\n");
105 return NULL;
106 }
107
110
111 hr = wined3d_init(object, flags);
112 if (FAILED(hr))
113 {
114 WARN("Failed to initialize wined3d object, hr %#x.\n", hr);
115 heap_free(object);
116 return NULL;
117 }
118
119 TRACE("Created wined3d object %p.\n", object);
120
121 return object;
122}
#define ERR(fmt,...)
Definition: debug.h:110
#define NULL
Definition: types.h:112
GLbitfield flags
Definition: glext.h:7161
#define FIELD_OFFSET(t, f)
Definition: typedefs.h:255
HRESULT wined3d_init(struct wined3d *wined3d, DWORD flags)
Definition: directx.c:6820

Referenced by d3d8_init(), d3d9_init(), ddraw_init(), and DirectDrawEnumerateExA().

◆ wined3d_decref()

ULONG __cdecl wined3d_decref ( struct wined3d wined3d)

Definition at line 465 of file directx.c.

466{
468
469 TRACE("%p decreasing refcount to %u.\n", wined3d, refcount);
470
471 if (!refcount)
472 {
473 unsigned int i;
474
475 for (i = 0; i < wined3d->adapter_count; ++i)
476 {
478 }
480 }
481
482 return refcount;
483}
static void wined3d_adapter_cleanup(struct wined3d_adapter *adapter)
Definition: directx.c:450

Referenced by d3d8_Release(), d3d9_Release(), ddraw_destroy(), ddraw_init(), device_init(), DirectDrawEnumerateExA(), and wined3d_device_decref().

◆ wined3d_device_acquire_focus_window()

HRESULT __cdecl wined3d_device_acquire_focus_window ( struct wined3d_device device,
HWND  window 
)

Definition at line 938 of file device.c.

939{
940 TRACE("device %p, window %p.\n", device, window);
941
943 {
944 ERR("Failed to register window %p.\n", window);
945 return E_FAIL;
946 }
947
948 InterlockedExchangePointer((void **)&device->focus_window, window);
949 SetWindowPos(window, 0, 0, 0, 0, 0, SWP_NOSIZE | SWP_NOMOVE);
950
951 return WINED3D_OK;
952}
#define E_FAIL
Definition: ddrawi.h:102
#define InterlockedExchangePointer(Target, Value)
Definition: dshow.h:45
static IHTMLWindow2 * window
Definition: events.c:77
BOOL wined3d_register_window(HWND window, struct wined3d_device *device)
Definition: wined3d_main.c:432
BOOL WINAPI SetWindowPos(_In_ HWND, _In_opt_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ UINT)
#define SWP_NOMOVE
Definition: winuser.h:1244
#define SWP_NOSIZE
Definition: winuser.h:1245

Referenced by ddraw_set_cooperative_level(), device_init(), and wined3d_swapchain_set_fullscreen().

◆ wined3d_device_begin_scene()

HRESULT __cdecl wined3d_device_begin_scene ( struct wined3d_device device)

Definition at line 3602 of file device.c.

3603{
3604 /* At the moment we have no need for any functionality at the beginning
3605 * of a scene. */
3606 TRACE("device %p.\n", device);
3607
3608 if (device->inScene)
3609 {
3610 WARN("Already in scene, returning WINED3DERR_INVALIDCALL.\n");
3612 }
3613 device->inScene = TRUE;
3614 return WINED3D_OK;
3615}

Referenced by d3d8_device_BeginScene(), d3d9_device_BeginScene(), and d3d_device7_BeginScene().

◆ wined3d_device_begin_stateblock()

HRESULT __cdecl wined3d_device_begin_stateblock ( struct wined3d_device device)

Definition at line 3555 of file device.c.

3556{
3557 struct wined3d_stateblock *stateblock;
3558 HRESULT hr;
3559
3560 TRACE("device %p.\n", device);
3561
3562 if (device->recording)
3564
3566 if (FAILED(hr))
3567 return hr;
3568
3569 device->recording = stateblock;
3570 device->update_state = &stateblock->state;
3571
3572 TRACE("Recording stateblock %p.\n", stateblock);
3573
3574 return WINED3D_OK;
3575}
struct wined3d_state state
HRESULT CDECL wined3d_stateblock_create(struct wined3d_device *device, enum wined3d_stateblock_type type, struct wined3d_stateblock **stateblock)
Definition: stateblock.c:1372

Referenced by d3d8_device_BeginStateBlock(), d3d9_device_BeginStateBlock(), and d3d_device7_BeginStateBlock().

◆ wined3d_device_clear()

HRESULT __cdecl wined3d_device_clear ( struct wined3d_device device,
DWORD  rect_count,
const RECT rects,
DWORD  flags,
const struct wined3d_color color,
float  z,
DWORD  stencil 
)

Definition at line 3633 of file device.c.

3635{
3636 TRACE("device %p, rect_count %u, rects %p, flags %#x, color %s, depth %.8e, stencil %u.\n",
3637 device, rect_count, rects, flags, debug_color(color), depth, stencil);
3638
3639 if (!rect_count && rects)
3640 {
3641 WARN("Rects is %p, but rect_count is 0, ignoring clear\n", rects);
3642 return WINED3D_OK;
3643 }
3644
3646 {
3647 struct wined3d_rendertarget_view *ds = device->fb.depth_stencil;
3648 if (!ds)
3649 {
3650 WARN("Clearing depth and/or stencil without a depth stencil buffer attached, returning WINED3DERR_INVALIDCALL\n");
3651 /* TODO: What about depth stencil buffers without stencil bits? */
3653 }
3654 else if (flags & WINED3DCLEAR_TARGET)
3655 {
3656 if (ds->width < device->fb.render_targets[0]->width
3657 || ds->height < device->fb.render_targets[0]->height)
3658 {
3659 WARN("Silently ignoring depth and target clear with mismatching sizes\n");
3660 return WINED3D_OK;
3661 }
3662 }
3663 }
3664
3665 wined3d_cs_emit_clear(device->cs, rect_count, rects, flags, color, depth, stencil);
3666
3667 return WINED3D_OK;
3668}
void wined3d_cs_emit_clear(struct wined3d_cs *cs, DWORD rect_count, const RECT *rects, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil)
Definition: cs.c:536
const char * debug_color(const struct wined3d_color *color)
Definition: utils.c:3948
GLint GLint GLsizei GLsizei GLsizei depth
Definition: gl.h:1546
GLuint color
Definition: glext.h:6243
GLint GLfloat GLint stencil
Definition: glext.h:6260
#define ds
Definition: i386-dis.c:443
#define WINED3DCLEAR_TARGET
Definition: wined3d.h:997
#define WINED3DCLEAR_STENCIL
Definition: wined3d.h:999
#define WINED3DCLEAR_ZBUFFER
Definition: wined3d.h:998

Referenced by d3d8_device_Clear(), d3d9_device_Clear(), d3d_device7_Clear(), and wined3d_device_init_3d().

◆ wined3d_device_clear_rendertarget_view()

HRESULT __cdecl wined3d_device_clear_rendertarget_view ( struct wined3d_device device,
struct wined3d_rendertarget_view view,
const RECT rect,
DWORD  flags,
const struct wined3d_color color,
float  depth,
DWORD  stencil 
)

Definition at line 4392 of file device.c.

4395{
4396 struct wined3d_resource *resource;
4397 RECT r;
4398
4399 TRACE("device %p, view %p, rect %s, flags %#x, color %s, depth %.8e, stencil %u.\n",
4401
4402 if (!flags)
4403 return WINED3D_OK;
4404
4405 resource = view->resource;
4407 {
4408 FIXME("Not implemented for %s resources.\n", debug_d3dresourcetype(resource->type));
4410 }
4411
4412 if (view->layer_count > 1)
4413 {
4414 FIXME("Layered clears not implemented.\n");
4416 }
4417
4418 if (!rect)
4419 {
4420 SetRect(&r, 0, 0, view->width, view->height);
4421 rect = &r;
4422 }
4423 else
4424 {
4425 struct wined3d_box b = {rect->left, rect->top, rect->right, rect->bottom, 0, 1};
4427 HRESULT hr;
4428
4430 view->sub_resource_idx % texture->level_count, &b)))
4431 return hr;
4432 }
4433
4435
4436 return WINED3D_OK;
4437}
static const char * wine_dbgstr_rect(const RECT *prc)
Definition: atltest.h:160
void wined3d_cs_emit_clear_rendertarget_view(struct wined3d_cs *cs, struct wined3d_rendertarget_view *view, const RECT *rect, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil)
Definition: cs.c:574
HRESULT wined3d_texture_check_box_dimensions(const struct wined3d_texture *texture, unsigned int level, const struct wined3d_box *box)
Definition: texture.c:1128
GLdouble GLdouble GLdouble r
Definition: gl.h:2055
GLenum GLuint texture
Definition: glext.h:6295
GLboolean GLboolean GLboolean b
Definition: glext.h:6204
#define resource
Definition: kernel32.h:9
& rect
Definition: startmenu.cpp:1413
static struct wined3d_texture * texture_from_resource(struct wined3d_resource *resource)
BOOL WINAPI SetRect(_Out_ LPRECT, _In_ int, _In_ int, _In_ int, _In_ int)

Referenced by d3d9_device_ColorFill(), and ddraw_surface_blt().

◆ wined3d_device_clear_unordered_access_view_uint()

void __cdecl wined3d_device_clear_unordered_access_view_uint ( struct wined3d_device device,
struct wined3d_unordered_access_view view,
const struct wined3d_uvec4 clear_value 
)

Definition at line 4439 of file device.c.

4441{
4442 TRACE("device %p, view %p, clear_value %s.\n", device, view, debug_uvec4(clear_value));
4443
4445}
void wined3d_cs_emit_clear_unordered_access_view_uint(struct wined3d_cs *cs, struct wined3d_unordered_access_view *view, const struct wined3d_uvec4 *clear_value)
Definition: cs.c:2381
const char * debug_uvec4(const struct wined3d_uvec4 *v)
Definition: utils.c:3964

◆ wined3d_device_copy_resource()

void __cdecl wined3d_device_copy_resource ( struct wined3d_device device,
struct wined3d_resource dst_resource,
struct wined3d_resource src_resource 
)

Definition at line 4043 of file device.c.

4045{
4046 struct wined3d_texture *dst_texture, *src_texture;
4047 struct wined3d_box box;
4048 unsigned int i, j;
4049
4050 TRACE("device %p, dst_resource %p, src_resource %p.\n", device, dst_resource, src_resource);
4051
4052 if (src_resource == dst_resource)
4053 {
4054 WARN("Source and destination are the same resource.\n");
4055 return;
4056 }
4057
4058 if (src_resource->type != dst_resource->type)
4059 {
4060 WARN("Resource types (%s / %s) don't match.\n",
4061 debug_d3dresourcetype(dst_resource->type),
4062 debug_d3dresourcetype(src_resource->type));
4063 return;
4064 }
4065
4066 if (src_resource->width != dst_resource->width
4067 || src_resource->height != dst_resource->height
4068 || src_resource->depth != dst_resource->depth)
4069 {
4070 WARN("Resource dimensions (%ux%ux%u / %ux%ux%u) don't match.\n",
4071 dst_resource->width, dst_resource->height, dst_resource->depth,
4072 src_resource->width, src_resource->height, src_resource->depth);
4073 return;
4074 }
4075
4076 if (src_resource->format->typeless_id != dst_resource->format->typeless_id
4077 || (!src_resource->format->typeless_id && src_resource->format->id != dst_resource->format->id))
4078 {
4079 WARN("Resource formats %s and %s are incompatible.\n",
4080 debug_d3dformat(dst_resource->format->id),
4081 debug_d3dformat(src_resource->format->id));
4082 return;
4083 }
4084
4085 if (dst_resource->type == WINED3D_RTYPE_BUFFER)
4086 {
4087 wined3d_box_set(&box, 0, 0, src_resource->size, 1, 0, 1);
4088 wined3d_cs_emit_blt_sub_resource(device->cs, dst_resource, 0, &box,
4089 src_resource, 0, &box, WINED3D_BLT_RAW, NULL, WINED3D_TEXF_POINT);
4090 return;
4091 }
4092
4093 dst_texture = texture_from_resource(dst_resource);
4094 src_texture = texture_from_resource(src_resource);
4095
4096 if (src_texture->layer_count != dst_texture->layer_count
4097 || src_texture->level_count != dst_texture->level_count)
4098 {
4099 WARN("Subresource layouts (%ux%u / %ux%u) don't match.\n",
4100 dst_texture->layer_count, dst_texture->level_count,
4101 src_texture->layer_count, src_texture->level_count);
4102 return;
4103 }
4104
4105 for (i = 0; i < dst_texture->level_count; ++i)
4106 {
4107 wined3d_box_set(&box, 0, 0,
4108 wined3d_texture_get_level_width(dst_texture, i),
4109 wined3d_texture_get_level_height(dst_texture, i),
4110 0, wined3d_texture_get_level_depth(dst_texture, i));
4111 for (j = 0; j < dst_texture->layer_count; ++j)
4112 {
4113 unsigned int idx = j * dst_texture->level_count + i;
4114
4115 wined3d_cs_emit_blt_sub_resource(device->cs, dst_resource, idx, &box,
4116 src_resource, idx, &box, WINED3D_BLT_RAW, NULL, WINED3D_TEXF_POINT);
4117 }
4118 }
4119}
void wined3d_cs_emit_blt_sub_resource(struct wined3d_cs *cs, struct wined3d_resource *dst_resource, unsigned int dst_sub_resource_idx, const struct wined3d_box *dst_box, struct wined3d_resource *src_resource, unsigned int src_sub_resource_idx, const struct wined3d_box *src_box, DWORD flags, const struct wined3d_blt_fx *fx, enum wined3d_texture_filter_type filter)
Definition: cs.c:2172
unsigned int idx
Definition: utils.c:41
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint j
Definition: glfuncs.h:250
enum wined3d_resource_type type
const struct wined3d_format * format
static void wined3d_box_set(struct wined3d_box *box, unsigned int left, unsigned int top, unsigned int right, unsigned int bottom, unsigned int front, unsigned int back)
Definition: wined3d.h:2789
#define WINED3D_BLT_RAW
Definition: wined3d.h:1366
static unsigned int wined3d_texture_get_level_height(const struct wined3d_texture *texture, unsigned int level)
static unsigned int wined3d_texture_get_level_width(const struct wined3d_texture *texture, unsigned int level)
static unsigned int wined3d_texture_get_level_depth(const struct wined3d_texture *texture, unsigned int level)

◆ wined3d_device_copy_sub_resource_region()

HRESULT __cdecl wined3d_device_copy_sub_resource_region ( struct wined3d_device device,
struct wined3d_resource dst_resource,
unsigned int  dst_sub_resource_idx,
unsigned int  dst_x,
unsigned int  dst_y,
unsigned int  dst_z,
struct wined3d_resource src_resource,
unsigned int  src_sub_resource_idx,
const struct wined3d_box src_box 
)

Definition at line 4121 of file device.c.

4125{
4126 struct wined3d_box dst_box, b;
4127
4128 TRACE("device %p, dst_resource %p, dst_sub_resource_idx %u, dst_x %u, dst_y %u, dst_z %u, "
4129 "src_resource %p, src_sub_resource_idx %u, src_box %s.\n",
4130 device, dst_resource, dst_sub_resource_idx, dst_x, dst_y, dst_z,
4131 src_resource, src_sub_resource_idx, debug_box(src_box));
4132
4133 if (src_resource == dst_resource && src_sub_resource_idx == dst_sub_resource_idx)
4134 {
4135 WARN("Source and destination are the same sub-resource.\n");
4137 }
4138
4139 if (src_resource->type != dst_resource->type)
4140 {
4141 WARN("Resource types (%s / %s) don't match.\n",
4142 debug_d3dresourcetype(dst_resource->type),
4143 debug_d3dresourcetype(src_resource->type));
4145 }
4146
4147 if (src_resource->format->typeless_id != dst_resource->format->typeless_id
4148 || (!src_resource->format->typeless_id && src_resource->format->id != dst_resource->format->id))
4149 {
4150 WARN("Resource formats %s and %s are incompatible.\n",
4151 debug_d3dformat(dst_resource->format->id),
4152 debug_d3dformat(src_resource->format->id));
4154 }
4155
4156 if (dst_resource->type == WINED3D_RTYPE_BUFFER)
4157 {
4158 if (dst_sub_resource_idx)
4159 {
4160 WARN("Invalid dst_sub_resource_idx %u.\n", dst_sub_resource_idx);
4162 }
4163
4164 if (src_sub_resource_idx)
4165 {
4166 WARN("Invalid src_sub_resource_idx %u.\n", src_sub_resource_idx);
4168 }
4169
4170 if (!src_box)
4171 {
4172 unsigned int dst_w;
4173
4174 dst_w = dst_resource->size - dst_x;
4175 wined3d_box_set(&b, 0, 0, min(src_resource->size, dst_w), 1, 0, 1);
4176 src_box = &b;
4177 }
4178 else if ((src_box->left >= src_box->right
4179 || src_box->top >= src_box->bottom
4180 || src_box->front >= src_box->back))
4181 {
4182 WARN("Invalid box %s specified.\n", debug_box(src_box));
4184 }
4185
4186 if (src_box->right > src_resource->size || dst_x >= dst_resource->size
4187 || src_box->right - src_box->left > dst_resource->size - dst_x)
4188 {
4189 WARN("Invalid range specified, dst_offset %u, src_offset %u, size %u.\n",
4190 dst_x, src_box->left, src_box->right - src_box->left);
4192 }
4193
4194 wined3d_box_set(&dst_box, dst_x, 0, dst_x + (src_box->right - src_box->left), 1, 0, 1);
4195 }
4196 else if (dst_resource->type == WINED3D_RTYPE_TEXTURE_2D)
4197 {
4198 struct wined3d_texture *dst_texture = texture_from_resource(dst_resource);
4199 struct wined3d_texture *src_texture = texture_from_resource(src_resource);
4200 unsigned int src_level = src_sub_resource_idx % src_texture->level_count;
4201
4202 if (dst_sub_resource_idx >= dst_texture->level_count * dst_texture->layer_count)
4203 {
4204 WARN("Invalid destination sub-resource %u.\n", dst_sub_resource_idx);
4206 }
4207
4208 if (src_sub_resource_idx >= src_texture->level_count * src_texture->layer_count)
4209 {
4210 WARN("Invalid source sub-resource %u.\n", src_sub_resource_idx);
4212 }
4213
4214#if !defined(STAGING_CSMT)
4215 if (dst_texture->sub_resources[dst_sub_resource_idx].map_count)
4216 {
4217 WARN("Destination sub-resource %u is mapped.\n", dst_sub_resource_idx);
4219 }
4220
4221 if (src_texture->sub_resources[src_sub_resource_idx].map_count)
4222 {
4223 WARN("Source sub-resource %u is mapped.\n", src_sub_resource_idx);
4225#else /* STAGING_CSMT */
4226 if (dst_texture->sub_resources[dst_sub_resource_idx].map_count ||
4227 src_texture->sub_resources[src_sub_resource_idx].map_count)
4228 {
4229 struct wined3d_device *device = dst_texture->resource.device;
4230 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
4231 if (dst_texture->sub_resources[dst_sub_resource_idx].map_count ||
4232 src_texture->sub_resources[src_sub_resource_idx].map_count)
4233 {
4234 WARN("Destination or source sub-resource is mapped.\n");
4235 return WINEDDERR_SURFACEBUSY;
4236 }
4237#endif /* STAGING_CSMT */
4238 }
4239
4240 if (!src_box)
4241 {
4242 unsigned int src_w, src_h, dst_w, dst_h, dst_level;
4243
4244 src_w = wined3d_texture_get_level_width(src_texture, src_level);
4245 src_h = wined3d_texture_get_level_height(src_texture, src_level);
4246
4247 dst_level = dst_sub_resource_idx % dst_texture->level_count;
4248 dst_w = wined3d_texture_get_level_width(dst_texture, dst_level) - dst_x;
4249 dst_h = wined3d_texture_get_level_height(dst_texture, dst_level) - dst_y;
4250
4251 wined3d_box_set(&b, 0, 0, min(src_w, dst_w), min(src_h, dst_h), 0, 1);
4252 src_box = &b;
4253 }
4254 else if (FAILED(wined3d_texture_check_box_dimensions(src_texture, src_level, src_box)))
4255 {
4256 WARN("Invalid source box %s.\n", debug_box(src_box));
4258 }
4259
4260 wined3d_box_set(&dst_box, dst_x, dst_y, dst_x + (src_box->right - src_box->left),
4261 dst_y + (src_box->bottom - src_box->top), 0, 1);
4263 dst_sub_resource_idx % dst_texture->level_count, &dst_box)))
4264 {
4265 WARN("Invalid destination box %s.\n", debug_box(&dst_box));
4267 }
4268 }
4269 else
4270 {
4271 FIXME("Not implemented for %s resources.\n", debug_d3dresourcetype(dst_resource->type));
4273 }
4274
4275 wined3d_cs_emit_blt_sub_resource(device->cs, dst_resource, dst_sub_resource_idx, &dst_box,
4276 src_resource, src_sub_resource_idx, src_box, WINED3D_BLT_RAW, NULL, WINED3D_TEXF_POINT);
4277
4278 return WINED3D_OK;
4279}
const char * debug_box(const struct wined3d_box *box)
Definition: utils.c:3939
#define b
Definition: ke_i.h:79
#define min(a, b)
Definition: monoChain.cc:55
UINT left
Definition: wined3d.h:1839
UINT right
Definition: wined3d.h:1841
UINT back
Definition: wined3d.h:1844
UINT front
Definition: wined3d.h:1843
UINT bottom
Definition: wined3d.h:1842
UINT top
Definition: wined3d.h:1840
struct wined3d_resource resource
struct wined3d_texture::wined3d_texture_sub_resource sub_resources[1]
#define WINEDDERR_SURFACEBUSY
Definition: wined3d.h:51
@ WINED3D_CS_QUEUE_DEFAULT

Referenced by d3d9_device_UpdateSurface().

◆ wined3d_device_copy_uav_counter()

void __cdecl wined3d_device_copy_uav_counter ( struct wined3d_device device,
struct wined3d_buffer dst_buffer,
unsigned int  offset,
struct wined3d_unordered_access_view uav 
)

Definition at line 4028 of file device.c.

4030{
4031 TRACE("device %p, dst_buffer %p, offset %u, uav %p.\n",
4032 device, dst_buffer, offset, uav);
4033
4034 if (offset + sizeof(GLuint) > dst_buffer->resource.size)
4035 {
4036 WARN("Offset %u too large.\n", offset);
4037 return;
4038 }
4039
4040 wined3d_cs_emit_copy_uav_counter(device->cs, dst_buffer, offset, uav);
4041}
void wined3d_cs_emit_copy_uav_counter(struct wined3d_cs *cs, struct wined3d_buffer *dst_buffer, unsigned int offset, struct wined3d_unordered_access_view *uav)
Definition: cs.c:2410
unsigned int GLuint
Definition: gl.h:159
GLintptr offset
Definition: glext.h:5920
struct wined3d_resource resource

◆ wined3d_device_create()

HRESULT __cdecl wined3d_device_create ( struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
HWND  focus_window,
DWORD  behaviour_flags,
BYTE  surface_alignment,
struct wined3d_device_parent device_parent,
struct wined3d_device **  device 
)

Definition at line 6244 of file directx.c.

6247{
6248 struct wined3d_device *object;
6249 HRESULT hr;
6250
6251 TRACE("wined3d %p, adapter_idx %u, device_type %#x, focus_window %p, flags %#x, surface_alignment %u, device_parent %p, device %p.\n",
6253
6254 /* Validate the adapter number. If no adapters are available(no GL), ignore the adapter
6255 * number and create a device without a 3D adapter for 2D only operation. */
6256 if (wined3d->adapter_count && adapter_idx >= wined3d->adapter_count)
6258
6259 if (!(object = heap_alloc_zero(sizeof(*object))))
6260 return E_OUTOFMEMORY;
6261
6262 hr = device_init(object, wined3d, adapter_idx, device_type,
6264 if (FAILED(hr))
6265 {
6266 WARN("Failed to initialize device, hr %#x.\n", hr);
6267 heap_free(object);
6268 return hr;
6269 }
6270
6271 TRACE("Created device %p.\n", object);
6272 *device = object;
6273
6274 device_parent->ops->wined3d_device_created(device_parent, *device);
6275
6276 return WINED3D_OK;
6277}
HRESULT device_init(struct d3d8_device *device, struct d3d8 *parent, struct wined3d *wined3d, UINT adapter, D3DDEVTYPE device_type, HWND focus_window, DWORD flags, D3DPRESENT_PARAMETERS *parameters) DECLSPEC_HIDDEN
Definition: device.c:3279
struct wined3d_device_parent * device_parent
unsigned char surface_alignment

Referenced by ddraw_init(), and device_init().

◆ wined3d_device_decref()

ULONG __cdecl wined3d_device_decref ( struct wined3d_device device)

Definition at line 472 of file device.c.

473{
474 ULONG refcount = InterlockedDecrement(&device->ref);
475
476 TRACE("%p decreasing refcount to %u.\n", device, refcount);
477
478 if (!refcount)
479 {
480 UINT i;
481
483
484 if (device->recording && wined3d_stateblock_decref(device->recording))
485 ERR("Something's still holding the recording stateblock.\n");
486 device->recording = NULL;
487
488 state_cleanup(&device->state);
489
490 for (i = 0; i < ARRAY_SIZE(device->multistate_funcs); ++i)
491 {
492 heap_free(device->multistate_funcs[i]);
493 device->multistate_funcs[i] = NULL;
494 }
495
496 if (!list_empty(&device->resources))
497 {
499
500 ERR("Device released with resources still bound.\n");
501
503 {
504 ERR("Leftover resource %p with type %s (%#x).\n",
506 }
507 }
508
509 if (device->contexts)
510 ERR("Context array not freed!\n");
511 if (device->hardwareCursor)
512 DestroyCursor(device->hardwareCursor);
513 device->hardwareCursor = 0;
514
516
517 wined3d_decref(device->wined3d);
518 device->wined3d = NULL;
520 TRACE("Freed device %p.\n", device);
521 }
522
523 return refcount;
524}
#define ARRAY_SIZE(A)
Definition: main.h:33
static int list_empty(struct list_entry *head)
Definition: list.h:58
void wined3d_cs_destroy(struct wined3d_cs *cs)
Definition: cs.c:2885
static void device_leftover_sampler(struct wine_rb_entry *entry, void *context)
Definition: device.c:465
unsigned int UINT
Definition: ndis.h:50
#define LIST_FOR_EACH_ENTRY(elem, list, type, field)
Definition: list.h:198
static void wine_rb_destroy(struct wine_rb_tree *tree, wine_rb_traverse_func_t *callback, void *context)
Definition: rbtree.h:198
struct list resource_list_entry
ULONG CDECL wined3d_decref(struct wined3d *wined3d)
Definition: directx.c:465
void state_cleanup(struct wined3d_state *state)
Definition: stateblock.c:528
ULONG CDECL wined3d_stateblock_decref(struct wined3d_stateblock *stateblock)
Definition: stateblock.c:552
BOOL WINAPI DestroyCursor(_In_ HCURSOR)
Definition: cursoricon.c:2689

Referenced by d3d8_device_Release(), d3d9_device_Release(), d3d_device_inner_Release(), ddraw_destroy(), ddraw_surface_release_iface(), and device_init().

◆ wined3d_device_dispatch_compute()

void __cdecl wined3d_device_dispatch_compute ( struct wined3d_device device,
unsigned int  group_count_x,
unsigned int  group_count_y,
unsigned int  group_count_z 
)

Definition at line 3700 of file device.c.

3702{
3703 TRACE("device %p, group_count_x %u, group_count_y %u, group_count_z %u.\n",
3704 device, group_count_x, group_count_y, group_count_z);
3705
3706 wined3d_cs_emit_dispatch(device->cs, group_count_x, group_count_y, group_count_z);
3707}
void wined3d_cs_emit_dispatch(struct wined3d_cs *cs, unsigned int group_count_x, unsigned int group_count_y, unsigned int group_count_z)
Definition: cs.c:738

◆ wined3d_device_dispatch_compute_indirect()

void __cdecl wined3d_device_dispatch_compute_indirect ( struct wined3d_device device,
struct wined3d_buffer buffer,
unsigned int  offset 
)

Definition at line 3709 of file device.c.

3711{
3712 TRACE("device %p, buffer %p, offset %u.\n", device, buffer, offset);
3713
3715}
void wined3d_cs_emit_dispatch_indirect(struct wined3d_cs *cs, struct wined3d_buffer *buffer, unsigned int offset)
Definition: cs.c:756

◆ wined3d_device_draw_indexed_primitive()

HRESULT __cdecl wined3d_device_draw_indexed_primitive ( struct wined3d_device device,
UINT  start_idx,
UINT  index_count 
)

Definition at line 3769 of file device.c.

3770{
3771 TRACE("device %p, start_idx %u, index_count %u.\n", device, start_idx, index_count);
3772
3773 if (!device->state.index_buffer)
3774 {
3775 /* D3D9 returns D3DERR_INVALIDCALL when DrawIndexedPrimitive is called
3776 * without an index buffer set. (The first time at least...)
3777 * D3D8 simply dies, but I doubt it can do much harm to return
3778 * D3DERR_INVALIDCALL there as well. */
3779 WARN("Called without a valid index buffer set, returning WINED3DERR_INVALIDCALL.\n");
3781 }
3782
3783 wined3d_cs_emit_draw(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3784 device->state.base_vertex_index, start_idx, index_count, 0, 0, TRUE);
3785
3786 return WINED3D_OK;
3787}
void wined3d_cs_emit_draw(struct wined3d_cs *cs, GLenum primitive_type, unsigned int patch_vertex_count, int base_vertex_idx, unsigned int start_idx, unsigned int index_count, unsigned int start_instance, unsigned int instance_count, BOOL indexed)
Definition: cs.c:873

Referenced by d3d8_device_DrawIndexedPrimitive(), d3d8_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawIndexedPrimitive(), d3d9_device_DrawIndexedPrimitiveUP(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), and d3d_device7_DrawIndexedPrimitiveVB().

◆ wined3d_device_draw_indexed_primitive_instanced()

void __cdecl wined3d_device_draw_indexed_primitive_instanced ( struct wined3d_device device,
UINT  start_idx,
UINT  index_count,
UINT  start_instance,
UINT  instance_count 
)

Definition at line 3789 of file device.c.

3791{
3792 TRACE("device %p, start_idx %u, index_count %u, start_instance %u, instance_count %u.\n",
3793 device, start_idx, index_count, start_instance, instance_count);
3794
3795 wined3d_cs_emit_draw(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3796 device->state.base_vertex_index, start_idx, index_count, start_instance, instance_count, TRUE);
3797}

◆ wined3d_device_draw_indexed_primitive_instanced_indirect()

void __cdecl wined3d_device_draw_indexed_primitive_instanced_indirect ( struct wined3d_device device,
struct wined3d_buffer buffer,
unsigned int  offset 
)

Definition at line 3799 of file device.c.

3801{
3802 TRACE("device %p, buffer %p, offset %u.\n", device, buffer, offset);
3803
3804 wined3d_cs_emit_draw_indirect(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3805 buffer, offset, TRUE);
3806}
void wined3d_cs_emit_draw_indirect(struct wined3d_cs *cs, GLenum primitive_type, unsigned int patch_vertex_count, struct wined3d_buffer *buffer, unsigned int offset, BOOL indexed)
Definition: cs.c:898

◆ wined3d_device_draw_primitive()

HRESULT __cdecl wined3d_device_draw_primitive ( struct wined3d_device device,
UINT  start_vertex,
UINT  vertex_count 
)

Definition at line 3740 of file device.c.

3741{
3742 TRACE("device %p, start_vertex %u, vertex_count %u.\n", device, start_vertex, vertex_count);
3743
3744 wined3d_cs_emit_draw(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3745 0, start_vertex, vertex_count, 0, 0, FALSE);
3746
3747 return WINED3D_OK;
3748}
int vertex_count
Definition: d3drm.c:3367

Referenced by d3d8_device_DrawPrimitive(), d3d8_device_DrawPrimitiveUP(), d3d9_device_DrawPrimitive(), d3d9_device_DrawPrimitiveUP(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), and d3d_device7_DrawPrimitiveVB().

◆ wined3d_device_draw_primitive_instanced()

void __cdecl wined3d_device_draw_primitive_instanced ( struct wined3d_device device,
UINT  start_vertex,
UINT  vertex_count,
UINT  start_instance,
UINT  instance_count 
)

Definition at line 3750 of file device.c.

3752{
3753 TRACE("device %p, start_vertex %u, vertex_count %u, start_instance %u, instance_count %u.\n",
3754 device, start_vertex, vertex_count, start_instance, instance_count);
3755
3756 wined3d_cs_emit_draw(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3757 0, start_vertex, vertex_count, start_instance, instance_count, FALSE);
3758}

◆ wined3d_device_draw_primitive_instanced_indirect()

void __cdecl wined3d_device_draw_primitive_instanced_indirect ( struct wined3d_device device,
struct wined3d_buffer buffer,
unsigned int  offset 
)

Definition at line 3760 of file device.c.

3762{
3763 TRACE("device %p, buffer %p, offset %u.\n", device, buffer, offset);
3764
3765 wined3d_cs_emit_draw_indirect(device->cs, device->state.gl_primitive_type, device->state.gl_patch_vertices,
3766 buffer, offset, FALSE);
3767}

◆ wined3d_device_end_scene()

HRESULT __cdecl wined3d_device_end_scene ( struct wined3d_device device)

Definition at line 3617 of file device.c.

3618{
3619 TRACE("device %p.\n", device);
3620
3621 if (!device->inScene)
3622 {
3623 WARN("Not in scene, returning WINED3DERR_INVALIDCALL.\n");
3625 }
3626
3628
3629 device->inScene = FALSE;
3630 return WINED3D_OK;
3631}
void wined3d_cs_emit_flush(struct wined3d_cs *cs)
Definition: cs.c:930

Referenced by d3d8_device_EndScene(), d3d9_device_EndScene(), and d3d_device7_EndScene().

◆ wined3d_device_end_stateblock()

HRESULT __cdecl wined3d_device_end_stateblock ( struct wined3d_device device,
struct wined3d_stateblock **  stateblock 
)

Definition at line 3577 of file device.c.

3579{
3580 struct wined3d_stateblock *object = device->recording;
3581
3582 TRACE("device %p, stateblock %p.\n", device, stateblock);
3583
3584 if (!device->recording)
3585 {
3586 WARN("Not recording.\n");
3587 *stateblock = NULL;
3589 }
3590
3592
3593 *stateblock = object;
3594 device->recording = NULL;
3595 device->update_state = &device->state;
3596
3597 TRACE("Returning stateblock %p.\n", *stateblock);
3598
3599 return WINED3D_OK;
3600}
void stateblock_init_contained_states(struct wined3d_stateblock *stateblock)
Definition: stateblock.c:290

Referenced by d3d8_device_EndStateBlock(), d3d9_device_EndStateBlock(), and d3d_device7_EndStateBlock().

◆ wined3d_device_evict_managed_resources()

void __cdecl wined3d_device_evict_managed_resources ( struct wined3d_device device)

Definition at line 4753 of file device.c.

4754{
4756
4757 TRACE("device %p.\n", device);
4758
4760 {
4761 TRACE("Checking resource %p for eviction.\n", resource);
4762
4763 if (wined3d_resource_access_is_managed(resource->access) && !resource->map_count)
4764 {
4765 TRACE("Evicting %p.\n", resource);
4767 }
4768 }
4769}
void wined3d_cs_emit_unload_resource(struct wined3d_cs *cs, struct wined3d_resource *resource)
Definition: cs.c:1978
const char cursor[]
Definition: icontest.c:13
#define LIST_FOR_EACH_ENTRY_SAFE(cursor, cursor2, list, type, field)
Definition: list.h:204
static BOOL wined3d_resource_access_is_managed(unsigned int access)

Referenced by d3d7_EvictManagedTextures(), d3d8_device_ResourceManagerDiscardBytes(), and d3d9_device_EvictManagedResources().

◆ wined3d_device_get_available_texture_mem()

UINT __cdecl wined3d_device_get_available_texture_mem ( const struct wined3d_device device)

Definition at line 1298 of file device.c.

1299{
1300 /* const struct wined3d_gl_info *gl_info = &device->adapter->gl_info; */
1301
1302 TRACE("device %p.\n", device);
1303
1304 /* We can not acquire the context unless there is a swapchain. */
1305 /*
1306 if (device->swapchains && gl_info->supported[NVX_GPU_MEMORY_INFO] &&
1307 !wined3d_settings.emulated_textureram)
1308 {
1309 GLint vram_free_kb;
1310 UINT64 vram_free;
1311
1312 struct wined3d_context *context = context_acquire(device, NULL, 0);
1313 gl_info->gl_ops.gl.p_glGetIntegerv(GL_GPU_MEMORY_INFO_CURRENT_AVAILABLE_VIDMEM_NVX, &vram_free_kb);
1314 vram_free = (UINT64)vram_free_kb * 1024;
1315 context_release(context);
1316
1317 TRACE("Total 0x%s bytes. emulation 0x%s left, driver 0x%s left.\n",
1318 wine_dbgstr_longlong(device->adapter->vram_bytes),
1319 wine_dbgstr_longlong(device->adapter->vram_bytes - device->adapter->vram_bytes_used),
1320 wine_dbgstr_longlong(vram_free));
1321
1322 vram_free = min(vram_free, device->adapter->vram_bytes - device->adapter->vram_bytes_used);
1323 return min(UINT_MAX, vram_free);
1324 }
1325 */
1326
1327 TRACE("Emulating 0x%s bytes. 0x%s used, returning 0x%s left.\n",
1328 wine_dbgstr_longlong(device->adapter->vram_bytes),
1329 wine_dbgstr_longlong(device->adapter->vram_bytes_used),
1330 wine_dbgstr_longlong(device->adapter->vram_bytes - device->adapter->vram_bytes_used));
1331
1332 return min(UINT_MAX, device->adapter->vram_bytes - device->adapter->vram_bytes_used);
1333}
static __inline const char * wine_dbgstr_longlong(ULONGLONG ll)
Definition: compat.h:49
#define UINT_MAX
Definition: limits.h:41

Referenced by d3d8_device_GetAvailableTextureMem(), d3d9_device_GetAvailableTextureMem(), ddraw7_GetAvailableVidMem(), and resource_init().

◆ wined3d_device_get_base_vertex_index()

INT __cdecl wined3d_device_get_base_vertex_index ( const struct wined3d_device device)

Definition at line 1924 of file device.c.

1925{
1926 TRACE("device %p.\n", device);
1927
1928 return device->state.base_vertex_index;
1929}

Referenced by d3d8_device_GetIndices().

◆ wined3d_device_get_blend_state()

struct wined3d_blend_state *__cdecl wined3d_device_get_blend_state ( const struct wined3d_device device)

Definition at line 1994 of file device.c.

1995{
1996 TRACE("device %p.\n", device);
1997
1998 return device->state.blend_state;
1999}

◆ wined3d_device_get_clip_plane()

HRESULT __cdecl wined3d_device_get_clip_plane ( const struct wined3d_device device,
UINT  plane_idx,
struct wined3d_vec4 plane 
)

Definition at line 1811 of file device.c.

1813{
1814 TRACE("device %p, plane_idx %u, plane %p.\n", device, plane_idx, plane);
1815
1816 if (plane_idx >= device->adapter->gl_info.limits.user_clip_distances)
1817 {
1818 TRACE("Application has requested clipplane this device doesn't support.\n");
1820 }
1821
1822 *plane = device->state.clip_planes[plane_idx];
1823
1824 return WINED3D_OK;
1825}
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum GLenum GLfloat GLenum GLenum GLint GLenum GLfloat GLenum GLint GLint GLushort GLenum GLenum GLfloat GLenum GLenum GLint GLfloat const GLubyte GLenum GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLint GLint GLsizei GLsizei GLint GLenum GLenum const GLvoid GLenum GLenum const GLfloat GLenum GLenum const GLint GLenum GLenum const GLdouble GLenum GLenum const GLfloat GLenum GLenum const GLint GLsizei GLuint GLfloat GLuint GLbitfield GLfloat GLint GLuint GLboolean GLenum GLfloat GLenum GLbitfield GLenum GLfloat GLfloat GLint GLint const GLfloat GLenum GLfloat GLfloat GLint GLint GLfloat GLfloat GLint GLint const GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat GLint GLfloat GLfloat const GLdouble const GLfloat const GLdouble const GLfloat GLint GLint GLint GLenum GLenum GLenum GLint GLuint GLenum GLenum GLfloat GLenum GLfloat GLenum GLint const GLfloat GLenum GLint const GLushort GLint GLint GLsizei GLsizei GLenum GLsizei GLsizei GLenum GLenum const GLvoid GLenum plane
Definition: glfuncs.h:270

Referenced by d3d8_device_GetClipPlane(), d3d9_device_GetClipPlane(), and d3d_device7_GetClipPlane().

◆ wined3d_device_get_clip_status()

HRESULT __cdecl wined3d_device_get_clip_status ( const struct wined3d_device device,
struct wined3d_clip_status clip_status 
)

Definition at line 1838 of file device.c.

1840{
1841 FIXME("device %p, clip_status %p stub!\n", device, clip_status);
1842
1843 if (!clip_status)
1845
1846 return WINED3D_OK;
1847}

Referenced by d3d8_device_GetClipStatus(), and d3d9_device_GetClipStatus().

◆ wined3d_device_get_compute_shader()

struct wined3d_shader *__cdecl wined3d_device_get_compute_shader ( const struct wined3d_device device)

Definition at line 2947 of file device.c.

2948{
2949 TRACE("device %p.\n", device);
2950
2951 return device->state.shader[WINED3D_SHADER_TYPE_COMPUTE];
2952}
@ WINED3D_SHADER_TYPE_COMPUTE

◆ wined3d_device_get_creation_parameters()

void __cdecl wined3d_device_get_creation_parameters ( const struct wined3d_device device,
struct wined3d_device_creation_parameters creation_parameters 
)

Definition at line 5042 of file device.c.

5044{
5045 TRACE("device %p, parameters %p.\n", device, parameters);
5046
5047 *parameters = device->create_parms;
5048}

Referenced by d3d8_device_GetCreationParameters(), and d3d9_device_GetCreationParameters().

◆ wined3d_device_get_cs_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_cs_cb ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2961 of file device.c.

2962{
2963 TRACE("device %p, idx %u.\n", device, idx);
2964
2966}
static struct wined3d_buffer * wined3d_device_get_constant_buffer(const struct wined3d_device *device, enum wined3d_shader_type shader_type, unsigned int idx)
Definition: device.c:2245

◆ wined3d_device_get_cs_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_cs_resource_view ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2976 of file device.c.

2978{
2979 TRACE("device %p, idx %u.\n", device, idx);
2980
2982}
static struct wined3d_shader_resource_view * wined3d_device_get_shader_resource_view(const struct wined3d_device *device, enum wined3d_shader_type shader_type, unsigned int idx)
Definition: device.c:2296

◆ wined3d_device_get_cs_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_cs_sampler ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2992 of file device.c.

2993{
2994 TRACE("device %p, idx %u.\n", device, idx);
2995
2997}
static struct wined3d_sampler * wined3d_device_get_sampler(const struct wined3d_device *device, enum wined3d_shader_type shader_type, unsigned int idx)
Definition: device.c:2347

◆ wined3d_device_get_cs_uav()

struct wined3d_unordered_access_view *__cdecl wined3d_device_get_cs_uav ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 3044 of file device.c.

3046{
3047 TRACE("device %p, idx %u.\n", device, idx);
3048
3050}
static struct wined3d_unordered_access_view * wined3d_device_get_pipeline_unordered_access_view(const struct wined3d_device *device, enum wined3d_pipeline pipeline, unsigned int idx)
Definition: device.c:3024
@ WINED3D_PIPELINE_COMPUTE

◆ wined3d_device_get_depth_stencil_view()

struct wined3d_rendertarget_view *__cdecl wined3d_device_get_depth_stencil_view ( const struct wined3d_device device)

Definition at line 4461 of file device.c.

4462{
4463 TRACE("device %p.\n", device);
4464
4465 return device->fb.depth_stencil;
4466}

Referenced by d3d8_device_GetDepthStencilSurface(), d3d8_device_SetRenderTarget(), d3d9_device_GetDepthStencilSurface(), ddraw_set_cooperative_level(), and ddraw_surface_delete_attached_surface().

◆ wined3d_device_get_device_caps()

HRESULT __cdecl wined3d_device_get_device_caps ( const struct wined3d_device device,
WINED3DCAPS caps 
)

Definition at line 3526 of file device.c.

3527{
3528 HRESULT hr;
3529
3530 TRACE("device %p, caps %p.\n", device, caps);
3531
3532 hr = wined3d_get_device_caps(device->wined3d, device->adapter->ordinal,
3533 device->create_parms.device_type, caps);
3534
3536 caps->MaxVertexBlendMatrixIndex = 255;
3537
3538 return hr;
3539}
DWORD MaxVertexBlendMatrixIndex
Definition: wined3d.h:1936
HRESULT CDECL wined3d_get_device_caps(const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_device_type device_type, WINED3DCAPS *caps)
Definition: directx.c:5659
static BOOL use_software_vertex_processing(const struct wined3d_device *device)

Referenced by d3d8_device_GetDeviceCaps(), d3d9_device_GetDeviceCaps(), and ddraw7_GetCaps().

◆ wined3d_device_get_display_mode()

HRESULT __cdecl wined3d_device_get_display_mode ( const struct wined3d_device device,
UINT  swapchain_idx,
struct wined3d_display_mode mode,
enum wined3d_display_rotation rotation 
)

Definition at line 3541 of file device.c.

3543{
3544 struct wined3d_swapchain *swapchain;
3545
3546 TRACE("device %p, swapchain_idx %u, mode %p, rotation %p.\n",
3547 device, swapchain_idx, mode, rotation);
3548
3549 if (!(swapchain = wined3d_device_get_swapchain(device, swapchain_idx)))
3551
3552 return wined3d_swapchain_get_display_mode(swapchain, mode, rotation);
3553}
struct wined3d_swapchain *CDECL wined3d_device_get_swapchain(const struct wined3d_device *device, UINT swapchain_idx)
Definition: device.c:533
GLenum mode
Definition: glext.h:6217
HRESULT CDECL wined3d_swapchain_get_display_mode(const struct wined3d_swapchain *swapchain, struct wined3d_display_mode *mode, enum wined3d_display_rotation *rotation)
Definition: swapchain.c:248

Referenced by d3d8_device_GetDisplayMode(), d3d9_device_GetDisplayMode(), and d3d9_device_GetDisplayModeEx().

◆ wined3d_device_get_domain_shader()

struct wined3d_shader *__cdecl wined3d_device_get_domain_shader ( const struct wined3d_device device)

Definition at line 2811 of file device.c.

2812{
2813 TRACE("device %p.\n", device);
2814
2815 return device->state.shader[WINED3D_SHADER_TYPE_DOMAIN];
2816}
@ WINED3D_SHADER_TYPE_DOMAIN

◆ wined3d_device_get_ds_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_ds_cb ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2825 of file device.c.

2826{
2827 TRACE("device %p, idx %u.\n", device, idx);
2828
2830}

◆ wined3d_device_get_ds_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_ds_resource_view ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2840 of file device.c.

2842{
2843 TRACE("device %p, idx %u.\n", device, idx);
2844
2846}

◆ wined3d_device_get_ds_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_ds_sampler ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2856 of file device.c.

2857{
2858 TRACE("device %p, idx %u.\n", device, idx);
2859
2861}

◆ wined3d_device_get_gamma_ramp()

void __cdecl wined3d_device_get_gamma_ramp ( const struct wined3d_device device,
UINT  swapchain_idx,
struct wined3d_gamma_ramp ramp 
)

Definition at line 5069 of file device.c.

5071{
5072 struct wined3d_swapchain *swapchain;
5073
5074 TRACE("device %p, swapchain_idx %u, ramp %p.\n",
5075 device, swapchain_idx, ramp);
5076
5077 if ((swapchain = wined3d_device_get_swapchain(device, swapchain_idx)))
5079}
static const BYTE ramp[17]
Definition: dib.c:2709
HRESULT CDECL wined3d_swapchain_get_gamma_ramp(const struct wined3d_swapchain *swapchain, struct wined3d_gamma_ramp *ramp)
Definition: swapchain.c:302

Referenced by d3d8_device_GetGammaRamp(), d3d9_device_GetGammaRamp(), and ddraw_gamma_control_GetGammaRamp().

◆ wined3d_device_get_geometry_shader()

struct wined3d_shader *__cdecl wined3d_device_get_geometry_shader ( const struct wined3d_device device)

Definition at line 2879 of file device.c.

2880{
2881 TRACE("device %p.\n", device);
2882
2883 return device->state.shader[WINED3D_SHADER_TYPE_GEOMETRY];
2884}
@ WINED3D_SHADER_TYPE_GEOMETRY

◆ wined3d_device_get_gs_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_gs_cb ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2893 of file device.c.

2894{
2895 TRACE("device %p, idx %u.\n", device, idx);
2896
2898}

◆ wined3d_device_get_gs_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_gs_resource_view ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2908 of file device.c.

2910{
2911 TRACE("device %p, idx %u.\n", device, idx);
2912
2914}

◆ wined3d_device_get_gs_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_gs_sampler ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2923 of file device.c.

2924{
2925 TRACE("device %p, idx %u.\n", device, idx);
2926
2928}

◆ wined3d_device_get_hs_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_hs_cb ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2756 of file device.c.

2757{
2758 TRACE("device %p, idx %u.\n", device, idx);
2759
2761}
@ WINED3D_SHADER_TYPE_HULL

◆ wined3d_device_get_hs_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_hs_resource_view ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2771 of file device.c.

2773{
2774 TRACE("device %p, idx %u.\n", device, idx);
2775
2777}

◆ wined3d_device_get_hs_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_hs_sampler ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 2787 of file device.c.

2788{
2789 TRACE("device %p, idx %u.\n", device, idx);
2790
2792}

◆ wined3d_device_get_hull_shader()

struct wined3d_shader *__cdecl wined3d_device_get_hull_shader ( const struct wined3d_device device)

Definition at line 2742 of file device.c.

2743{
2744 TRACE("device %p.\n", device);
2745
2746 return device->state.shader[WINED3D_SHADER_TYPE_HULL];
2747}

◆ wined3d_device_get_index_buffer()

struct wined3d_buffer *__cdecl wined3d_device_get_index_buffer ( const struct wined3d_device device,
enum wined3d_format_id format,
unsigned int offset 
)

Definition at line 1906 of file device.c.

1908{
1909 TRACE("device %p, format %p, offset %p.\n", device, format, offset);
1910
1911 *format = device->state.index_format;
1912 if (offset)
1913 *offset = device->state.index_offset;
1914 return device->state.index_buffer;
1915}

Referenced by d3d8_device_GetIndices(), and d3d9_device_GetIndices().

◆ wined3d_device_get_light()

HRESULT __cdecl wined3d_device_get_light ( const struct wined3d_device device,
UINT  light_idx,
struct wined3d_light light 
)

Definition at line 1724 of file device.c.

1726{
1727 struct wined3d_light_info *light_info;
1728
1729 TRACE("device %p, light_idx %u, light %p.\n", device, light_idx, light);
1730
1731 if (!(light_info = wined3d_state_get_light(&device->state, light_idx)))
1732 {
1733 TRACE("Light information requested but light not defined\n");
1735 }
1736
1737 *light = light_info->OriginalParms;
1738 return WINED3D_OK;
1739}
GLsizei GLenum const GLvoid GLsizei GLenum GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLint GLint GLint GLshort GLshort GLshort GLubyte GLubyte GLubyte GLuint GLuint GLuint GLushort GLushort GLushort GLbyte GLbyte GLbyte GLbyte GLdouble GLdouble GLdouble GLdouble GLfloat GLfloat GLfloat GLfloat GLint GLint GLint GLint GLshort GLshort GLshort GLshort GLubyte GLubyte GLubyte GLubyte GLuint GLuint GLuint GLuint GLushort GLushort GLushort GLushort GLboolean const GLdouble const GLfloat const GLint const GLshort const GLbyte const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLdouble const GLfloat const GLfloat const GLint const GLint const GLshort const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort const GLdouble const GLfloat const GLint const GLshort GLenum GLenum GLenum GLfloat GLenum GLint GLenum GLenum light
Definition: glfuncs.h:170
struct wined3d_light OriginalParms
struct wined3d_light_info * wined3d_state_get_light(const struct wined3d_state *state, unsigned int idx)
Definition: stateblock.c:567

Referenced by d3d8_device_GetLight(), d3d9_device_GetLight(), and d3d_device7_GetLight().

◆ wined3d_device_get_light_enable()

HRESULT __cdecl wined3d_device_get_light_enable ( const struct wined3d_device device,
UINT  light_idx,
BOOL enable 
)

Definition at line 1767 of file device.c.

1768{
1769 struct wined3d_light_info *light_info;
1770
1771 TRACE("device %p, light_idx %u, enable %p.\n", device, light_idx, enable);
1772
1773 if (!(light_info = wined3d_state_get_light(&device->state, light_idx)))
1774 {
1775 TRACE("Light enabled state requested but light not defined.\n");
1777 }
1778 /* true is 128 according to SetLightEnable */
1779 *enable = light_info->enabled ? 128 : 0;
1780 return WINED3D_OK;
1781}
GLboolean enable
Definition: glext.h:11120

Referenced by d3d8_device_GetLightEnable(), d3d9_device_GetLightEnable(), and d3d_device7_GetLightEnable().

◆ wined3d_device_get_material()

void __cdecl wined3d_device_get_material ( const struct wined3d_device device,
struct wined3d_material material 
)

Definition at line 1861 of file device.c.

1862{
1863 TRACE("device %p, material %p.\n", device, material);
1864
1865 *material = device->state.material;
1866
1867 TRACE("diffuse %s\n", debug_color(&material->diffuse));
1868 TRACE("ambient %s\n", debug_color(&material->ambient));
1869 TRACE("specular %s\n", debug_color(&material->specular));
1870 TRACE("emissive %s\n", debug_color(&material->emissive));
1871 TRACE("power %.8e.\n", material->power);
1872}
struct wined3d_color specular
Definition: wined3d.h:1664
struct wined3d_color ambient
Definition: wined3d.h:1663
struct wined3d_color diffuse
Definition: wined3d.h:1662
struct wined3d_color emissive
Definition: wined3d.h:1665

Referenced by d3d8_device_GetMaterial(), d3d9_device_GetMaterial(), and d3d_device7_GetMaterial().

◆ wined3d_device_get_npatch_mode()

float __cdecl wined3d_device_get_npatch_mode ( const struct wined3d_device device)

Definition at line 4013 of file device.c.

4014{
4015 static BOOL warned;
4016
4017 TRACE("device %p.\n", device);
4018
4019 if (!warned)
4020 {
4021 FIXME("device %p stub!\n", device);
4022 warned = TRUE;
4023 }
4024
4025 return 0.0f;
4026}

Referenced by d3d9_device_GetNPatchMode().

◆ wined3d_device_get_pixel_shader()

struct wined3d_shader *__cdecl wined3d_device_get_pixel_shader ( const struct wined3d_device device)

Definition at line 2530 of file device.c.

2531{
2532 TRACE("device %p.\n", device);
2533
2534 return device->state.shader[WINED3D_SHADER_TYPE_PIXEL];
2535}
@ WINED3D_SHADER_TYPE_PIXEL

Referenced by d3d8_device_DeletePixelShader(), d3d8_device_GetPixelShader(), and d3d9_device_GetPixelShader().

◆ wined3d_device_get_predication()

struct wined3d_query *__cdecl wined3d_device_get_predication ( struct wined3d_device device,
BOOL value 
)

Definition at line 3691 of file device.c.

3692{
3693 TRACE("device %p, value %p.\n", device, value);
3694
3695 if (value)
3696 *value = device->state.predicate_value;
3697 return device->state.predicate;
3698}
Definition: pdh_main.c:94

◆ wined3d_device_get_primitive_type()

void __cdecl wined3d_device_get_primitive_type ( const struct wined3d_device device,
enum wined3d_primitive_type primitive_topology,
unsigned int patch_vertex_count 
)

Definition at line 3727 of file device.c.

3729{
3730 TRACE("device %p, primitive_type %p, patch_vertex_count %p.\n",
3731 device, primitive_type, patch_vertex_count);
3732
3733 *primitive_type = d3d_primitive_type_from_gl(device->state.gl_primitive_type);
3734 if (patch_vertex_count)
3735 *patch_vertex_count = device->state.gl_patch_vertices;
3736
3737 TRACE("Returning %s.\n", debug_d3dprimitivetype(*primitive_type));
3738}
static enum wined3d_primitive_type d3d_primitive_type_from_gl(GLenum primitive_type)
Definition: device.c:102
const char * debug_d3dprimitivetype(enum wined3d_primitive_type primitive_type)
Definition: utils.c:4346

◆ wined3d_device_get_ps_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_ps_cb ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2544 of file device.c.

2545{
2546 TRACE("device %p, idx %u.\n", device, idx);
2547
2549}

◆ wined3d_device_get_ps_consts_b()

HRESULT __cdecl wined3d_device_get_ps_consts_b ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
BOOL constants 
)

Definition at line 2614 of file device.c.

2616{
2617 TRACE("device %p, start_idx %u, count %u,constants %p.\n",
2618 device, start_idx, count, constants);
2619
2620 if (!constants || start_idx >= WINED3D_MAX_CONSTS_B)
2622
2623 if (count > WINED3D_MAX_CONSTS_B - start_idx)
2624 count = WINED3D_MAX_CONSTS_B - start_idx;
2625 memcpy(constants, &device->state.ps_consts_b[start_idx], count * sizeof(*constants));
2626
2627 return WINED3D_OK;
2628}
GLuint GLuint GLsizei count
Definition: gl.h:1545
#define memcpy(s1, s2, n)
Definition: mkisofs.h:878
constants
Definition: resource.c:29
#define WINED3D_MAX_CONSTS_B

Referenced by d3d9_device_GetPixelShaderConstantB().

◆ wined3d_device_get_ps_consts_f()

HRESULT __cdecl wined3d_device_get_ps_consts_f ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
struct wined3d_vec4 constants 
)

Definition at line 2708 of file device.c.

2710{
2711 const struct wined3d_d3d_info *d3d_info = &device->adapter->d3d_info;
2712
2713 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2714 device, start_idx, count, constants);
2715
2716 if (!constants || start_idx >= d3d_info->limits.ps_uniform_count
2717 || count > d3d_info->limits.ps_uniform_count - start_idx)
2719
2720 memcpy(constants, &device->state.ps_consts_f[start_idx], count * sizeof(*constants));
2721
2722 return WINED3D_OK;
2723}
struct wined3d_d3d_limits limits

Referenced by d3d8_device_GetPixelShaderConstant(), and d3d9_device_GetPixelShaderConstantF().

◆ wined3d_device_get_ps_consts_i()

HRESULT __cdecl wined3d_device_get_ps_consts_i ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
struct wined3d_ivec4 constants 
)

Definition at line 2663 of file device.c.

2665{
2666 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2667 device, start_idx, count, constants);
2668
2669 if (!constants || start_idx >= WINED3D_MAX_CONSTS_I)
2671
2672 if (count > WINED3D_MAX_CONSTS_I - start_idx)
2673 count = WINED3D_MAX_CONSTS_I - start_idx;
2674 memcpy(constants, &device->state.ps_consts_i[start_idx], count * sizeof(*constants));
2675
2676 return WINED3D_OK;
2677}
#define WINED3D_MAX_CONSTS_I

Referenced by d3d9_device_GetPixelShaderConstantI().

◆ wined3d_device_get_ps_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_ps_resource_view ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2559 of file device.c.

2561{
2562 TRACE("device %p, idx %u.\n", device, idx);
2563
2565}

◆ wined3d_device_get_ps_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_ps_sampler ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2574 of file device.c.

2575{
2576 TRACE("device %p, idx %u.\n", device, idx);
2577
2579}

◆ wined3d_device_get_raster_status()

HRESULT __cdecl wined3d_device_get_raster_status ( const struct wined3d_device device,
UINT  swapchain_idx,
struct wined3d_raster_status raster_status 
)

Definition at line 3981 of file device.c.

3983{
3984 struct wined3d_swapchain *swapchain;
3985
3986 TRACE("device %p, swapchain_idx %u, raster_status %p.\n",
3987 device, swapchain_idx, raster_status);
3988
3989 if (!(swapchain = wined3d_device_get_swapchain(device, swapchain_idx)))
3991
3992 return wined3d_swapchain_get_raster_status(swapchain, raster_status);
3993}
HRESULT CDECL wined3d_swapchain_get_raster_status(const struct wined3d_swapchain *swapchain, struct wined3d_raster_status *raster_status)
Definition: swapchain.c:239

Referenced by d3d8_device_GetRasterStatus(), and d3d9_device_GetRasterStatus().

◆ wined3d_device_get_rasterizer_state()

struct wined3d_rasterizer_state *__cdecl wined3d_device_get_rasterizer_state ( struct wined3d_device device)

Definition at line 2020 of file device.c.

2021{
2022 TRACE("device %p.\n", device);
2023
2024 return device->state.rasterizer_state;
2025}

◆ wined3d_device_get_render_state()

DWORD __cdecl wined3d_device_get_render_state ( const struct wined3d_device device,
enum wined3d_render_state  state 
)

Definition at line 2064 of file device.c.

2065{
2066 TRACE("device %p, state %s (%#x).\n", device, debug_d3drenderstate(state), state);
2067
2068 return device->state.render_states[state];
2069}
const char * debug_d3drenderstate(enum wined3d_render_state state)
Definition: utils.c:4370

Referenced by d3d8_device_GetRenderState(), d3d9_device_GetRenderState(), d3d_device7_GetRenderState(), and d3d_vertex_buffer7_ProcessVertices().

◆ wined3d_device_get_rendertarget_view()

struct wined3d_rendertarget_view *__cdecl wined3d_device_get_rendertarget_view ( const struct wined3d_device device,
unsigned int  view_idx 
)

Definition at line 4447 of file device.c.

4449{
4450 TRACE("device %p, view_idx %u.\n", device, view_idx);
4451
4452 if (view_idx >= device->adapter->gl_info.limits.buffers)
4453 {
4454 WARN("Only %u render targets are supported.\n", device->adapter->gl_info.limits.buffers);
4455 return NULL;
4456 }
4457
4458 return device->fb.render_targets[view_idx];
4459}

Referenced by d3d8_device_GetRenderTarget(), d3d8_device_SetRenderTarget(), d3d9_device_GetRenderTarget(), d3d9_device_reset(), ddraw_set_cooperative_level(), ddraw_surface7_Flip(), and device_init().

◆ wined3d_device_get_sampler_state()

DWORD __cdecl wined3d_device_get_sampler_state ( const struct wined3d_device device,
UINT  sampler_idx,
enum wined3d_sampler_state  state 
)

Definition at line 2108 of file device.c.

2110{
2111 TRACE("device %p, sampler_idx %u, state %s.\n",
2112 device, sampler_idx, debug_d3dsamplerstate(state));
2113
2114 if (sampler_idx >= WINED3DVERTEXTEXTURESAMPLER0 && sampler_idx <= WINED3DVERTEXTEXTURESAMPLER3)
2116
2117 if (sampler_idx >= ARRAY_SIZE(device->state.sampler_states))
2118 {
2119 WARN("Invalid sampler %u.\n", sampler_idx);
2120 return 0; /* Windows accepts overflowing this array ... we do not. */
2121 }
2122
2123 return device->state.sampler_states[sampler_idx][state];
2124}
const char * debug_d3dsamplerstate(enum wined3d_sampler_state state)
Definition: utils.c:4514
#define WINED3DVERTEXTEXTURESAMPLER3
Definition: wined3d.h:1028
#define WINED3DVERTEXTEXTURESAMPLER0
Definition: wined3d.h:1025
#define MAX_FRAGMENT_SAMPLERS

Referenced by d3d8_device_GetTextureStageState(), d3d9_device_GetSamplerState(), d3d_device7_GetRenderState(), and d3d_device7_GetTextureStageState().

◆ wined3d_device_get_scissor_rect()

void __cdecl wined3d_device_get_scissor_rect ( const struct wined3d_device device,
RECT rect 
)

Definition at line 2149 of file device.c.

2150{
2151 TRACE("device %p, rect %p.\n", device, rect);
2152
2153 *rect = device->state.scissor_rect;
2154 TRACE("Returning rect %s.\n", wine_dbgstr_rect(rect));
2155}

Referenced by d3d9_device_GetScissorRect().

◆ wined3d_device_get_software_vertex_processing()

BOOL __cdecl wined3d_device_get_software_vertex_processing ( const struct wined3d_device device)

Definition at line 3974 of file device.c.

3975{
3976 TRACE("device %p.\n", device);
3977
3978 return device->softwareVertexProcessing;
3979}

Referenced by d3d9_device_GetSoftwareVertexProcessing().

◆ wined3d_device_get_stream_output()

struct wined3d_buffer *__cdecl wined3d_device_get_stream_output ( struct wined3d_device device,
UINT  idx,
UINT offset 
)

Definition at line 1362 of file device.c.

1364{
1365 TRACE("device %p, idx %u, offset %p.\n", device, idx, offset);
1366
1368 {
1369 WARN("Invalid stream output %u.\n", idx);
1370 return NULL;
1371 }
1372
1373 if (offset)
1374 *offset = device->state.stream_output[idx].offset;
1375 return device->state.stream_output[idx].buffer;
1376}
#define WINED3D_MAX_STREAM_OUTPUT_BUFFERS
Definition: wined3d.h:1569

◆ wined3d_device_get_stream_source()

HRESULT __cdecl wined3d_device_get_stream_source ( const struct wined3d_device device,
UINT  stream_idx,
struct wined3d_buffer **  buffer,
UINT offset,
UINT stride 
)

Definition at line 1428 of file device.c.

1430{
1431 const struct wined3d_stream_state *stream;
1432
1433 TRACE("device %p, stream_idx %u, buffer %p, offset %p, stride %p.\n",
1434 device, stream_idx, buffer, offset, stride);
1435
1436 if (stream_idx >= MAX_STREAMS)
1437 {
1438 WARN("Stream index %u out of range.\n", stream_idx);
1440 }
1441
1442 stream = &device->state.streams[stream_idx];
1443 *buffer = stream->buffer;
1444 if (offset)
1445 *offset = stream->offset;
1446 *stride = stream->stride;
1447
1448 return WINED3D_OK;
1449}
GLsizei stride
Definition: glext.h:5848
Definition: parse.h:23
#define MAX_STREAMS

Referenced by d3d8_device_GetStreamSource(), d3d9_device_GetStreamSource(), and d3d_vertex_buffer7_Release().

◆ wined3d_device_get_stream_source_freq()

HRESULT __cdecl wined3d_device_get_stream_source_freq ( const struct wined3d_device device,
UINT  stream_idx,
UINT divider 
)

Definition at line 1490 of file device.c.

1492{
1493 const struct wined3d_stream_state *stream;
1494
1495 TRACE("device %p, stream_idx %u, divider %p.\n", device, stream_idx, divider);
1496
1497 stream = &device->state.streams[stream_idx];
1498 *divider = stream->flags | stream->frequency;
1499
1500 TRACE("Returning %#x.\n", *divider);
1501
1502 return WINED3D_OK;
1503}

Referenced by d3d9_device_GetStreamSourceFreq().

◆ wined3d_device_get_swapchain()

struct wined3d_swapchain *__cdecl wined3d_device_get_swapchain ( const struct wined3d_device device,
UINT  swapchain_idx 
)

Definition at line 533 of file device.c.

534{
535 TRACE("device %p, swapchain_idx %u.\n", device, swapchain_idx);
536
537 if (swapchain_idx >= device->swapchain_count)
538 {
539 WARN("swapchain_idx %u >= swapchain_count %u.\n",
540 swapchain_idx, device->swapchain_count);
541 return NULL;
542 }
543
544 return device->swapchains[swapchain_idx];
545}

Referenced by d3d8_device_CreateAdditionalSwapChain(), d3d9_device_CreateAdditionalSwapChain(), d3d9_device_get_swapchains(), ddraw_create_swapchain(), device_init(), wined3d_device_get_display_mode(), wined3d_device_get_gamma_ramp(), wined3d_device_get_raster_status(), wined3d_device_reset(), and wined3d_device_set_gamma_ramp().

◆ wined3d_device_get_swapchain_count()

UINT __cdecl wined3d_device_get_swapchain_count ( const struct wined3d_device device)

Definition at line 526 of file device.c.

527{
528 TRACE("device %p.\n", device);
529
530 return device->swapchain_count;
531}

Referenced by d3d8_device_CreateAdditionalSwapChain(), d3d9_device_CreateAdditionalSwapChain(), d3d9_device_get_swapchains(), and d3d9_device_GetNumberOfSwapChains().

◆ wined3d_device_get_texture()

struct wined3d_texture *__cdecl wined3d_device_get_texture ( const struct wined3d_device device,
UINT  stage 
)

Definition at line 3510 of file device.c.

3511{
3512 TRACE("device %p, stage %u.\n", device, stage);
3513
3516
3517 if (stage >= ARRAY_SIZE(device->state.textures))
3518 {
3519 WARN("Ignoring invalid stage %u.\n", stage);
3520 return NULL; /* Windows accepts overflowing this array ... we do not. */
3521 }
3522
3523 return device->state.textures[stage];
3524}

Referenced by d3d8_device_GetTexture(), d3d9_device_GetTexture(), d3d_device3_GetRenderState(), d3d_device3_SetRenderState(), d3d_device3_SetTexture(), and d3d_device7_GetTexture().

◆ wined3d_device_get_texture_stage_state()

DWORD __cdecl wined3d_device_get_texture_stage_state ( const struct wined3d_device device,
UINT  stage,
enum wined3d_texture_stage_state  state 
)

Definition at line 3447 of file device.c.

3449{
3450 TRACE("device %p, stage %u, state %s.\n",
3452
3454 {
3455 WARN("Invalid state %#x passed.\n", state);
3456 return 0;
3457 }
3458
3459 return device->state.texture_states[stage][state];
3460}
const char * debug_d3dtexturestate(enum wined3d_texture_stage_state state)
Definition: utils.c:4559
#define WINED3D_HIGHEST_TEXTURE_STATE
Definition: wined3d.h:595

Referenced by d3d8_device_GetTextureStageState(), d3d9_device_GetTextureStageState(), d3d_device3_GetRenderState(), and d3d_device7_GetTextureStageState().

◆ wined3d_device_get_transform()

void __cdecl wined3d_device_get_transform ( const struct wined3d_device device,
enum wined3d_transform_state  state,
struct wined3d_matrix matrix 
)

Definition at line 1540 of file device.c.

1542{
1543 TRACE("device %p, state %s, matrix %p.\n", device, debug_d3dtstype(state), matrix);
1544
1545 *matrix = device->state.transforms[state];
1546}
const char * debug_d3dtstype(enum wined3d_transform_state tstype)
Definition: utils.c:4627
GLuint GLenum matrix
Definition: glext.h:9407

Referenced by d3d8_device_GetTransform(), d3d9_device_GetTransform(), d3d_device7_GetTransform(), d3d_viewport_TransformVertices(), prepare_clip_space_planes(), and process_vertices_strided().

◆ wined3d_device_get_unordered_access_view()

struct wined3d_unordered_access_view *__cdecl wined3d_device_get_unordered_access_view ( const struct wined3d_device device,
unsigned int  idx 
)

Definition at line 3060 of file device.c.

3062{
3063 TRACE("device %p, idx %u.\n", device, idx);
3064
3066}
@ WINED3D_PIPELINE_GRAPHICS

◆ wined3d_device_get_vertex_declaration()

struct wined3d_vertex_declaration *__cdecl wined3d_device_get_vertex_declaration ( const struct wined3d_device device)

Definition at line 2179 of file device.c.

2180{
2181 TRACE("device %p.\n", device);
2182
2183 return device->state.vertex_declaration;
2184}

Referenced by d3d8_device_GetVertexShader(), d3d9_device_GetFVF(), and d3d9_device_GetVertexDeclaration().

◆ wined3d_device_get_vertex_shader()

struct wined3d_shader *__cdecl wined3d_device_get_vertex_shader ( const struct wined3d_device device)

Definition at line 2207 of file device.c.

2208{
2209 TRACE("device %p.\n", device);
2210
2211 return device->state.shader[WINED3D_SHADER_TYPE_VERTEX];
2212}
@ WINED3D_SHADER_TYPE_VERTEX

Referenced by d3d8_device_DeleteVertexShader(), and d3d9_device_GetVertexShader().

◆ wined3d_device_get_viewport()

void __cdecl wined3d_device_get_viewport ( const struct wined3d_device device,
struct wined3d_viewport viewport 
)

Definition at line 1950 of file device.c.

1951{
1952 TRACE("device %p, viewport %p.\n", device, viewport);
1953
1954 *viewport = device->state.viewport;
1955}

Referenced by d3d8_device_GetViewport(), d3d9_device_GetViewport(), d3d_device7_GetViewport(), and process_vertices_strided().

◆ wined3d_device_get_vs_cb()

struct wined3d_buffer *__cdecl wined3d_device_get_vs_cb ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2257 of file device.c.

2258{
2259 TRACE("device %p, idx %u.\n", device, idx);
2260
2262}

◆ wined3d_device_get_vs_consts_b()

HRESULT __cdecl wined3d_device_get_vs_consts_b ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
BOOL constants 
)

Definition at line 2399 of file device.c.

2401{
2402 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2403 device, start_idx, count, constants);
2404
2405 if (!constants || start_idx >= WINED3D_MAX_CONSTS_B)
2407
2408 if (count > WINED3D_MAX_CONSTS_B - start_idx)
2409 count = WINED3D_MAX_CONSTS_B - start_idx;
2410 memcpy(constants, &device->state.vs_consts_b[start_idx], count * sizeof(*constants));
2411
2412 return WINED3D_OK;
2413}

Referenced by d3d9_device_GetVertexShaderConstantB().

◆ wined3d_device_get_vs_consts_f()

HRESULT __cdecl wined3d_device_get_vs_consts_f ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
struct wined3d_vec4 constants 
)

Definition at line 2492 of file device.c.

2494{
2495 const struct wined3d_d3d_info *d3d_info = &device->adapter->d3d_info;
2496
2497 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2498 device, start_idx, count, constants);
2499
2500 if (!constants || start_idx >= d3d_info->limits.vs_uniform_count
2501 || count > d3d_info->limits.vs_uniform_count - start_idx)
2503
2504 memcpy(constants, &device->state.vs_consts_f[start_idx], count * sizeof(*constants));
2505
2506 return WINED3D_OK;
2507}

Referenced by d3d8_device_GetVertexShaderConstant(), and d3d9_device_GetVertexShaderConstantF().

◆ wined3d_device_get_vs_consts_i()

HRESULT __cdecl wined3d_device_get_vs_consts_i ( const struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
struct wined3d_ivec4 constants 
)

Definition at line 2448 of file device.c.

2450{
2451 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2452 device, start_idx, count, constants);
2453
2454 if (!constants || start_idx >= WINED3D_MAX_CONSTS_I)
2456
2457 if (count > WINED3D_MAX_CONSTS_I - start_idx)
2458 count = WINED3D_MAX_CONSTS_I - start_idx;
2459 memcpy(constants, &device->state.vs_consts_i[start_idx], count * sizeof(*constants));
2460 return WINED3D_OK;
2461}

Referenced by d3d9_device_GetVertexShaderConstantI().

◆ wined3d_device_get_vs_resource_view()

struct wined3d_shader_resource_view *__cdecl wined3d_device_get_vs_resource_view ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2308 of file device.c.

2310{
2311 TRACE("device %p, idx %u.\n", device, idx);
2312
2314}

◆ wined3d_device_get_vs_sampler()

struct wined3d_sampler *__cdecl wined3d_device_get_vs_sampler ( const struct wined3d_device device,
UINT  idx 
)

Definition at line 2359 of file device.c.

2360{
2361 TRACE("device %p, idx %u.\n", device, idx);
2362
2364}

◆ wined3d_device_get_wined3d()

struct wined3d *__cdecl wined3d_device_get_wined3d ( const struct wined3d_device device)

Definition at line 5050 of file device.c.

5051{
5052 TRACE("device %p.\n", device);
5053
5054 return device->wined3d;
5055}

◆ wined3d_device_incref()

ULONG __cdecl wined3d_device_incref ( struct wined3d_device device)

Definition at line 456 of file device.c.

457{
458 ULONG refcount = InterlockedIncrement(&device->ref);
459
460 TRACE("%p increasing refcount to %u.\n", device, refcount);
461
462 return refcount;
463}

Referenced by d3d_device_init(), and ddraw_surface_create().

◆ wined3d_device_init_3d()

HRESULT __cdecl wined3d_device_init_3d ( struct wined3d_device device,
struct wined3d_swapchain_desc swapchain_desc 
)

Definition at line 1061 of file device.c.

1063{
1064 static const struct wined3d_color black = {0.0f, 0.0f, 0.0f, 0.0f};
1065 struct wined3d_swapchain *swapchain = NULL;
1066 DWORD clear_flags = 0;
1067 HRESULT hr;
1068
1069 TRACE("device %p, swapchain_desc %p.\n", device, swapchain_desc);
1070
1071 if (device->d3d_initialized)
1073 if (device->wined3d->flags & WINED3D_NO3D)
1075
1076 memset(device->fb.render_targets, 0, sizeof(device->fb.render_targets));
1077
1078 /* Setup the implicit swapchain. This also initializes a context. */
1079 TRACE("Creating implicit swapchain.\n");
1080 if (FAILED(hr = device->device_parent->ops->create_swapchain(device->device_parent,
1081 swapchain_desc, &swapchain)))
1082 {
1083 WARN("Failed to create implicit swapchain.\n");
1084 goto err_out;
1085 }
1086
1087 if (swapchain_desc->backbuffer_count)
1088 {
1089 struct wined3d_resource *back_buffer = &swapchain->back_buffers[0]->resource;
1090 struct wined3d_view_desc view_desc;
1091
1092 view_desc.format_id = back_buffer->format->id;
1093 view_desc.flags = 0;
1094 view_desc.u.texture.level_idx = 0;
1095 view_desc.u.texture.level_count = 1;
1096 view_desc.u.texture.layer_idx = 0;
1097 view_desc.u.texture.layer_count = 1;
1098 if (FAILED(hr = wined3d_rendertarget_view_create(&view_desc, back_buffer,
1099 NULL, &wined3d_null_parent_ops, &device->back_buffer_view)))
1100 {
1101 ERR("Failed to create rendertarget view, hr %#x.\n", hr);
1102 goto err_out;
1103 }
1104 }
1105
1106 device->swapchain_count = 1;
1107 if (!(device->swapchains = heap_calloc(device->swapchain_count, sizeof(*device->swapchains))))
1108 {
1109 ERR("Out of memory!\n");
1110 goto err_out;
1111 }
1112 device->swapchains[0] = swapchain;
1113
1115 goto err_out;
1117
1118 device->contexts[0]->last_was_rhw = 0;
1119
1120 TRACE("All defaults now set up.\n");
1121
1122 /* Clear the screen */
1123 if (swapchain->back_buffers && swapchain->back_buffers[0])
1124 clear_flags |= WINED3DCLEAR_TARGET;
1125 if (swapchain_desc->enable_auto_depth_stencil)
1127 if (clear_flags)
1128 wined3d_device_clear(device, 0, NULL, clear_flags, &black, 1.0f, 0);
1129
1130 device->d3d_initialized = TRUE;
1131
1134 return WINED3D_OK;
1135
1136err_out:
1137 heap_free(device->swapchains);
1138 device->swapchain_count = 0;
1139 if (device->back_buffer_view)
1140 wined3d_rendertarget_view_decref(device->back_buffer_view);
1141 if (swapchain)
1142 wined3d_swapchain_decref(swapchain);
1143
1144 return hr;
1145}
static HRESULT wined3d_device_create_primary_opengl_context(struct wined3d_device *device)
Definition: device.c:1051
HRESULT CDECL wined3d_device_clear(struct wined3d_device *device, DWORD rect_count, const RECT *rects, DWORD flags, const struct wined3d_color *color, float depth, DWORD stencil)
Definition: device.c:3633
static void device_load_logo(struct wined3d_device *device, const char *filename)
Definition: device.c:547
static void device_init_swapchain_state(struct wined3d_device *device, struct wined3d_swapchain *swapchain)
Definition: device.c:962
HRESULT CDECL wined3d_rendertarget_view_create(const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_rendertarget_view **view)
Definition: view.c:598
ULONG CDECL wined3d_rendertarget_view_decref(struct wined3d_rendertarget_view *view)
Definition: view.c:348
static void * heap_calloc(SIZE_T count, SIZE_T size)
Definition: heap.h:49
#define memset(x, y, z)
Definition: compat.h:39
BOOL enable_auto_depth_stencil
Definition: wined3d.h:1742
struct wined3d_texture ** back_buffers
enum wined3d_format_id format_id
Definition: wined3d.h:2080
const struct wined3d_parent_ops wined3d_null_parent_ops
Definition: directx.c:6815
ULONG CDECL wined3d_swapchain_decref(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:113

Referenced by ddraw_attach_d3d_device(), and device_init().

◆ wined3d_device_init_gdi()

HRESULT __cdecl wined3d_device_init_gdi ( struct wined3d_device device,
struct wined3d_swapchain_desc swapchain_desc 
)

Definition at line 1147 of file device.c.

1149{
1150 struct wined3d_swapchain *swapchain = NULL;
1151 HRESULT hr;
1152
1153 TRACE("device %p, swapchain_desc %p.\n", device, swapchain_desc);
1154
1155 /* Setup the implicit swapchain */
1156 TRACE("Creating implicit swapchain\n");
1157 hr = device->device_parent->ops->create_swapchain(device->device_parent,
1158 swapchain_desc, &swapchain);
1159 if (FAILED(hr))
1160 {
1161 WARN("Failed to create implicit swapchain\n");
1162 goto err_out;
1163 }
1164
1165 device->swapchain_count = 1;
1166 if (!(device->swapchains = heap_calloc(device->swapchain_count, sizeof(*device->swapchains))))
1167 {
1168 ERR("Out of memory!\n");
1169 goto err_out;
1170 }
1171 device->swapchains[0] = swapchain;
1172
1173 if (!(device->blitter = wined3d_cpu_blitter_create()))
1174 {
1175 ERR("Failed to create CPU blitter.\n");
1176 heap_free(device->swapchains);
1177 device->swapchain_count = 0;
1178 goto err_out;
1179 }
1180
1181 return WINED3D_OK;
1182
1183err_out:
1184 wined3d_swapchain_decref(swapchain);
1185 return hr;
1186}
struct wined3d_blitter * wined3d_cpu_blitter_create(void)
Definition: surface.c:3983

Referenced by ddraw_create_swapchain().

◆ wined3d_device_multiply_transform()

void __cdecl wined3d_device_multiply_transform ( struct wined3d_device device,
enum wined3d_transform_state  state,
const struct wined3d_matrix matrix 
)

Definition at line 1548 of file device.c.

1550{
1551 const struct wined3d_matrix *mat;
1552 struct wined3d_matrix temp;
1553
1554 TRACE("device %p, state %s, matrix %p.\n", device, debug_d3dtstype(state), matrix);
1555
1556 /* Note: Using 'updateStateBlock' rather than 'stateblock' in the code
1557 * below means it will be recorded in a state block change, but it
1558 * works regardless where it is recorded.
1559 * If this is found to be wrong, change to StateBlock. */
1561 {
1562 WARN("Unhandled transform state %#x.\n", state);
1563 return;
1564 }
1565
1566 mat = &device->update_state->transforms[state];
1568
1569 /* Apply change via set transform - will reapply to eg. lights this way. */
1571}
void multiply_matrix(D3DMATRIX *dst, const D3DMATRIX *src1, const D3DMATRIX *src2) DECLSPEC_HIDDEN
Definition: utils.c:1173
void CDECL wined3d_device_set_transform(struct wined3d_device *device, enum wined3d_transform_state d3dts, const struct wined3d_matrix *matrix)
Definition: device.c:1505
static const MAT2 mat
Definition: font.c:66
static calc_node_t temp
Definition: rpn_ieee.c:38
#define HIGHEST_TRANSFORMSTATE

Referenced by d3d8_device_MultiplyTransform(), d3d9_device_MultiplyTransform(), and d3d_device7_MultiplyTransform().

◆ wined3d_device_process_vertices()

HRESULT __cdecl wined3d_device_process_vertices ( struct wined3d_device device,
UINT  src_start_idx,
UINT  dst_idx,
UINT  vertex_count,
struct wined3d_buffer dst_buffer,
const struct wined3d_vertex_declaration declaration,
DWORD  flags,
DWORD  dst_fvf 
)

Definition at line 3340 of file device.c.

3343{
3344 struct wined3d_state *state = &device->state;
3346 struct wined3d_resource *resource;
3347 struct wined3d_box box = {0};
3348 struct wined3d_shader *vs;
3349 unsigned int i;
3350 HRESULT hr;
3351 WORD map;
3352
3353 TRACE("device %p, src_start_idx %u, dst_idx %u, vertex_count %u, "
3354 "dst_buffer %p, declaration %p, flags %#x, dst_fvf %#x.\n",
3355 device, src_start_idx, dst_idx, vertex_count,
3356 dst_buffer, declaration, flags, dst_fvf);
3357
3358 if (declaration)
3359 FIXME("Output vertex declaration not implemented yet.\n");
3360
3363 wined3d_stream_info_from_declaration(&stream_info, state, &device->adapter->gl_info, &device->adapter->d3d_info);
3365
3366 /* We can't convert FROM a VBO, and vertex buffers used to source into
3367 * process_vertices() are unlikely to ever be used for drawing. Release
3368 * VBOs in those buffers and fix up the stream_info structure.
3369 *
3370 * Also apply the start index. */
3371 for (i = 0, map = stream_info.use_map; map; map >>= 1, ++i)
3372 {
3374 struct wined3d_map_desc map_desc;
3375
3376 if (!(map & 1))
3377 continue;
3378
3379 e = &stream_info.elements[i];
3380 resource = &state->streams[e->stream_idx].buffer->resource;
3381 box.left = src_start_idx * e->stride;
3382 box.right = box.left + vertex_count * e->stride;
3384 ERR("Failed to map resource.\n");
3385 e->data.buffer_object = 0;
3386 e->data.addr += (ULONG_PTR)map_desc.data;
3387 }
3388
3390 &stream_info, dst_buffer, flags, dst_fvf);
3391
3392 for (i = 0, map = stream_info.use_map; map; map >>= 1, ++i)
3393 {
3394 if (!(map & 1))
3395 continue;
3396
3397 resource = &state->streams[stream_info.elements[i].stream_idx].buffer->resource;
3399 ERR("Failed to unmap resource.\n");
3400 }
3401
3402 return hr;
3403}
Definition: _map.h:48
void wined3d_stream_info_from_declaration(struct wined3d_stream_info *stream_info, const struct wined3d_state *state, const struct wined3d_gl_info *gl_info, const struct wined3d_d3d_info *d3d_info)
Definition: context.c:3523
static HRESULT process_vertices_strided(const struct wined3d_device *device, DWORD dwDestIndex, DWORD dwCount, const struct wined3d_stream_info *stream_info, struct wined3d_buffer *dest, DWORD flags, DWORD DestFVF)
Definition: device.c:3070
HRESULT CDECL wined3d_resource_unmap(struct wined3d_resource *resource, unsigned int sub_resource_idx)
Definition: resource.c:382
HRESULT CDECL wined3d_resource_map(struct wined3d_resource *resource, unsigned int sub_resource_idx, struct wined3d_map_desc *map_desc, const struct wined3d_box *box, DWORD flags)
Definition: resource.c:344
#define ULONG_PTR
Definition: config.h:101
unsigned short WORD
Definition: ntddk_ex.h:93
#define e
Definition: ke_i.h:82
static void stream_info(IStream *stream, HGLOBAL *hmem, int *size, int *pos)
static vector_t * vs
Definition: server.c:127
#define WINED3D_MAP_READ
Definition: wined3d.h:939

Referenced by d3d8_device_ProcessVertices(), d3d9_device_ProcessVertices(), and d3d_vertex_buffer7_ProcessVertices().

◆ wined3d_device_release_focus_window()

void __cdecl wined3d_device_release_focus_window ( struct wined3d_device device)

Definition at line 954 of file device.c.

955{
956 TRACE("device %p.\n", device);
957
958 if (device->focus_window) wined3d_unregister_window(device->focus_window);
959 InterlockedExchangePointer((void **)&device->focus_window, NULL);
960}
void wined3d_unregister_window(HWND window)
Definition: wined3d_main.c:470

Referenced by d3d8_device_Release(), d3d9_device_Release(), ddraw_set_cooperative_level(), device_init(), swapchain_cleanup(), and wined3d_swapchain_set_fullscreen().

◆ wined3d_device_reset()

HRESULT __cdecl wined3d_device_reset ( struct wined3d_device device,
const struct wined3d_swapchain_desc swapchain_desc,
const struct wined3d_display_mode mode,
wined3d_device_reset_cb  callback,
BOOL  reset_state 
)

Definition at line 4771 of file device.c.

4774{
4776 struct wined3d_swapchain *swapchain;
4777 struct wined3d_view_desc view_desc;
4778 BOOL backbuffer_resized;
4780 unsigned int i;
4781
4782 TRACE("device %p, swapchain_desc %p, mode %p, callback %p, reset_state %#x.\n",
4783 device, swapchain_desc, mode, callback, reset_state);
4784
4785 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
4786
4787 if (!(swapchain = wined3d_device_get_swapchain(device, 0)))
4788 {
4789 ERR("Failed to get the first implicit swapchain.\n");
4791 }
4792
4793 if (reset_state)
4794 {
4795 if (device->logo_texture)
4796 {
4797 wined3d_texture_decref(device->logo_texture);
4798 device->logo_texture = NULL;
4799 }
4800 if (device->cursor_texture)
4801 {
4802 wined3d_texture_decref(device->cursor_texture);
4803 device->cursor_texture = NULL;
4804 }
4806 }
4807
4808 for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
4809 {
4811 }
4813
4814 if (reset_state)
4815 {
4816 LIST_FOR_EACH_ENTRY_SAFE(resource, cursor, &device->resources, struct wined3d_resource, resource_list_entry)
4817 {
4818 TRACE("Enumerating resource %p.\n", resource);
4819 if (FAILED(hr = callback(resource)))
4820 return hr;
4821 }
4822 }
4823
4824 TRACE("New params:\n");
4825 TRACE("backbuffer_width %u\n", swapchain_desc->backbuffer_width);
4826 TRACE("backbuffer_height %u\n", swapchain_desc->backbuffer_height);
4827 TRACE("backbuffer_format %s\n", debug_d3dformat(swapchain_desc->backbuffer_format));
4828 TRACE("backbuffer_count %u\n", swapchain_desc->backbuffer_count);
4829 TRACE("multisample_type %#x\n", swapchain_desc->multisample_type);
4830 TRACE("multisample_quality %u\n", swapchain_desc->multisample_quality);
4831 TRACE("swap_effect %#x\n", swapchain_desc->swap_effect);
4832 TRACE("device_window %p\n", swapchain_desc->device_window);
4833 TRACE("windowed %#x\n", swapchain_desc->windowed);
4834 TRACE("enable_auto_depth_stencil %#x\n", swapchain_desc->enable_auto_depth_stencil);
4835 if (swapchain_desc->enable_auto_depth_stencil)
4836 TRACE("auto_depth_stencil_format %s\n", debug_d3dformat(swapchain_desc->auto_depth_stencil_format));
4837 TRACE("flags %#x\n", swapchain_desc->flags);
4838 TRACE("refresh_rate %u\n", swapchain_desc->refresh_rate);
4839 TRACE("swap_interval %u\n", swapchain_desc->swap_interval);
4840 TRACE("auto_restore_display_mode %#x\n", swapchain_desc->auto_restore_display_mode);
4841
4842 if (swapchain_desc->backbuffer_usage != WINED3DUSAGE_RENDERTARGET)
4843 FIXME("Got unexpected backbuffer usage %#x.\n", swapchain_desc->backbuffer_usage);
4844
4845 if (swapchain_desc->swap_effect != WINED3D_SWAP_EFFECT_DISCARD
4846 && swapchain_desc->swap_effect != WINED3D_SWAP_EFFECT_SEQUENTIAL
4847 && swapchain_desc->swap_effect != WINED3D_SWAP_EFFECT_COPY)
4848 FIXME("Unimplemented swap effect %#x.\n", swapchain_desc->swap_effect);
4849
4850 /* No special treatment of these parameters. Just store them */
4851 swapchain->desc.swap_effect = swapchain_desc->swap_effect;
4852 swapchain->desc.enable_auto_depth_stencil = swapchain_desc->enable_auto_depth_stencil;
4853 swapchain->desc.auto_depth_stencil_format = swapchain_desc->auto_depth_stencil_format;
4854 swapchain->desc.flags = swapchain_desc->flags;
4855 swapchain->desc.refresh_rate = swapchain_desc->refresh_rate;
4856 swapchain->desc.swap_interval = swapchain_desc->swap_interval;
4857 swapchain->desc.auto_restore_display_mode = swapchain_desc->auto_restore_display_mode;
4858
4859 if (swapchain_desc->device_window
4860 && swapchain_desc->device_window != swapchain->desc.device_window)
4861 {
4862 TRACE("Changing the device window from %p to %p.\n",
4863 swapchain->desc.device_window, swapchain_desc->device_window);
4864 swapchain->desc.device_window = swapchain_desc->device_window;
4865 swapchain->device_window = swapchain_desc->device_window;
4867 }
4868
4869 backbuffer_resized = swapchain_desc->backbuffer_width != swapchain->desc.backbuffer_width
4870 || swapchain_desc->backbuffer_height != swapchain->desc.backbuffer_height;
4871
4872 if (!swapchain_desc->windowed != !swapchain->desc.windowed
4873 || swapchain->reapply_mode || mode
4874 || (!swapchain_desc->windowed && backbuffer_resized))
4875 {
4876 if (FAILED(hr = wined3d_swapchain_set_fullscreen(swapchain, swapchain_desc, mode)))
4877 return hr;
4878 }
4879 else if (!swapchain_desc->windowed)
4880 {
4881 DWORD style = device->style;
4882 DWORD exStyle = device->exStyle;
4883 /* If we're in fullscreen, and the mode wasn't changed, we have to get the window back into
4884 * the right position. Some applications(Battlefield 2, Guild Wars) move it and then call
4885 * Reset to clear up their mess. Guild Wars also loses the device during that.
4886 */
4887 device->style = 0;
4888 device->exStyle = 0;
4890 swapchain_desc->backbuffer_width,
4891 swapchain_desc->backbuffer_height);
4892 device->style = style;
4893 device->exStyle = exStyle;
4894 }
4895
4896 if (FAILED(hr = wined3d_swapchain_resize_buffers(swapchain, swapchain_desc->backbuffer_count,
4897 swapchain_desc->backbuffer_width, swapchain_desc->backbuffer_height, swapchain_desc->backbuffer_format,
4898 swapchain_desc->multisample_type, swapchain_desc->multisample_quality)))
4899 return hr;
4900
4901 if (device->auto_depth_stencil_view)
4902 {
4903 wined3d_rendertarget_view_decref(device->auto_depth_stencil_view);
4904 device->auto_depth_stencil_view = NULL;
4905 }
4906 if (swapchain->desc.enable_auto_depth_stencil)
4907 {
4908 struct wined3d_resource_desc texture_desc;
4909 struct wined3d_texture *texture;
4910 DWORD flags = 0;
4911
4912 TRACE("Creating the depth stencil buffer.\n");
4913
4914 texture_desc.resource_type = WINED3D_RTYPE_TEXTURE_2D;
4915 texture_desc.format = swapchain->desc.auto_depth_stencil_format;
4916 texture_desc.multisample_type = swapchain->desc.multisample_type;
4917 texture_desc.multisample_quality = swapchain->desc.multisample_quality;
4918 texture_desc.usage = WINED3DUSAGE_DEPTHSTENCIL;
4919 texture_desc.access = WINED3D_RESOURCE_ACCESS_GPU;
4920 texture_desc.width = swapchain->desc.backbuffer_width;
4921 texture_desc.height = swapchain->desc.backbuffer_height;
4922 texture_desc.depth = 1;
4923 texture_desc.size = 0;
4924
4925 if (swapchain_desc->flags & WINED3D_SWAPCHAIN_GDI_COMPATIBLE)
4927
4928 if (FAILED(hr = device->device_parent->ops->create_swapchain_texture(device->device_parent,
4929 device->device_parent, &texture_desc, flags, &texture)))
4930 {
4931 ERR("Failed to create the auto depth/stencil surface, hr %#x.\n", hr);
4933 }
4934
4935 view_desc.format_id = texture->resource.format->id;
4936 view_desc.flags = 0;
4937 view_desc.u.texture.level_idx = 0;
4938 view_desc.u.texture.level_count = 1;
4939 view_desc.u.texture.layer_idx = 0;
4940 view_desc.u.texture.layer_count = 1;
4941 hr = wined3d_rendertarget_view_create(&view_desc, &texture->resource,
4942 NULL, &wined3d_null_parent_ops, &device->auto_depth_stencil_view);
4944 if (FAILED(hr))
4945 {
4946 ERR("Failed to create rendertarget view, hr %#x.\n", hr);
4947 return hr;
4948 }
4949
4950 wined3d_device_set_depth_stencil_view(device, device->auto_depth_stencil_view);
4951 }
4952
4953 if (device->back_buffer_view)
4954 {
4955 wined3d_rendertarget_view_decref(device->back_buffer_view);
4956 device->back_buffer_view = NULL;
4957 }
4958 if (swapchain->desc.backbuffer_count)
4959 {
4960 struct wined3d_resource *back_buffer = &swapchain->back_buffers[0]->resource;
4961
4962 view_desc.format_id = back_buffer->format->id;
4963 view_desc.flags = 0;
4964 view_desc.u.texture.level_idx = 0;
4965 view_desc.u.texture.level_count = 1;
4966 view_desc.u.texture.layer_idx = 0;
4967 view_desc.u.texture.layer_count = 1;
4968 if (FAILED(hr = wined3d_rendertarget_view_create(&view_desc, back_buffer,
4969 NULL, &wined3d_null_parent_ops, &device->back_buffer_view)))
4970 {
4971 ERR("Failed to create rendertarget view, hr %#x.\n", hr);
4972 return hr;
4973 }
4974 }
4975
4977
4978 if (reset_state)
4979 {
4980 TRACE("Resetting stateblock.\n");
4981 if (device->recording)
4982 {
4984 device->recording = NULL;
4985 }
4987 state_cleanup(&device->state);
4988
4989 if (device->d3d_initialized)
4991
4992 memset(&device->state, 0, sizeof(device->state));
4993 state_init(&device->state, &device->fb, &device->adapter->gl_info,
4994 &device->adapter->d3d_info, WINED3D_STATE_INIT_DEFAULT);
4995 device->update_state = &device->state;
4996
5000 }
5001 else if (device->back_buffer_view)
5002 {
5003 struct wined3d_rendertarget_view *view = device->back_buffer_view;
5004 struct wined3d_state *state = &device->state;
5005
5007
5008 /* Note the min_z / max_z is not reset. */
5009 state->viewport.x = 0;
5010 state->viewport.y = 0;
5011 state->viewport.width = view->width;
5012 state->viewport.height = view->height;
5013 wined3d_cs_emit_set_viewport(device->cs, &state->viewport);
5014
5015 SetRect(&state->scissor_rect, 0, 0, view->width, view->height);
5016 wined3d_cs_emit_set_scissor_rect(device->cs, &state->scissor_rect);
5017 }
5018
5019 if (device->d3d_initialized)
5020 {
5021 if (reset_state)
5024 }
5025
5026 /* All done. There is no need to reload resources or shaders, this will happen automatically on the
5027 * first use
5028 */
5029 return hr;
5030}
Arabic default style
Definition: afstyles.h:94
void wined3d_cs_emit_set_scissor_rect(struct wined3d_cs *cs, const RECT *rect)
Definition: cs.c:988
void wined3d_cs_emit_set_viewport(struct wined3d_cs *cs, const struct wined3d_viewport *viewport)
Definition: cs.c:969
void wined3d_cs_emit_reset_state(struct wined3d_cs *cs)
Definition: cs.c:1856
void state_init(void *ipp)
Definition: dhclient.c:210
HRESULT CDECL wined3d_device_set_rendertarget_view(struct wined3d_device *device, unsigned int view_idx, struct wined3d_rendertarget_view *view, BOOL set_viewport)
Definition: device.c:4468
void CDECL wined3d_device_setup_fullscreen_window(struct wined3d_device *device, HWND window, UINT w, UINT h)
Definition: device.c:853
static void wined3d_device_delete_opengl_contexts(struct wined3d_device *device)
Definition: device.c:1011
void CDECL wined3d_device_set_depth_stencil_view(struct wined3d_device *device, struct wined3d_rendertarget_view *view)
Definition: device.c:4524
static void device_free_sampler(struct wine_rb_entry *entry, void *context)
Definition: device.c:1188
ULONG CDECL wined3d_texture_decref(struct wined3d_texture *texture)
Definition: texture.c:1023
static IPrintDialogCallback callback
Definition: printdlg.c:326
static void wine_rb_clear(struct wine_rb_tree *tree, wine_rb_traverse_func_t *callback, void *context)
Definition: rbtree.h:191
BOOL auto_restore_display_mode
Definition: wined3d.h:1747
enum wined3d_multisample_type multisample_type
Definition: wined3d.h:1737
enum wined3d_format_id auto_depth_stencil_format
Definition: wined3d.h:1743
enum wined3d_format_id backbuffer_format
Definition: wined3d.h:1734
enum wined3d_swap_effect swap_effect
Definition: wined3d.h:1739
struct wined3d_swapchain_desc desc
struct wined3d_swapchain * swapchain
void state_unbind_resources(struct wined3d_state *state)
Definition: stateblock.c:429
void swapchain_update_swap_interval(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:1144
void CDECL wined3d_swapchain_set_window(struct wined3d_swapchain *swapchain, HWND window)
Definition: swapchain.c:140
HRESULT CDECL wined3d_swapchain_resize_buffers(struct wined3d_swapchain *swapchain, unsigned int buffer_count, unsigned int width, unsigned int height, enum wined3d_format_id format_id, enum wined3d_multisample_type multisample_type, unsigned int multisample_quality)
Definition: swapchain.c:1200
HRESULT CDECL wined3d_swapchain_set_fullscreen(struct wined3d_swapchain *swapchain, const struct wined3d_swapchain_desc *swapchain_desc, const struct wined3d_display_mode *mode)
Definition: swapchain.c:1369
#define WINED3D_RESOURCE_ACCESS_GPU
Definition: wined3d.h:55
#define WINED3D_SWAPCHAIN_GDI_COMPATIBLE
Definition: wined3d.h:886
#define WINED3D_TEXTURE_CREATE_GET_DC
Definition: wined3d.h:1561
#define WINED3D_STATE_INIT_DEFAULT

Referenced by d3d8_device_Reset(), d3d9_device_reset(), and ddraw_surface_create().

◆ wined3d_device_resolve_sub_resource()

void __cdecl wined3d_device_resolve_sub_resource ( struct wined3d_device device,
struct wined3d_resource dst_resource,
unsigned int  dst_sub_resource_idx,
struct wined3d_resource src_resource,
unsigned int  src_sub_resource_idx,
enum wined3d_format_id  format_id 
)

Definition at line 4346 of file device.c.

4350{
4351 struct wined3d_texture *dst_texture, *src_texture;
4352 unsigned int dst_level, src_level;
4353 RECT dst_rect, src_rect;
4354
4355 TRACE("device %p, dst_resource %p, dst_sub_resource_idx %u, "
4356 "src_resource %p, src_sub_resource_idx %u, format %s.\n",
4357 device, dst_resource, dst_sub_resource_idx,
4358 src_resource, src_sub_resource_idx, debug_d3dformat(format_id));
4359
4360 if (wined3d_format_is_typeless(dst_resource->format)
4361 || wined3d_format_is_typeless(src_resource->format))
4362 {
4363 FIXME("Unhandled multisample resolve, dst_format %s, src_format %s, format %s.\n",
4364 debug_d3dformat(dst_resource->format->id), debug_d3dformat(src_resource->format->id),
4366 return;
4367 }
4368 if (dst_resource->type != WINED3D_RTYPE_TEXTURE_2D)
4369 {
4370 WARN("Invalid destination resource type %s.\n", debug_d3dresourcetype(dst_resource->type));
4371 return;
4372 }
4373 if (src_resource->type != WINED3D_RTYPE_TEXTURE_2D)
4374 {
4375 WARN("Invalid source resource type %s.\n", debug_d3dresourcetype(src_resource->type));
4376 return;
4377 }
4378
4379 dst_texture = texture_from_resource(dst_resource);
4380 src_texture = texture_from_resource(src_resource);
4381
4382 dst_level = dst_sub_resource_idx % dst_texture->level_count;
4383 SetRect(&dst_rect, 0, 0, wined3d_texture_get_level_width(dst_texture, dst_level),
4384 wined3d_texture_get_level_height(dst_texture, dst_level));
4385 src_level = src_sub_resource_idx % src_texture->level_count;
4386 SetRect(&src_rect, 0, 0, wined3d_texture_get_level_width(src_texture, src_level),
4387 wined3d_texture_get_level_height(src_texture, src_level));
4388 wined3d_texture_blt(dst_texture, dst_sub_resource_idx, &dst_rect,
4389 src_texture, src_sub_resource_idx, &src_rect, 0, NULL, WINED3D_TEXF_POINT);
4390}
HRESULT CDECL wined3d_texture_blt(struct wined3d_texture *dst_texture, unsigned int dst_sub_resource_idx, const RECT *dst_rect, struct wined3d_texture *src_texture, unsigned int src_sub_resource_idx, const RECT *src_rect, DWORD flags, const struct wined3d_blt_fx *fx, enum wined3d_texture_filter_type filter)
Definition: texture.c:3262
static BOOL wined3d_format_is_typeless(const struct wined3d_format *format)

Referenced by resolve_depth_buffer().

◆ wined3d_device_restore_fullscreen_window()

void __cdecl wined3d_device_restore_fullscreen_window ( struct wined3d_device device,
HWND  window,
const RECT window_rect 
)

Definition at line 885 of file device.c.

887{
888 unsigned int window_pos_flags = SWP_FRAMECHANGED | SWP_NOZORDER | SWP_NOACTIVATE;
889 BOOL filter_messages;
890 LONG style, exstyle;
891 RECT rect = {0};
892
893 if (!device->style && !device->exStyle)
894 return;
895
898
899 /* These flags are set by wined3d_device_setup_fullscreen_window, not the
900 * application, and we want to ignore them in the test below, since it's
901 * not the application's fault that they changed. Additionally, we want to
902 * preserve the current status of these flags (i.e. don't restore them) to
903 * more closely emulate the behavior of Direct3D, which leaves these flags
904 * alone when returning to windowed mode. */
905 device->style ^= (device->style ^ style) & WS_VISIBLE;
906 device->exStyle ^= (device->exStyle ^ exstyle) & WS_EX_TOPMOST;
907
908 TRACE("Restoring window style of window %p to %08x, %08x.\n",
909 window, device->style, device->exStyle);
910
911 filter_messages = device->filter_messages;
912 device->filter_messages = TRUE;
913
914 /* Only restore the style if the application didn't modify it during the
915 * fullscreen phase. Some applications change it before calling Reset()
916 * when switching between windowed and fullscreen modes (HL2), some
917 * depend on the original style (Eve Online). */
918 if (style == fullscreen_style(device->style) && exstyle == fullscreen_exstyle(device->exStyle))
919 {
922 }
923
924 if (window_rect)
925 rect = *window_rect;
926 else
927 window_pos_flags |= (SWP_NOMOVE | SWP_NOSIZE);
928 SetWindowPos(window, 0, rect.left, rect.top,
929 rect.right - rect.left, rect.bottom - rect.top, window_pos_flags);
930
931 device->filter_messages = filter_messages;
932
933 /* Delete the old values. */
934 device->style = 0;
935 device->exStyle = 0;
936}
static LONG fullscreen_style(LONG style)
Definition: device.c:836
static LONG fullscreen_exstyle(LONG exstyle)
Definition: device.c:845
#define WS_VISIBLE
Definition: pedump.c:620
#define WS_EX_TOPMOST
Definition: pedump.c:647
long LONG
Definition: pedump.c:60
#define SWP_NOACTIVATE
Definition: winuser.h:1242
#define SWP_FRAMECHANGED
Definition: winuser.h:1240
LONG WINAPI SetWindowLongW(_In_ HWND, _In_ int, _In_ LONG)
LONG WINAPI GetWindowLongW(_In_ HWND, _In_ int)
#define SWP_NOZORDER
Definition: winuser.h:1247
#define GWL_STYLE
Definition: winuser.h:852
#define GWL_EXSTYLE
Definition: winuser.h:851

Referenced by ddraw_set_cooperative_level(), swapchain_cleanup(), and wined3d_swapchain_set_fullscreen().

◆ wined3d_device_set_base_vertex_index()

void __cdecl wined3d_device_set_base_vertex_index ( struct wined3d_device device,
INT  base_index 
)

◆ wined3d_device_set_blend_state()

void __cdecl wined3d_device_set_blend_state ( struct wined3d_device device,
struct wined3d_blend_state blend_state 
)

Definition at line 1976 of file device.c.

1977{
1978 struct wined3d_blend_state *prev;
1979
1980 TRACE("device %p, blend_state %p.\n", device, blend_state);
1981
1982 prev = device->update_state->blend_state;
1983 if (prev == blend_state)
1984 return;
1985
1986 if (blend_state)
1987 wined3d_blend_state_incref(blend_state);
1988 device->update_state->blend_state = blend_state;
1989 wined3d_cs_emit_set_blend_state(device->cs, blend_state);
1990 if (prev)
1992}
void wined3d_cs_emit_set_blend_state(struct wined3d_cs *cs, struct wined3d_blend_state *state)
Definition: cs.c:1457
ULONG CDECL wined3d_blend_state_incref(struct wined3d_blend_state *state)
Definition: state.c:44
ULONG CDECL wined3d_blend_state_decref(struct wined3d_blend_state *state)
Definition: state.c:58

◆ wined3d_device_set_clip_plane()

HRESULT __cdecl wined3d_device_set_clip_plane ( struct wined3d_device device,
UINT  plane_idx,
const struct wined3d_vec4 plane 
)

Definition at line 1783 of file device.c.

1785{
1786 TRACE("device %p, plane_idx %u, plane %p.\n", device, plane_idx, plane);
1787
1788 if (plane_idx >= device->adapter->gl_info.limits.user_clip_distances)
1789 {
1790 TRACE("Application has requested clipplane this device doesn't support.\n");
1792 }
1793
1794 if (device->recording)
1795 device->recording->changed.clipplane |= 1u << plane_idx;
1796
1797 if (!memcmp(&device->update_state->clip_planes[plane_idx], plane, sizeof(*plane)))
1798 {
1799 TRACE("Application is setting old values over, nothing to do.\n");
1800 return WINED3D_OK;
1801 }
1802
1803 device->update_state->clip_planes[plane_idx] = *plane;
1804
1805 if (!device->recording)
1807
1808 return WINED3D_OK;
1809}
int memcmp(void *Buffer1, void *Buffer2, ACPI_SIZE Count)
Definition: utclib.c:112
void wined3d_cs_emit_set_clip_plane(struct wined3d_cs *cs, UINT plane_idx, const struct wined3d_vec4 *plane)
Definition: cs.c:1582

Referenced by d3d8_device_SetClipPlane(), d3d9_device_SetClipPlane(), d3d_device7_SetClipPlane(), and wined3d_stateblock_apply().

◆ wined3d_device_set_clip_status()

HRESULT __cdecl wined3d_device_set_clip_status ( struct wined3d_device device,
const struct wined3d_clip_status clip_status 
)

Definition at line 1827 of file device.c.

1829{
1830 FIXME("device %p, clip_status %p stub!\n", device, clip_status);
1831
1832 if (!clip_status)
1834
1835 return WINED3D_OK;
1836}

Referenced by d3d8_device_SetClipStatus(), and d3d9_device_SetClipStatus().

◆ wined3d_device_set_compute_shader()

void __cdecl wined3d_device_set_compute_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2930 of file device.c.

2931{
2932 struct wined3d_shader *prev;
2933
2934 TRACE("device %p, shader %p.\n", device, shader);
2935
2936 prev = device->update_state->shader[WINED3D_SHADER_TYPE_COMPUTE];
2937 if (device->recording || shader == prev)
2938 return;
2939 if (shader)
2941 device->update_state->shader[WINED3D_SHADER_TYPE_COMPUTE] = shader;
2943 if (prev)
2945}
void wined3d_cs_emit_set_shader(struct wined3d_cs *cs, enum wined3d_shader_type type, struct wined3d_shader *shader)
Definition: cs.c:1437
ULONG CDECL wined3d_shader_incref(struct wined3d_shader *shader)
Definition: shader.c:3339
ULONG CDECL wined3d_shader_decref(struct wined3d_shader *shader)
Definition: shader.c:3364
GLuint shader
Definition: glext.h:6030

◆ wined3d_device_set_cs_cb()

void __cdecl wined3d_device_set_cs_cb ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_buffer buffer 
)

Definition at line 2954 of file device.c.

2955{
2956 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2957
2959}
static void wined3d_device_set_constant_buffer(struct wined3d_device *device, enum wined3d_shader_type type, UINT idx, struct wined3d_buffer *buffer)
Definition: device.c:2214

◆ wined3d_device_set_cs_resource_view()

void __cdecl wined3d_device_set_cs_resource_view ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2968 of file device.c.

2970{
2971 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2972
2974}
static void wined3d_device_set_shader_resource_view(struct wined3d_device *device, enum wined3d_shader_type type, UINT idx, struct wined3d_shader_resource_view *view)
Definition: device.c:2264

◆ wined3d_device_set_cs_sampler()

void __cdecl wined3d_device_set_cs_sampler ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_sampler sampler 
)

Definition at line 2984 of file device.c.

2986{
2987 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2988
2990}
static void wined3d_device_set_sampler(struct wined3d_device *device, enum wined3d_shader_type type, UINT idx, struct wined3d_sampler *sampler)
Definition: device.c:2316
GLuint sampler
Definition: glext.h:7283

◆ wined3d_device_set_cs_uav()

void __cdecl wined3d_device_set_cs_uav ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_unordered_access_view uav,
unsigned int  initial_count 
)

Definition at line 3036 of file device.c.

3038{
3039 TRACE("device %p, idx %u, uav %p, initial_count %#x.\n", device, idx, uav, initial_count);
3040
3042}
static void wined3d_device_set_pipeline_unordered_access_view(struct wined3d_device *device, enum wined3d_pipeline pipeline, unsigned int idx, struct wined3d_unordered_access_view *uav, unsigned int initial_count)
Definition: device.c:2999

◆ wined3d_device_set_cursor_position()

void __cdecl wined3d_device_set_cursor_position ( struct wined3d_device device,
int  x_screen_space,
int  y_screen_space,
DWORD  flags 
)

Definition at line 4690 of file device.c.

4692{
4693 TRACE("device %p, x %d, y %d, flags %#x.\n",
4694 device, x_screen_space, y_screen_space, flags);
4695
4696 device->xScreenSpace = x_screen_space;
4697 device->yScreenSpace = y_screen_space;
4698
4699 if (device->hardwareCursor)
4700 {
4701 POINT pt;
4702
4703 GetCursorPos( &pt );
4704 if (x_screen_space == pt.x && y_screen_space == pt.y)
4705 return;
4706 SetCursorPos( x_screen_space, y_screen_space );
4707
4708 /* Switch to the software cursor if position diverges from the hardware one. */
4709 GetCursorPos( &pt );
4710 if (x_screen_space != pt.x || y_screen_space != pt.y)
4711 {
4712 if (device->bCursorVisible) SetCursor( NULL );
4713 DestroyCursor( device->hardwareCursor );
4714 device->hardwareCursor = 0;
4715 }
4716 }
4717}
#define pt(x, y)
Definition: drawing.c:79
BOOL WINAPI GetCursorPos(_Out_ LPPOINT)
Definition: cursoricon.c:2670
HCURSOR WINAPI SetCursor(_In_opt_ HCURSOR)
BOOL WINAPI SetCursorPos(_In_ int, _In_ int)
Definition: cursoricon.c:2662

Referenced by d3d8_device_SetCursorPosition(), and d3d9_device_SetCursorPosition().

◆ wined3d_device_set_cursor_properties()

HRESULT __cdecl wined3d_device_set_cursor_properties ( struct wined3d_device device,
UINT  x_hotspot,
UINT  y_hotspot,
struct wined3d_texture texture,
unsigned int  sub_resource_idx 
)

Definition at line 4587 of file device.c.

4589{
4590 unsigned int texture_level = sub_resource_idx % texture->level_count;
4591 unsigned int cursor_width, cursor_height;
4593 struct wined3d_map_desc map_desc;
4594 HRESULT hr;
4595
4596 TRACE("device %p, x_hotspot %u, y_hotspot %u, texture %p, sub_resource_idx %u.\n",
4597 device, x_hotspot, y_hotspot, texture, sub_resource_idx);
4598
4599 if (sub_resource_idx >= texture->level_count * texture->layer_count
4600 || texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
4602
4603 if (device->cursor_texture)
4604 {
4605 wined3d_texture_decref(device->cursor_texture);
4606 device->cursor_texture = NULL;
4607 }
4608
4609 if (texture->resource.format->id != WINED3DFMT_B8G8R8A8_UNORM)
4610 {
4611 WARN("Texture %p has invalid format %s.\n",
4612 texture, debug_d3dformat(texture->resource.format->id));
4614 }
4615
4616 if (FAILED(hr = wined3d_get_adapter_display_mode(device->wined3d, device->adapter->ordinal, &mode, NULL)))
4617 {
4618 ERR("Failed to get display mode, hr %#x.\n", hr);
4620 }
4621
4622 cursor_width = wined3d_texture_get_level_width(texture, texture_level);
4623 cursor_height = wined3d_texture_get_level_height(texture, texture_level);
4624 if (cursor_width > mode.width || cursor_height > mode.height)
4625 {
4626 WARN("Texture %p, sub-resource %u dimensions are %ux%u, but screen dimensions are %ux%u.\n",
4627 texture, sub_resource_idx, cursor_width, cursor_height, mode.width, mode.height);
4629 }
4630
4631 /* TODO: MSDN: Cursor sizes must be a power of 2 */
4632
4633 /* Do not store the surface's pointer because the application may
4634 * release it after setting the cursor image. Windows doesn't
4635 * addref the set surface, so we can't do this either without
4636 * creating circular refcount dependencies. */
4637 if (!(device->cursor_texture = wined3d_device_create_cursor_texture(device, texture, sub_resource_idx)))
4638 {
4639 ERR("Failed to create cursor texture.\n");
4641 }
4642
4643 if (cursor_width == 32 && cursor_height == 32)
4644 {
4645 UINT mask_size = cursor_width * cursor_height / 8;
4646 ICONINFO cursor_info;
4647 DWORD *mask_bits;
4649
4650 /* 32-bit user32 cursors ignore the alpha channel if it's all
4651 * zeroes, and use the mask instead. Fill the mask with all ones
4652 * to ensure we still get a fully transparent cursor. */
4653 if (!(mask_bits = heap_alloc(mask_size)))
4654 return E_OUTOFMEMORY;
4655 memset(mask_bits, 0xff, mask_size);
4656
4657 wined3d_resource_map(&texture->resource, sub_resource_idx, &map_desc, NULL,
4659 cursor_info.fIcon = FALSE;
4660 cursor_info.xHotspot = x_hotspot;
4661 cursor_info.yHotspot = y_hotspot;
4662 cursor_info.hbmMask = CreateBitmap(cursor_width, cursor_height, 1, 1, mask_bits);
4663 cursor_info.hbmColor = CreateBitmap(cursor_width, cursor_height, 1, 32, map_desc.data);
4664 wined3d_resource_unmap(&texture->resource, sub_resource_idx);
4665
4666 /* Create our cursor and clean up. */
4667 cursor = CreateIconIndirect(&cursor_info);
4668 if (cursor_info.hbmMask)
4669 DeleteObject(cursor_info.hbmMask);
4670 if (cursor_info.hbmColor)
4671 DeleteObject(cursor_info.hbmColor);
4672 if (device->hardwareCursor)
4673 DestroyCursor(device->hardwareCursor);
4674 device->hardwareCursor = cursor;
4675 if (device->bCursorVisible)
4677
4678 heap_free(mask_bits);
4679 }
4680
4681 TRACE("New cursor dimensions are %ux%u.\n", cursor_width, cursor_height);
4682 device->cursorWidth = cursor_width;
4683 device->cursorHeight = cursor_height;
4684 device->xHotSpot = x_hotspot;
4685 device->yHotSpot = y_hotspot;
4686
4687 return WINED3D_OK;
4688}
static void * heap_alloc(size_t len)
Definition: appwiz.h:66
static struct wined3d_texture * wined3d_device_create_cursor_texture(struct wined3d_device *device, struct wined3d_texture *cursor_image, unsigned int sub_resource_idx)
Definition: device.c:4544
pKey DeleteObject()
DWORD yHotspot
Definition: winuser.h:3125
BOOL fIcon
Definition: winuser.h:3123
DWORD xHotspot
Definition: winuser.h:3124
HBITMAP hbmColor
Definition: winuser.h:3127
HBITMAP hbmMask
Definition: winuser.h:3126
HICON HCURSOR
Definition: windef.h:299
HRESULT CDECL wined3d_get_adapter_display_mode(const struct wined3d *wined3d, UINT adapter_idx, struct wined3d_display_mode *mode, enum wined3d_display_rotation *rotation)
Definition: directx.c:4767
#define WINED3D_MAP_NO_DIRTY_UPDATE
Definition: wined3d.h:937
HBITMAP WINAPI CreateBitmap(_In_ INT cx, _In_ INT cy, _In_ UINT cPlanes, _In_ UINT cBitsPerPel, _In_opt_ const VOID *pvBits)
HICON WINAPI CreateIconIndirect(_In_ PICONINFO)
Definition: cursoricon.c:2581

Referenced by d3d8_device_SetCursorProperties(), and d3d9_device_SetCursorProperties().

◆ wined3d_device_set_depth_stencil_view()

void __cdecl wined3d_device_set_depth_stencil_view ( struct wined3d_device device,
struct wined3d_rendertarget_view view 
)

Definition at line 4524 of file device.c.

4525{
4526 struct wined3d_rendertarget_view *prev;
4527
4528 TRACE("device %p, view %p.\n", device, view);
4529
4530 prev = device->fb.depth_stencil;
4531 if (prev == view)
4532 {
4533 TRACE("Trying to do a NOP SetRenderTarget operation.\n");
4534 return;
4535 }
4536
4537 if ((device->fb.depth_stencil = view))
4540 if (prev)
4542}
void wined3d_cs_emit_set_depth_stencil_view(struct wined3d_cs *cs, struct wined3d_rendertarget_view *view)
Definition: cs.c:1057
ULONG CDECL wined3d_rendertarget_view_incref(struct wined3d_rendertarget_view *view)
Definition: view.c:318

Referenced by d3d8_device_SetRenderTarget(), d3d9_device_SetDepthStencilSurface(), d3d_device_update_depth_stencil(), ddraw_set_cooperative_level(), ddraw_surface_delete_attached_surface(), device_init_swapchain_state(), and wined3d_device_reset().

◆ wined3d_device_set_dialog_box_mode()

HRESULT __cdecl wined3d_device_set_dialog_box_mode ( struct wined3d_device device,
BOOL  enable_dialogs 
)

Definition at line 5032 of file device.c.

5033{
5034 TRACE("device %p, enable_dialogs %#x.\n", device, enable_dialogs);
5035
5036 if (!enable_dialogs) FIXME("Dialogs cannot be disabled yet.\n");
5037
5038 return WINED3D_OK;
5039}

Referenced by d3d9_device_SetDialogBoxMode().

◆ wined3d_device_set_domain_shader()

void __cdecl wined3d_device_set_domain_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2794 of file device.c.

2795{
2796 struct wined3d_shader *prev;
2797
2798 TRACE("device %p, shader %p.\n", device, shader);
2799
2800 prev = device->update_state->shader[WINED3D_SHADER_TYPE_DOMAIN];
2801 if (shader == prev)
2802 return;
2803 if (shader)
2805 device->update_state->shader[WINED3D_SHADER_TYPE_DOMAIN] = shader;
2807 if (prev)
2809}

◆ wined3d_device_set_ds_cb()

void __cdecl wined3d_device_set_ds_cb ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_buffer buffer 
)

Definition at line 2818 of file device.c.

2819{
2820 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2821
2823}

◆ wined3d_device_set_ds_resource_view()

void __cdecl wined3d_device_set_ds_resource_view ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2832 of file device.c.

2834{
2835 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2836
2838}

◆ wined3d_device_set_ds_sampler()

void __cdecl wined3d_device_set_ds_sampler ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_sampler sampler 
)

Definition at line 2848 of file device.c.

2850{
2851 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2852
2854}

◆ wined3d_device_set_gamma_ramp()

void __cdecl wined3d_device_set_gamma_ramp ( const struct wined3d_device device,
UINT  swapchain_idx,
DWORD  flags,
const struct wined3d_gamma_ramp ramp 
)

Definition at line 5057 of file device.c.

5059{
5060 struct wined3d_swapchain *swapchain;
5061
5062 TRACE("device %p, swapchain_idx %u, flags %#x, ramp %p.\n",
5063 device, swapchain_idx, flags, ramp);
5064
5065 if ((swapchain = wined3d_device_get_swapchain(device, swapchain_idx)))
5067}
HRESULT CDECL wined3d_swapchain_set_gamma_ramp(const struct wined3d_swapchain *swapchain, DWORD flags, const struct wined3d_gamma_ramp *ramp)
Definition: swapchain.c:279

Referenced by d3d8_device_SetGammaRamp(), d3d9_device_SetGammaRamp(), and ddraw_gamma_control_SetGammaRamp().

◆ wined3d_device_set_geometry_shader()

void __cdecl wined3d_device_set_geometry_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2863 of file device.c.

2864{
2865 struct wined3d_shader *prev = device->update_state->shader[WINED3D_SHADER_TYPE_GEOMETRY];
2866
2867 TRACE("device %p, shader %p.\n", device, shader);
2868
2869 if (device->recording || shader == prev)
2870 return;
2871 if (shader)
2873 device->update_state->shader[WINED3D_SHADER_TYPE_GEOMETRY] = shader;
2875 if (prev)
2877}

◆ wined3d_device_set_gs_cb()

void __cdecl wined3d_device_set_gs_cb ( struct wined3d_device device,
UINT  idx,
struct wined3d_buffer buffer 
)

Definition at line 2886 of file device.c.

2887{
2888 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2889
2891}

◆ wined3d_device_set_gs_resource_view()

void __cdecl wined3d_device_set_gs_resource_view ( struct wined3d_device device,
UINT  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2900 of file device.c.

2902{
2903 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2904
2906}

◆ wined3d_device_set_gs_sampler()

void __cdecl wined3d_device_set_gs_sampler ( struct wined3d_device device,
UINT  idx,
struct wined3d_sampler sampler 
)

Definition at line 2916 of file device.c.

2917{
2918 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2919
2921}

◆ wined3d_device_set_hs_cb()

void __cdecl wined3d_device_set_hs_cb ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_buffer buffer 
)

Definition at line 2749 of file device.c.

2750{
2751 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2752
2754}

◆ wined3d_device_set_hs_resource_view()

void __cdecl wined3d_device_set_hs_resource_view ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2763 of file device.c.

2765{
2766 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2767
2769}

◆ wined3d_device_set_hs_sampler()

void __cdecl wined3d_device_set_hs_sampler ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_sampler sampler 
)

Definition at line 2779 of file device.c.

2781{
2782 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2783
2785}

◆ wined3d_device_set_hull_shader()

void __cdecl wined3d_device_set_hull_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2725 of file device.c.

2726{
2727 struct wined3d_shader *prev;
2728
2729 TRACE("device %p, shader %p.\n", device, shader);
2730
2731 prev = device->update_state->shader[WINED3D_SHADER_TYPE_HULL];
2732 if (shader == prev)
2733 return;
2734 if (shader)
2736 device->update_state->shader[WINED3D_SHADER_TYPE_HULL] = shader;
2738 if (prev)
2740}

◆ wined3d_device_set_index_buffer()

void __cdecl wined3d_device_set_index_buffer ( struct wined3d_device device,
struct wined3d_buffer index_buffer,
enum wined3d_format_id  format_id,
unsigned int  offset 
)

Definition at line 1874 of file device.c.

1876{
1877 enum wined3d_format_id prev_format;
1878 struct wined3d_buffer *prev_buffer;
1879 unsigned int prev_offset;
1880
1881 TRACE("device %p, buffer %p, format %s, offset %u.\n",
1883
1884 prev_buffer = device->update_state->index_buffer;
1885 prev_format = device->update_state->index_format;
1886 prev_offset = device->update_state->index_offset;
1887
1888 device->update_state->index_buffer = buffer;
1889 device->update_state->index_format = format_id;
1890 device->update_state->index_offset = offset;
1891
1892 if (device->recording)
1893 device->recording->changed.indices = TRUE;
1894
1895 if (prev_buffer == buffer && prev_format == format_id && prev_offset == offset)
1896 return;
1897
1898 if (buffer)
1900 if (!device->recording)
1902 if (prev_buffer)
1903 wined3d_buffer_decref(prev_buffer);
1904}
void wined3d_cs_emit_set_index_buffer(struct wined3d_cs *cs, struct wined3d_buffer *buffer, enum wined3d_format_id format_id, unsigned int offset)
Definition: cs.c:1198
ULONG CDECL wined3d_buffer_incref(struct wined3d_buffer *buffer)
Definition: buffer.c:525
ULONG CDECL wined3d_buffer_decref(struct wined3d_buffer *buffer)
Definition: buffer.c:791
wined3d_format_id
Definition: wined3d.h:106

Referenced by d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_SetIndices(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_SetIndices(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), and wined3d_stateblock_apply().

◆ wined3d_device_set_light()

HRESULT __cdecl wined3d_device_set_light ( struct wined3d_device device,
UINT  light_idx,
const struct wined3d_light light 
)

Definition at line 1580 of file device.c.

1582{
1583 UINT hash_idx = LIGHTMAP_HASHFUNC(light_idx);
1584 struct wined3d_light_info *object = NULL;
1585 float rho;
1586
1587 TRACE("device %p, light_idx %u, light %p.\n", device, light_idx, light);
1588
1589 /* Check the parameter range. Need for speed most wanted sets junk lights
1590 * which confuse the GL driver. */
1591 if (!light)
1593
1594 switch (light->type)
1595 {
1597 case WINED3D_LIGHT_SPOT:
1599 /* Incorrect attenuation values can cause the gl driver to crash.
1600 * Happens with Need for speed most wanted. */
1601 if (light->attenuation0 < 0.0f || light->attenuation1 < 0.0f || light->attenuation2 < 0.0f)
1602 {
1603 WARN("Attenuation is negative, returning WINED3DERR_INVALIDCALL.\n");
1605 }
1606 break;
1607
1610 /* Ignores attenuation */
1611 break;
1612
1613 default:
1614 WARN("Light type out of range, returning WINED3DERR_INVALIDCALL\n");
1616 }
1617
1618 if (!(object = wined3d_state_get_light(device->update_state, light_idx)))
1619 {
1620 TRACE("Adding new light\n");
1621 if (!(object = heap_alloc_zero(sizeof(*object))))
1622 return E_OUTOFMEMORY;
1623
1624 list_add_head(&device->update_state->light_map[hash_idx], &object->entry);
1625 object->glIndex = -1;
1626 object->OriginalIndex = light_idx;
1627 }
1628
1629 /* Initialize the object. */
1630 TRACE("Light %u setting to type %#x, diffuse %s, specular %s, ambient %s, "
1631 "position {%.8e, %.8e, %.8e}, direction {%.8e, %.8e, %.8e}, "
1632 "range %.8e, falloff %.8e, theta %.8e, phi %.8e.\n",
1633 light_idx, light->type, debug_color(&light->diffuse),
1634 debug_color(&light->specular), debug_color(&light->ambient),
1635 light->position.x, light->position.y, light->position.z,
1636 light->direction.x, light->direction.y, light->direction.z,
1637 light->range, light->falloff, light->theta, light->phi);
1638
1639 /* Save away the information. */
1640 object->OriginalParms = *light;
1641
1642 switch (light->type)
1643 {
1645 /* Position */
1646 object->position.x = light->position.x;
1647 object->position.y = light->position.y;
1648 object->position.z = light->position.z;
1649 object->position.w = 1.0f;
1650 object->cutoff = 180.0f;
1651 /* FIXME: Range */
1652 break;
1653
1655 /* Direction */
1656 object->direction.x = -light->direction.x;
1657 object->direction.y = -light->direction.y;
1658 object->direction.z = -light->direction.z;
1659 object->direction.w = 0.0f;
1660 object->exponent = 0.0f;
1661 object->cutoff = 180.0f;
1662 break;
1663
1664 case WINED3D_LIGHT_SPOT:
1665 /* Position */
1666 object->position.x = light->position.x;
1667 object->position.y = light->position.y;
1668 object->position.z = light->position.z;
1669 object->position.w = 1.0f;
1670
1671 /* Direction */
1672 object->direction.x = light->direction.x;
1673 object->direction.y = light->direction.y;
1674 object->direction.z = light->direction.z;
1675 object->direction.w = 0.0f;
1676
1677 /* opengl-ish and d3d-ish spot lights use too different models
1678 * for the light "intensity" as a function of the angle towards
1679 * the main light direction, so we only can approximate very
1680 * roughly. However, spot lights are rather rarely used in games
1681 * (if ever used at all). Furthermore if still used, probably
1682 * nobody pays attention to such details. */
1683 if (!light->falloff)
1684 {
1685 /* Falloff = 0 is easy, because d3d's and opengl's spot light
1686 * equations have the falloff resp. exponent parameter as an
1687 * exponent, so the spot light lighting will always be 1.0 for
1688 * both of them, and we don't have to care for the rest of the
1689 * rather complex calculation. */
1690 object->exponent = 0.0f;
1691 }
1692 else
1693 {
1694 rho = light->theta + (light->phi - light->theta) / (2 * light->falloff);
1695 if (rho < 0.0001f)
1696 rho = 0.0001f;
1697 object->exponent = -0.3f / logf(cosf(rho / 2));
1698 }
1699
1700 if (object->exponent > 128.0f)
1701 object->exponent = 128.0f;
1702
1703 object->cutoff = (float)(light->phi * 90 / M_PI);
1704 /* FIXME: Range */
1705 break;
1706
1708 object->position.x = light->position.x;
1709 object->position.y = light->position.y;
1710 object->position.z = light->position.z;
1711 object->position.w = 1.0f;
1712 break;
1713
1714 default:
1715 FIXME("Unrecognized light type %#x.\n", light->type);
1716 }
1717
1718 if (!device->recording)
1719 wined3d_cs_emit_set_light(device->cs, object);
1720
1721 return WINED3D_OK;
1722}
static void list_add_head(struct list_entry *head, struct list_entry *entry)
Definition: list.h:76
void wined3d_cs_emit_set_light(struct wined3d_cs *cs, const struct wined3d_light_info *light)
Definition: cs.c:1733
_Check_return_ float __cdecl logf(_In_ float x)
Definition: math.h:229
_Check_return_ float __cdecl cosf(_In_ float x)
Definition: math.h:224
#define M_PI
Definition: macros.h:263
static float(__cdecl *square_half_float)(float x
#define LIGHTMAP_HASHFUNC(x)

Referenced by apply_lights(), d3d8_device_SetLight(), d3d9_device_SetLight(), d3d_device7_SetLight(), and wined3d_device_set_light_enable().

◆ wined3d_device_set_light_enable()

HRESULT __cdecl wined3d_device_set_light_enable ( struct wined3d_device device,
UINT  light_idx,
BOOL  enable 
)

Definition at line 1741 of file device.c.

1742{
1743 struct wined3d_light_info *light_info;
1744
1745 TRACE("device %p, light_idx %u, enable %#x.\n", device, light_idx, enable);
1746
1747 /* Special case - enabling an undefined light creates one with a strict set of parameters. */
1748 if (!(light_info = wined3d_state_get_light(device->update_state, light_idx)))
1749 {
1750 TRACE("Light enabled requested but light not defined, so defining one!\n");
1752
1753 if (!(light_info = wined3d_state_get_light(device->update_state, light_idx)))
1754 {
1755 FIXME("Adding default lights has failed dismally\n");
1757 }
1758 }
1759
1760 wined3d_state_enable_light(device->update_state, &device->adapter->d3d_info, light_info, enable);
1761 if (!device->recording)
1763
1764 return WINED3D_OK;
1765}
void wined3d_cs_emit_set_light_enable(struct wined3d_cs *cs, unsigned int idx, BOOL enable)
Definition: cs.c:1766
HRESULT CDECL wined3d_device_set_light(struct wined3d_device *device, UINT light_idx, const struct wined3d_light *light)
Definition: device.c:1580
const struct wined3d_light WINED3D_default_light
Definition: device.c:41
void wined3d_state_enable_light(struct wined3d_state *state, const struct wined3d_d3d_info *d3d_info, struct wined3d_light_info *light_info, BOOL enable)
Definition: stateblock.c:582

Referenced by apply_lights(), d3d8_device_LightEnable(), d3d9_device_LightEnable(), and d3d_device7_LightEnable().

◆ wined3d_device_set_material()

void __cdecl wined3d_device_set_material ( struct wined3d_device device,
const struct wined3d_material material 
)

Definition at line 1849 of file device.c.

1850{
1851 TRACE("device %p, material %p.\n", device, material);
1852
1853 device->update_state->material = *material;
1854
1855 if (device->recording)
1856 device->recording->changed.material = TRUE;
1857 else
1858 wined3d_cs_emit_set_material(device->cs, material);
1859}
void wined3d_cs_emit_set_material(struct wined3d_cs *cs, const struct wined3d_material *material)
Definition: cs.c:1685

Referenced by d3d8_device_SetMaterial(), d3d9_device_SetMaterial(), d3d_device7_SetMaterial(), and wined3d_stateblock_apply().

◆ wined3d_device_set_multithreaded()

void __cdecl wined3d_device_set_multithreaded ( struct wined3d_device device)

Definition at line 1290 of file device.c.

1291{
1292 TRACE("device %p.\n", device);
1293
1294 /* For now just store the flag (needed in case of ddraw). */
1295 device->create_parms.flags |= WINED3DCREATE_MULTITHREADED;
1296}
#define WINED3DCREATE_MULTITHREADED

Referenced by ddraw_set_cooperative_level(), and device_init().

◆ wined3d_device_set_npatch_mode()

HRESULT __cdecl wined3d_device_set_npatch_mode ( struct wined3d_device device,
float  segments 
)

Definition at line 3995 of file device.c.

3996{
3997 static BOOL warned;
3998
3999 TRACE("device %p, segments %.8e.\n", device, segments);
4000
4001 if (segments != 0.0f)
4002 {
4003 if (!warned)
4004 {
4005 FIXME("device %p, segments %.8e stub!\n", device, segments);
4006 warned = TRUE;
4007 }
4008 }
4009
4010 return WINED3D_OK;
4011}

Referenced by d3d9_device_SetNPatchMode().

◆ wined3d_device_set_pixel_shader()

void __cdecl wined3d_device_set_pixel_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2509 of file device.c.

2510{
2511 struct wined3d_shader *prev = device->update_state->shader[WINED3D_SHADER_TYPE_PIXEL];
2512
2513 TRACE("device %p, shader %p.\n", device, shader);
2514
2515 if (device->recording)
2516 device->recording->changed.pixelShader = TRUE;
2517
2518 if (shader == prev)
2519 return;
2520
2521 if (shader)
2523 device->update_state->shader[WINED3D_SHADER_TYPE_PIXEL] = shader;
2524 if (!device->recording)
2526 if (prev)
2528}

Referenced by d3d8_device_SetPixelShader(), d3d9_device_SetPixelShader(), and wined3d_stateblock_apply().

◆ wined3d_device_set_predication()

void __cdecl wined3d_device_set_predication ( struct wined3d_device device,
struct wined3d_query predicate,
BOOL  value 
)

Definition at line 3670 of file device.c.

3672{
3673 struct wined3d_query *prev;
3674
3675 TRACE("device %p, predicate %p, value %#x.\n", device, predicate, value);
3676
3677 prev = device->update_state->predicate;
3678 if (predicate)
3679 {
3680 FIXME("Predicated rendering not implemented.\n");
3681 wined3d_query_incref(predicate);
3682 }
3683 device->update_state->predicate = predicate;
3684 device->update_state->predicate_value = value;
3685 if (!device->recording)
3687 if (prev)
3689}
void wined3d_cs_emit_set_predication(struct wined3d_cs *cs, struct wined3d_query *predicate, BOOL value)
Definition: cs.c:949
ULONG CDECL wined3d_query_incref(struct wined3d_query *query)
Definition: query.c:326
ULONG CDECL wined3d_query_decref(struct wined3d_query *query)
Definition: query.c:349

◆ wined3d_device_set_primitive_type()

void __cdecl wined3d_device_set_primitive_type ( struct wined3d_device device,
enum wined3d_primitive_type  primitive_topology,
unsigned int  patch_vertex_count 
)

Definition at line 3717 of file device.c.

3719{
3720 TRACE("device %p, primitive_type %s, patch_vertex_count %u.\n",
3721 device, debug_d3dprimitivetype(primitive_type), patch_vertex_count);
3722
3723 device->state.gl_primitive_type = gl_primitive_type_from_d3d(primitive_type);
3724 device->state.gl_patch_vertices = patch_vertex_count;
3725}
GLenum gl_primitive_type_from_d3d(enum wined3d_primitive_type primitive_type)
Definition: device.c:58

Referenced by d3d8_device_DrawIndexedPrimitive(), d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_DrawPrimitive(), d3d8_device_DrawPrimitiveUP(), d3d9_device_DrawIndexedPrimitive(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawPrimitive(), d3d9_device_DrawPrimitiveUP(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), and d3d_device7_DrawPrimitiveVB().

◆ wined3d_device_set_ps_cb()

void __cdecl wined3d_device_set_ps_cb ( struct wined3d_device device,
UINT  idx,
struct wined3d_buffer buffer 
)

Definition at line 2537 of file device.c.

2538{
2539 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2540
2542}

◆ wined3d_device_set_ps_consts_b()

HRESULT __cdecl wined3d_device_set_ps_consts_b ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const BOOL constants 
)

Definition at line 2581 of file device.c.

2583{
2584 unsigned int i;
2585
2586 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2587 device, start_idx, count, constants);
2588
2589 if (!constants || start_idx >= WINED3D_MAX_CONSTS_B)
2591
2592 if (count > WINED3D_MAX_CONSTS_B - start_idx)
2593 count = WINED3D_MAX_CONSTS_B - start_idx;
2594 memcpy(&device->update_state->ps_consts_b[start_idx], constants, count * sizeof(*constants));
2595 if (TRACE_ON(d3d))
2596 {
2597 for (i = 0; i < count; ++i)
2598 TRACE("Set BOOL constant %u to %#x.\n", start_idx + i, constants[i]);
2599 }
2600
2601 if (device->recording)
2602 {
2603 for (i = start_idx; i < count + start_idx; ++i)
2604 device->recording->changed.pixelShaderConstantsB |= (1u << i);
2605 }
2606 else
2607 {
2609 }
2610
2611 return WINED3D_OK;
2612}
#define TRACE_ON(x)
Definition: compat.h:75
@ WINED3D_PUSH_CONSTANTS_PS_B

Referenced by d3d9_device_SetPixelShaderConstantB(), and wined3d_stateblock_apply().

◆ wined3d_device_set_ps_consts_f()

HRESULT __cdecl wined3d_device_set_ps_consts_f ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const struct wined3d_vec4 constants 
)

Definition at line 2679 of file device.c.

2681{
2682 const struct wined3d_d3d_info *d3d_info = &device->adapter->d3d_info;
2683 unsigned int i;
2684
2685 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2686 device, start_idx, count, constants);
2687
2688 if (!constants || start_idx >= d3d_info->limits.ps_uniform_count
2689 || count > d3d_info->limits.ps_uniform_count - start_idx)
2691
2692 memcpy(&device->update_state->ps_consts_f[start_idx], constants, count * sizeof(*constants));
2693 if (TRACE_ON(d3d))
2694 {
2695 for (i = 0; i < count; ++i)
2696 TRACE("Set vec4 constant %u to %s.\n", start_idx + i, debug_vec4(&constants[i]));
2697 }
2698
2699 if (device->recording)
2700 memset(&device->recording->changed.ps_consts_f[start_idx], 1,
2701 count * sizeof(*device->recording->changed.ps_consts_f));
2702 else
2704
2705 return WINED3D_OK;
2706}
const char * debug_vec4(const struct wined3d_vec4 *v)
Definition: utils.c:3972
@ WINED3D_PUSH_CONSTANTS_PS_F

Referenced by d3d8_device_SetPixelShaderConstant(), d3d9_device_SetPixelShaderConstantF(), and wined3d_stateblock_apply().

◆ wined3d_device_set_ps_consts_i()

HRESULT __cdecl wined3d_device_set_ps_consts_i ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const struct wined3d_ivec4 constants 
)

Definition at line 2630 of file device.c.

2632{
2633 unsigned int i;
2634
2635 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2636 device, start_idx, count, constants);
2637
2638 if (!constants || start_idx >= WINED3D_MAX_CONSTS_I)
2640
2641 if (count > WINED3D_MAX_CONSTS_I - start_idx)
2642 count = WINED3D_MAX_CONSTS_I - start_idx;
2643 memcpy(&device->update_state->ps_consts_i[start_idx], constants, count * sizeof(*constants));
2644 if (TRACE_ON(d3d))
2645 {
2646 for (i = 0; i < count; ++i)
2647 TRACE("Set ivec4 constant %u to %s.\n", start_idx + i, debug_ivec4(&constants[i]));
2648 }
2649
2650 if (device->recording)
2651 {
2652 for (i = start_idx; i < count + start_idx; ++i)
2653 device->recording->changed.pixelShaderConstantsI |= (1u << i);
2654 }
2655 else
2656 {
2658 }
2659
2660 return WINED3D_OK;
2661}
const char * debug_ivec4(const struct wined3d_ivec4 *v)
Definition: utils.c:3956
@ WINED3D_PUSH_CONSTANTS_PS_I

Referenced by d3d9_device_SetPixelShaderConstantI(), and wined3d_stateblock_apply().

◆ wined3d_device_set_ps_resource_view()

void __cdecl wined3d_device_set_ps_resource_view ( struct wined3d_device device,
UINT  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2551 of file device.c.

2553{
2554 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2555
2557}

◆ wined3d_device_set_ps_sampler()

void __cdecl wined3d_device_set_ps_sampler ( struct wined3d_device device,
UINT  idx,
struct wined3d_sampler sampler 
)

Definition at line 2567 of file device.c.

2568{
2569 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2570
2572}

◆ wined3d_device_set_rasterizer_state()

void __cdecl wined3d_device_set_rasterizer_state ( struct wined3d_device device,
struct wined3d_rasterizer_state rasterizer_state 
)

Definition at line 2001 of file device.c.

2003{
2004 struct wined3d_rasterizer_state *prev;
2005
2006 TRACE("device %p, rasterizer_state %p.\n", device, rasterizer_state);
2007
2008 prev = device->update_state->rasterizer_state;
2009 if (prev == rasterizer_state)
2010 return;
2011
2012 if (rasterizer_state)
2013 wined3d_rasterizer_state_incref(rasterizer_state);
2014 device->update_state->rasterizer_state = rasterizer_state;
2015 wined3d_cs_emit_set_rasterizer_state(device->cs, rasterizer_state);
2016 if (prev)
2018}
void wined3d_cs_emit_set_rasterizer_state(struct wined3d_cs *cs, struct wined3d_rasterizer_state *rasterizer_state)
Definition: cs.c:1476
ULONG CDECL wined3d_rasterizer_state_incref(struct wined3d_rasterizer_state *state)
Definition: state.c:105
ULONG CDECL wined3d_rasterizer_state_decref(struct wined3d_rasterizer_state *state)
Definition: state.c:119

◆ wined3d_device_set_render_state()

void __cdecl wined3d_device_set_render_state ( struct wined3d_device device,
enum wined3d_render_state  state,
DWORD  value 
)

Definition at line 2027 of file device.c.

2029{
2031
2032 TRACE("device %p, state %s (%#x), value %#x.\n", device, debug_d3drenderstate(state), state, value);
2033
2035 {
2036 WARN("Unhandled render state %#x.\n", state);
2037 return;
2038 }
2039
2040 old_value = device->state.render_states[state];
2041 device->update_state->render_states[state] = value;
2042
2043 /* Handle recording of state blocks. */
2044 if (device->recording)
2045 {
2046 TRACE("Recording... not performing anything.\n");
2047 device->recording->changed.renderState[state >> 5] |= 1u << (state & 0x1f);
2048 return;
2049 }
2050
2051 /* Compared here and not before the assignment to allow proper stateblock recording. */
2052 if (value == old_value)
2053 TRACE("Application is setting the old value over, nothing to do.\n");
2054 else
2056
2058 {
2059 TRACE("RESZ multisampled depth buffer resolve triggered.\n");
2061 }
2062}
void wined3d_cs_emit_set_render_state(struct wined3d_cs *cs, enum wined3d_render_state state, DWORD value)
Definition: cs.c:1496
static void resolve_depth_buffer(struct wined3d_device *device)
Definition: device.c:1957
static ULONG * old_value
Definition: directory.c:54
#define WINED3D_RESZ_CODE
Definition: wined3d.h:1332
#define WINEHIGHEST_RENDER_STATE
Definition: wined3d.h:398

Referenced by d3d8_device_Reset(), d3d8_device_SetRenderState(), d3d9_device_reset(), d3d9_device_SetRenderState(), d3d_device7_SetRenderState(), d3d_device_init(), d3d_vertex_buffer7_ProcessVertices(), ddraw_surface_create(), device_init(), setup_lighting(), and wined3d_stateblock_apply().

◆ wined3d_device_set_rendertarget_view()

HRESULT __cdecl wined3d_device_set_rendertarget_view ( struct wined3d_device device,
unsigned int  view_idx,
struct wined3d_rendertarget_view view,
BOOL  set_viewport 
)

Definition at line 4468 of file device.c.

4470{
4471 struct wined3d_rendertarget_view *prev;
4472
4473 TRACE("device %p, view_idx %u, view %p, set_viewport %#x.\n",
4474 device, view_idx, view, set_viewport);
4475
4476 if (view_idx >= device->adapter->gl_info.limits.buffers)
4477 {
4478 WARN("Only %u render targets are supported.\n", device->adapter->gl_info.limits.buffers);
4480 }
4481
4482 if (view && !(view->resource->usage & WINED3DUSAGE_RENDERTARGET))
4483 {
4484 WARN("View resource %p doesn't have render target usage.\n", view->resource);
4486 }
4487
4488 /* Set the viewport and scissor rectangles, if requested. Tests show that
4489 * stateblock recording is ignored, the change goes directly into the
4490 * primary stateblock. */
4491 if (!view_idx && set_viewport)
4492 {
4493 struct wined3d_state *state = &device->state;
4494
4495 state->viewport.x = 0;
4496 state->viewport.y = 0;
4497 state->viewport.width = view->width;
4498 state->viewport.height = view->height;
4499 state->viewport.min_z = 0.0f;
4500 state->viewport.max_z = 1.0f;
4501 wined3d_cs_emit_set_viewport(device->cs, &state->viewport);
4502
4503 SetRect(&state->scissor_rect, 0, 0, view->width, view->height);
4504 wined3d_cs_emit_set_scissor_rect(device->cs, &state->scissor_rect);
4505 }
4506
4507
4508 prev = device->fb.render_targets[view_idx];
4509 if (view == prev)
4510 return WINED3D_OK;
4511
4512 if (view)
4514 device->fb.render_targets[view_idx] = view;
4516 /* Release after the assignment, to prevent device_resource_released()
4517 * from seeing the surface as still in use. */
4518 if (prev)
4520
4521 return WINED3D_OK;
4522}
void wined3d_cs_emit_set_rendertarget_view(struct wined3d_cs *cs, unsigned int view_idx, struct wined3d_rendertarget_view *view)
Definition: cs.c:1007

Referenced by d3d8_device_SetRenderTarget(), d3d9_device_SetRenderTarget(), d3d_device_init(), d3d_device_inner_Release(), d3d_device_set_render_target(), ddraw_set_cooperative_level(), ddraw_surface7_Flip(), device_init_swapchain_state(), wined3d_device_reset(), and wined3d_device_uninit_3d().

◆ wined3d_device_set_sampler_state()

void __cdecl wined3d_device_set_sampler_state ( struct wined3d_device device,
UINT  sampler_idx,
enum wined3d_sampler_state  state,
DWORD  value 
)

Definition at line 2071 of file device.c.

2073{
2075
2076 TRACE("device %p, sampler_idx %u, state %s, value %#x.\n",
2077 device, sampler_idx, debug_d3dsamplerstate(state), value);
2078
2079 if (sampler_idx >= WINED3DVERTEXTEXTURESAMPLER0 && sampler_idx <= WINED3DVERTEXTEXTURESAMPLER3)
2081
2082 if (sampler_idx >= ARRAY_SIZE(device->state.sampler_states))
2083 {
2084 WARN("Invalid sampler %u.\n", sampler_idx);
2085 return; /* Windows accepts overflowing this array ... we do not. */
2086 }
2087
2088 old_value = device->state.sampler_states[sampler_idx][state];
2089 device->update_state->sampler_states[sampler_idx][state] = value;
2090
2091 /* Handle recording of state blocks. */
2092 if (device->recording)
2093 {
2094 TRACE("Recording... not performing anything.\n");
2095 device->recording->changed.samplerState[sampler_idx] |= 1u << state;
2096 return;
2097 }
2098
2099 if (old_value == value)
2100 {
2101 TRACE("Application is setting the old value over, nothing to do.\n");
2102 return;
2103 }
2104
2106}
void wined3d_cs_emit_set_sampler_state(struct wined3d_cs *cs, UINT sampler_idx, enum wined3d_sampler_state state, DWORD value)
Definition: cs.c:1538

Referenced by d3d8_device_SetTextureStageState(), d3d9_device_SetSamplerState(), d3d_device7_SetRenderState(), d3d_device7_SetTextureStageState(), and wined3d_stateblock_apply().

◆ wined3d_device_set_scissor_rect()

void __cdecl wined3d_device_set_scissor_rect ( struct wined3d_device device,
const RECT rect 
)

Definition at line 2126 of file device.c.

2127{
2128 TRACE("device %p, rect %s.\n", device, wine_dbgstr_rect(rect));
2129
2130 if (device->recording)
2131 device->recording->changed.scissorRect = TRUE;
2132
2133 if (EqualRect(&device->update_state->scissor_rect, rect))
2134 {
2135 TRACE("App is setting the old scissor rectangle over, nothing to do.\n");
2136 return;
2137 }
2138 CopyRect(&device->update_state->scissor_rect, rect);
2139
2140 if (device->recording)
2141 {
2142 TRACE("Recording... not performing anything.\n");
2143 return;
2144 }
2145
2147}
BOOL WINAPI CopyRect(_Out_ LPRECT, _In_ LPCRECT)
BOOL WINAPI EqualRect(_In_ LPCRECT, _In_ LPCRECT)

Referenced by d3d9_device_SetScissorRect(), and wined3d_stateblock_apply().

◆ wined3d_device_set_software_vertex_processing()

void __cdecl wined3d_device_set_software_vertex_processing ( struct wined3d_device device,
BOOL  software 
)

Definition at line 3967 of file device.c.

3968{
3969 TRACE("device %p, software %#x.\n", device, software);
3970
3971 device->softwareVertexProcessing = software;
3972}

Referenced by d3d9_device_SetSoftwareVertexProcessing().

◆ wined3d_device_set_stream_output()

void __cdecl wined3d_device_set_stream_output ( struct wined3d_device device,
UINT  idx,
struct wined3d_buffer buffer,
UINT  offset 
)

Definition at line 1335 of file device.c.

1337{
1339 struct wined3d_buffer *prev_buffer;
1340
1341 TRACE("device %p, idx %u, buffer %p, offset %u.\n", device, idx, buffer, offset);
1342
1344 {
1345 WARN("Invalid stream output %u.\n", idx);
1346 return;
1347 }
1348
1349 stream = &device->update_state->stream_output[idx];
1350 prev_buffer = stream->buffer;
1351
1352 if (buffer)
1354 stream->buffer = buffer;
1355 stream->offset = offset;
1356 if (!device->recording)
1358 if (prev_buffer)
1359 wined3d_buffer_decref(prev_buffer);
1360}
void wined3d_cs_emit_set_stream_output(struct wined3d_cs *cs, UINT stream_idx, struct wined3d_buffer *buffer, UINT offset)
Definition: cs.c:1166

◆ wined3d_device_set_stream_source()

HRESULT __cdecl wined3d_device_set_stream_source ( struct wined3d_device device,
UINT  stream_idx,
struct wined3d_buffer buffer,
UINT  offset,
UINT  stride 
)

Definition at line 1378 of file device.c.

1380{
1382 struct wined3d_buffer *prev_buffer;
1383
1384 TRACE("device %p, stream_idx %u, buffer %p, offset %u, stride %u.\n",
1385 device, stream_idx, buffer, offset, stride);
1386
1387 if (stream_idx >= MAX_STREAMS)
1388 {
1389 WARN("Stream index %u out of range.\n", stream_idx);
1391 }
1392 else if (offset & 0x3)
1393 {
1394 WARN("Offset %u is not 4 byte aligned.\n", offset);
1396 }
1397
1398 stream = &device->update_state->streams[stream_idx];
1399 prev_buffer = stream->buffer;
1400
1401 if (device->recording)
1402 device->recording->changed.streamSource |= 1u << stream_idx;
1403
1404 if (prev_buffer == buffer
1405 && stream->stride == stride
1406 && stream->offset == offset)
1407 {
1408 TRACE("Application is setting the old values over, nothing to do.\n");
1409 return WINED3D_OK;
1410 }
1411
1412 stream->buffer = buffer;
1413 if (buffer)
1414 {
1415 stream->stride = stride;
1416 stream->offset = offset;
1418 }
1419
1420 if (!device->recording)
1422 if (prev_buffer)
1423 wined3d_buffer_decref(prev_buffer);
1424
1425 return WINED3D_OK;
1426}
void wined3d_cs_emit_set_stream_source(struct wined3d_cs *cs, UINT stream_idx, struct wined3d_buffer *buffer, UINT offset, UINT stride)
Definition: cs.c:1107

Referenced by d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_DrawPrimitiveUP(), d3d8_device_SetStreamSource(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawPrimitiveUP(), d3d9_device_SetStreamSource(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), d3d_device7_DrawPrimitiveVB(), d3d_vertex_buffer7_ProcessVertices(), d3d_vertex_buffer7_Release(), and wined3d_stateblock_apply().

◆ wined3d_device_set_stream_source_freq()

HRESULT __cdecl wined3d_device_set_stream_source_freq ( struct wined3d_device device,
UINT  stream_idx,
UINT  divider 
)

Definition at line 1451 of file device.c.

1452{
1454 UINT old_flags, old_freq;
1455
1456 TRACE("device %p, stream_idx %u, divider %#x.\n", device, stream_idx, divider);
1457
1458 /* Verify input. At least in d3d9 this is invalid. */
1460 {
1461 WARN("INSTANCEDATA and INDEXEDDATA were set, returning D3DERR_INVALIDCALL.\n");
1463 }
1464 if ((divider & WINED3DSTREAMSOURCE_INSTANCEDATA) && !stream_idx)
1465 {
1466 WARN("INSTANCEDATA used on stream 0, returning D3DERR_INVALIDCALL.\n");
1468 }
1469 if (!divider)
1470 {
1471 WARN("Divider is 0, returning D3DERR_INVALIDCALL.\n");
1473 }
1474
1475 stream = &device->update_state->streams[stream_idx];
1476 old_flags = stream->flags;
1477 old_freq = stream->frequency;
1478
1480 stream->frequency = divider & 0x7fffff;
1481
1482 if (device->recording)
1483 device->recording->changed.streamFreq |= 1u << stream_idx;
1484 else if (stream->frequency != old_freq || stream->flags != old_flags)
1485 wined3d_cs_emit_set_stream_source_freq(device->cs, stream_idx, stream->frequency, stream->flags);
1486
1487 return WINED3D_OK;
1488}
void wined3d_cs_emit_set_stream_source_freq(struct wined3d_cs *cs, UINT stream_idx, UINT frequency, UINT flags)
Definition: cs.c:1134
#define WINED3DSTREAMSOURCE_INSTANCEDATA
Definition: wined3d.h:1003
#define WINED3DSTREAMSOURCE_INDEXEDDATA
Definition: wined3d.h:1002

Referenced by d3d9_device_SetStreamSourceFreq(), and wined3d_stateblock_apply().

◆ wined3d_device_set_texture()

HRESULT __cdecl wined3d_device_set_texture ( struct wined3d_device device,
UINT  stage,
struct wined3d_texture texture 
)

Definition at line 3462 of file device.c.

3464{
3465 struct wined3d_texture *prev;
3466
3467 TRACE("device %p, stage %u, texture %p.\n", device, stage, texture);
3468
3471
3472 /* Windows accepts overflowing this array... we do not. */
3473 if (stage >= ARRAY_SIZE(device->state.textures))
3474 {
3475 WARN("Ignoring invalid stage %u.\n", stage);
3476 return WINED3D_OK;
3477 }
3478
3479 if (texture && texture->resource.usage & WINED3DUSAGE_SCRATCH)
3480 {
3481 WARN("Rejecting attempt to set scratch texture.\n");
3483 }
3484
3485 if (device->recording)
3486 device->recording->changed.textures |= 1u << stage;
3487
3488 prev = device->update_state->textures[stage];
3489 TRACE("Previous texture %p.\n", prev);
3490
3491 if (texture == prev)
3492 {
3493 TRACE("App is setting the same texture again, nothing to do.\n");
3494 return WINED3D_OK;
3495 }
3496
3497 TRACE("Setting new texture to %p.\n", texture);
3498 device->update_state->textures[stage] = texture;
3499
3500 if (texture)
3502 if (!device->recording)
3504 if (prev)
3506
3507 return WINED3D_OK;
3508}
void wined3d_cs_emit_set_texture(struct wined3d_cs *cs, UINT stage, struct wined3d_texture *texture)
Definition: cs.c:1321
ULONG CDECL wined3d_texture_incref(struct wined3d_texture *texture)
Definition: texture.c:994
#define WINED3DUSAGE_SCRATCH
Definition: wined3d.h:915

Referenced by d3d8_device_SetTexture(), d3d9_device_SetTexture(), d3d_device3_SetRenderState(), d3d_device7_SetTexture(), and wined3d_stateblock_apply().

◆ wined3d_device_set_texture_stage_state()

void __cdecl wined3d_device_set_texture_stage_state ( struct wined3d_device device,
UINT  stage,
enum wined3d_texture_stage_state  state,
DWORD  value 
)

Definition at line 3405 of file device.c.

3407{
3408 const struct wined3d_d3d_info *d3d_info = &device->adapter->d3d_info;
3410
3411 TRACE("device %p, stage %u, state %s, value %#x.\n",
3413
3415 {
3416 WARN("Invalid state %#x passed.\n", state);
3417 return;
3418 }
3419
3420 if (stage >= d3d_info->limits.ffp_blend_stages)
3421 {
3422 WARN("Attempting to set stage %u which is higher than the max stage %u, ignoring.\n",
3423 stage, d3d_info->limits.ffp_blend_stages - 1);
3424 return;
3425 }
3426
3427 old_value = device->update_state->texture_states[stage][state];
3428 device->update_state->texture_states[stage][state] = value;
3429
3430 if (device->recording)
3431 {
3432 TRACE("Recording... not performing anything.\n");
3433 device->recording->changed.textureState[stage] |= 1u << state;
3434 return;
3435 }
3436
3437 /* Checked after the assignments to allow proper stateblock recording. */
3438 if (old_value == value)
3439 {
3440 TRACE("Application is setting the old value over, nothing to do.\n");
3441 return;
3442 }
3443
3445}
void wined3d_cs_emit_set_texture_state(struct wined3d_cs *cs, UINT stage, enum wined3d_texture_stage_state state, DWORD value)
Definition: cs.c:1516

Referenced by d3d8_device_SetTextureStageState(), d3d9_device_SetTextureStageState(), d3d_device3_SetRenderState(), d3d_device3_SetTexture(), d3d_device7_SetTextureStageState(), and wined3d_stateblock_apply().

◆ wined3d_device_set_transform()

void __cdecl wined3d_device_set_transform ( struct wined3d_device device,
enum wined3d_transform_state  state,
const struct wined3d_matrix matrix 
)

Definition at line 1505 of file device.c.

1507{
1508 TRACE("device %p, state %s, matrix %p.\n",
1509 device, debug_d3dtstype(d3dts), matrix);
1510 TRACE("%.8e %.8e %.8e %.8e\n", matrix->_11, matrix->_12, matrix->_13, matrix->_14);
1511 TRACE("%.8e %.8e %.8e %.8e\n", matrix->_21, matrix->_22, matrix->_23, matrix->_24);
1512 TRACE("%.8e %.8e %.8e %.8e\n", matrix->_31, matrix->_32, matrix->_33, matrix->_34);
1513 TRACE("%.8e %.8e %.8e %.8e\n", matrix->_41, matrix->_42, matrix->_43, matrix->_44);
1514
1515 /* Handle recording of state blocks. */
1516 if (device->recording)
1517 {
1518 TRACE("Recording... not performing anything.\n");
1519 device->recording->changed.transform[d3dts >> 5] |= 1u << (d3dts & 0x1f);
1520 device->update_state->transforms[d3dts] = *matrix;
1521 return;
1522 }
1523
1524 /* If the new matrix is the same as the current one,
1525 * we cut off any further processing. this seems to be a reasonable
1526 * optimization because as was noticed, some apps (warcraft3 for example)
1527 * tend towards setting the same matrix repeatedly for some reason.
1528 *
1529 * From here on we assume that the new matrix is different, wherever it matters. */
1530 if (!memcmp(&device->state.transforms[d3dts], matrix, sizeof(*matrix)))
1531 {
1532 TRACE("The application is setting the same matrix over again.\n");
1533 return;
1534 }
1535
1536 device->state.transforms[d3dts] = *matrix;
1538}
void wined3d_cs_emit_set_transform(struct wined3d_cs *cs, enum wined3d_transform_state state, const struct wined3d_matrix *matrix)
Definition: cs.c:1561

Referenced by d3d8_device_SetTransform(), d3d9_device_SetTransform(), d3d_device1_SetMatrix(), d3d_device3_MultiplyTransform(), d3d_device3_SetTransform(), d3d_device7_SetTransform(), update_clip_space(), wined3d_device_multiply_transform(), and wined3d_stateblock_apply().

◆ wined3d_device_set_unordered_access_view()

void __cdecl wined3d_device_set_unordered_access_view ( struct wined3d_device device,
unsigned int  idx,
struct wined3d_unordered_access_view uav,
unsigned int  initial_count 
)

Definition at line 3052 of file device.c.

3054{
3055 TRACE("device %p, idx %u, uav %p, initial_count %#x.\n", device, idx, uav, initial_count);
3056
3058}

◆ wined3d_device_set_vertex_declaration()

void __cdecl wined3d_device_set_vertex_declaration ( struct wined3d_device device,
struct wined3d_vertex_declaration declaration 
)

Definition at line 2157 of file device.c.

2159{
2160 struct wined3d_vertex_declaration *prev = device->update_state->vertex_declaration;
2161
2162 TRACE("device %p, declaration %p.\n", device, declaration);
2163
2164 if (device->recording)
2165 device->recording->changed.vertexDecl = TRUE;
2166
2167 if (declaration == prev)
2168 return;
2169
2170 if (declaration)
2172 device->update_state->vertex_declaration = declaration;
2173 if (!device->recording)
2175 if (prev)
2177}
void wined3d_cs_emit_set_vertex_declaration(struct wined3d_cs *cs, struct wined3d_vertex_declaration *declaration)
Definition: cs.c:1076
ULONG CDECL wined3d_vertex_declaration_incref(struct wined3d_vertex_declaration *declaration)
ULONG CDECL wined3d_vertex_declaration_decref(struct wined3d_vertex_declaration *declaration)

Referenced by d3d8_device_SetVertexShader(), d3d9_device_SetFVF(), d3d9_device_SetVertexDeclaration(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), d3d_device7_DrawPrimitiveVB(), d3d_vertex_buffer7_ProcessVertices(), and wined3d_stateblock_apply().

◆ wined3d_device_set_vertex_shader()

void __cdecl wined3d_device_set_vertex_shader ( struct wined3d_device device,
struct wined3d_shader shader 
)

Definition at line 2186 of file device.c.

2187{
2188 struct wined3d_shader *prev = device->update_state->shader[WINED3D_SHADER_TYPE_VERTEX];
2189
2190 TRACE("device %p, shader %p.\n", device, shader);
2191
2192 if (device->recording)
2193 device->recording->changed.vertexShader = TRUE;
2194
2195 if (shader == prev)
2196 return;
2197
2198 if (shader)
2200 device->update_state->shader[WINED3D_SHADER_TYPE_VERTEX] = shader;
2201 if (!device->recording)
2203 if (prev)
2205}

Referenced by d3d8_device_SetVertexShader(), d3d9_device_SetVertexShader(), and wined3d_stateblock_apply().

◆ wined3d_device_set_viewport()

void __cdecl wined3d_device_set_viewport ( struct wined3d_device device,
const struct wined3d_viewport viewport 
)

Definition at line 1931 of file device.c.

1932{
1933 TRACE("device %p, viewport %p.\n", device, viewport);
1934 TRACE("x %.8e, y %.8e, w %.8e, h %.8e, min_z %.8e, max_z %.8e.\n",
1935 viewport->x, viewport->y, viewport->width, viewport->height, viewport->min_z, viewport->max_z);
1936
1937 device->update_state->viewport = *viewport;
1938
1939 /* Handle recording of state blocks */
1940 if (device->recording)
1941 {
1942 TRACE("Recording... not performing anything\n");
1943 device->recording->changed.viewport = TRUE;
1944 return;
1945 }
1946
1947 wined3d_cs_emit_set_viewport(device->cs, viewport);
1948}

Referenced by d3d8_device_SetViewport(), d3d9_device_SetViewport(), d3d_device7_SetViewport(), and wined3d_stateblock_apply().

◆ wined3d_device_set_vs_cb()

void __cdecl wined3d_device_set_vs_cb ( struct wined3d_device device,
UINT  idx,
struct wined3d_buffer buffer 
)

Definition at line 2238 of file device.c.

2239{
2240 TRACE("device %p, idx %u, buffer %p.\n", device, idx, buffer);
2241
2243}

◆ wined3d_device_set_vs_consts_b()

HRESULT __cdecl wined3d_device_set_vs_consts_b ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const BOOL constants 
)

Definition at line 2366 of file device.c.

2368{
2369 unsigned int i;
2370
2371 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2372 device, start_idx, count, constants);
2373
2374 if (!constants || start_idx >= WINED3D_MAX_CONSTS_B)
2376
2377 if (count > WINED3D_MAX_CONSTS_B - start_idx)
2378 count = WINED3D_MAX_CONSTS_B - start_idx;
2379 memcpy(&device->update_state->vs_consts_b[start_idx], constants, count * sizeof(*constants));
2380 if (TRACE_ON(d3d))
2381 {
2382 for (i = 0; i < count; ++i)
2383 TRACE("Set BOOL constant %u to %#x.\n", start_idx + i, constants[i]);
2384 }
2385
2386 if (device->recording)
2387 {
2388 for (i = start_idx; i < count + start_idx; ++i)
2389 device->recording->changed.vertexShaderConstantsB |= (1u << i);
2390 }
2391 else
2392 {
2394 }
2395
2396 return WINED3D_OK;
2397}
@ WINED3D_PUSH_CONSTANTS_VS_B

Referenced by d3d9_device_SetVertexShaderConstantB(), and wined3d_stateblock_apply().

◆ wined3d_device_set_vs_consts_f()

HRESULT __cdecl wined3d_device_set_vs_consts_f ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const struct wined3d_vec4 constants 
)

Definition at line 2463 of file device.c.

2465{
2466 const struct wined3d_d3d_info *d3d_info = &device->adapter->d3d_info;
2467 unsigned int i;
2468
2469 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2470 device, start_idx, count, constants);
2471
2472 if (!constants || start_idx >= d3d_info->limits.vs_uniform_count
2473 || count > d3d_info->limits.vs_uniform_count - start_idx)
2475
2476 memcpy(&device->update_state->vs_consts_f[start_idx], constants, count * sizeof(*constants));
2477 if (TRACE_ON(d3d))
2478 {
2479 for (i = 0; i < count; ++i)
2480 TRACE("Set vec4 constant %u to %s.\n", start_idx + i, debug_vec4(&constants[i]));
2481 }
2482
2483 if (device->recording)
2484 memset(&device->recording->changed.vs_consts_f[start_idx], 1,
2485 count * sizeof(*device->recording->changed.vs_consts_f));
2486 else
2488
2489 return WINED3D_OK;
2490}
@ WINED3D_PUSH_CONSTANTS_VS_F

Referenced by d3d8_device_SetVertexShaderConstant(), d3d9_device_SetVertexShaderConstantF(), and wined3d_stateblock_apply().

◆ wined3d_device_set_vs_consts_i()

HRESULT __cdecl wined3d_device_set_vs_consts_i ( struct wined3d_device device,
unsigned int  start_idx,
unsigned int  count,
const struct wined3d_ivec4 constants 
)

Definition at line 2415 of file device.c.

2417{
2418 unsigned int i;
2419
2420 TRACE("device %p, start_idx %u, count %u, constants %p.\n",
2421 device, start_idx, count, constants);
2422
2423 if (!constants || start_idx >= WINED3D_MAX_CONSTS_I)
2425
2426 if (count > WINED3D_MAX_CONSTS_I - start_idx)
2427 count = WINED3D_MAX_CONSTS_I - start_idx;
2428 memcpy(&device->update_state->vs_consts_i[start_idx], constants, count * sizeof(*constants));
2429 if (TRACE_ON(d3d))
2430 {
2431 for (i = 0; i < count; ++i)
2432 TRACE("Set ivec4 constant %u to %s.\n", start_idx + i, debug_ivec4(&constants[i]));
2433 }
2434
2435 if (device->recording)
2436 {
2437 for (i = start_idx; i < count + start_idx; ++i)
2438 device->recording->changed.vertexShaderConstantsI |= (1u << i);
2439 }
2440 else
2441 {
2443 }
2444
2445 return WINED3D_OK;
2446}
@ WINED3D_PUSH_CONSTANTS_VS_I

Referenced by d3d9_device_SetVertexShaderConstantI(), and wined3d_stateblock_apply().

◆ wined3d_device_set_vs_resource_view()

void __cdecl wined3d_device_set_vs_resource_view ( struct wined3d_device device,
UINT  idx,
struct wined3d_shader_resource_view view 
)

Definition at line 2288 of file device.c.

2290{
2291 TRACE("device %p, idx %u, view %p.\n", device, idx, view);
2292
2294}

◆ wined3d_device_set_vs_sampler()

void __cdecl wined3d_device_set_vs_sampler ( struct wined3d_device device,
UINT  idx,
struct wined3d_sampler sampler 
)

Definition at line 2340 of file device.c.

2341{
2342 TRACE("device %p, idx %u, sampler %p.\n", device, idx, sampler);
2343
2345}

◆ wined3d_device_setup_fullscreen_window()

void __cdecl wined3d_device_setup_fullscreen_window ( struct wined3d_device device,
HWND  window,
UINT  w,
UINT  h 
)

Definition at line 853 of file device.c.

854{
855 BOOL filter_messages;
856 LONG style, exstyle;
857
858 TRACE("Setting up window %p for fullscreen mode.\n", window);
859
860 if (device->style || device->exStyle)
861 {
862 ERR("Changing the window style for window %p, but another style (%08x, %08x) is already stored.\n",
863 window, device->style, device->exStyle);
864 }
865
868
869 style = fullscreen_style(device->style);
870 exstyle = fullscreen_exstyle(device->exStyle);
871
872 TRACE("Old style was %08x, %08x, setting to %08x, %08x.\n",
873 device->style, device->exStyle, style, exstyle);
874
875 filter_messages = device->filter_messages;
876 device->filter_messages = TRUE;
877
881
882 device->filter_messages = filter_messages;
883}
GLubyte GLubyte GLubyte GLubyte w
Definition: glext.h:6102
GLfloat GLfloat GLfloat GLfloat h
Definition: glext.h:7723
#define HWND_TOPMOST
Definition: winuser.h:1208
#define SWP_SHOWWINDOW
Definition: winuser.h:1248

Referenced by ddraw_set_cooperative_level(), device_init(), wined3d_device_reset(), and wined3d_swapchain_set_fullscreen().

◆ wined3d_device_show_cursor()

BOOL __cdecl wined3d_device_show_cursor ( struct wined3d_device device,
BOOL  show 
)

Definition at line 4719 of file device.c.

4720{
4721 BOOL oldVisible = device->bCursorVisible;
4722
4723 TRACE("device %p, show %#x.\n", device, show);
4724
4725 /*
4726 * When ShowCursor is first called it should make the cursor appear at the OS's last
4727 * known cursor position.
4728 */
4729 if (show && !oldVisible)
4730 {
4731 POINT pt;
4732 GetCursorPos(&pt);
4733 device->xScreenSpace = pt.x;
4734 device->yScreenSpace = pt.y;
4735 }
4736
4737 if (device->hardwareCursor)
4738 {
4739 device->bCursorVisible = show;
4740 if (show)
4741 SetCursor(device->hardwareCursor);
4742 else
4743 SetCursor(NULL);
4744 }
4745 else if (device->cursor_texture)
4746 {
4747 device->bCursorVisible = show;
4748 }
4749
4750 return oldVisible;
4751}

Referenced by d3d8_device_ShowCursor(), and d3d9_device_ShowCursor().

◆ wined3d_device_uninit_3d()

HRESULT __cdecl wined3d_device_uninit_3d ( struct wined3d_device device)

Definition at line 1195 of file device.c.

1196{
1197 unsigned int i;
1198
1199 TRACE("device %p.\n", device);
1200
1201 if (!device->d3d_initialized)
1203
1204 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
1205
1206 if (device->logo_texture)
1207 wined3d_texture_decref(device->logo_texture);
1208 if (device->cursor_texture)
1209 wined3d_texture_decref(device->cursor_texture);
1210
1212
1214
1215#if defined(STAGING_CSMT)
1217#endif /* STAGING_CSMT */
1219
1220 if (device->fb.depth_stencil)
1221 {
1222 struct wined3d_rendertarget_view *view = device->fb.depth_stencil;
1223
1224 TRACE("Releasing depth/stencil view %p.\n", view);
1225
1226 device->fb.depth_stencil = NULL;
1228 }
1229
1230 if (device->auto_depth_stencil_view)
1231 {
1232 struct wined3d_rendertarget_view *view = device->auto_depth_stencil_view;
1233
1234 device->auto_depth_stencil_view = NULL;
1236 ERR("Something's still holding the auto depth/stencil view (%p).\n", view);
1237 }
1238
1239 for (i = 0; i < device->adapter->gl_info.limits.buffers; ++i)
1240 {
1242 }
1243 if (device->back_buffer_view)
1244 {
1245 wined3d_rendertarget_view_decref(device->back_buffer_view);
1246 device->back_buffer_view = NULL;
1247 }
1248
1249 for (i = 0; i < device->swapchain_count; ++i)
1250 {
1251 TRACE("Releasing the implicit swapchain %u.\n", i);
1252 if (wined3d_swapchain_decref(device->swapchains[i]))
1253 FIXME("Something's still holding the implicit swapchain.\n");
1254 }
1255
1256 heap_free(device->swapchains);
1257 device->swapchains = NULL;
1258 device->swapchain_count = 0;
1259
1260 device->d3d_initialized = FALSE;
1261
1262 return WINED3D_OK;
1263}
BOOL context_set_current(struct wined3d_context *ctx)
Definition: context.c:1512

Referenced by d3d8_device_Release(), d3d9_device_Release(), ddraw_attach_d3d_device(), ddraw_destroy_swapchain(), and device_init().

◆ wined3d_device_uninit_gdi()

HRESULT __cdecl wined3d_device_uninit_gdi ( struct wined3d_device device)

Definition at line 1265 of file device.c.

1266{
1267 unsigned int i;
1268
1269 device->blitter->ops->blitter_destroy(device->blitter, NULL);
1270
1271 for (i = 0; i < device->swapchain_count; ++i)
1272 {
1273 TRACE("Releasing the implicit swapchain %u.\n", i);
1274 if (wined3d_swapchain_decref(device->swapchains[i]))
1275 FIXME("Something's still holding the implicit swapchain.\n");
1276 }
1277
1278 heap_free(device->swapchains);
1279 device->swapchains = NULL;
1280 device->swapchain_count = 0;
1281 return WINED3D_OK;
1282}

Referenced by ddraw_destroy_swapchain().

◆ wined3d_device_update_sub_resource()

void __cdecl wined3d_device_update_sub_resource ( struct wined3d_device device,
struct wined3d_resource resource,
unsigned int  sub_resource_idx,
const struct wined3d_box box,
const void data,
unsigned int  row_pitch,
unsigned int  depth_pitch 
)

Definition at line 4281 of file device.c.

4284{
4285 unsigned int width, height, depth;
4286 struct wined3d_box b;
4287
4288 TRACE("device %p, resource %p, sub_resource_idx %u, box %s, data %p, row_pitch %u, depth_pitch %u.\n",
4289 device, resource, sub_resource_idx, debug_box(box), data, row_pitch, depth_pitch);
4290
4291 if (resource->type == WINED3D_RTYPE_BUFFER)
4292 {
4293 if (sub_resource_idx > 0)
4294 {
4295 WARN("Invalid sub_resource_idx %u.\n", sub_resource_idx);
4296 return;
4297 }
4298
4299 width = resource->size;
4300 height = 1;
4301 depth = 1;
4302 }
4303 else if (resource->type == WINED3D_RTYPE_TEXTURE_1D ||
4305 {
4307 unsigned int level;
4308
4309 if (sub_resource_idx >= texture->level_count * texture->layer_count)
4310 {
4311 WARN("Invalid sub_resource_idx %u.\n", sub_resource_idx);
4312 return;
4313 }
4314
4315 level = sub_resource_idx % texture->level_count;
4319 }
4320 else
4321 {
4322 FIXME("Not implemented for %s resources.\n", debug_d3dresourcetype(resource->type));
4323 return;
4324 }
4325
4326 if (!box)
4327 {
4328 wined3d_box_set(&b, 0, 0, width, height, 0, depth);
4329 box = &b;
4330 }
4331 else if (box->left >= box->right || box->right > width
4332 || box->top >= box->bottom || box->bottom > height
4333 || box->front >= box->back || box->back > depth)
4334 {
4335 WARN("Invalid box %s specified.\n", debug_box(box));
4336 return;
4337 }
4338
4339#if !defined(STAGING_CSMT)
4341
4342#endif /* STAGING_CSMT */
4343 wined3d_cs_emit_update_sub_resource(device->cs, resource, sub_resource_idx, box, data, row_pitch, depth_pitch);
4344}
void wined3d_cs_emit_update_sub_resource(struct wined3d_cs *cs, struct wined3d_resource *resource, unsigned int sub_resource_idx, const struct wined3d_box *box, const void *data, unsigned int row_pitch, unsigned int slice_pitch)
Definition: cs.c:2260
GLint level
Definition: gl.h:1546
GLint GLint GLsizei GLsizei height
Definition: gl.h:1546
size_t size
Definition: utils.c:259
unsigned int row_pitch
static void wined3d_resource_wait_idle(struct wined3d_resource *resource)

Referenced by buffer_init(), and wined3d_texture_create().

◆ wined3d_device_update_texture()

HRESULT __cdecl wined3d_device_update_texture ( struct wined3d_device device,
struct wined3d_texture src_texture,
struct wined3d_texture dst_texture 
)

Definition at line 3808 of file device.c.

3810{
3811 unsigned int src_size, dst_size, src_skip_levels = 0;
3812 unsigned int src_level_count, dst_level_count;
3813 unsigned int layer_count, level_count, i, j;
3814 unsigned int width, height, depth;
3816 struct wined3d_box box;
3817
3818 TRACE("device %p, src_texture %p, dst_texture %p.\n", device, src_texture, dst_texture);
3819
3820 /* Verify that the source and destination textures are non-NULL. */
3821 if (!src_texture || !dst_texture)
3822 {
3823 WARN("Source and destination textures must be non-NULL, returning WINED3DERR_INVALIDCALL.\n");
3825 }
3826
3827 if (src_texture->resource.access & WINED3D_RESOURCE_ACCESS_GPU
3828 || src_texture->resource.usage & WINED3DUSAGE_SCRATCH)
3829 {
3830 WARN("Source resource is GPU accessible or a scratch resource.\n");
3832 }
3833 if (dst_texture->resource.access & WINED3D_RESOURCE_ACCESS_CPU)
3834 {
3835 WARN("Destination resource is CPU accessible.\n");
3837 }
3838
3839 /* Verify that the source and destination textures are the same type. */
3840 type = src_texture->resource.type;
3841 if (dst_texture->resource.type != type)
3842 {
3843 WARN("Source and destination have different types, returning WINED3DERR_INVALIDCALL.\n");
3845 }
3846
3847 layer_count = src_texture->layer_count;
3848 if (layer_count != dst_texture->layer_count)
3849 {
3850 WARN("Source and destination have different layer counts.\n");
3852 }
3853
3854 if (src_texture->resource.format != dst_texture->resource.format)
3855 {
3856 WARN("Source and destination formats do not match.\n");
3858 }
3859
3860 src_level_count = src_texture->level_count;
3861 dst_level_count = dst_texture->level_count;
3862 level_count = min(src_level_count, dst_level_count);
3863
3864 src_size = max(src_texture->resource.width, src_texture->resource.height);
3865 dst_size = max(dst_texture->resource.width, dst_texture->resource.height);
3867 {
3868 src_size = max(src_size, src_texture->resource.depth);
3869 dst_size = max(dst_size, dst_texture->resource.depth);
3870 }
3871 while (src_size > dst_size)
3872 {
3873 src_size >>= 1;
3874 ++src_skip_levels;
3875 }
3876
3877 if (wined3d_texture_get_level_width(src_texture, src_skip_levels) != dst_texture->resource.width
3878 || wined3d_texture_get_level_height(src_texture, src_skip_levels) != dst_texture->resource.height
3879 || wined3d_texture_get_level_depth(src_texture, src_skip_levels) != dst_texture->resource.depth)
3880 {
3881 WARN("Source and destination dimensions do not match.\n");
3883 }
3884
3885 /* Update every surface level of the texture. */
3886 for (i = 0; i < level_count; ++i)
3887 {
3888 width = wined3d_texture_get_level_width(dst_texture, i);
3890 depth = wined3d_texture_get_level_depth(dst_texture, i);
3891 wined3d_box_set(&box, 0, 0, width, height, 0, depth);
3892
3893 for (j = 0; j < layer_count; ++j)
3894 {
3896 &dst_texture->resource, j * dst_level_count + i, &box,
3897 &src_texture->resource, j * src_level_count + i + src_skip_levels, &box,
3899 }
3900 }
3901
3902 return WINED3D_OK;
3903}
GLuint GLuint GLsizei GLenum type
Definition: gl.h:1545
#define max(a, b)
Definition: svc.c:63
#define WINED3D_RESOURCE_ACCESS_CPU
Definition: wined3d.h:56
wined3d_resource_type
Definition: wined3d.h:696

Referenced by d3d8_device_UpdateTexture(), and d3d9_device_UpdateTexture().

◆ wined3d_device_validate_device()

HRESULT __cdecl wined3d_device_validate_device ( const struct wined3d_device device,
DWORD num_passes 
)

Definition at line 3905 of file device.c.

3906{
3907 const struct wined3d_state *state = &device->state;
3908 struct wined3d_texture *texture;
3909 DWORD i;
3910
3911 TRACE("device %p, num_passes %p.\n", device, num_passes);
3912
3913 for (i = 0; i < MAX_COMBINED_SAMPLERS; ++i)
3914 {
3915 if (state->sampler_states[i][WINED3D_SAMP_MIN_FILTER] == WINED3D_TEXF_NONE)
3916 {
3917 WARN("Sampler state %u has minfilter D3DTEXF_NONE, returning D3DERR_UNSUPPORTEDTEXTUREFILTER\n", i);
3919 }
3920 if (state->sampler_states[i][WINED3D_SAMP_MAG_FILTER] == WINED3D_TEXF_NONE)
3921 {
3922 WARN("Sampler state %u has magfilter D3DTEXF_NONE, returning D3DERR_UNSUPPORTEDTEXTUREFILTER\n", i);
3924 }
3925
3926 texture = state->textures[i];
3927 if (!texture || texture->resource.format_flags & WINED3DFMT_FLAG_FILTERING) continue;
3928
3929 if (state->sampler_states[i][WINED3D_SAMP_MAG_FILTER] != WINED3D_TEXF_POINT)
3930 {
3931 WARN("Non-filterable texture and mag filter enabled on sampler %u, returning E_FAIL\n", i);
3932 return E_FAIL;
3933 }
3934 if (state->sampler_states[i][WINED3D_SAMP_MIN_FILTER] != WINED3D_TEXF_POINT)
3935 {
3936 WARN("Non-filterable texture and min filter enabled on sampler %u, returning E_FAIL\n", i);
3937 return E_FAIL;
3938 }
3939 if (state->sampler_states[i][WINED3D_SAMP_MIP_FILTER] != WINED3D_TEXF_NONE
3940 && state->sampler_states[i][WINED3D_SAMP_MIP_FILTER] != WINED3D_TEXF_POINT)
3941 {
3942 WARN("Non-filterable texture and mip filter enabled on sampler %u, returning E_FAIL\n", i);
3943 return E_FAIL;
3944 }
3945 }
3946
3947 if (state->render_states[WINED3D_RS_ZENABLE] || state->render_states[WINED3D_RS_ZWRITEENABLE]
3948 || state->render_states[WINED3D_RS_STENCILENABLE])
3949 {
3950 struct wined3d_rendertarget_view *rt = device->fb.render_targets[0];
3951 struct wined3d_rendertarget_view *ds = device->fb.depth_stencil;
3952
3953 if (ds && rt && (ds->width < rt->width || ds->height < rt->height))
3954 {
3955 WARN("Depth stencil is smaller than the color buffer, returning D3DERR_CONFLICTINGRENDERSTATE\n");
3957 }
3958 }
3959
3960 /* return a sensible default */
3961 *num_passes = 1;
3962
3963 TRACE("returning D3D_OK\n");
3964 return WINED3D_OK;
3965}
#define WINED3DERR_UNSUPPORTEDTEXTUREFILTER
Definition: wined3d.h:45
#define WINED3DERR_CONFLICTINGRENDERSTATE
Definition: wined3d.h:44
#define MAX_COMBINED_SAMPLERS

Referenced by d3d8_device_ValidateDevice(), d3d9_device_ValidateDevice(), and d3d_device7_ValidateDevice().

◆ wined3d_dxt1_decode()

BOOL wined3d_dxt1_decode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 317 of file dxtn.c.

319{
320 if (!txc_dxtn_handle)
321 return FALSE;
322
323 switch (format)
324 {
326 return dxt1_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, TRUE);
328 return dxt1_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, FALSE);
330 return dxt1_to_x4r4g4b4(src, dst, pitch_in, pitch_out, w, h, TRUE);
332 return dxt1_to_x4r4g4b4(src, dst, pitch_in, pitch_out, w, h, FALSE);
334 return dxt1_to_x1r5g5b5(src, dst, pitch_in, pitch_out, w, h, TRUE);
336 return dxt1_to_x1r5g5b5(src, dst, pitch_in, pitch_out, w, h, FALSE);
337 default:
338 break;
339 }
340
341 FIXME("Cannot find a conversion function from format DXT1 to %s.\n", debug_d3dformat(format));
342 return FALSE;
343}
static BOOL dxt1_to_x4r4g4b4(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:65
static BOOL dxt1_to_x1r5g5b5(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:97
static void * txc_dxtn_handle
Definition: dxtn.c:26
static BOOL dxt1_to_x8r8g8b8(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:33
GLenum src
Definition: glext.h:6340
GLenum GLenum dst
Definition: glext.h:6340

Referenced by convert_dxt1_a1r5g5b5(), convert_dxt1_a4r4g4b4(), convert_dxt1_a8r8g8b8(), convert_dxt1_x1r5g5b5(), convert_dxt1_x4r4g4b4(), and convert_dxt1_x8r8g8b8().

◆ wined3d_dxt1_encode()

BOOL wined3d_dxt1_encode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 389 of file dxtn.c.

391{
392 if (!txc_dxtn_handle)
393 return FALSE;
394
395 switch (format)
396 {
398 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
401 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
404 return x1r5g5b5_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
407 return x1r5g5b5_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
409 default:
410 break;
411 }
412
413 FIXME("Cannot find a conversion function from format %s to DXT1.\n", debug_d3dformat(format));
414 return FALSE;
415}
static BOOL x8r8g8b8_to_dxtn(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, GLenum destformat, BOOL alpha)
Definition: dxtn.c:225
static BOOL x1r5g5b5_to_dxtn(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, GLenum destformat, BOOL alpha)
Definition: dxtn.c:265
#define GL_COMPRESSED_RGB_S3TC_DXT1_EXT
Definition: glext.h:3489
#define GL_COMPRESSED_RGBA_S3TC_DXT1_EXT
Definition: glext.h:3490

Referenced by convert_a1r5g5b5_dxt1(), convert_a8r8g8b8_dxt1(), convert_x1r5g5b5_dxt1(), and convert_x8r8g8b8_dxt1().

◆ wined3d_dxt3_decode()

BOOL wined3d_dxt3_decode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 345 of file dxtn.c.

347{
348 if (!txc_dxtn_handle)
349 return FALSE;
350
351 switch (format)
352 {
354 return dxt3_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, TRUE);
356 return dxt3_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, FALSE);
358 return dxt3_to_x4r4g4b4(src, dst, pitch_in, pitch_out, w, h, TRUE);
360 return dxt3_to_x4r4g4b4(src, dst, pitch_in, pitch_out, w, h, FALSE);
361 default:
362 break;
363 }
364
365 FIXME("Cannot find a conversion function from format DXT3 to %s.\n", debug_d3dformat(format));
366 return FALSE;
367}
static BOOL dxt3_to_x4r4g4b4(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:161
static BOOL dxt3_to_x8r8g8b8(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:129

Referenced by convert_dxt3_a4r4g4b4(), convert_dxt3_a8r8g8b8(), convert_dxt3_x4r4g4b4(), and convert_dxt3_x8r8g8b8().

◆ wined3d_dxt3_encode()

BOOL wined3d_dxt3_encode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 417 of file dxtn.c.

419{
420 if (!txc_dxtn_handle)
421 return FALSE;
422
423 switch (format)
424 {
426 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
429 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
431 default:
432 break;
433 }
434
435 FIXME("Cannot find a conversion function from format %s to DXT3.\n", debug_d3dformat(format));
436 return FALSE;
437}
#define GL_COMPRESSED_RGBA_S3TC_DXT3_EXT
Definition: glext.h:3491

Referenced by convert_a8r8g8b8_dxt3(), and convert_x8r8g8b8_dxt3().

◆ wined3d_dxt5_decode()

BOOL wined3d_dxt5_decode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 369 of file dxtn.c.

371{
372 if (!txc_dxtn_handle)
373 return FALSE;
374
375 switch (format)
376 {
378 return dxt5_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, TRUE);
380 return dxt5_to_x8r8g8b8(src, dst, pitch_in, pitch_out, w, h, FALSE);
381 default:
382 break;
383 }
384
385 FIXME("Cannot find a conversion function from format DXT5 to %s.\n", debug_d3dformat(format));
386 return FALSE;
387}
static BOOL dxt5_to_x8r8g8b8(const BYTE *src, BYTE *dst, DWORD pitch_in, DWORD pitch_out, unsigned int w, unsigned int h, BOOL alpha)
Definition: dxtn.c:193

Referenced by convert_dxt5_a8r8g8b8(), and convert_dxt5_x8r8g8b8().

◆ wined3d_dxt5_encode()

BOOL wined3d_dxt5_encode ( const BYTE src,
BYTE dst,
DWORD  pitch_in,
DWORD  pitch_out,
enum wined3d_format_id  format,
unsigned int  w,
unsigned int  h 
)

Definition at line 439 of file dxtn.c.

441{
442 if (!txc_dxtn_handle)
443 return FALSE;
444
445 switch (format)
446 {
448 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
451 return x8r8g8b8_to_dxtn(src, dst, pitch_in, pitch_out, w, h,
453 default:
454 break;
455 }
456
457 FIXME("Cannot find a conversion function from format %s to DXT5.\n", debug_d3dformat(format));
458 return FALSE;
459}
#define GL_COMPRESSED_RGBA_S3TC_DXT5_EXT
Definition: glext.h:3492

Referenced by convert_a8r8g8b8_dxt5(), and convert_x8r8g8b8_dxt5().

◆ wined3d_dxtn_supported()

BOOL wined3d_dxtn_supported ( void  )

Definition at line 510 of file dxtn.c.

511{
512 return (txc_dxtn_handle != NULL);
513}

Referenced by find_converter().

◆ wined3d_enum_adapter_modes()

HRESULT __cdecl wined3d_enum_adapter_modes ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_format_id  format_id,
enum wined3d_scanline_ordering  scanline_ordering,
UINT  mode_idx,
struct wined3d_display_mode mode 
)

Definition at line 4589 of file directx.c.

4592{
4593 const struct wined3d_adapter *adapter;
4594 const struct wined3d_format *format;
4595 UINT format_bits;
4596 DEVMODEW m;
4597 UINT i = 0;
4598 int j = 0;
4599
4600 TRACE("wined3d %p, adapter_idx %u, format %s, scanline_ordering %#x, mode_idx %u, mode %p.\n",
4601 wined3d, adapter_idx, debug_d3dformat(format_id), scanline_ordering, mode_idx, mode);
4602
4603 if (!mode || adapter_idx >= wined3d->adapter_count)
4605
4606 adapter = &wined3d->adapters[adapter_idx];
4608 format_bits = format->byte_count * CHAR_BIT;
4609
4610 memset(&m, 0, sizeof(m));
4611 m.dmSize = sizeof(m);
4612
4613 while (i <= mode_idx)
4614 {
4615 if (!EnumDisplaySettingsExW(adapter->DeviceName, j++, &m, 0))
4616 {
4617 WARN("Invalid mode_idx %u.\n", mode_idx);
4619 }
4620
4621 if (m.dmFields & DM_DISPLAYFLAGS)
4622 {
4623 if (scanline_ordering == WINED3D_SCANLINE_ORDERING_PROGRESSIVE
4624 && (m.u2.dmDisplayFlags & DM_INTERLACED))
4625 continue;
4626
4627 if (scanline_ordering == WINED3D_SCANLINE_ORDERING_INTERLACED
4628 && !(m.u2.dmDisplayFlags & DM_INTERLACED))
4629 continue;
4630 }
4631
4633 {
4634 /* This is for d3d8, do not enumerate P8 here. */
4635 if (m.dmBitsPerPel == 32 || m.dmBitsPerPel == 16) ++i;
4636 }
4637 else if (m.dmBitsPerPel == format_bits)
4638 {
4639 ++i;
4640 }
4641 }
4642
4643 mode->width = m.dmPelsWidth;
4644 mode->height = m.dmPelsHeight;
4645 mode->refresh_rate = DEFAULT_REFRESH_RATE;
4646 if (m.dmFields & DM_DISPLAYFREQUENCY)
4647 mode->refresh_rate = m.dmDisplayFrequency;
4648
4650 mode->format_id = pixelformat_for_depth(m.dmBitsPerPel);
4651 else
4652 mode->format_id = format_id;
4653
4654 if (!(m.dmFields & DM_DISPLAYFLAGS))
4655 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_UNKNOWN;
4656 else if (m.u2.dmDisplayFlags & DM_INTERLACED)
4657 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_INTERLACED;
4658 else
4659 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_PROGRESSIVE;
4660
4661 TRACE("%ux%u@%u %u bpp, %s %#x.\n", mode->width, mode->height, mode->refresh_rate,
4662 m.dmBitsPerPel, debug_d3dformat(mode->format_id), mode->scanline_ordering);
4663
4664 return WINED3D_OK;
4665}
enum wined3d_format_id pixelformat_for_depth(DWORD depth)
Definition: utils.c:5388
#define CHAR_BIT
Definition: urlcache.c:62
const GLfloat * m
Definition: glext.h:10848
BOOL WINAPI EnumDisplaySettingsExW(LPCWSTR lpszDeviceName, DWORD iModeNum, LPDEVMODEW lpDevMode, DWORD dwFlags)
Definition: display.c:330
#define DEFAULT_REFRESH_RATE
Definition: directx.c:36
#define DM_DISPLAYFREQUENCY
Definition: wingdi.h:1272
#define DM_INTERLACED
Definition: wingdi.h:1228
#define DM_DISPLAYFLAGS
Definition: wingdi.h:1271

Referenced by d3d8_EnumAdapterModes(), d3d9_EnumAdapterModes(), d3d9_EnumAdapterModesEx(), ddraw7_EnumDisplayModes(), and wined3d_find_closest_matching_adapter_mode().

◆ wined3d_find_closest_matching_adapter_mode()

HRESULT __cdecl wined3d_find_closest_matching_adapter_mode ( const struct wined3d wined3d,
unsigned int  adapter_idx,
struct wined3d_display_mode mode 
)

Definition at line 4667 of file directx.c.

4669{
4670 unsigned int i, j, mode_count, matching_mode_count, closest;
4671 struct wined3d_display_mode **matching_modes;
4672 struct wined3d_display_mode *modes;
4673 HRESULT hr;
4674
4675 TRACE("wined3d %p, adapter_idx %u, mode %p.\n", wined3d, adapter_idx, mode);
4676
4677 if (!(mode_count = wined3d_get_adapter_mode_count(wined3d, adapter_idx,
4679 {
4680 WARN("Adapter has 0 matching modes.\n");
4681 return E_FAIL;
4682 }
4683
4684 if (!(modes = heap_calloc(mode_count, sizeof(*modes))))
4685 return E_OUTOFMEMORY;
4686 if (!(matching_modes = heap_calloc(mode_count, sizeof(*matching_modes))))
4687 {
4688 heap_free(modes);
4689 return E_OUTOFMEMORY;
4690 }
4691
4692 for (i = 0; i < mode_count; ++i)
4693 {
4694 if (FAILED(hr = wined3d_enum_adapter_modes(wined3d, adapter_idx,
4695 mode->format_id, WINED3D_SCANLINE_ORDERING_UNKNOWN, i, &modes[i])))
4696 {
4697 heap_free(matching_modes);
4698 heap_free(modes);
4699 return hr;
4700 }
4701 matching_modes[i] = &modes[i];
4702 }
4703
4704 matching_mode_count = mode_count;
4705
4706 if (mode->scanline_ordering != WINED3D_SCANLINE_ORDERING_UNKNOWN)
4707 {
4708 for (i = 0, j = 0; i < matching_mode_count; ++i)
4709 {
4710 if (matching_modes[i]->scanline_ordering == mode->scanline_ordering)
4711 matching_modes[j++] = matching_modes[i];
4712 }
4713 if (j > 0)
4714 matching_mode_count = j;
4715 }
4716
4717 if (mode->refresh_rate)
4718 {
4719 for (i = 0, j = 0; i < matching_mode_count; ++i)
4720 {
4721 if (matching_modes[i]->refresh_rate == mode->refresh_rate)
4722 matching_modes[j++] = matching_modes[i];
4723 }
4724 if (j > 0)
4725 matching_mode_count = j;
4726 }
4727
4728 if (!mode->width || !mode->height)
4729 {
4730 struct wined3d_display_mode current_mode;
4732 &current_mode, NULL)))
4733 {
4734 heap_free(matching_modes);
4735 heap_free(modes);
4736 return hr;
4737 }
4738 mode->width = current_mode.width;
4739 mode->height = current_mode.height;
4740 }
4741
4742 closest = ~0u;
4743 for (i = 0, j = 0; i < matching_mode_count; ++i)
4744 {
4745 unsigned int d = abs(mode->width - matching_modes[i]->width)
4746 + abs(mode->height - matching_modes[i]->height);
4747
4748 if (closest > d)
4749 {
4750 closest = d;
4751 j = i;
4752 }
4753 }
4754
4755 *mode = *matching_modes[j];
4756
4757 heap_free(matching_modes);
4758 heap_free(modes);
4759
4760 TRACE("Returning %ux%u@%u %s %#x.\n", mode->width, mode->height,
4761 mode->refresh_rate, debug_d3dformat(mode->format_id),
4762 mode->scanline_ordering);
4763
4764 return WINED3D_OK;
4765}
#define abs(i)
Definition: fconv.c:206
#define d
Definition: ke_i.h:81
enum wined3d_scanline_ordering scanline_ordering
Definition: wined3d.h:1585
HRESULT CDECL wined3d_enum_adapter_modes(const struct wined3d *wined3d, UINT adapter_idx, enum wined3d_format_id format_id, enum wined3d_scanline_ordering scanline_ordering, UINT mode_idx, struct wined3d_display_mode *mode)
Definition: directx.c:4589

Referenced by wined3d_swapchain_set_display_mode().

◆ wined3d_get_adapter_count()

UINT __cdecl wined3d_get_adapter_count ( const struct wined3d wined3d)

Definition at line 4484 of file directx.c.

4485{
4486 TRACE("wined3d %p, reporting %u adapters.\n",
4488
4489 return wined3d->adapter_count;
4490}

Referenced by d3d8_GetAdapterCount(), and d3d9_GetAdapterCount().

◆ wined3d_get_adapter_display_mode()

HRESULT __cdecl wined3d_get_adapter_display_mode ( const struct wined3d wined3d,
UINT  adapter_idx,
struct wined3d_display_mode mode,
enum wined3d_display_rotation rotation 
)

Definition at line 4767 of file directx.c.

4769{
4770 const struct wined3d_adapter *adapter;
4771 DEVMODEW m;
4772
4773 TRACE("wined3d %p, adapter_idx %u, display_mode %p, rotation %p.\n",
4774 wined3d, adapter_idx, mode, rotation);
4775
4776 if (!mode || adapter_idx >= wined3d->adapter_count)
4778
4779 adapter = &wined3d->adapters[adapter_idx];
4780
4781 memset(&m, 0, sizeof(m));
4782 m.dmSize = sizeof(m);
4783
4785 mode->width = m.dmPelsWidth;
4786 mode->height = m.dmPelsHeight;
4787 mode->refresh_rate = DEFAULT_REFRESH_RATE;
4788 if (m.dmFields & DM_DISPLAYFREQUENCY)
4789 mode->refresh_rate = m.dmDisplayFrequency;
4790 mode->format_id = pixelformat_for_depth(m.dmBitsPerPel);
4791
4792 /* Lie about the format. X11 can't change the color depth, and some apps
4793 * are pretty angry if they SetDisplayMode from 24 to 16 bpp and find out
4794 * that GetDisplayMode still returns 24 bpp. This should probably be
4795 * handled in winex11 instead. */
4796 if (adapter->screen_format && adapter->screen_format != mode->format_id)
4797 {
4798 WARN("Overriding format %s with stored format %s.\n",
4799 debug_d3dformat(mode->format_id),
4800 debug_d3dformat(adapter->screen_format));
4801 mode->format_id = adapter->screen_format;
4802 }
4803
4804 if (!(m.dmFields & DM_DISPLAYFLAGS))
4805 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_UNKNOWN;
4806 else if (m.u2.dmDisplayFlags & DM_INTERLACED)
4807 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_INTERLACED;
4808 else
4809 mode->scanline_ordering = WINED3D_SCANLINE_ORDERING_PROGRESSIVE;
4810
4811 if (rotation)
4812 {
4813 switch (m.u1.s2.dmDisplayOrientation)
4814 {
4815 case DMDO_DEFAULT:
4816 *rotation = WINED3D_DISPLAY_ROTATION_0;
4817 break;
4818 case DMDO_90:
4819 *rotation = WINED3D_DISPLAY_ROTATION_90;
4820 break;
4821 case DMDO_180:
4822 *rotation = WINED3D_DISPLAY_ROTATION_180;
4823 break;
4824 case DMDO_270:
4825 *rotation = WINED3D_DISPLAY_ROTATION_270;
4826 break;
4827 default:
4828 FIXME("Unhandled display rotation %#x.\n", m.u1.s2.dmDisplayOrientation);
4830 break;
4831 }
4832 }
4833
4834 TRACE("Returning %ux%u@%u %s %#x.\n", mode->width, mode->height,
4835 mode->refresh_rate, debug_d3dformat(mode->format_id),
4836 mode->scanline_ordering);
4837 return WINED3D_OK;
4838}
#define DMDO_DEFAULT
Definition: wingdi.h:1217
#define DMDO_180
Definition: wingdi.h:1219
#define DMDO_270
Definition: wingdi.h:1220
#define DMDO_90
Definition: wingdi.h:1218
#define ENUM_CURRENT_SETTINGS
Definition: winuser.h:179

Referenced by d3d7_EnumZBufferFormats(), d3d8_GetAdapterDisplayMode(), d3d9_GetAdapterDisplayMode(), d3d9_GetAdapterDisplayModeEx(), d3d_device2_EnumTextureFormats(), d3d_device7_EnumTextureFormats(), ddraw7_GetAvailableVidMem(), ddraw7_GetDisplayMode(), ddraw7_GetFourCCCodes(), ddraw7_GetMonitorFrequency(), ddraw_create_swapchain(), ddraw_set_cooperative_level(), ddraw_surface_create(), swapchain_init(), wined3d_device_set_cursor_properties(), wined3d_find_closest_matching_adapter_mode(), wined3d_get_adapter_raster_status(), wined3d_get_output_desc(), wined3d_swapchain_get_display_mode(), wined3d_swapchain_resize_target(), and wined3d_swapchain_set_fullscreen().

◆ wined3d_get_adapter_identifier()

HRESULT __cdecl wined3d_get_adapter_identifier ( const struct wined3d wined3d,
UINT  adapter_idx,
DWORD  flags,
struct wined3d_adapter_identifier identifier 
)

Definition at line 4939 of file directx.c.

4941{
4942 const struct wined3d_adapter *adapter;
4943 size_t len;
4944
4945 TRACE("wined3d %p, adapter_idx %u, flags %#x, identifier %p.\n",
4946 wined3d, adapter_idx, flags, identifier);
4947
4948 if (adapter_idx >= wined3d->adapter_count)
4950
4951 adapter = &wined3d->adapters[adapter_idx];
4952
4953 if (identifier->driver_size)
4954 {
4955 const char *name = adapter->driver_info.name;
4956 len = min(strlen(name), identifier->driver_size - 1);
4957 memcpy(identifier->driver, name, len);
4958 memset(&identifier->driver[len], 0, identifier->driver_size - len);
4959 }
4960
4961 if (identifier->description_size)
4962 {
4963 const char *description = adapter->driver_info.description;
4964 len = min(strlen(description), identifier->description_size - 1);
4965 memcpy(identifier->description, description, len);
4966 memset(&identifier->description[len], 0, identifier->description_size - len);
4967 }
4968
4969 /* Note that d3d8 doesn't supply a device name. */
4970 if (identifier->device_name_size)
4971 {
4972 if (!WideCharToMultiByte(CP_ACP, 0, adapter->DeviceName, -1, identifier->device_name,
4973 identifier->device_name_size, NULL, NULL))
4974 {
4975 ERR("Failed to convert device name, last error %#x.\n", GetLastError());
4977 }
4978 }
4979
4980 identifier->driver_version.u.HighPart = adapter->driver_info.version_high;
4981 identifier->driver_version.u.LowPart = adapter->driver_info.version_low;
4982 identifier->vendor_id = adapter->driver_info.vendor;
4983 identifier->device_id = adapter->driver_info.device;
4984 identifier->subsystem_id = 0;
4985 identifier->revision = 0;
4986 memcpy(&identifier->device_identifier, &IID_D3DDEVICE_D3DUID, sizeof(identifier->device_identifier));
4987 identifier->whql_level = (flags & WINED3DENUM_NO_WHQL_LEVEL) ? 0 : 1;
4988 memcpy(&identifier->adapter_luid, &adapter->luid, sizeof(identifier->adapter_luid));
4989 identifier->video_memory = min(~(SIZE_T)0, adapter->vram_bytes);
4990
4991 return WINED3D_OK;
4992}
ACPI_SIZE strlen(const char *String)
Definition: utclib.c:269
#define CP_ACP
Definition: compat.h:109
#define WideCharToMultiByte
Definition: compat.h:111
GLenum GLsizei len
Definition: glext.h:6722
Definition: name.c:39
LARGE_INTEGER driver_version
Definition: wined3d.h:1719
ULONG_PTR SIZE_T
Definition: typedefs.h:80
struct _LARGE_INTEGER::@2290 u
DWORD WINAPI GetLastError(void)
Definition: except.c:1042
const char * description
Definition: directx.c:2497
static const GUID IID_D3DDEVICE_D3DUID
Definition: directx.c:94
#define WINED3DENUM_NO_WHQL_LEVEL
Definition: wined3d.h:858

Referenced by d3d8_GetAdapterIdentifier(), d3d9_GetAdapterIdentifier(), d3d9_GetAdapterLUID(), ddraw7_GetAvailableVidMem(), ddraw7_GetDeviceIdentifier(), and ddraw_enumerate_secondary_devices().

◆ wined3d_get_adapter_mode_count()

UINT __cdecl wined3d_get_adapter_mode_count ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_format_id  format_id,
enum wined3d_scanline_ordering  scanline_ordering 
)

Definition at line 4536 of file directx.c.

4538{
4539 const struct wined3d_adapter *adapter;
4540 const struct wined3d_format *format;
4541 unsigned int i = 0;
4542 unsigned int j = 0;
4543 UINT format_bits;
4544 DEVMODEW mode;
4545
4546 TRACE("wined3d %p, adapter_idx %u, format %s, scanline_ordering %#x.\n",
4547 wined3d, adapter_idx, debug_d3dformat(format_id), scanline_ordering);
4548
4549 if (adapter_idx >= wined3d->adapter_count)
4550 return 0;
4551
4552 adapter = &wined3d->adapters[adapter_idx];
4554 format_bits = format->byte_count * CHAR_BIT;
4555
4556 memset(&mode, 0, sizeof(mode));
4557 mode.dmSize = sizeof(mode);
4558
4559 while (EnumDisplaySettingsExW(adapter->DeviceName, j++, &mode, 0))
4560 {
4561 if (mode.dmFields & DM_DISPLAYFLAGS)
4562 {
4563 if (scanline_ordering == WINED3D_SCANLINE_ORDERING_PROGRESSIVE
4564 && (mode.u2.dmDisplayFlags & DM_INTERLACED))
4565 continue;
4566
4567 if (scanline_ordering == WINED3D_SCANLINE_ORDERING_INTERLACED
4568 && !(mode.u2.dmDisplayFlags & DM_INTERLACED))
4569 continue;
4570 }
4571
4573 {
4574 /* This is for d3d8, do not enumerate P8 here. */
4575 if (mode.dmBitsPerPel == 32 || mode.dmBitsPerPel == 16) ++i;
4576 }
4577 else if (mode.dmBitsPerPel == format_bits)
4578 {
4579 ++i;
4580 }
4581 }
4582
4583 TRACE("Returning %u matching modes (out of %u total) for adapter %u.\n", i, j, adapter_idx);
4584
4585 return i;
4586}

Referenced by d3d8_GetAdapterModeCount(), d3d9_GetAdapterModeCount(), d3d9_GetAdapterModeCountEx(), wined3d_check_device_type(), and wined3d_find_closest_matching_adapter_mode().

◆ wined3d_get_adapter_raster_status()

HRESULT __cdecl wined3d_get_adapter_raster_status ( const struct wined3d wined3d,
UINT  adapter_idx,
struct wined3d_raster_status raster_status 
)

Definition at line 4994 of file directx.c.

4996{
4997 LONGLONG freq_per_frame, freq_per_line;
4998 LARGE_INTEGER counter, freq_per_sec;
5000 static UINT once;
5001
5002 if (!once++)
5003 FIXME("wined3d %p, adapter_idx %u, raster_status %p semi-stub!\n",
5004 wined3d, adapter_idx, raster_status);
5005 else
5006 WARN("wined3d %p, adapter_idx %u, raster_status %p semi-stub!\n",
5007 wined3d, adapter_idx, raster_status);
5008
5009 /* Obtaining the raster status is a widely implemented but optional
5010 * feature. When this method returns OK StarCraft 2 expects the
5011 * raster_status->InVBlank value to actually change over time.
5012 * And Endless Alice Crysis doesn't care even if this method fails.
5013 * Thus this method returns OK and fakes raster_status by
5014 * QueryPerformanceCounter. */
5015
5020 if (mode.refresh_rate == DEFAULT_REFRESH_RATE)
5021 mode.refresh_rate = 60;
5022
5023 freq_per_frame = freq_per_sec.QuadPart / mode.refresh_rate;
5024 /* Assume 20 scan lines in the vertical blank. */
5025 freq_per_line = freq_per_frame / (mode.height + 20);
5026 raster_status->scan_line = (counter.QuadPart % freq_per_frame) / freq_per_line;
5027 if (raster_status->scan_line < mode.height)
5028 raster_status->in_vblank = FALSE;
5029 else
5030 {
5031 raster_status->scan_line = 0;
5032 raster_status->in_vblank = TRUE;
5033 }
5034
5035 TRACE("Returning fake value, in_vblank %u, scan_line %u.\n",
5036 raster_status->in_vblank, raster_status->scan_line);
5037
5038 return WINED3D_OK;
5039}
BOOL WINAPI QueryPerformanceFrequency(OUT PLARGE_INTEGER lpFrequency)
Definition: perfcnt.c:45
BOOL WINAPI QueryPerformanceCounter(OUT PLARGE_INTEGER lpPerformanceCount)
Definition: perfcnt.c:23
int64_t LONGLONG
Definition: typedefs.h:68
LONGLONG QuadPart
Definition: typedefs.h:114

Referenced by ddraw7_GetScanLine(), ddraw7_GetVerticalBlankStatus(), and wined3d_swapchain_get_raster_status().

◆ wined3d_get_device_caps()

HRESULT __cdecl wined3d_get_device_caps ( const struct wined3d wined3d,
UINT  adapter_idx,
enum wined3d_device_type  device_type,
WINED3DCAPS caps 
)

Definition at line 5659 of file directx.c.

5661{
5662 const struct wined3d_adapter *adapter = &wined3d->adapters[adapter_idx];
5663 const struct wined3d_d3d_info *d3d_info = &adapter->d3d_info;
5664 const struct wined3d_gl_info *gl_info = &adapter->gl_info;
5665 struct wined3d_vertex_caps vertex_caps;
5666 DWORD ckey_caps, blit_caps, fx_caps;
5668 struct shader_caps shader_caps;
5669
5670 TRACE("wined3d %p, adapter_idx %u, device_type %s, caps %p.\n",
5671 wined3d, adapter_idx, debug_d3ddevicetype(device_type), caps);
5672
5673 if (adapter_idx >= wined3d->adapter_count)
5675
5677 caps->AdapterOrdinal = adapter_idx;
5678
5679 caps->Caps = 0;
5685
5689
5692
5695
5710
5719 /* TODO:
5720 WINED3DPMISCCAPS_NULLREFERENCE
5721 WINED3DPMISCCAPS_FOGANDSPECULARALPHA
5722 WINED3DPMISCCAPS_MRTINDEPENDENTBITDEPTHS
5723 WINED3DPMISCCAPS_FOGVERTEXCLAMPED */
5724
5729 if (gl_info->supported[EXT_DRAW_BUFFERS2])
5731 if (gl_info->supported[ARB_FRAMEBUFFER_SRGB])
5733
5746
5748 {
5752 }
5753
5762
5763 /* WINED3DPBLENDCAPS_BOTHINVSRCALPHA and WINED3DPBLENDCAPS_BOTHSRCALPHA
5764 * are legacy settings for srcblend only. */
5778
5789
5790 if (gl_info->supported[ARB_BLEND_FUNC_EXTENDED])
5792
5793 if (gl_info->supported[EXT_BLEND_COLOR])
5794 {
5797 }
5798
5799
5808
5817
5825
5827 {
5831 }
5832
5833 if (gl_info->supported[EXT_TEXTURE3D])
5834 {
5838 {
5840 }
5841 }
5842
5843 if (gl_info->supported[ARB_TEXTURE_CUBE_MAP])
5844 {
5848 {
5850 }
5851 }
5852
5865
5867 {
5870 }
5871
5872 if (gl_info->supported[ARB_TEXTURE_CUBE_MAP])
5873 {
5886
5888 {
5891 }
5892 }
5893 else
5894 {
5895 caps->CubeTextureFilterCaps = 0;
5896 }
5897
5898 if (gl_info->supported[EXT_TEXTURE3D])
5899 {
5912 }
5913 else
5914 {
5915 caps->VolumeTextureFilterCaps = 0;
5916 }
5917
5921
5922 if (gl_info->supported[ARB_TEXTURE_BORDER_CLAMP])
5923 {
5925 }
5927 {
5929 }
5931 {
5933 }
5934
5935 if (gl_info->supported[EXT_TEXTURE3D])
5936 {
5940 if (gl_info->supported[ARB_TEXTURE_BORDER_CLAMP])
5941 {
5943 }
5945 {
5947 }
5949 {
5951 }
5952 }
5953 else
5954 {
5955 caps->VolumeTextureAddressCaps = 0;
5956 }
5957
5963 /* WINED3DLINECAPS_ANTIALIAS is not supported on Windows, and dx and gl seem to have a different
5964 * idea how generating the smoothing alpha values works; the result is different
5965 */
5966
5967 caps->MaxTextureWidth = gl_info->limits.texture_size;
5968 caps->MaxTextureHeight = gl_info->limits.texture_size;
5969
5970 if (gl_info->supported[EXT_TEXTURE3D])
5971 caps->MaxVolumeExtent = gl_info->limits.texture3d_size;
5972 else
5973 caps->MaxVolumeExtent = 0;
5974
5975 caps->MaxTextureRepeat = 32768;
5976 caps->MaxTextureAspectRatio = gl_info->limits.texture_size;
5977 caps->MaxVertexW = 1.0f;
5978
5979 caps->GuardBandLeft = 0.0f;
5980 caps->GuardBandTop = 0.0f;
5981 caps->GuardBandRight = 0.0f;
5982 caps->GuardBandBottom = 0.0f;
5983
5984 caps->ExtentsAdjust = 0.0f;
5985
5992 if (gl_info->supported[EXT_STENCIL_WRAP])
5993 {
5996 }
5998 || gl_info->supported[ATI_SEPARATE_STENCIL])
5999 {
6001 }
6002
6003 caps->MaxAnisotropy = gl_info->limits.anisotropy;
6004 caps->MaxPointSize = gl_info->limits.pointsize_max;
6005
6006 caps->MaxPrimitiveCount = 0x555555; /* Taken from an AMD Radeon HD 5700 (Evergreen) GPU. */
6007 caps->MaxVertexIndex = 0xffffff; /* Taken from an AMD Radeon HD 5700 (Evergreen) GPU. */
6008 caps->MaxStreams = MAX_STREAMS;
6009 caps->MaxStreamStride = 1024;
6010
6011 /* d3d9.dll sets D3DDEVCAPS2_CAN_STRETCHRECT_FROM_TEXTURES here because StretchRects is implemented in d3d9 */
6015 caps->MasterAdapterOrdinal = 0;
6016 caps->AdapterOrdinalInGroup = 0;
6017 caps->NumberOfAdaptersInGroup = 1;
6018
6019 caps->NumSimultaneousRTs = gl_info->limits.buffers;
6020
6025 caps->VertexTextureFilterCaps = 0;
6026
6027 adapter->shader_backend->shader_get_caps(&adapter->gl_info, &shader_caps);
6028 adapter->fragment_pipe->get_caps(&adapter->gl_info, &fragment_caps);
6029 adapter->vertex_pipe->vp_get_caps(&adapter->gl_info, &vertex_caps);
6030
6031 /* Add shader misc caps. Only some of them belong to the shader parts of the pipeline */
6033
6036
6039
6043
6044 caps->MaxUserClipPlanes = vertex_caps.max_user_clip_planes;
6045 caps->MaxActiveLights = vertex_caps.max_active_lights;
6046 caps->MaxVertexBlendMatrices = vertex_caps.max_vertex_blend_matrices;
6048 caps->MaxVertexBlendMatrixIndex = vertex_caps.max_vertex_blend_matrix_index;
6049 else
6050 caps->MaxVertexBlendMatrixIndex = 255;
6051 caps->VertexProcessingCaps = vertex_caps.vertex_processing_caps;
6052 caps->FVFCaps = vertex_caps.fvf_caps;
6053 caps->RasterCaps |= vertex_caps.raster_caps;
6054
6055 /* The following caps are shader specific, but they are things we cannot detect, or which
6056 * are the same among all shader models. So to avoid code duplication set the shader version
6057 * specific, but otherwise constant caps here
6058 */
6059 if (caps->VertexShaderVersion >= 3)
6060 {
6061 /* Where possible set the caps based on OpenGL extensions and if they
6062 * aren't set (in case of software rendering) use the VS 3.0 from
6063 * MSDN or else if there's OpenGL spec use a hardcoded value minimum
6064 * VS3.0 value. */
6066 /* VS 3.0 requires MAX_DYNAMICFLOWCONTROLDEPTH (24) */
6067 caps->VS20Caps.dynamic_flow_control_depth = WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH;
6068 caps->VS20Caps.temp_count = max(32, adapter->gl_info.limits.arb_vs_temps);
6069 /* level of nesting in loops / if-statements; VS 3.0 requires MAX (4) */
6070 caps->VS20Caps.static_flow_control_depth = WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH;
6071
6072 caps->MaxVShaderInstructionsExecuted = 65535; /* VS 3.0 needs at least 65535, some cards even use 2^32-1 */
6073 caps->MaxVertexShader30InstructionSlots = max(512, adapter->gl_info.limits.arb_vs_instructions);
6075 }
6076 else if (caps->VertexShaderVersion == 2)
6077 {
6078 caps->VS20Caps.caps = 0;
6079 caps->VS20Caps.dynamic_flow_control_depth = WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH;
6080 caps->VS20Caps.temp_count = max(12, adapter->gl_info.limits.arb_vs_temps);
6081 caps->VS20Caps.static_flow_control_depth = 1;
6082
6083 caps->MaxVShaderInstructionsExecuted = 65535;
6085 }
6086 else
6087 { /* VS 1.x */
6088 caps->VS20Caps.caps = 0;
6089 caps->VS20Caps.dynamic_flow_control_depth = 0;
6090 caps->VS20Caps.temp_count = 0;
6091 caps->VS20Caps.static_flow_control_depth = 0;
6092
6095 }
6096
6097 if (caps->PixelShaderVersion >= 3)
6098 {
6099 /* Where possible set the caps based on OpenGL extensions and if they
6100 * aren't set (in case of software rendering) use the PS 3.0 from
6101 * MSDN or else if there's OpenGL spec use a hardcoded value minimum
6102 * PS 3.0 value. */
6103
6104 /* Caps is more or less undocumented on MSDN but it appears to be
6105 * used for PS20Caps based on results from R9600/FX5900/Geforce6800
6106 * cards from Windows */
6112 /* PS 3.0 requires MAX_DYNAMICFLOWCONTROLDEPTH (24) */
6113 caps->PS20Caps.dynamic_flow_control_depth = WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH;
6114 caps->PS20Caps.temp_count = max(32, adapter->gl_info.limits.arb_ps_temps);
6115 /* PS 3.0 requires MAX_STATICFLOWCONTROLDEPTH (4) */
6116 caps->PS20Caps.static_flow_control_depth = WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH;
6117 /* PS 3.0 requires MAX_NUMINSTRUCTIONSLOTS (512) */
6118 caps->PS20Caps.instruction_slot_count = WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS;
6119
6120 caps->MaxPShaderInstructionsExecuted = 65535;
6122 adapter->gl_info.limits.arb_ps_instructions);
6123 }
6124 else if(caps->PixelShaderVersion == 2)
6125 {
6126 /* Below we assume PS2.0 specs, not extended 2.0a(GeforceFX)/2.0b(Radeon R3xx) ones */
6127 caps->PS20Caps.caps = 0;
6128 caps->PS20Caps.dynamic_flow_control_depth = 0; /* WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH = 0 */
6129 caps->PS20Caps.temp_count = max(12, adapter->gl_info.limits.arb_ps_temps);
6130 caps->PS20Caps.static_flow_control_depth = WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH; /* Minimum: 1 */
6131 /* Minimum number (64 ALU + 32 Texture), a GeforceFX uses 512 */
6132 caps->PS20Caps.instruction_slot_count = WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS;
6133
6134 caps->MaxPShaderInstructionsExecuted = 512; /* Minimum value, a GeforceFX uses 1024 */
6136 }
6137 else /* PS 1.x */
6138 {
6139 caps->PS20Caps.caps = 0;
6140 caps->PS20Caps.dynamic_flow_control_depth = 0;
6141 caps->PS20Caps.temp_count = 0;
6142 caps->PS20Caps.static_flow_control_depth = 0;
6143 caps->PS20Caps.instruction_slot_count = 0;
6144
6147 }
6148
6149 if (caps->VertexShaderVersion >= 2)
6150 {
6151 /* OpenGL supports all the formats below, perhaps not always
6152 * without conversion, but it supports them.
6153 * Further GLSL doesn't seem to have an official unsigned type so
6154 * don't advertise it yet as I'm not sure how we handle it.
6155 * We might need to add some clamping in the shader engine to
6156 * support it.
6157 * TODO: WINED3DDTCAPS_USHORT2N, WINED3DDTCAPS_USHORT4N, WINED3DDTCAPS_UDEC3, WINED3DDTCAPS_DEC3N */
6162 if (gl_info->supported[ARB_HALF_FLOAT_VERTEX])
6163 {
6166 }
6167 }
6168 else
6169 {
6170 caps->DeclTypes = 0;
6171 }
6172
6173 /* Set DirectDraw helper Caps */
6174 ckey_caps = WINEDDCKEYCAPS_DESTBLT |
6176 fx_caps = WINEDDFXCAPS_BLTALPHA |
6188 blit_caps = WINEDDCAPS_BLT |
6197
6198 /* Fill the ddraw caps structure */
6199 caps->ddraw_caps.caps = WINEDDCAPS_GDI |
6201 blit_caps;
6202 caps->ddraw_caps.caps2 = WINEDDCAPS2_CERTIFIED |
6207 caps->ddraw_caps.color_key_caps = ckey_caps;
6208 caps->ddraw_caps.fx_caps = fx_caps;
6209 caps->ddraw_caps.svb_caps = blit_caps;
6210 caps->ddraw_caps.svb_color_key_caps = ckey_caps;
6211 caps->ddraw_caps.svb_fx_caps = fx_caps;
6212 caps->ddraw_caps.vsb_caps = blit_caps;
6213 caps->ddraw_caps.vsb_color_key_caps = ckey_caps;
6214 caps->ddraw_caps.vsb_fx_caps = fx_caps;
6215 caps->ddraw_caps.ssb_caps = blit_caps;
6216 caps->ddraw_caps.ssb_color_key_caps = ckey_caps;
6217 caps->ddraw_caps.ssb_fx_caps = fx_caps;
6218
6219 caps->ddraw_caps.dds_caps = WINEDDSCAPS_ALPHA |
6229
6230 if (!(wined3d->flags & WINED3D_NO3D))
6231 {
6232 caps->ddraw_caps.dds_caps |= WINEDDSCAPS_3DDEVICE |
6236 caps->ddraw_caps.caps |= WINEDDCAPS_3D;
6237 }
6238
6240
6241 return WINED3D_OK;
6242}
DWORD MaxVertexShader30InstructionSlots
Definition: wined3d.h:1968
DWORD DevCaps
Definition: wined3d.h:1895
DWORD MaxVertexShaderConst
Definition: wined3d.h:1946
DWORD MaxPrimitiveCount
Definition: wined3d.h:1940
DWORD MaxTextureAspectRatio
Definition: wined3d.h:1915
DWORD ShadeCaps
Definition: wined3d.h:1902
DWORD PrimitiveMiscCaps
Definition: wined3d.h:1896
struct wined3d_pixel_shader_caps PS20Caps
Definition: wined3d.h:1964
DWORD CursorCaps
Definition: wined3d.h:1894
struct wined3d_ddraw_caps ddraw_caps
Definition: wined3d.h:1973
DWORD MaxStreamStride
Definition: wined3d.h:1943
float GuardBandRight
Definition: wined3d.h:1921
DWORD TextureFilterCaps
Definition: wined3d.h:1904
DWORD DeclTypes
Definition: wined3d.h:1960
DWORD VolumeTextureFilterCaps
Definition: wined3d.h:1906
DWORD MaxTextureHeight
Definition: wined3d.h:1912
UINT MasterAdapterOrdinal
Definition: wined3d.h:1957
DWORD MaxAnisotropy
Definition: wined3d.h:1916
float MaxNpatchTessellationLevel
Definition: wined3d.h:1954
UINT AdapterOrdinalInGroup
Definition: wined3d.h:1958
DWORD StretchRectFilterCaps
Definition: wined3d.h:1962
UINT NumberOfAdaptersInGroup
Definition: wined3d.h:1959
DWORD MaxTextureWidth
Definition: wined3d.h:1911
float MaxVertexW
Definition: wined3d.h:1917
DWORD CubeTextureFilterCaps
Definition: wined3d.h:1905
DWORD AlphaCmpCaps
Definition: wined3d.h:1901
DWORD NumSimultaneousRTs
Definition: wined3d.h:1961
float PixelShader1xMaxValue
Definition: wined3d.h:1949
DWORD TextureAddressCaps
Definition: wined3d.h:1907
DWORD MaxVolumeExtent
Definition: wined3d.h:1913
float GuardBandBottom
Definition: wined3d.h:1922
DWORD DevCaps2
Definition: wined3d.h:1952
struct wined3d_vertex_shader_caps VS20Caps
Definition: wined3d.h:1963
DWORD Caps
Definition: wined3d.h:1889
DWORD LineCaps
Definition: wined3d.h:1909
DWORD MaxVShaderInstructionsExecuted
Definition: wined3d.h:1966
DWORD MaxTextureRepeat
Definition: wined3d.h:1914
DWORD PixelShaderVersion
Definition: wined3d.h:1948
DWORD StencilCaps
Definition: wined3d.h:1925
DWORD MaxUserClipPlanes
Definition: wined3d.h:1934
UINT AdapterOrdinal
Definition: wined3d.h:1887
DWORD VertexProcessingCaps
Definition: wined3d.h:1932
float MaxPointSize
Definition: wined3d.h:1938
DWORD VolumeTextureAddressCaps
Definition: wined3d.h:1908
DWORD TextureCaps
Definition: wined3d.h:1903
DWORD MaxTextureBlendStages
Definition: wined3d.h:1929
DWORD DestBlendCaps
Definition: wined3d.h:1900
float ExtentsAdjust
Definition: wined3d.h:1924
float GuardBandLeft
Definition: wined3d.h:1919
DWORD TextureOpCaps
Definition: wined3d.h:1928
DWORD Caps3
Definition: wined3d.h:1891
DWORD MaxStreams
Definition: wined3d.h:1942
DWORD MaxVertexBlendMatrices
Definition: wined3d.h:1935
DWORD ZCmpCaps
Definition: wined3d.h:1898
BOOL shader_double_precision
Definition: wined3d.h:1975
enum wined3d_device_type DeviceType
Definition: wined3d.h:1886
DWORD MaxSimultaneousTextures
Definition: wined3d.h:1930
DWORD VertexTextureFilterCaps
Definition: wined3d.h:1965
DWORD VertexShaderVersion
Definition: wined3d.h:1945
DWORD PresentationIntervals
Definition: wined3d.h:1892
float GuardBandTop
Definition: wined3d.h:1920
DWORD FVFCaps
Definition: wined3d.h:1927
DWORD RasterCaps
Definition: wined3d.h:1897
DWORD SrcBlendCaps
Definition: wined3d.h:1899
DWORD Caps2
Definition: wined3d.h:1890
DWORD MaxVertexIndex
Definition: wined3d.h:1941
DWORD MaxPixelShader30InstructionSlots
Definition: wined3d.h:1969
DWORD MaxActiveLights
Definition: wined3d.h:1933
DWORD MaxPShaderInstructionsExecuted
Definition: wined3d.h:1967
DWORD MaxSimultaneousTextures
DWORD MaxTextureBlendStages
unsigned int vs_version
DWORD vs_uniform_count
unsigned int ps_version
struct wined3d_gl_limits limits
#define WINED3DPS20_MAX_DYNAMICFLOWCONTROLDEPTH
Definition: wined3d.h:1113
#define WINED3DSTENCILCAPS_ZERO
Definition: wined3d.h:1136
#define WINED3DPMISCCAPS_MASKZ
Definition: wined3d.h:1093
#define WINED3DPTEXTURECAPS_MIPCUBEMAP
Definition: wined3d.h:1255
#define WINED3DPMISCCAPS_CULLCW
Definition: wined3d.h:1096
#define WINED3DPSHADECAPS_FOGGOURAUD
Definition: wined3d.h:1237
#define WINED3DPMISCCAPS_POSTBLENDSRGBCONVERT
Definition: wined3d.h:1111
#define WINED3DSTENCILCAPS_KEEP
Definition: wined3d.h:1135
#define WINEDDCAPS_BLTSTRETCH
Definition: wined3d.h:1504
#define WINED3DPRASTERCAPS_ANISOTROPY
Definition: wined3d.h:1207
#define WINED3DPTADDRESSCAPS_WRAP
Definition: wined3d.h:1128
#define WINED3DPRASTERCAPS_FOGVERTEX
Definition: wined3d.h:1197
#define WINEDDSCAPS_PRIMARYSURFACE
Definition: wined3d.h:1424
#define WINED3DPTEXTURECAPS_NONPOW2CONDITIONAL
Definition: wined3d.h:1248
#define WINED3DVS20_MAX_DYNAMICFLOWCONTROLDEPTH
Definition: wined3d.h:1172
#define WINED3DPBLENDCAPS_INVSRCALPHA
Definition: wined3d.h:1074
#define WINED3DPRASTERCAPS_FOGTABLE
Definition: wined3d.h:1198
#define WINEDDCAPS_COLORKEY
Definition: wined3d.h:1517
#define WINED3DPCMPCAPS_LESSEQUAL
Definition: wined3d.h:1087
#define WINED3DPBLENDCAPS_INVDESTCOLOR
Definition: wined3d.h:1078
#define WINED3DDEVCAPS_TEXTURESYSTEMMEMORY
Definition: wined3d.h:1298
#define WINED3DDEVCAPS_TEXTUREVIDEOMEMORY
Definition: wined3d.h:1299
#define WINED3DDEVCAPS_DRAWPRIMITIVES2
Definition: wined3d.h:1303
#define WINED3DPCMPCAPS_NEVER
Definition: wined3d.h:1084
#define WINED3DCAPS2_DYNAMICTEXTURES
Definition: wined3d.h:1187
#define WINED3DPRASTERCAPS_WFOG
Definition: wined3d.h:1210
#define WINED3DDEVCAPS_PUREDEVICE
Definition: wined3d.h:1309
#define WINED3DPSHADECAPS_COLORFLATRGB
Definition: wined3d.h:1219
#define WINED3DPMISCCAPS_MRTPOSTPIXELSHADERBLENDING
Definition: wined3d.h:1109
#define WINED3DSTENCILCAPS_DECR
Definition: wined3d.h:1142
#define WINEDDCKEYCAPS_DESTBLT
Definition: wined3d.h:1446
#define WINEDDSCAPS_ZBUFFER
Definition: wined3d.h:1432
#define WINED3DPTFILTERCAPS_LINEARMIPNEAREST
Definition: wined3d.h:1264
#define WINED3DVS20CAPS_PREDICATION
Definition: wined3d.h:1179
#define WINEDDFXCAPS_BLTROTATION90
Definition: wined3d.h:1473
#define WINEDDSCAPS_VIDEOMEMORY
Definition: wined3d.h:1429
#define WINED3DPMISCCAPS_INDEPENDENTWRITEMASKS
Definition: wined3d.h:1104
#define WINED3DPS20_MAX_NUMINSTRUCTIONSLOTS
Definition: wined3d.h:1119
#define WINED3DPS20_MAX_STATICFLOWCONTROLDEPTH
Definition: wined3d.h:1117
#define WINED3DPTFILTERCAPS_MAGFLINEAR
Definition: wined3d.h:1272
#define WINED3DPRESENT_INTERVAL_ONE
Definition: wined3d.h:944
#define WINED3DPTEXTURECAPS_CUBEMAP_POW2
Definition: wined3d.h:1256
#define WINED3DPTADDRESSCAPS_INDEPENDENTUV
Definition: wined3d.h:1132
#define WINED3DPTFILTERCAPS_MIPNEAREST
Definition: wined3d.h:1262
#define WINED3DPTEXTURECAPS_MIPVOLUMEMAP
Definition: wined3d.h:1254
#define WINED3DLINECAPS_BLEND
Definition: wined3d.h:1061
#define WINED3DCAPS2_CANRENDERWINDOWED
Definition: wined3d.h:1183
#define WINED3DPBLENDCAPS_ZERO
Definition: wined3d.h:1069
#define WINED3DCAPS3_ALPHA_FULLSCREEN_FLIP_OR_DISCARD
Definition: wined3d.h:1030
#define WINED3DPTADDRESSCAPS_CLAMP
Definition: wined3d.h:1130
#define WINEDDFXCAPS_BLTSTRETCHX
Definition: wined3d.h:1478
#define WINED3DPBLENDCAPS_SRCALPHASAT
Definition: wined3d.h:1079
#define WINEDDFXCAPS_BLTSHRINKYN
Definition: wined3d.h:1477
#define WINED3DCAPS2_CANGENMIPMAP
Definition: wined3d.h:1188
#define WINED3DDEVCAPS_TLVERTEXSYSTEMMEMORY
Definition: wined3d.h:1296
#define WINED3DCAPS2_FULLSCREENGAMMA
Definition: wined3d.h:1182
#define WINED3DPRASTERCAPS_MIPMAPLODBIAS
Definition: wined3d.h:1203
#define WINED3DPSHADECAPS_ALPHAGOURAUDBLEND
Definition: wined3d.h:1232
#define WINED3DSTENCILCAPS_REPLACE
Definition: wined3d.h:1137
#define WINEDDSCAPS_OFFSCREENPLAIN
Definition: wined3d.h:1421
#define WINED3DSTENCILCAPS_INCRSAT
Definition: wined3d.h:1138
#define WINED3DPTFILTERCAPS_MINFANISOTROPIC
Definition: wined3d.h:1268
#define WINED3DPTEXTURECAPS_VOLUMEMAP
Definition: wined3d.h:1252
#define WINED3DPRASTERCAPS_ZTEST
Definition: wined3d.h:1194
#define WINED3DPTFILTERCAPS_MIPFLINEAR
Definition: wined3d.h:1270
#define WINED3DPTEXTURECAPS_ALPHA
Definition: wined3d.h:1242
#define WINED3DPMISCCAPS_CULLNONE
Definition: wined3d.h:1095
#define WINED3DPS20CAPS_PREDICATION
Definition: wined3d.h:1124
#define WINED3DPTEXTURECAPS_POW2
Definition: wined3d.h:1241
#define WINED3DPMISCCAPS_SEPARATEALPHABLEND
Definition: wined3d.h:1107
#define WINED3DDEVCAPS_DRAWPRIMTLVERTEX
Definition: wined3d.h:1300
#define WINEDDCAPS_3D
Definition: wined3d.h:1495
#define WINED3DPS20_MIN_STATICFLOWCONTROLDEPTH
Definition: wined3d.h:1118
#define WINEDDFXCAPS_BLTSTRETCHYN
Definition: wined3d.h:1481
#define WINEDDCAPS_GDI
Definition: wined3d.h:1505
#define WINED3DLINECAPS_ZTEST
Definition: wined3d.h:1060
#define WINED3DPTEXTURECAPS_BORDER
Definition: wined3d.h:1244
#define WINED3DPMISCCAPS_CULLCCW
Definition: wined3d.h:1097
#define WINED3DDTCAPS_SHORT4N
Definition: wined3d.h:1047
#define WINED3DVS20_MIN_DYNAMICFLOWCONTROLDEPTH
Definition: wined3d.h:1173
#define WINEDDSCAPS_PALETTE
Definition: wined3d.h:1423
#define WINEDDCAPS_BLTDEPTHFILL
Definition: wined3d.h:1523
#define WINEDDCAPS_CANCLIP
Definition: wined3d.h:1524
#define WINED3DLINECAPS_FOG
Definition: wined3d.h:1063
#define WINED3DPSHADECAPS_SPECULARFLATRGB
Definition: wined3d.h:1225
#define WINEDDSCAPS_VISIBLE
Definition: wined3d.h:1430
#define WINED3DPRASTERCAPS_ZFOG
Definition: wined3d.h:1211
#define WINED3DSTENCILCAPS_DECRSAT
Definition: wined3d.h:1139
#define WINED3DDTCAPS_FLOAT16_2
Definition: wined3d.h:1052
#define WINED3DPTADDRESSCAPS_MIRRORONCE
Definition: wined3d.h:1133
#define WINEDDCAPS_COLORKEYHWASSIST
Definition: wined3d.h:1519
#define WINED3DPBLENDCAPS_SRCCOLOR
Definition: wined3d.h:1071
#define WINED3DDEVCAPS_FLOATTLVERTEX
Definition: wined3d.h:1290
#define WINEDDCAPS_BLTCOLORFILL
Definition: wined3d.h:1521
#define WINED3DPRASTERCAPS_SUBPIXEL
Definition: wined3d.h:1195
#define WINED3DDEVCAPS_EXECUTESYSTEMMEMORY
Definition: wined3d.h:1294
#define WINED3DPTEXTURECAPS_TRANSPARENCY
Definition: wined3d.h:1243
#define WINED3DPRASTERCAPS_STIPPLE
Definition: wined3d.h:1199
#define WINED3DPS20CAPS_ARBITRARYSWIZZLE
Definition: wined3d.h:1122
#define WINED3DPCMPCAPS_LESS
Definition: wined3d.h:1085
#define WINED3DPSHADECAPS_SPECULARGOURAUDRGB
Definition: wined3d.h:1227
#define WINED3DPSHADECAPS_COLORGOURAUDRGB
Definition: wined3d.h:1221
#define WINED3DPTFILTERCAPS_LINEARMIPLINEAR
Definition: wined3d.h:1265
#define WINEDDSCAPS_TEXTURE
Definition: wined3d.h:1427
#define WINEDDCAPS2_CERTIFIED
Definition: wined3d.h:1528
#define WINED3DPTEXTURECAPS_MIPMAP
Definition: wined3d.h:1253
#define WINED3DPBLENDCAPS_DESTCOLOR
Definition: wined3d.h:1077
#define WINEDDCAPS2_NOPAGELOCKREQUIRED
Definition: wined3d.h:1539
#define WINED3DDEVCAPS_HWRASTERIZATION
Definition: wined3d.h:1308
#define WINEDDFXCAPS_BLTSHRINKXN
Definition: wined3d.h:1475
#define WINED3DPRASTERCAPS_PAT
Definition: wined3d.h:1193
#define WINEDDFXCAPS_BLTMIRRORUPDOWN
Definition: wined3d.h:1471
#define WINED3DPTADDRESSCAPS_BORDER
Definition: wined3d.h:1131
#define WINEDDFXCAPS_BLTSTRETCHXN
Definition: wined3d.h:1479
#define WINED3DPSHADECAPS_ALPHAFLATBLEND
Definition: wined3d.h:1230
#define WINED3DPBLENDCAPS_ONE
Definition: wined3d.h:1070
#define WINED3DDTCAPS_FLOAT16_4
Definition: wined3d.h:1053
#define WINEDDSCAPS_ALPHA
Definition: wined3d.h:1416
#define WINED3DCAPS3_COPY_TO_VIDMEM
Definition: wined3d.h:1032
#define WINED3DPRASTERCAPS_ZBIAS
Definition: wined3d.h:1204
#define WINED3DPTADDRESSCAPS_MIRROR
Definition: wined3d.h:1129
#define WINED3DPTFILTERCAPS_NEAREST
Definition: wined3d.h:1260
#define WINEDDCAPS_PALETTE
Definition: wined3d.h:1510
#define WINED3DPRASTERCAPS_DEPTHBIAS
Definition: wined3d.h:1215
#define WINEDDCAPS_CANBLTSYSMEM
Definition: wined3d.h:1526
#define WINEDDSCAPS_FLIP
Definition: wined3d.h:1419
#define WINED3DPTFILTERCAPS_MAGFPOINT
Definition: wined3d.h:1271
#define WINEDDCAPS_CANCLIPSTRETCHED
Definition: wined3d.h:1525
#define WINED3DMIN30SHADERINSTRUCTIONS
Definition: wined3d.h:1067
#define WINED3DDEVCAPS_CANRENDERAFTERFLIP
Definition: wined3d.h:1301
#define WINED3DPRASTERCAPS_SLOPESCALEDEPTHBIAS
Definition: wined3d.h:1214
#define WINED3DPTFILTERCAPS_LINEAR
Definition: wined3d.h:1261
#define WINED3DPS20CAPS_GRADIENTINSTRUCTIONS
Definition: wined3d.h:1123
#define WINED3DPRASTERCAPS_DITHER
Definition: wined3d.h:1190
#define WINED3DPTFILTERCAPS_MAGFANISOTROPIC
Definition: wined3d.h:1273
#define WINEDDSCAPS_FRONTBUFFER
Definition: wined3d.h:1420
#define WINED3DPTEXTURECAPS_PERSPECTIVE
Definition: wined3d.h:1240
#define WINED3DCURSORCAPS_COLOR
Definition: wined3d.h:1287
#define WINEDDFXCAPS_BLTSHRINKX
Definition: wined3d.h:1474
#define WINED3DDTCAPS_UBYTE4N
Definition: wined3d.h:1045
#define WINED3DPBLENDCAPS_BOTHINVSRCALPHA
Definition: wined3d.h:1081
#define WINED3DPS20CAPS_NOTEXINSTRUCTIONLIMIT
Definition: wined3d.h:1126
#define WINED3DCURSORCAPS_LOWRES
Definition: wined3d.h:1288
#define WINED3DPMISCCAPS_BLENDOP
Definition: wined3d.h:1102
#define WINED3DPS20_MIN_NUMINSTRUCTIONSLOTS
Definition: wined3d.h:1120
#define WINED3DSTENCILCAPS_INVERT
Definition: wined3d.h:1140
#define WINED3DPTFILTERCAPS_MIPLINEAR
Definition: wined3d.h:1263
#define WINEDDCAPS2_CANRENDERWINDOWED
Definition: wined3d.h:1545
#define WINED3DPMISCCAPS_CLIPPLANESCALEDPOINTS
Definition: wined3d.h:1099
#define WINED3DPTEXTURECAPS_PROJECTED
Definition: wined3d.h:1249
#define WINED3DPCMPCAPS_GREATEREQUAL
Definition: wined3d.h:1090
#define WINED3DDTCAPS_SHORT2N
Definition: wined3d.h:1046
#define WINED3DPTFILTERCAPS_MINFPOINT
Definition: wined3d.h:1266
#define WINED3DPTEXTURECAPS_VOLUMEMAP_POW2
Definition: wined3d.h:1257
#define WINED3DPBLENDCAPS_INVSRCCOLOR
Definition: wined3d.h:1072
#define WINEDDCAPS2_PRIMARYGAMMA
Definition: wined3d.h:1544
#define WINED3DPCMPCAPS_EQUAL
Definition: wined3d.h:1086
#define WINED3DPBLENDCAPS_BLENDFACTOR
Definition: wined3d.h:1082
#define WINED3DPMISCCAPS_COLORWRITEENABLE
Definition: wined3d.h:1098
#define WINEDDFXCAPS_BLTSHRINKY
Definition: wined3d.h:1476
#define WINED3DPCMPCAPS_NOTEQUAL
Definition: wined3d.h:1089
#define WINED3DSTENCILCAPS_INCR
Definition: wined3d.h:1141
#define WINEDDSCAPS_SYSTEMMEMORY
Definition: wined3d.h:1426
#define WINED3DPTEXTURECAPS_CUBEMAP
Definition: wined3d.h:1250
#define WINED3DLINECAPS_TEXTURE
Definition: wined3d.h:1059
#define WINED3DPBLENDCAPS_SRCALPHA
Definition: wined3d.h:1073
#define WINED3DPRESENT_INTERVAL_IMMEDIATE
Definition: wined3d.h:948
#define WINED3DDEVCAPS2_STREAMOFFSET
Definition: wined3d.h:1036
#define WINED3DDEVCAPS_DRAWPRIMITIVES2EX
Definition: wined3d.h:1305
#define WINEDDFXCAPS_BLTSTRETCHY
Definition: wined3d.h:1480
#define WINED3DPBLENDCAPS_DESTALPHA
Definition: wined3d.h:1075
#define WINED3DPRASTERCAPS_SCISSORTEST
Definition: wined3d.h:1213
#define WINED3DPTFILTERCAPS_MIPFPOINT
Definition: wined3d.h:1269
#define WINED3DCAPS3_COPY_TO_SYSTEMMEM
Definition: wined3d.h:1033
#define WINED3DPS20CAPS_NODEPENDENTREADLIMIT
Definition: wined3d.h:1125
#define WINED3DPCMPCAPS_GREATER
Definition: wined3d.h:1088
#define WINEDDCKEYCAPS_SRCBLT
Definition: wined3d.h:1455
#define WINEDDFXCAPS_BLTALPHA
Definition: wined3d.h:1466
#define WINED3DPBLENDCAPS_INVDESTALPHA
Definition: wined3d.h:1076
#define WINEDDCAPS2_WIDESURFACES
Definition: wined3d.h:1540
#define WINED3DPTFILTERCAPS_MINFLINEAR
Definition: wined3d.h:1267
#define WINEDDSCAPS_3DDEVICE
Definition: wined3d.h:1428
#define WINED3DPTEXTURECAPS_ALPHAPALETTE
Definition: wined3d.h:1247
#define WINED3DPBLENDCAPS_BOTHSRCALPHA
Definition: wined3d.h:1080
#define WINEDDSCAPS_MIPMAP
Definition: wined3d.h:1437
#define WINEDDSCAPS_BACKBUFFER
Definition: wined3d.h:1417
#define WINEDDCAPS_BLT
Definition: wined3d.h:1501
#define WINED3DDEVCAPS_EXECUTEVIDEOMEMORY
Definition: wined3d.h:1295
#define WINEDDFXCAPS_BLTMIRRORLEFTRIGHT
Definition: wined3d.h:1470
#define WINED3DPMISCCAPS_CLIPTLVERTS
Definition: wined3d.h:1100
#define WINED3DDTCAPS_UBYTE4
Definition: wined3d.h:1044
#define WINED3DVS20_MAX_STATICFLOWCONTROLDEPTH
Definition: wined3d.h:1176
#define WINED3DDEVCAPS_TLVERTEXVIDEOMEMORY
Definition: wined3d.h:1297
#define WINED3DDEVCAPS_HWTRANSFORMANDLIGHT
Definition: wined3d.h:1306
#define WINED3DLINECAPS_ALPHACMP
Definition: wined3d.h:1062
#define WINED3DPSHADECAPS_FOGFLAT
Definition: wined3d.h:1236
#define WINED3DPCMPCAPS_ALWAYS
Definition: wined3d.h:1091
#define WINED3DDEVCAPS2_VERTEXELEMENTSCANSHARESTREAMOFFSET
Definition: wined3d.h:1042
#define WINED3DSTENCILCAPS_TWOSIDED
Definition: wined3d.h:1143
@ EXT_STENCIL_TWO_SIDE
Definition: wined3d_gl.h:169
@ EXT_BLEND_EQUATION_SEPARATE
Definition: wined3d_gl.h:151
@ ARB_TEXTURE_FILTER_ANISOTROPIC
Definition: wined3d_gl.h:117
@ ARB_TEXTURE_CUBE_MAP
Definition: wined3d_gl.h:113
@ ATI_SEPARATE_STENCIL
Definition: wined3d_gl.h:145
@ WINED3D_GL_BLEND_EQUATION
Definition: wined3d_gl.h:212
@ EXT_STENCIL_WRAP
Definition: wined3d_gl.h:170
@ ARB_TEXTURE_MIRRORED_REPEAT
Definition: wined3d_gl.h:120
@ ARB_FRAMEBUFFER_OBJECT
Definition: wined3d_gl.h:73
@ EXT_TEXTURE3D
Definition: wined3d_gl.h:171
@ ARB_TEXTURE_BORDER_CLAMP
Definition: wined3d_gl.h:107
@ ARB_HALF_FLOAT_VERTEX
Definition: wined3d_gl.h:78
@ EXT_BLEND_FUNC_SEPARATE
Definition: wined3d_gl.h:152
@ ARB_FRAMEBUFFER_SRGB
Definition: wined3d_gl.h:74
@ WINED3D_GL_NORMALIZED_TEXRECT
Definition: wined3d_gl.h:214
@ EXT_BLEND_COLOR
Definition: wined3d_gl.h:150
@ ARB_BLEND_FUNC_EXTENDED
Definition: wined3d_gl.h:46
@ ARB_TEXTURE_MIRROR_CLAMP_TO_EDGE
Definition: wined3d_gl.h:121
@ ARB_TEXTURE_RECTANGLE
Definition: wined3d_gl.h:125
@ ARB_TEXTURE_NON_POWER_OF_TWO
Definition: wined3d_gl.h:123
@ EXT_FRAMEBUFFER_OBJECT
Definition: wined3d_gl.h:160
@ WINED3D_GL_VERSION_2_0
Definition: wined3d_gl.h:216
@ EXT_DRAW_BUFFERS2
Definition: wined3d_gl.h:155

Referenced by d3d8_GetDeviceCaps(), d3d9_GetDeviceCaps(), ddraw_get_d3dcaps(), ddraw_init(), device_init(), and wined3d_device_get_device_caps().

◆ wined3d_get_output_desc()

HRESULT __cdecl wined3d_get_output_desc ( const struct wined3d wined3d,
unsigned int  adapter_idx,
struct wined3d_output_desc desc 
)

Definition at line 4499 of file directx.c.

4501{
4502 enum wined3d_display_rotation rotation;
4503 const struct wined3d_adapter *adapter;
4505 HMONITOR monitor;
4506 HRESULT hr;
4507
4508 TRACE("wined3d %p, adapter_idx %u, desc %p.\n", wined3d, adapter_idx, desc);
4509
4510 if (adapter_idx >= wined3d->adapter_count)
4512
4513 adapter = &wined3d->adapters[adapter_idx];
4514 if (!(monitor = MonitorFromPoint(adapter->monitor_position, MONITOR_DEFAULTTOPRIMARY)))
4516
4517 if (FAILED(hr = wined3d_get_adapter_display_mode(wined3d, adapter_idx, &mode, &rotation)))
4518 return hr;
4519
4520 memcpy(desc->device_name, adapter->DeviceName, sizeof(desc->device_name));
4521 SetRect(&desc->desktop_rect, 0, 0, mode.width, mode.height);
4522 OffsetRect(&desc->desktop_rect, adapter->monitor_position.x, adapter->monitor_position.y);
4523 /* FIXME: We should get this from EnumDisplayDevices() when the adapters
4524 * are created. */
4525 desc->attached_to_desktop = TRUE;
4526 desc->rotation = rotation;
4527 desc->monitor = monitor;
4528
4529 return WINED3D_OK;
4530}
HMONITOR WINAPI MonitorFromPoint(POINT, DWORD)
wined3d_display_rotation
Definition: wined3d.h:838
BOOL WINAPI OffsetRect(_Inout_ LPRECT, _In_ int, _In_ int)

Referenced by d3d8_GetAdapterMonitor(), d3d9_GetAdapterMonitor(), and ddraw_enumerate_secondary_devices().

◆ wined3d_incref()

ULONG __cdecl wined3d_incref ( struct wined3d wined3d)

Definition at line 456 of file directx.c.

457{
459
460 TRACE("%p increasing refcount to %u.\n", wined3d, refcount);
461
462 return refcount;
463}

Referenced by device_init().

◆ wined3d_log2i()

static unsigned int wined3d_log2i ( unsigned int  x)
inlinestatic

Definition at line 2759 of file wined3d.h.

2760{
2761#ifdef HAVE___BUILTIN_CLZ
2762 return __builtin_clz(x) ^ 0x1f;
2763#else
2764 static const unsigned int l[] =
2765 {
2766 ~0u, 0, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, 3,
2767 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4, 4,
2768 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
2769 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5, 5,
2770 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
2771 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
2772 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
2773 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6, 6,
2774 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2775 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2776 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2777 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2778 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2779 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2780 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2781 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7, 7,
2782 };
2783 unsigned int i;
2784
2785 return (i = x >> 16) ? (x = i >> 8) ? l[x] + 24 : l[i] + 16 : (i = x >> 8) ? l[i] + 8 : l[x];
2786#endif
2787}
r l[0]
Definition: byte_order.h:168
GLint GLint GLint GLint GLint x
Definition: gl.h:1548

Referenced by cubetexture_init(), ddraw_surface_create(), query_internal_format(), shader_find_free_input_register(), shader_glsl_alloc(), shader_glsl_generate_vshader(), texture_init(), and volumetexture_init().

◆ wined3d_mutex_lock()

void __stdcall wined3d_mutex_lock ( void  )

Definition at line 368 of file wined3d_main.c.

369{
371}
void WINAPI EnterCriticalSection(LPCRITICAL_SECTION)

Referenced by CF_CreateDirectDraw(), CF_CreateDirectDrawClipper(), cubetexture_init(), d3d2_CreateDevice(), d3d3_CreateDevice(), d3d3_EnumDevices(), d3d7_CreateDevice(), d3d7_EnumDevices(), d3d7_EnumZBufferFormats(), d3d7_EvictManagedTextures(), d3d8_CheckDepthStencilMatch(), d3d8_CheckDeviceFormat(), d3d8_CheckDeviceMultiSampleType(), d3d8_CheckDeviceType(), d3d8_device_ApplyStateBlock(), d3d8_device_BeginScene(), d3d8_device_BeginStateBlock(), d3d8_device_CaptureStateBlock(), d3d8_device_Clear(), d3d8_device_CopyRects(), d3d8_device_create_surface(), d3d8_device_CreateAdditionalSwapChain(), d3d8_device_CreatePixelShader(), d3d8_device_CreateStateBlock(), d3d8_device_CreateVertexShader(), d3d8_device_DeletePixelShader(), d3d8_device_DeleteStateBlock(), d3d8_device_DeleteVertexShader(), d3d8_device_DrawIndexedPrimitive(), d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_DrawPrimitive(), d3d8_device_DrawPrimitiveUP(), d3d8_device_EndScene(), d3d8_device_EndStateBlock(), d3d8_device_GetAvailableTextureMem(), d3d8_device_GetBackBuffer(), d3d8_device_GetClipPlane(), d3d8_device_GetClipStatus(), d3d8_device_GetCreationParameters(), d3d8_device_GetDepthStencilSurface(), d3d8_device_GetDeviceCaps(), d3d8_device_GetDisplayMode(), d3d8_device_GetFrontBuffer(), d3d8_device_GetGammaRamp(), d3d8_device_GetIndices(), d3d8_device_GetLight(), d3d8_device_GetLightEnable(), d3d8_device_GetMaterial(), d3d8_device_GetPixelShader(), d3d8_device_GetPixelShaderConstant(), d3d8_device_GetPixelShaderFunction(), d3d8_device_GetRasterStatus(), d3d8_device_GetRenderState(), d3d8_device_GetRenderTarget(), d3d8_device_GetStreamSource(), d3d8_device_GetTexture(), d3d8_device_GetTextureStageState(), d3d8_device_GetTransform(), d3d8_device_GetVertexShader(), d3d8_device_GetVertexShaderConstant(), d3d8_device_GetVertexShaderDeclaration(), d3d8_device_GetVertexShaderFunction(), d3d8_device_GetViewport(), d3d8_device_LightEnable(), d3d8_device_MultiplyTransform(), d3d8_device_ProcessVertices(), d3d8_device_Release(), d3d8_device_Reset(), d3d8_device_ResourceManagerDiscardBytes(), d3d8_device_SetClipPlane(), d3d8_device_SetClipStatus(), d3d8_device_SetCursorPosition(), d3d8_device_SetCursorProperties(), d3d8_device_SetGammaRamp(), d3d8_device_SetIndices(), d3d8_device_SetLight(), d3d8_device_SetMaterial(), d3d8_device_SetPixelShader(), d3d8_device_SetPixelShaderConstant(), d3d8_device_SetRenderState(), d3d8_device_SetRenderTarget(), d3d8_device_SetStreamSource(), d3d8_device_SetTexture(), d3d8_device_SetTextureStageState(), d3d8_device_SetTransform(), d3d8_device_SetVertexShader(), d3d8_device_SetVertexShaderConstant(), d3d8_device_SetViewport(), d3d8_device_ShowCursor(), d3d8_device_UpdateTexture(), d3d8_device_ValidateDevice(), d3d8_EnumAdapterModes(), d3d8_GetAdapterCount(), d3d8_GetAdapterDisplayMode(), d3d8_GetAdapterIdentifier(), d3d8_GetAdapterModeCount(), d3d8_GetAdapterMonitor(), d3d8_GetDeviceCaps(), d3d8_indexbuffer_AddRef(), d3d8_indexbuffer_GetDesc(), d3d8_indexbuffer_GetPriority(), d3d8_indexbuffer_Lock(), d3d8_indexbuffer_PreLoad(), d3d8_indexbuffer_Release(), d3d8_indexbuffer_SetPriority(), d3d8_indexbuffer_Unlock(), d3d8_init(), d3d8_pixel_shader_destroy(), d3d8_pixel_shader_init(), d3d8_RegisterSoftwareDevice(), d3d8_Release(), d3d8_resource_free_private_data(), d3d8_resource_get_private_data(), d3d8_resource_set_private_data(), d3d8_surface_AddRef(), d3d8_surface_GetDesc(), d3d8_surface_LockRect(), d3d8_surface_Release(), d3d8_surface_UnlockRect(), d3d8_swapchain_AddRef(), d3d8_swapchain_GetBackBuffer(), d3d8_swapchain_Present(), d3d8_swapchain_Release(), d3d8_texture_2d_AddDirtyRect(), d3d8_texture_2d_AddRef(), d3d8_texture_2d_GetLevelCount(), d3d8_texture_2d_GetLevelDesc(), d3d8_texture_2d_GetLOD(), d3d8_texture_2d_GetPriority(), d3d8_texture_2d_GetSurfaceLevel(), d3d8_texture_2d_LockRect(), d3d8_texture_2d_PreLoad(), d3d8_texture_2d_Release(), d3d8_texture_2d_SetLOD(), d3d8_texture_2d_SetPriority(), d3d8_texture_2d_UnlockRect(), d3d8_texture_3d_AddDirtyBox(), d3d8_texture_3d_AddRef(), d3d8_texture_3d_GetLevelCount(), d3d8_texture_3d_GetLevelDesc(), d3d8_texture_3d_GetLOD(), d3d8_texture_3d_GetPriority(), d3d8_texture_3d_GetVolumeLevel(), d3d8_texture_3d_LockBox(), d3d8_texture_3d_PreLoad(), d3d8_texture_3d_Release(), d3d8_texture_3d_SetLOD(), d3d8_texture_3d_SetPriority(), d3d8_texture_3d_UnlockBox(), d3d8_texture_cube_AddDirtyRect(), d3d8_texture_cube_AddRef(), d3d8_texture_cube_GetCubeMapSurface(), d3d8_texture_cube_GetLevelCount(), d3d8_texture_cube_GetLevelDesc(), d3d8_texture_cube_GetLOD(), d3d8_texture_cube_GetPriority(), d3d8_texture_cube_LockRect(), d3d8_texture_cube_PreLoad(), d3d8_texture_cube_Release(), d3d8_texture_cube_SetLOD(), d3d8_texture_cube_SetPriority(), d3d8_texture_cube_UnlockRect(), d3d8_vertex_declaration_destroy(), d3d8_vertex_declaration_init(), d3d8_vertex_shader_destroy(), d3d8_vertex_shader_init(), d3d8_vertexbuffer_AddRef(), d3d8_vertexbuffer_GetDesc(), d3d8_vertexbuffer_GetPriority(), d3d8_vertexbuffer_Lock(), d3d8_vertexbuffer_PreLoad(), d3d8_vertexbuffer_Release(), d3d8_vertexbuffer_SetPriority(), d3d8_vertexbuffer_Unlock(), d3d8_volume_GetDesc(), d3d8_volume_LockBox(), d3d8_volume_UnlockBox(), d3d9_CheckDepthStencilMatch(), d3d9_CheckDeviceFormat(), d3d9_CheckDeviceFormatConversion(), d3d9_CheckDeviceMultiSampleType(), d3d9_CheckDeviceType(), d3d9_device_BeginScene(), d3d9_device_BeginStateBlock(), d3d9_device_CheckDeviceState(), d3d9_device_Clear(), d3d9_device_ColorFill(), d3d9_device_create_surface(), d3d9_device_CreateAdditionalSwapChain(), d3d9_device_DrawIndexedPrimitive(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawPrimitive(), d3d9_device_DrawPrimitiveUP(), d3d9_device_EndScene(), d3d9_device_EndStateBlock(), d3d9_device_EvictManagedResources(), d3d9_device_GetAvailableTextureMem(), d3d9_device_GetBackBuffer(), d3d9_device_GetClipPlane(), d3d9_device_GetClipStatus(), d3d9_device_GetCreationParameters(), d3d9_device_GetDepthStencilSurface(), d3d9_device_GetDeviceCaps(), d3d9_device_GetDisplayMode(), d3d9_device_GetDisplayModeEx(), d3d9_device_GetFrontBufferData(), d3d9_device_GetFVF(), d3d9_device_GetGammaRamp(), d3d9_device_GetIndices(), d3d9_device_GetLight(), d3d9_device_GetLightEnable(), d3d9_device_GetMaterial(), d3d9_device_GetNPatchMode(), d3d9_device_GetNumberOfSwapChains(), d3d9_device_GetPixelShader(), d3d9_device_GetPixelShaderConstantB(), d3d9_device_GetPixelShaderConstantF(), d3d9_device_GetPixelShaderConstantI(), d3d9_device_GetRasterStatus(), d3d9_device_GetRenderState(), d3d9_device_GetRenderTarget(), d3d9_device_GetRenderTargetData(), d3d9_device_GetSamplerState(), d3d9_device_GetScissorRect(), d3d9_device_GetSoftwareVertexProcessing(), d3d9_device_GetStreamSource(), d3d9_device_GetStreamSourceFreq(), d3d9_device_GetSwapChain(), d3d9_device_GetTexture(), d3d9_device_GetTextureStageState(), d3d9_device_GetTransform(), d3d9_device_GetVertexDeclaration(), d3d9_device_GetVertexShader(), d3d9_device_GetVertexShaderConstantB(), d3d9_device_GetVertexShaderConstantF(), d3d9_device_GetVertexShaderConstantI(), d3d9_device_GetViewport(), d3d9_device_LightEnable(), d3d9_device_MultiplyTransform(), d3d9_device_Present(), d3d9_device_PresentEx(), d3d9_device_ProcessVertices(), d3d9_device_Release(), d3d9_device_reset(), d3d9_device_SetClipPlane(), d3d9_device_SetClipStatus(), d3d9_device_SetCursorPosition(), d3d9_device_SetCursorProperties(), d3d9_device_SetDepthStencilSurface(), d3d9_device_SetDialogBoxMode(), d3d9_device_SetFVF(), d3d9_device_SetGammaRamp(), d3d9_device_SetIndices(), d3d9_device_SetLight(), d3d9_device_SetMaterial(), d3d9_device_SetNPatchMode(), d3d9_device_SetPixelShader(), d3d9_device_SetPixelShaderConstantB(), d3d9_device_SetPixelShaderConstantF(), d3d9_device_SetPixelShaderConstantI(), d3d9_device_SetRenderState(), d3d9_device_SetRenderTarget(), d3d9_device_SetSamplerState(), d3d9_device_SetScissorRect(), d3d9_device_SetSoftwareVertexProcessing(), d3d9_device_SetStreamSource(), d3d9_device_SetStreamSourceFreq(), d3d9_device_SetTexture(), d3d9_device_SetTextureStageState(), d3d9_device_SetTransform(), d3d9_device_SetVertexDeclaration(), d3d9_device_SetVertexShader(), d3d9_device_SetVertexShaderConstantB(), d3d9_device_SetVertexShaderConstantF(), d3d9_device_SetVertexShaderConstantI(), d3d9_device_SetViewport(), d3d9_device_ShowCursor(), d3d9_device_StretchRect(), d3d9_device_UpdateSurface(), d3d9_device_UpdateTexture(), d3d9_device_ValidateDevice(), d3d9_EnumAdapterModes(), d3d9_EnumAdapterModesEx(), d3d9_GetAdapterCount(), d3d9_GetAdapterDisplayMode(), d3d9_GetAdapterDisplayModeEx(), d3d9_GetAdapterIdentifier(), d3d9_GetAdapterLUID(), d3d9_GetAdapterModeCount(), d3d9_GetAdapterModeCountEx(), d3d9_GetAdapterMonitor(), d3d9_GetDeviceCaps(), d3d9_indexbuffer_AddRef(), d3d9_indexbuffer_GetDesc(), d3d9_indexbuffer_GetPriority(), d3d9_indexbuffer_Lock(), d3d9_indexbuffer_PreLoad(), d3d9_indexbuffer_Release(), d3d9_indexbuffer_SetPriority(), d3d9_indexbuffer_Unlock(), d3d9_init(), d3d9_pixelshader_AddRef(), d3d9_pixelshader_GetFunction(), d3d9_pixelshader_Release(), d3d9_query_GetData(), d3d9_query_GetType(), d3d9_query_Issue(), d3d9_query_Release(), d3d9_RegisterSoftwareDevice(), d3d9_Release(), d3d9_resource_free_private_data(), d3d9_resource_get_private_data(), d3d9_resource_set_private_data(), d3d9_stateblock_Apply(), d3d9_stateblock_Capture(), d3d9_stateblock_Release(), d3d9_surface_AddRef(), d3d9_surface_GetDC(), d3d9_surface_GetDesc(), d3d9_surface_LockRect(), d3d9_surface_PreLoad(), d3d9_surface_Release(), d3d9_surface_ReleaseDC(), d3d9_surface_UnlockRect(), d3d9_swapchain_AddRef(), d3d9_swapchain_GetBackBuffer(), d3d9_swapchain_GetDisplayMode(), d3d9_swapchain_GetDisplayModeEx(), d3d9_swapchain_GetFrontBufferData(), d3d9_swapchain_GetPresentParameters(), d3d9_swapchain_GetRasterStatus(), d3d9_swapchain_Present(), d3d9_swapchain_Release(), d3d9_texture_2d_AddDirtyRect(), d3d9_texture_2d_AddRef(), d3d9_texture_2d_GenerateMipSubLevels(), d3d9_texture_2d_GetLevelCount(), d3d9_texture_2d_GetLevelDesc(), d3d9_texture_2d_GetLOD(), d3d9_texture_2d_GetPriority(), d3d9_texture_2d_GetSurfaceLevel(), d3d9_texture_2d_LockRect(), d3d9_texture_2d_PreLoad(), d3d9_texture_2d_SetLOD(), d3d9_texture_2d_SetPriority(), d3d9_texture_2d_UnlockRect(), d3d9_texture_3d_AddDirtyBox(), d3d9_texture_3d_AddRef(), d3d9_texture_3d_GetLevelCount(), d3d9_texture_3d_GetLevelDesc(), d3d9_texture_3d_GetLOD(), d3d9_texture_3d_GetPriority(), d3d9_texture_3d_GetVolumeLevel(), d3d9_texture_3d_LockBox(), d3d9_texture_3d_PreLoad(), d3d9_texture_3d_SetLOD(), d3d9_texture_3d_SetPriority(), d3d9_texture_3d_UnlockBox(), d3d9_texture_cleanup(), d3d9_texture_cube_AddDirtyRect(), d3d9_texture_cube_AddRef(), d3d9_texture_cube_GenerateMipSubLevels(), d3d9_texture_cube_GetCubeMapSurface(), d3d9_texture_cube_GetLevelCount(), d3d9_texture_cube_GetLevelDesc(), d3d9_texture_cube_GetLOD(), d3d9_texture_cube_GetPriority(), d3d9_texture_cube_LockRect(), d3d9_texture_cube_PreLoad(), d3d9_texture_cube_SetLOD(), d3d9_texture_cube_SetPriority(), d3d9_texture_cube_UnlockRect(), d3d9_vertex_declaration_AddRef(), d3d9_vertex_declaration_Release(), d3d9_vertexbuffer_AddRef(), d3d9_vertexbuffer_GetDesc(), d3d9_vertexbuffer_GetPriority(), d3d9_vertexbuffer_Lock(), d3d9_vertexbuffer_PreLoad(), d3d9_vertexbuffer_Release(), d3d9_vertexbuffer_SetPriority(), d3d9_vertexbuffer_Unlock(), d3d9_vertexshader_AddRef(), d3d9_vertexshader_GetFunction(), d3d9_vertexshader_Release(), d3d9_volume_GetDesc(), d3d9_volume_LockBox(), d3d9_volume_UnlockBox(), d3d_device1_CreateMatrix(), d3d_device1_DeleteMatrix(), d3d_device1_Execute(), d3d_device1_GetMatrix(), d3d_device1_SetMatrix(), d3d_device2_EnumTextureFormats(), d3d_device2_SetRenderTarget(), d3d_device2_SwapTextureHandles(), d3d_device3_AddViewport(), d3d_device3_Begin(), d3d_device3_DeleteViewport(), d3d_device3_GetCurrentViewport(), d3d_device3_GetLightState(), d3d_device3_GetRenderState(), d3d_device3_GetTransform(), d3d_device3_MultiplyTransform(), d3d_device3_NextViewport(), d3d_device3_SetCurrentViewport(), d3d_device3_SetLightState(), d3d_device3_SetRenderState(), d3d_device3_SetRenderTarget(), d3d_device3_SetTexture(), d3d_device3_SetTransform(), d3d_device3_Vertex(), d3d_device7_ApplyStateBlock(), d3d_device7_BeginScene(), d3d_device7_BeginStateBlock(), d3d_device7_CaptureStateBlock(), d3d_device7_Clear(), d3d_device7_CreateStateBlock(), d3d_device7_DeleteStateBlock(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), d3d_device7_DrawPrimitiveVB(), d3d_device7_EndScene(), d3d_device7_EndStateBlock(), d3d_device7_EnumTextureFormats(), d3d_device7_GetClipPlane(), d3d_device7_GetLight(), d3d_device7_GetLightEnable(), d3d_device7_GetMaterial(), d3d_device7_GetRenderState(), d3d_device7_GetRenderTarget(), d3d_device7_GetTexture(), d3d_device7_GetTextureStageState(), d3d_device7_GetTransform(), d3d_device7_GetViewport(), d3d_device7_LightEnable(), d3d_device7_Load(), d3d_device7_MultiplyTransform(), d3d_device7_PreLoad(), d3d_device7_SetClipPlane(), d3d_device7_SetLight(), d3d_device7_SetMaterial(), d3d_device7_SetRenderState(), d3d_device7_SetRenderTarget(), d3d_device7_SetTexture(), d3d_device7_SetTextureStageState(), d3d_device7_SetTransform(), d3d_device7_SetViewport(), d3d_device7_ValidateDevice(), d3d_device_inner_Release(), d3d_light_GetLight(), d3d_light_SetLight(), d3d_material3_GetHandle(), d3d_material3_GetMaterial(), d3d_material3_Release(), d3d_material3_SetMaterial(), d3d_texture2_GetHandle(), d3d_texture2_Load(), d3d_vertex_buffer7_GetVertexBufferDesc(), d3d_vertex_buffer7_Lock(), d3d_vertex_buffer7_Optimize(), d3d_vertex_buffer7_ProcessVertices(), d3d_vertex_buffer7_Release(), d3d_vertex_buffer7_Unlock(), d3d_vertex_buffer_create(), d3d_viewport_AddLight(), d3d_viewport_Clear(), d3d_viewport_Clear2(), d3d_viewport_DeleteLight(), d3d_viewport_GetBackground(), d3d_viewport_GetViewport(), d3d_viewport_GetViewport2(), d3d_viewport_NextLight(), d3d_viewport_SetBackground(), d3d_viewport_SetViewport(), d3d_viewport_SetViewport2(), d3d_viewport_TransformVertices(), ddraw1_CreateSurface(), ddraw2_CreateSurface(), ddraw4_CreateSurface(), ddraw7_CreatePalette(), ddraw7_CreateSurface(), ddraw7_EnumDisplayModes(), ddraw7_EnumSurfaces(), ddraw7_FlipToGDISurface(), ddraw7_GetAvailableVidMem(), ddraw7_GetCaps(), ddraw7_GetDeviceIdentifier(), ddraw7_GetDisplayMode(), ddraw7_GetGDISurface(), ddraw7_GetMonitorFrequency(), ddraw7_GetScanLine(), ddraw7_GetSurfaceFromDC(), ddraw7_GetVerticalBlankStatus(), ddraw7_RestoreDisplayMode(), ddraw7_SetDisplayMode(), ddraw_clipper_GetClipList(), ddraw_clipper_GetHWnd(), ddraw_clipper_Initialize(), ddraw_clipper_SetClipList(), ddraw_clipper_SetHWnd(), ddraw_destroy(), ddraw_enumerate_secondary_devices(), ddraw_gamma_control_GetGammaRamp(), ddraw_gamma_control_SetGammaRamp(), ddraw_get_d3dcaps(), ddraw_palette_GetCaps(), ddraw_palette_GetEntries(), ddraw_palette_Release(), ddraw_palette_SetEntries(), ddraw_set_cooperative_level(), ddraw_surface3_GetSurfaceDesc(), ddraw_surface7_Blt(), ddraw_surface7_BltFast(), ddraw_surface7_EnumAttachedSurfaces(), ddraw_surface7_Flip(), ddraw_surface7_FreePrivateData(), ddraw_surface7_GetAttachedSurface(), ddraw_surface7_GetClipper(), ddraw_surface7_GetColorKey(), ddraw_surface7_GetDC(), ddraw_surface7_GetLOD(), ddraw_surface7_GetOverlayPosition(), ddraw_surface7_GetPalette(), ddraw_surface7_GetPixelFormat(), ddraw_surface7_GetPriority(), ddraw_surface7_GetPrivateData(), ddraw_surface7_GetSurfaceDesc(), ddraw_surface7_QueryInterface(), ddraw_surface7_ReleaseDC(), ddraw_surface7_SetClipper(), ddraw_surface7_SetLOD(), ddraw_surface7_SetOverlayPosition(), ddraw_surface7_SetPriority(), ddraw_surface7_SetPrivateData(), ddraw_surface7_SetSurfaceDesc(), ddraw_surface7_Unlock(), ddraw_surface7_UpdateOverlay(), ddraw_surface7_UpdateOverlayZOrder(), ddraw_surface_add_iface(), ddraw_surface_attach_surface(), ddraw_surface_delete_attached_surface(), ddraw_surface_release_iface(), ddraw_surface_set_color_key(), ddraw_surface_set_palette(), device_init(), DirectDrawCreate(), DirectDrawCreateClipper(), DirectDrawCreateEx(), GetSurfaceFromDC(), indexbuffer_init(), pixelshader_init(), prepare_clip_space_planes(), query_init(), stateblock_init(), surface_lock(), swapchain_init(), texture_init(), vertexbuffer_init(), vertexdeclaration_init(), vertexshader_init(), and volumetexture_init().

◆ wined3d_mutex_unlock()

void __stdcall wined3d_mutex_unlock ( void  )

Definition at line 373 of file wined3d_main.c.

374{
376}
void WINAPI LeaveCriticalSection(LPCRITICAL_SECTION)

Referenced by CF_CreateDirectDraw(), CF_CreateDirectDrawClipper(), cubetexture_init(), d3d2_CreateDevice(), d3d3_CreateDevice(), d3d3_EnumDevices(), d3d7_CreateDevice(), d3d7_EnumDevices(), d3d7_EnumZBufferFormats(), d3d7_EvictManagedTextures(), d3d8_CheckDepthStencilMatch(), d3d8_CheckDeviceFormat(), d3d8_CheckDeviceMultiSampleType(), d3d8_CheckDeviceType(), d3d8_device_ApplyStateBlock(), d3d8_device_BeginScene(), d3d8_device_BeginStateBlock(), d3d8_device_CaptureStateBlock(), d3d8_device_Clear(), d3d8_device_CopyRects(), d3d8_device_create_surface(), d3d8_device_CreateAdditionalSwapChain(), d3d8_device_CreatePixelShader(), d3d8_device_CreateStateBlock(), d3d8_device_CreateVertexShader(), d3d8_device_DeletePixelShader(), d3d8_device_DeleteStateBlock(), d3d8_device_DeleteVertexShader(), d3d8_device_DrawIndexedPrimitive(), d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_DrawPrimitive(), d3d8_device_DrawPrimitiveUP(), d3d8_device_EndScene(), d3d8_device_EndStateBlock(), d3d8_device_GetAvailableTextureMem(), d3d8_device_GetBackBuffer(), d3d8_device_GetClipPlane(), d3d8_device_GetClipStatus(), d3d8_device_GetCreationParameters(), d3d8_device_GetDepthStencilSurface(), d3d8_device_GetDeviceCaps(), d3d8_device_GetDisplayMode(), d3d8_device_GetFrontBuffer(), d3d8_device_GetGammaRamp(), d3d8_device_GetIndices(), d3d8_device_GetLight(), d3d8_device_GetLightEnable(), d3d8_device_GetMaterial(), d3d8_device_GetPixelShader(), d3d8_device_GetPixelShaderConstant(), d3d8_device_GetPixelShaderFunction(), d3d8_device_GetRasterStatus(), d3d8_device_GetRenderState(), d3d8_device_GetRenderTarget(), d3d8_device_GetStreamSource(), d3d8_device_GetTexture(), d3d8_device_GetTextureStageState(), d3d8_device_GetTransform(), d3d8_device_GetVertexShader(), d3d8_device_GetVertexShaderConstant(), d3d8_device_GetVertexShaderDeclaration(), d3d8_device_GetVertexShaderFunction(), d3d8_device_GetViewport(), d3d8_device_LightEnable(), d3d8_device_MultiplyTransform(), d3d8_device_ProcessVertices(), d3d8_device_Release(), d3d8_device_Reset(), d3d8_device_ResourceManagerDiscardBytes(), d3d8_device_SetClipPlane(), d3d8_device_SetClipStatus(), d3d8_device_SetCursorPosition(), d3d8_device_SetCursorProperties(), d3d8_device_SetGammaRamp(), d3d8_device_SetIndices(), d3d8_device_SetLight(), d3d8_device_SetMaterial(), d3d8_device_SetPixelShader(), d3d8_device_SetPixelShaderConstant(), d3d8_device_SetRenderState(), d3d8_device_SetRenderTarget(), d3d8_device_SetStreamSource(), d3d8_device_SetTexture(), d3d8_device_SetTextureStageState(), d3d8_device_SetTransform(), d3d8_device_SetVertexShader(), d3d8_device_SetVertexShaderConstant(), d3d8_device_SetViewport(), d3d8_device_ShowCursor(), d3d8_device_UpdateTexture(), d3d8_device_ValidateDevice(), d3d8_EnumAdapterModes(), d3d8_GetAdapterCount(), d3d8_GetAdapterDisplayMode(), d3d8_GetAdapterIdentifier(), d3d8_GetAdapterModeCount(), d3d8_GetAdapterMonitor(), d3d8_GetDeviceCaps(), d3d8_indexbuffer_AddRef(), d3d8_indexbuffer_GetDesc(), d3d8_indexbuffer_GetPriority(), d3d8_indexbuffer_Lock(), d3d8_indexbuffer_PreLoad(), d3d8_indexbuffer_Release(), d3d8_indexbuffer_SetPriority(), d3d8_indexbuffer_Unlock(), d3d8_init(), d3d8_pixel_shader_destroy(), d3d8_pixel_shader_init(), d3d8_RegisterSoftwareDevice(), d3d8_Release(), d3d8_resource_free_private_data(), d3d8_resource_get_private_data(), d3d8_resource_set_private_data(), d3d8_surface_AddRef(), d3d8_surface_GetDesc(), d3d8_surface_LockRect(), d3d8_surface_Release(), d3d8_surface_UnlockRect(), d3d8_swapchain_AddRef(), d3d8_swapchain_GetBackBuffer(), d3d8_swapchain_Present(), d3d8_swapchain_Release(), d3d8_texture_2d_AddDirtyRect(), d3d8_texture_2d_AddRef(), d3d8_texture_2d_GetLevelCount(), d3d8_texture_2d_GetLevelDesc(), d3d8_texture_2d_GetLOD(), d3d8_texture_2d_GetPriority(), d3d8_texture_2d_GetSurfaceLevel(), d3d8_texture_2d_LockRect(), d3d8_texture_2d_PreLoad(), d3d8_texture_2d_Release(), d3d8_texture_2d_SetLOD(), d3d8_texture_2d_SetPriority(), d3d8_texture_2d_UnlockRect(), d3d8_texture_3d_AddDirtyBox(), d3d8_texture_3d_AddRef(), d3d8_texture_3d_GetLevelCount(), d3d8_texture_3d_GetLevelDesc(), d3d8_texture_3d_GetLOD(), d3d8_texture_3d_GetPriority(), d3d8_texture_3d_GetVolumeLevel(), d3d8_texture_3d_LockBox(), d3d8_texture_3d_PreLoad(), d3d8_texture_3d_Release(), d3d8_texture_3d_SetLOD(), d3d8_texture_3d_SetPriority(), d3d8_texture_3d_UnlockBox(), d3d8_texture_cube_AddDirtyRect(), d3d8_texture_cube_AddRef(), d3d8_texture_cube_GetCubeMapSurface(), d3d8_texture_cube_GetLevelCount(), d3d8_texture_cube_GetLevelDesc(), d3d8_texture_cube_GetLOD(), d3d8_texture_cube_GetPriority(), d3d8_texture_cube_LockRect(), d3d8_texture_cube_PreLoad(), d3d8_texture_cube_Release(), d3d8_texture_cube_SetLOD(), d3d8_texture_cube_SetPriority(), d3d8_texture_cube_UnlockRect(), d3d8_vertex_declaration_destroy(), d3d8_vertex_declaration_init(), d3d8_vertex_shader_destroy(), d3d8_vertex_shader_init(), d3d8_vertexbuffer_AddRef(), d3d8_vertexbuffer_GetDesc(), d3d8_vertexbuffer_GetPriority(), d3d8_vertexbuffer_Lock(), d3d8_vertexbuffer_PreLoad(), d3d8_vertexbuffer_Release(), d3d8_vertexbuffer_SetPriority(), d3d8_vertexbuffer_Unlock(), d3d8_volume_GetDesc(), d3d8_volume_LockBox(), d3d8_volume_UnlockBox(), d3d9_CheckDepthStencilMatch(), d3d9_CheckDeviceFormat(), d3d9_CheckDeviceFormatConversion(), d3d9_CheckDeviceMultiSampleType(), d3d9_CheckDeviceType(), d3d9_device_BeginScene(), d3d9_device_BeginStateBlock(), d3d9_device_CheckDeviceState(), d3d9_device_Clear(), d3d9_device_ColorFill(), d3d9_device_create_surface(), d3d9_device_CreateAdditionalSwapChain(), d3d9_device_DrawIndexedPrimitive(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawPrimitive(), d3d9_device_DrawPrimitiveUP(), d3d9_device_EndScene(), d3d9_device_EndStateBlock(), d3d9_device_EvictManagedResources(), d3d9_device_GetAvailableTextureMem(), d3d9_device_GetBackBuffer(), d3d9_device_GetClipPlane(), d3d9_device_GetClipStatus(), d3d9_device_GetCreationParameters(), d3d9_device_GetDepthStencilSurface(), d3d9_device_GetDeviceCaps(), d3d9_device_GetDisplayMode(), d3d9_device_GetDisplayModeEx(), d3d9_device_GetFrontBufferData(), d3d9_device_GetFVF(), d3d9_device_GetGammaRamp(), d3d9_device_GetIndices(), d3d9_device_GetLight(), d3d9_device_GetLightEnable(), d3d9_device_GetMaterial(), d3d9_device_GetNPatchMode(), d3d9_device_GetNumberOfSwapChains(), d3d9_device_GetPixelShader(), d3d9_device_GetPixelShaderConstantB(), d3d9_device_GetPixelShaderConstantF(), d3d9_device_GetPixelShaderConstantI(), d3d9_device_GetRasterStatus(), d3d9_device_GetRenderState(), d3d9_device_GetRenderTarget(), d3d9_device_GetRenderTargetData(), d3d9_device_GetSamplerState(), d3d9_device_GetScissorRect(), d3d9_device_GetSoftwareVertexProcessing(), d3d9_device_GetStreamSource(), d3d9_device_GetStreamSourceFreq(), d3d9_device_GetSwapChain(), d3d9_device_GetTexture(), d3d9_device_GetTextureStageState(), d3d9_device_GetTransform(), d3d9_device_GetVertexDeclaration(), d3d9_device_GetVertexShader(), d3d9_device_GetVertexShaderConstantB(), d3d9_device_GetVertexShaderConstantF(), d3d9_device_GetVertexShaderConstantI(), d3d9_device_GetViewport(), d3d9_device_LightEnable(), d3d9_device_MultiplyTransform(), d3d9_device_Present(), d3d9_device_PresentEx(), d3d9_device_ProcessVertices(), d3d9_device_Release(), d3d9_device_reset(), d3d9_device_SetClipPlane(), d3d9_device_SetClipStatus(), d3d9_device_SetCursorPosition(), d3d9_device_SetCursorProperties(), d3d9_device_SetDepthStencilSurface(), d3d9_device_SetDialogBoxMode(), d3d9_device_SetFVF(), d3d9_device_SetGammaRamp(), d3d9_device_SetIndices(), d3d9_device_SetLight(), d3d9_device_SetMaterial(), d3d9_device_SetNPatchMode(), d3d9_device_SetPixelShader(), d3d9_device_SetPixelShaderConstantB(), d3d9_device_SetPixelShaderConstantF(), d3d9_device_SetPixelShaderConstantI(), d3d9_device_SetRenderState(), d3d9_device_SetRenderTarget(), d3d9_device_SetSamplerState(), d3d9_device_SetScissorRect(), d3d9_device_SetSoftwareVertexProcessing(), d3d9_device_SetStreamSource(), d3d9_device_SetStreamSourceFreq(), d3d9_device_SetTexture(), d3d9_device_SetTextureStageState(), d3d9_device_SetTransform(), d3d9_device_SetVertexDeclaration(), d3d9_device_SetVertexShader(), d3d9_device_SetVertexShaderConstantB(), d3d9_device_SetVertexShaderConstantF(), d3d9_device_SetVertexShaderConstantI(), d3d9_device_SetViewport(), d3d9_device_ShowCursor(), d3d9_device_StretchRect(), d3d9_device_UpdateSurface(), d3d9_device_UpdateTexture(), d3d9_device_ValidateDevice(), d3d9_EnumAdapterModes(), d3d9_EnumAdapterModesEx(), d3d9_GetAdapterCount(), d3d9_GetAdapterDisplayMode(), d3d9_GetAdapterDisplayModeEx(), d3d9_GetAdapterIdentifier(), d3d9_GetAdapterLUID(), d3d9_GetAdapterModeCount(), d3d9_GetAdapterModeCountEx(), d3d9_GetAdapterMonitor(), d3d9_GetDeviceCaps(), d3d9_indexbuffer_AddRef(), d3d9_indexbuffer_GetDesc(), d3d9_indexbuffer_GetPriority(), d3d9_indexbuffer_Lock(), d3d9_indexbuffer_PreLoad(), d3d9_indexbuffer_Release(), d3d9_indexbuffer_SetPriority(), d3d9_indexbuffer_Unlock(), d3d9_init(), d3d9_pixelshader_AddRef(), d3d9_pixelshader_GetFunction(), d3d9_pixelshader_Release(), d3d9_query_GetData(), d3d9_query_GetType(), d3d9_query_Issue(), d3d9_query_Release(), d3d9_RegisterSoftwareDevice(), d3d9_Release(), d3d9_resource_free_private_data(), d3d9_resource_get_private_data(), d3d9_resource_set_private_data(), d3d9_stateblock_Apply(), d3d9_stateblock_Capture(), d3d9_stateblock_Release(), d3d9_surface_AddRef(), d3d9_surface_GetDC(), d3d9_surface_GetDesc(), d3d9_surface_LockRect(), d3d9_surface_PreLoad(), d3d9_surface_Release(), d3d9_surface_ReleaseDC(), d3d9_surface_UnlockRect(), d3d9_swapchain_AddRef(), d3d9_swapchain_GetBackBuffer(), d3d9_swapchain_GetDisplayMode(), d3d9_swapchain_GetDisplayModeEx(), d3d9_swapchain_GetFrontBufferData(), d3d9_swapchain_GetPresentParameters(), d3d9_swapchain_GetRasterStatus(), d3d9_swapchain_Present(), d3d9_swapchain_Release(), d3d9_texture_2d_AddDirtyRect(), d3d9_texture_2d_AddRef(), d3d9_texture_2d_GenerateMipSubLevels(), d3d9_texture_2d_GetLevelCount(), d3d9_texture_2d_GetLevelDesc(), d3d9_texture_2d_GetLOD(), d3d9_texture_2d_GetPriority(), d3d9_texture_2d_GetSurfaceLevel(), d3d9_texture_2d_LockRect(), d3d9_texture_2d_PreLoad(), d3d9_texture_2d_SetLOD(), d3d9_texture_2d_SetPriority(), d3d9_texture_2d_UnlockRect(), d3d9_texture_3d_AddDirtyBox(), d3d9_texture_3d_AddRef(), d3d9_texture_3d_GetLevelCount(), d3d9_texture_3d_GetLevelDesc(), d3d9_texture_3d_GetLOD(), d3d9_texture_3d_GetPriority(), d3d9_texture_3d_GetVolumeLevel(), d3d9_texture_3d_LockBox(), d3d9_texture_3d_PreLoad(), d3d9_texture_3d_SetLOD(), d3d9_texture_3d_SetPriority(), d3d9_texture_3d_UnlockBox(), d3d9_texture_cleanup(), d3d9_texture_cube_AddDirtyRect(), d3d9_texture_cube_AddRef(), d3d9_texture_cube_GenerateMipSubLevels(), d3d9_texture_cube_GetCubeMapSurface(), d3d9_texture_cube_GetLevelCount(), d3d9_texture_cube_GetLevelDesc(), d3d9_texture_cube_GetLOD(), d3d9_texture_cube_GetPriority(), d3d9_texture_cube_LockRect(), d3d9_texture_cube_PreLoad(), d3d9_texture_cube_SetLOD(), d3d9_texture_cube_SetPriority(), d3d9_texture_cube_UnlockRect(), d3d9_vertex_declaration_AddRef(), d3d9_vertex_declaration_Release(), d3d9_vertexbuffer_AddRef(), d3d9_vertexbuffer_GetDesc(), d3d9_vertexbuffer_GetPriority(), d3d9_vertexbuffer_Lock(), d3d9_vertexbuffer_PreLoad(), d3d9_vertexbuffer_Release(), d3d9_vertexbuffer_SetPriority(), d3d9_vertexbuffer_Unlock(), d3d9_vertexshader_AddRef(), d3d9_vertexshader_GetFunction(), d3d9_vertexshader_Release(), d3d9_volume_GetDesc(), d3d9_volume_LockBox(), d3d9_volume_UnlockBox(), d3d_device1_CreateMatrix(), d3d_device1_DeleteMatrix(), d3d_device1_Execute(), d3d_device1_GetMatrix(), d3d_device1_SetMatrix(), d3d_device2_EnumTextureFormats(), d3d_device2_SetRenderTarget(), d3d_device2_SwapTextureHandles(), d3d_device3_AddViewport(), d3d_device3_Begin(), d3d_device3_DeleteViewport(), d3d_device3_GetCurrentViewport(), d3d_device3_GetLightState(), d3d_device3_GetRenderState(), d3d_device3_GetTransform(), d3d_device3_MultiplyTransform(), d3d_device3_NextViewport(), d3d_device3_SetCurrentViewport(), d3d_device3_SetLightState(), d3d_device3_SetRenderState(), d3d_device3_SetRenderTarget(), d3d_device3_SetTexture(), d3d_device3_SetTransform(), d3d_device3_Vertex(), d3d_device7_ApplyStateBlock(), d3d_device7_BeginScene(), d3d_device7_BeginStateBlock(), d3d_device7_CaptureStateBlock(), d3d_device7_Clear(), d3d_device7_CreateStateBlock(), d3d_device7_DeleteStateBlock(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), d3d_device7_DrawPrimitiveVB(), d3d_device7_EndScene(), d3d_device7_EndStateBlock(), d3d_device7_EnumTextureFormats(), d3d_device7_GetClipPlane(), d3d_device7_GetLight(), d3d_device7_GetLightEnable(), d3d_device7_GetMaterial(), d3d_device7_GetRenderState(), d3d_device7_GetRenderTarget(), d3d_device7_GetTexture(), d3d_device7_GetTextureStageState(), d3d_device7_GetTransform(), d3d_device7_GetViewport(), d3d_device7_LightEnable(), d3d_device7_Load(), d3d_device7_MultiplyTransform(), d3d_device7_PreLoad(), d3d_device7_SetClipPlane(), d3d_device7_SetLight(), d3d_device7_SetMaterial(), d3d_device7_SetRenderState(), d3d_device7_SetRenderTarget(), d3d_device7_SetTexture(), d3d_device7_SetTextureStageState(), d3d_device7_SetTransform(), d3d_device7_SetViewport(), d3d_device7_ValidateDevice(), d3d_device_inner_Release(), d3d_light_GetLight(), d3d_light_SetLight(), d3d_material3_GetHandle(), d3d_material3_GetMaterial(), d3d_material3_Release(), d3d_material3_SetMaterial(), d3d_texture2_GetHandle(), d3d_texture2_Load(), d3d_vertex_buffer7_GetVertexBufferDesc(), d3d_vertex_buffer7_Lock(), d3d_vertex_buffer7_Optimize(), d3d_vertex_buffer7_ProcessVertices(), d3d_vertex_buffer7_Release(), d3d_vertex_buffer7_Unlock(), d3d_vertex_buffer_create(), d3d_viewport_AddLight(), d3d_viewport_Clear(), d3d_viewport_Clear2(), d3d_viewport_DeleteLight(), d3d_viewport_GetBackground(), d3d_viewport_GetViewport(), d3d_viewport_GetViewport2(), d3d_viewport_NextLight(), d3d_viewport_SetBackground(), d3d_viewport_SetViewport(), d3d_viewport_SetViewport2(), d3d_viewport_TransformVertices(), ddraw1_CreateSurface(), ddraw2_CreateSurface(), ddraw4_CreateSurface(), ddraw7_CreatePalette(), ddraw7_CreateSurface(), ddraw7_EnumDisplayModes(), ddraw7_EnumSurfaces(), ddraw7_FlipToGDISurface(), ddraw7_GetAvailableVidMem(), ddraw7_GetCaps(), ddraw7_GetDeviceIdentifier(), ddraw7_GetDisplayMode(), ddraw7_GetGDISurface(), ddraw7_GetMonitorFrequency(), ddraw7_GetScanLine(), ddraw7_GetSurfaceFromDC(), ddraw7_GetVerticalBlankStatus(), ddraw7_RestoreDisplayMode(), ddraw7_SetDisplayMode(), ddraw_clipper_GetClipList(), ddraw_clipper_GetHWnd(), ddraw_clipper_Initialize(), ddraw_clipper_SetClipList(), ddraw_clipper_SetHWnd(), ddraw_destroy(), ddraw_enumerate_secondary_devices(), ddraw_gamma_control_GetGammaRamp(), ddraw_gamma_control_SetGammaRamp(), ddraw_get_d3dcaps(), ddraw_palette_GetCaps(), ddraw_palette_GetEntries(), ddraw_palette_Release(), ddraw_palette_SetEntries(), ddraw_set_cooperative_level(), ddraw_surface3_GetSurfaceDesc(), ddraw_surface7_Blt(), ddraw_surface7_BltFast(), ddraw_surface7_EnumAttachedSurfaces(), ddraw_surface7_Flip(), ddraw_surface7_FreePrivateData(), ddraw_surface7_GetAttachedSurface(), ddraw_surface7_GetClipper(), ddraw_surface7_GetColorKey(), ddraw_surface7_GetDC(), ddraw_surface7_GetLOD(), ddraw_surface7_GetOverlayPosition(), ddraw_surface7_GetPalette(), ddraw_surface7_GetPixelFormat(), ddraw_surface7_GetPriority(), ddraw_surface7_GetPrivateData(), ddraw_surface7_GetSurfaceDesc(), ddraw_surface7_QueryInterface(), ddraw_surface7_ReleaseDC(), ddraw_surface7_SetClipper(), ddraw_surface7_SetLOD(), ddraw_surface7_SetOverlayPosition(), ddraw_surface7_SetPriority(), ddraw_surface7_SetPrivateData(), ddraw_surface7_SetSurfaceDesc(), ddraw_surface7_Unlock(), ddraw_surface7_UpdateOverlay(), ddraw_surface7_UpdateOverlayZOrder(), ddraw_surface_add_iface(), ddraw_surface_attach_surface(), ddraw_surface_delete_attached_surface(), ddraw_surface_release_iface(), ddraw_surface_set_color_key(), ddraw_surface_set_palette(), device_init(), DirectDrawCreate(), DirectDrawCreateClipper(), DirectDrawCreateEx(), GetSurfaceFromDC(), indexbuffer_init(), pixelshader_init(), prepare_clip_space_planes(), query_init(), stateblock_init(), surface_lock(), swapchain_init(), texture_init(), vertexbuffer_init(), vertexdeclaration_init(), vertexshader_init(), and volumetexture_init().

◆ wined3d_palette_apply_to_dc()

void __cdecl wined3d_palette_apply_to_dc ( const struct wined3d_palette palette,
HDC  dc 
)

Definition at line 86 of file palette.c.

87{
88 if (SetDIBColorTable(dc, 0, 256, palette->colors) != 256)
89#ifdef __REACTOS__
90 {
91 static int warn_once;
92 if (!warn_once++)
93 ERR("Failed to set DIB color table. (Only printing once)\n");
94 }
95#else
96 ERR("Failed to set DIB color table.\n");
97#endif
98}
static const WCHAR dc[]
static HPALETTE palette
Definition: clipboard.c:1345
UINT WINAPI SetDIBColorTable(_In_ HDC hdc, _In_ UINT iStart, _In_ UINT cEntries, _In_reads_(cEntries) const RGBQUAD *prgbq)

Referenced by ddraw_surface7_GetDC(), ddraw_surface_update_frontbuffer(), and swapchain_gdi_frontbuffer_updated().

◆ wined3d_palette_create()

HRESULT __cdecl wined3d_palette_create ( struct wined3d_device device,
DWORD  flags,
unsigned int  entry_count,
const PALETTEENTRY entries,
struct wined3d_palette **  palette 
)

Definition at line 162 of file palette.c.

164{
165 struct wined3d_palette *object;
166 HRESULT hr;
167
168 TRACE("device %p, flags %#x, entry_count %u, entries %p, palette %p.\n",
169 device, flags, entry_count, entries, palette);
170
171 if (!(object = heap_alloc_zero(sizeof(*object))))
172 return E_OUTOFMEMORY;
173
174 if (FAILED(hr = wined3d_palette_init(object, device, flags, entry_count, entries)))
175 {
176 WARN("Failed to initialize palette, hr %#x.\n", hr);
177 heap_free(object);
178 return hr;
179 }
180
181 TRACE("Created palette %p.\n", object);
182 *palette = object;
183
184 return WINED3D_OK;
185}
static HRESULT wined3d_palette_init(struct wined3d_palette *palette, struct wined3d_device *device, DWORD flags, unsigned int entry_count, const PALETTEENTRY *entries)
Definition: palette.c:143

Referenced by ddraw_palette_init().

◆ wined3d_palette_decref()

ULONG __cdecl wined3d_palette_decref ( struct wined3d_palette palette)

Definition at line 41 of file palette.c.

42{
43 ULONG refcount = InterlockedDecrement(&palette->ref);
44
45 TRACE("%p decreasing refcount to %u.\n", palette, refcount);
46
47 if (!refcount)
49
50 return refcount;
51}
static void wined3d_palette_destroy_object(void *object)
Definition: palette.c:36

Referenced by ddraw_palette_Release().

◆ wined3d_palette_get_entries()

HRESULT __cdecl wined3d_palette_get_entries ( const struct wined3d_palette palette,
DWORD  flags,
DWORD  start,
DWORD  count,
PALETTEENTRY entries 
)

Definition at line 53 of file palette.c.

55{
56 unsigned int i;
57 TRACE("palette %p, flags %#x, start %u, count %u, entries %p.\n",
58 palette, flags, start, count, entries);
59
60 if (flags)
61 return WINED3DERR_INVALIDCALL; /* unchecked */
62 if (start > palette->size || count > palette->size - start)
64
66 {
67 BYTE *entry = (BYTE *)entries;
68
69 for (i = start; i < count + start; ++i)
70 *entry++ = palette->colors[i].rgbRed;
71 }
72 else
73 {
74 for (i = 0; i < count; ++i)
75 {
76 entries[i].peRed = palette->colors[i + start].rgbRed;
77 entries[i].peGreen = palette->colors[i + start].rgbGreen;
78 entries[i].peBlue = palette->colors[i + start].rgbBlue;
79 entries[i].peFlags = palette->colors[i + start].rgbReserved;
80 }
81 }
82
83 return WINED3D_OK;
84}
GLuint start
Definition: gl.h:1545
uint32_t entry
Definition: isohybrid.c:63
#define WINED3D_PALETTE_8BIT_ENTRIES
Definition: wined3d.h:1554

Referenced by ddraw_palette_GetEntries(), and wined3d_colour_from_ddraw_colour().

◆ wined3d_palette_incref()

ULONG __cdecl wined3d_palette_incref ( struct wined3d_palette palette)

Definition at line 27 of file palette.c.

28{
29 ULONG refcount = InterlockedIncrement(&palette->ref);
30
31 TRACE("%p increasing refcount to %u.\n", palette, refcount);
32
33 return refcount;
34}

◆ wined3d_palette_set_entries()

HRESULT __cdecl wined3d_palette_set_entries ( struct wined3d_palette palette,
DWORD  flags,
DWORD  start,
DWORD  count,
const PALETTEENTRY entries 
)

Definition at line 100 of file palette.c.

102{
103 unsigned int i;
104
105 TRACE("palette %p, flags %#x, start %u, count %u, entries %p.\n",
106 palette, flags, start, count, entries);
107 TRACE("Palette flags: %#x.\n", palette->flags);
108
110 {
111 const BYTE *entry = (const BYTE *)entries;
112
113 for (i = start; i < count + start; ++i)
114 palette->colors[i].rgbRed = *entry++;
115 }
116 else
117 {
118 for (i = 0; i < count; ++i)
119 {
120 palette->colors[i + start].rgbRed = entries[i].peRed;
121 palette->colors[i + start].rgbGreen = entries[i].peGreen;
122 palette->colors[i + start].rgbBlue = entries[i].peBlue;
123 palette->colors[i + start].rgbReserved = entries[i].peFlags;
124 }
125
126 /* When WINEDDCAPS_ALLOW256 isn't set we need to override entry 0 with black and 255 with white */
127 if (!(palette->flags & WINED3D_PALETTE_ALLOW_256))
128 {
129 TRACE("WINED3D_PALETTE_ALLOW_256 not set, overriding palette entry 0 with black and 255 with white.\n");
130 palette->colors[0].rgbRed = 0;
131 palette->colors[0].rgbGreen = 0;
132 palette->colors[0].rgbBlue = 0;
133
134 palette->colors[255].rgbRed = 255;
135 palette->colors[255].rgbGreen = 255;
136 palette->colors[255].rgbBlue = 255;
137 }
138 }
139
140 return WINED3D_OK;
141}
#define WINED3D_PALETTE_ALLOW_256
Definition: wined3d.h:1555

Referenced by ddraw_palette_SetEntries(), and wined3d_palette_init().

◆ wined3d_private_store_cleanup()

static void wined3d_private_store_cleanup ( struct wined3d_private_store store)
inlinestatic

Definition at line 2541 of file wined3d.h.

2542{
2543 struct wined3d_private_data *data;
2544 struct list *e1, *e2;
2545
2546 LIST_FOR_EACH_SAFE(e1, e2, &store->content)
2547 {
2550 }
2551}
Definition: list.h:37
#define LIST_FOR_EACH_SAFE(cursor, cursor2, list)
Definition: list.h:192
struct list content
Definition: wined3d.h:2155
#define LIST_ENTRY(type)
Definition: queue.h:175
static void wined3d_private_store_free_private_data(struct wined3d_private_store *store, struct wined3d_private_data *entry)
Definition: wined3d.h:2532

Referenced by d3d8_resource_cleanup(), d3d9_resource_cleanup(), and ddraw_surface_wined3d_object_destroyed().

◆ wined3d_private_store_free_private_data()

static void wined3d_private_store_free_private_data ( struct wined3d_private_store store,
struct wined3d_private_data entry 
)
inlinestatic

Definition at line 2532 of file wined3d.h.

2534{
2535 if (entry->flags & WINED3DSPD_IUNKNOWN)
2536 IUnknown_Release(entry->content.object);
2537 list_remove(&entry->entry);
2539}
static void list_remove(struct list_entry *entry)
Definition: list.h:90
#define GetProcessHeap()
Definition: compat.h:736
#define HeapFree(x, y, z)
Definition: compat.h:735
#define WINED3DSPD_IUNKNOWN
Definition: wined3d.h:1006

Referenced by d3d8_resource_free_private_data(), d3d9_resource_free_private_data(), ddraw_surface7_FreePrivateData(), wined3d_private_store_cleanup(), and wined3d_private_store_set_private_data().

◆ wined3d_private_store_get_private_data()

static struct wined3d_private_data * wined3d_private_store_get_private_data ( const struct wined3d_private_store store,
const GUID tag 
)
inlinestatic

Definition at line 2517 of file wined3d.h.

2519{
2520 struct wined3d_private_data *data;
2521 struct list *entry;
2522
2523 LIST_FOR_EACH(entry, &store->content)
2524 {
2526 if (IsEqualGUID(&data->tag, tag))
2527 return data;
2528 }
2529 return NULL;
2530}
#define IsEqualGUID(rguid1, rguid2)
Definition: guiddef.h:147
#define LIST_FOR_EACH(cursor, list)
Definition: list.h:188
Definition: ecma_167.h:138

Referenced by d3d8_resource_free_private_data(), d3d8_resource_get_private_data(), d3d9_resource_free_private_data(), d3d9_resource_get_private_data(), ddraw_surface7_FreePrivateData(), ddraw_surface7_GetPrivateData(), and wined3d_private_store_set_private_data().

◆ wined3d_private_store_init()

static void wined3d_private_store_init ( struct wined3d_private_store store)
inlinestatic

Definition at line 2512 of file wined3d.h.

2513{
2514 list_init(&store->content);
2515}
static void list_init(struct list_entry *head)
Definition: list.h:51

Referenced by d3d8_resource_init(), d3d9_resource_init(), and ddraw_surface_init().

◆ wined3d_private_store_set_private_data()

static HRESULT wined3d_private_store_set_private_data ( struct wined3d_private_store store,
const GUID guid,
const void data,
DWORD  data_size,
DWORD  flags 
)
inlinestatic

Definition at line 2553 of file wined3d.h.

2555{
2556 struct wined3d_private_data *d, *old;
2557 const void *ptr = data;
2558
2560 {
2561 if (data_size != sizeof(IUnknown *))
2563 ptr = &data;
2564 }
2565
2566 if (!(d = HeapAlloc(GetProcessHeap(), 0,
2567 FIELD_OFFSET(struct wined3d_private_data, content.data[data_size]))))
2568 return E_OUTOFMEMORY;
2569
2570 d->tag = *guid;
2571 d->flags = flags;
2572 d->size = data_size;
2573
2574 memcpy(d->content.data, ptr, data_size);
2576 IUnknown_AddRef(d->content.object);
2577
2579 if (old)
2581 list_add_tail(&store->content, &d->entry);
2582
2583 return WINED3D_OK;
2584}
static void list_add_tail(struct list_entry *head, struct list_entry *entry)
Definition: list.h:83
content
Definition: atl_ax.c:994
#define HeapAlloc
Definition: compat.h:733
const GUID * guid
static PVOID ptr
Definition: dispmode.c:27
static struct wined3d_private_data * wined3d_private_store_get_private_data(const struct wined3d_private_store *store, const GUID *tag)
Definition: wined3d.h:2517

Referenced by d3d8_resource_set_private_data(), d3d9_resource_set_private_data(), and ddraw_surface7_SetPrivateData().

◆ wined3d_query_create()

HRESULT __cdecl wined3d_query_create ( struct wined3d_device device,
enum wined3d_query_type  type,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_query **  query 
)

Definition at line 1294 of file query.c.

1296{
1297 TRACE("device %p, type %#x, parent %p, parent_ops %p, query %p.\n",
1298 device, type, parent, parent_ops, query);
1299
1300 switch (type)
1301 {
1303 return wined3d_event_query_create(device, type, parent, parent_ops, query);
1304
1306 return wined3d_occlusion_query_create(device, type, parent, parent_ops, query);
1307
1309 return wined3d_timestamp_query_create(device, type, parent, parent_ops, query);
1310
1314
1320
1322 return wined3d_pipeline_query_create(device, type, parent, parent_ops, query);
1323
1326
1328 return wined3d_overflow_query_create(device, type, parent, parent_ops, query);
1329
1330 default:
1331 FIXME("Unhandled query type %#x.\n", type);
1333 }
1334}
static HRESULT wined3d_timestamp_disjoint_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1089
static HRESULT wined3d_pipeline_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1200
static HRESULT wined3d_statistics_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1240
static HRESULT wined3d_timestamp_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1049
static HRESULT wined3d_overflow_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1273
static HRESULT wined3d_so_statistics_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1145
static HRESULT wined3d_event_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:959
static HRESULT wined3d_occlusion_query_create(struct wined3d_device *device, enum wined3d_query_type type, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_query **query)
Definition: query.c:1005

Referenced by query_init().

◆ wined3d_query_decref()

ULONG __cdecl wined3d_query_decref ( struct wined3d_query query)

Definition at line 349 of file query.c.

350{
351 ULONG refcount = InterlockedDecrement(&query->ref);
352
353 TRACE("%p decreasing refcount to %u.\n", query, refcount);
354
355 if (!refcount)
356 {
357 query->parent_ops->wined3d_object_destroyed(query->parent);
359 }
360
361 return refcount;
362}
static void wined3d_query_destroy_object(void *object)
Definition: query.c:335

Referenced by d3d9_query_Release(), and wined3d_device_set_predication().

◆ wined3d_query_get_data()

HRESULT __cdecl wined3d_query_get_data ( struct wined3d_query query,
void data,
UINT  data_size,
DWORD  flags 
)

Definition at line 364 of file query.c.

366{
367 TRACE("query %p, data %p, data_size %u, flags %#x.\n",
368 query, data, data_size, flags);
369
370 if (flags)
371 WARN("Ignoring flags %#x.\n", flags);
372
373 if (query->state == QUERY_BUILDING)
374 {
375 WARN("Query is building, returning S_FALSE.\n");
376 return S_FALSE;
377 }
378
379 if (query->state == QUERY_CREATED)
380 {
381 WARN("Query wasn't started yet.\n");
383 }
384
385 if (!query->device->cs->thread)
386 {
387 if (!query->query_ops->query_poll(query, flags))
388 return S_FALSE;
389 }
390 else if (query->counter_main != query->counter_retrieved)
391 {
392 if (flags & WINED3DGETDATA_FLUSH && !query->device->cs->queries_flushed)
393 wined3d_cs_emit_flush(query->device->cs);
394 return S_FALSE;
395 }
396
397 if (data)
398 memcpy(data, query->data, min(data_size, query->data_size));
399
400 return S_OK;
401}
#define S_OK
Definition: intsafe.h:52
HANDLE thread
Definition: pdh_main.c:145
#define WINED3DGETDATA_FLUSH
Definition: wined3d.h:763
@ QUERY_BUILDING
@ QUERY_CREATED
#define S_FALSE
Definition: winerror.h:2357

Referenced by d3d9_query_GetData().

◆ wined3d_query_get_data_size()

UINT __cdecl wined3d_query_get_data_size ( const struct wined3d_query query)

Definition at line 403 of file query.c.

404{
405 TRACE("query %p.\n", query);
406
407 return query->data_size;
408}

Referenced by query_init().

◆ wined3d_query_get_parent()

void *__cdecl wined3d_query_get_parent ( const struct wined3d_query query)

Definition at line 491 of file query.c.

492{
493 TRACE("query %p.\n", query);
494
495 return query->parent;
496}

◆ wined3d_query_get_type()

enum wined3d_query_type __cdecl wined3d_query_get_type ( const struct wined3d_query query)

Definition at line 498 of file query.c.

499{
500 TRACE("query %p.\n", query);
501
502 return query->type;
503}

Referenced by d3d9_query_GetData(), and d3d9_query_GetType().

◆ wined3d_query_incref()

ULONG __cdecl wined3d_query_incref ( struct wined3d_query query)

Definition at line 326 of file query.c.

327{
328 ULONG refcount = InterlockedIncrement(&query->ref);
329
330 TRACE("%p increasing refcount to %u.\n", query, refcount);
331
332 return refcount;
333}

Referenced by wined3d_device_set_predication().

◆ wined3d_query_issue()

HRESULT __cdecl wined3d_query_issue ( struct wined3d_query query,
DWORD  flags 
)

Definition at line 410 of file query.c.

411{
412 TRACE("query %p, flags %#x.\n", query, flags);
413
415 ++query->counter_main;
416
418
420 query->state = QUERY_BUILDING;
421 else
422 query->state = QUERY_SIGNALLED;
423
424 return WINED3D_OK;
425}
void wined3d_cs_emit_query_issue(struct wined3d_cs *cs, struct wined3d_query *query, DWORD flags)
Definition: cs.c:1934
#define WINED3DISSUE_BEGIN
Definition: wined3d.h:761
#define WINED3DISSUE_END
Definition: wined3d.h:762
@ QUERY_SIGNALLED

Referenced by d3d9_query_Issue().

◆ wined3d_rasterizer_state_create()

HRESULT __cdecl wined3d_rasterizer_state_create ( struct wined3d_device device,
const struct wined3d_rasterizer_state_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_rasterizer_state **  state 
)

Definition at line 142 of file state.c.

145{
147
148 TRACE("device %p, desc %p, parent %p, parent_ops %p, state %p.\n",
150
151 if (!(object = heap_alloc_zero(sizeof(*object))))
152 return E_OUTOFMEMORY;
153
154 object->refcount = 1;
155 object->desc = *desc;
156 object->parent = parent;
157 object->parent_ops = parent_ops;
158 object->device = device;
159
160 TRACE("Created rasterizer state %p.\n", object);
161 *state = object;
162
163 return WINED3D_OK;
164}
struct wined3d_device * device
const struct wined3d_parent_ops * parent_ops

◆ wined3d_rasterizer_state_decref()

ULONG __cdecl wined3d_rasterizer_state_decref ( struct wined3d_rasterizer_state state)

Definition at line 119 of file state.c.

120{
121 ULONG refcount = InterlockedDecrement(&state->refcount);
122 struct wined3d_device *device = state->device;
123
124 TRACE("%p decreasing refcount to %u.\n", state, refcount);
125
126 if (!refcount)
127 {
128 state->parent_ops->wined3d_object_destroyed(state->parent);
130 }
131
132 return refcount;
133}
static void wined3d_rasterizer_state_destroy_object(void *object)
Definition: state.c:114

Referenced by wined3d_device_set_rasterizer_state().

◆ wined3d_rasterizer_state_get_parent()

void *__cdecl wined3d_rasterizer_state_get_parent ( const struct wined3d_rasterizer_state state)

Definition at line 135 of file state.c.

136{
137 TRACE("rasterizer_state %p.\n", state);
138
139 return state->parent;
140}

◆ wined3d_rasterizer_state_incref()

ULONG __cdecl wined3d_rasterizer_state_incref ( struct wined3d_rasterizer_state state)

Definition at line 105 of file state.c.

106{
107 ULONG refcount = InterlockedIncrement(&state->refcount);
108
109 TRACE("%p increasing refcount to %u.\n", state, refcount);
110
111 return refcount;
112}

Referenced by wined3d_device_set_rasterizer_state().

◆ wined3d_register_software_device()

HRESULT __cdecl wined3d_register_software_device ( struct wined3d wined3d,
void init_function 
)

Definition at line 4492 of file directx.c.

4493{
4494 FIXME("wined3d %p, init_function %p stub!\n", wined3d, init_function);
4495
4496 return WINED3D_OK;
4497}

Referenced by d3d8_RegisterSoftwareDevice(), and d3d9_RegisterSoftwareDevice().

◆ wined3d_rendertarget_view_create()

HRESULT __cdecl wined3d_rendertarget_view_create ( const struct wined3d_view_desc desc,
struct wined3d_resource resource,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_rendertarget_view **  view 
)

Definition at line 598 of file view.c.

601{
603 HRESULT hr;
604
605 TRACE("desc %p, resource %p, parent %p, parent_ops %p, view %p.\n",
607
608 if (!(object = heap_alloc_zero(sizeof(*object))))
609 return E_OUTOFMEMORY;
610
612 {
613 heap_free(object);
614 WARN("Failed to initialise view, hr %#x.\n", hr);
615 return hr;
616 }
617
618 TRACE("Created render target view %p.\n", object);
619 *view = object;
620
621 return hr;
622}
static HRESULT wined3d_rendertarget_view_init(struct wined3d_rendertarget_view *view, const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: view.c:550
const struct wined3d_parent_ops * parent_ops

Referenced by swapchain_init(), wined3d_device_init_3d(), wined3d_device_reset(), and wined3d_rendertarget_view_create_from_sub_resource().

◆ wined3d_rendertarget_view_create_from_sub_resource()

HRESULT __cdecl wined3d_rendertarget_view_create_from_sub_resource ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_rendertarget_view **  view 
)

Definition at line 624 of file view.c.

627{
628 struct wined3d_view_desc desc;
629
630 TRACE("texture %p, sub_resource_idx %u, parent %p, parent_ops %p, view %p.\n",
631 texture, sub_resource_idx, parent, parent_ops, view);
632
633 desc.format_id = texture->resource.format->id;
634 desc.flags = 0;
635 desc.u.texture.level_idx = sub_resource_idx % texture->level_count;
636 desc.u.texture.level_count = 1;
637 desc.u.texture.layer_idx = sub_resource_idx / texture->level_count;
638 desc.u.texture.layer_count = 1;
639
640 return wined3d_rendertarget_view_create(&desc, &texture->resource, parent, parent_ops, view);
641}

Referenced by d3d8_surface_acquire_rendertarget_view(), d3d9_surface_acquire_rendertarget_view(), and ddraw_surface_get_rendertarget_view().

◆ wined3d_rendertarget_view_decref()

ULONG __cdecl wined3d_rendertarget_view_decref ( struct wined3d_rendertarget_view view)

Definition at line 348 of file view.c.

349{
350 ULONG refcount = InterlockedDecrement(&view->refcount);
351
352 TRACE("%p decreasing refcount to %u.\n", view, refcount);
353
354 if (!refcount)
355 {
356 struct wined3d_resource *resource = view->resource;
357 struct wined3d_device *device = resource->device;
358
359 /* Call wined3d_object_destroyed() before releasing the resource,
360 * since releasing the resource may end up destroying the parent. */
361 view->parent_ops->wined3d_object_destroyed(view->parent);
364 }
365
366 return refcount;
367}
static void wined3d_rendertarget_view_destroy_object(void *object)
Definition: view.c:327
static ULONG wined3d_resource_decref(struct wined3d_resource *resource)

Referenced by d3d8_surface_Release(), d3d8_texture_2d_Release(), d3d8_texture_cube_Release(), d3d9_surface_Release(), d3d9_texture_cleanup(), d3d9_texture_cube_AddRef(), ddraw_set_cooperative_level(), ddraw_surface_cleanup(), wined3d_device_init_3d(), wined3d_device_reset(), wined3d_device_set_depth_stencil_view(), wined3d_device_set_rendertarget_view(), and wined3d_device_uninit_3d().

◆ wined3d_rendertarget_view_get_parent()

void *__cdecl wined3d_rendertarget_view_get_parent ( const struct wined3d_rendertarget_view view)

Definition at line 369 of file view.c.

370{
371 TRACE("view %p.\n", view);
372
373 return view->parent;
374}

◆ wined3d_rendertarget_view_get_resource()

struct wined3d_resource *__cdecl wined3d_rendertarget_view_get_resource ( const struct wined3d_rendertarget_view view)

Definition at line 397 of file view.c.

398{
399 TRACE("view %p.\n", view);
400
401 return view->resource;
402}

◆ wined3d_rendertarget_view_get_sub_resource_parent()

void *__cdecl wined3d_rendertarget_view_get_sub_resource_parent ( const struct wined3d_rendertarget_view view)

Definition at line 376 of file view.c.

377{
378 struct wined3d_texture *texture;
379
380 TRACE("view %p.\n", view);
381
382 if (view->resource->type == WINED3D_RTYPE_BUFFER)
384
386
387 return texture->sub_resources[view->sub_resource_idx].parent;
388}
void *CDECL wined3d_buffer_get_parent(const struct wined3d_buffer *buffer)
Definition: buffer.c:807
enum view_type type
static struct wined3d_buffer * buffer_from_resource(struct wined3d_resource *resource)

Referenced by d3d8_device_GetDepthStencilSurface(), d3d8_device_GetRenderTarget(), d3d8_device_SetRenderTarget(), d3d9_device_GetDepthStencilSurface(), d3d9_device_GetRenderTarget(), d3d9_device_reset(), ddraw_set_cooperative_level(), and device_init().

◆ wined3d_rendertarget_view_incref()

ULONG __cdecl wined3d_rendertarget_view_incref ( struct wined3d_rendertarget_view view)

◆ wined3d_rendertarget_view_set_parent()

void __cdecl wined3d_rendertarget_view_set_parent ( struct wined3d_rendertarget_view view,
void parent 
)

Definition at line 390 of file view.c.

391{
392 TRACE("view %p, parent %p.\n", view, parent);
393
394 view->parent = parent;
395}

Referenced by ddraw_surface7_Flip().

◆ wined3d_resource_get_desc()

void __cdecl wined3d_resource_get_desc ( const struct wined3d_resource resource,
struct wined3d_resource_desc desc 
)

Definition at line 295 of file resource.c.

296{
297 desc->resource_type = resource->type;
298 desc->format = resource->format->id;
299 desc->multisample_type = resource->multisample_type;
300 desc->multisample_quality = resource->multisample_quality;
301 desc->usage = resource->usage;
302 desc->access = resource->access;
303 desc->width = resource->width;
304 desc->height = resource->height;
305 desc->depth = resource->depth;
306 desc->size = resource->size;
307}

Referenced by d3d8_indexbuffer_GetDesc(), d3d8_vertexbuffer_GetDesc(), d3d9_indexbuffer_GetDesc(), d3d9_vertexbuffer_GetDesc(), d3d_device3_GetRenderState(), d3d_device3_SetRenderState(), d3d_device3_SetTexture(), d3d_vertex_buffer7_GetVertexBufferDesc(), d3d_vertex_buffer7_Lock(), and reset_enum_callback().

◆ wined3d_resource_get_parent()

void *__cdecl wined3d_resource_get_parent ( const struct wined3d_resource resource)

Definition at line 285 of file resource.c.

286{
287 return resource->parent;
288}

Referenced by reset_enum_callback().

◆ wined3d_resource_get_priority()

◆ wined3d_resource_map()

HRESULT __cdecl wined3d_resource_map ( struct wined3d_resource resource,
unsigned int  sub_resource_idx,
struct wined3d_map_desc map_desc,
const struct wined3d_box box,
DWORD  flags 
)

Definition at line 344 of file resource.c.

346{
347 TRACE("resource %p, sub_resource_idx %u, map_desc %p, box %s, flags %#x.\n",
348 resource, sub_resource_idx, map_desc, debug_box(box), flags);
349
351 {
352 WARN("No read/write flags specified.\n");
353 return E_INVALIDARG;
354 }
355
357 {
358 WARN("Resource does not have MAP_R access.\n");
359 return E_INVALIDARG;
360 }
361
363 {
364 WARN("Resource does not have MAP_W access.\n");
365 return E_INVALIDARG;
366 }
367
370
371 return wined3d_cs_map(resource->device->cs, resource, sub_resource_idx, map_desc, box, flags);
372}
#define E_INVALIDARG
Definition: ddrawi.h:101
static DWORD wined3d_resource_sanitise_map_flags(const struct wined3d_resource *resource, DWORD flags)
Definition: resource.c:309
#define WINED3D_RESOURCE_ACCESS_MAP_R
Definition: wined3d.h:57
#define WINED3D_MAP_WRITE
Definition: wined3d.h:938
#define WINED3D_RESOURCE_ACCESS_MAP_W
Definition: wined3d.h:58

Referenced by d3d8_device_DrawIndexedPrimitiveUP(), d3d8_device_DrawPrimitiveUP(), d3d8_indexbuffer_Lock(), d3d8_surface_LockRect(), d3d8_vertexbuffer_Lock(), d3d8_volume_LockBox(), d3d9_device_DrawIndexedPrimitiveUP(), d3d9_device_DrawPrimitiveUP(), d3d9_indexbuffer_Lock(), d3d9_surface_LockRect(), d3d9_vertexbuffer_Lock(), d3d9_volume_LockBox(), d3d_device7_DrawIndexedPrimitive(), d3d_device7_DrawIndexedPrimitiveStrided(), d3d_device7_DrawIndexedPrimitiveVB(), d3d_device7_DrawPrimitive(), d3d_device7_DrawPrimitiveStrided(), d3d_execute_buffer_SetExecuteData(), d3d_vertex_buffer7_Lock(), process_vertices_strided(), surface_lock(), wined3d_device_create_cursor_texture(), wined3d_device_process_vertices(), and wined3d_device_set_cursor_properties().

◆ wined3d_resource_map_info()

HRESULT __cdecl wined3d_resource_map_info ( struct wined3d_resource resource,
unsigned int  sub_resource_idx,
struct wined3d_map_info info,
DWORD  flags 
)

Definition at line 374 of file resource.c.

376{
377 TRACE("resource %p, sub_resource_idx %u.\n", resource, sub_resource_idx);
378
379 return resource->resource_ops->resource_map_info(resource, sub_resource_idx, info, flags);
380}

◆ wined3d_resource_preload()

◆ wined3d_resource_set_parent()

void __cdecl wined3d_resource_set_parent ( struct wined3d_resource resource,
void parent 
)

Definition at line 290 of file resource.c.

291{
292 resource->parent = parent;
293}

Referenced by ddraw_surface7_Flip().

◆ wined3d_resource_set_priority()

DWORD __cdecl wined3d_resource_set_priority ( struct wined3d_resource resource,
DWORD  priority 
)

Definition at line 263 of file resource.c.

264{
265 DWORD prev;
266
268 {
269 WARN("Called on non-managed resource %p, ignoring.\n", resource);
270 return 0;
271 }
272
273 prev = resource->priority;
274 resource->priority = priority;
275 TRACE("resource %p, new priority %u, returning old priority %u.\n", resource, priority, prev);
276 return prev;
277}
static int priority
Definition: timer.c:163

Referenced by d3d8_indexbuffer_SetPriority(), d3d8_texture_2d_SetPriority(), d3d8_texture_3d_SetPriority(), d3d8_texture_cube_SetPriority(), d3d8_vertexbuffer_SetPriority(), d3d9_indexbuffer_SetPriority(), d3d9_texture_2d_SetPriority(), d3d9_texture_3d_SetPriority(), d3d9_texture_cube_SetPriority(), d3d9_vertexbuffer_SetPriority(), and ddraw_surface7_SetPriority().

◆ wined3d_resource_unmap()

◆ wined3d_resource_update_info()

UINT __cdecl wined3d_resource_update_info ( struct wined3d_resource resource,
unsigned int  sub_resource_idx,
const struct wined3d_box box,
unsigned int  row_pitch,
unsigned int  depth_pitch 
)

Definition at line 389 of file resource.c.

391{
392 unsigned int width, height, depth;
393 struct wined3d_box b;
394 UINT data_size;
395
396 TRACE("resource %p, sub_resource_idx %u, box %s, row_pitch %u, depth_pitch %u.\n",
397 resource, sub_resource_idx, debug_box(box), row_pitch, depth_pitch);
398
399 if (resource->type == WINED3D_RTYPE_BUFFER)
400 {
401 if (sub_resource_idx > 0)
402 {
403 WARN("Invalid sub_resource_idx %u.\n", sub_resource_idx);
404 return 0;
405 }
406
408 height = 1;
409 depth = 1;
410 }
411 else if (resource->type == WINED3D_RTYPE_TEXTURE_1D ||
413 {
415 unsigned int level;
416
417 if (sub_resource_idx >= texture->level_count * texture->layer_count)
418 {
419 WARN("Invalid sub_resource_idx %u.\n", sub_resource_idx);
420 return 0;
421 }
422
423 level = sub_resource_idx % texture->level_count;
427 }
428 else
429 {
430 FIXME("Not implemented for %s resources.\n", debug_d3dresourcetype(resource->type));
431 return 0;
432 }
433
434 if (!box)
435 {
436 wined3d_box_set(&b, 0, 0, width, height, 0, depth);
437 box = &b;
438 }
439 else if (box->left >= box->right || box->right > width
440 || box->top >= box->bottom || box->bottom > height
441 || box->front >= box->back || box->back > depth)
442 {
443 WARN("Invalid box %s specified.\n", debug_box(box));
444 return 0;
445 }
446
447 if (resource->format_flags & WINED3DFMT_FLAG_BLOCKS)
448 {
450 {
451 FIXME("Calculation of block formats not implemented for %s resources.\n", debug_d3dresourcetype(resource->type));
452 return 0;
453 }
454
455 height = (box->bottom - box->top + resource->format->block_height - 1) / resource->format->block_height;
456 width = (box->right - box->left + resource->format->block_width - 1) / resource->format->block_width;
457 return (height - 1) * row_pitch + width * resource->format->block_byte_count;
458 }
459
460 data_size = 0;
461 switch (resource->type)
462 {
464 data_size += (box->back - box->front - 1) * depth_pitch;
465 /* fall-through */
467 data_size += (box->bottom - box->top - 1) * row_pitch;
468 /* fall-through */
470 data_size += (box->right - box->left) * resource->format->byte_count;
471 break;
473 data_size = box->right - box->left;
474 break;
476 break;
477 }
478
479 return data_size;
480}
#define WINED3DFMT_FLAG_BLOCKS

◆ WINED3D_RS_COLORWRITE()

static enum wined3d_render_state WINED3D_RS_COLORWRITE ( int  index)
inlinestatic

Definition at line 400 of file wined3d.h.

401{
402 if (index == 0) return WINED3D_RS_COLORWRITEENABLE;
403 if (index <= 3) return WINED3D_RS_COLORWRITEENABLE1 + index - 1;
404 if (index <= 7) return WINED3D_RS_COLORWRITEENABLE4 + index - 4;
406}
GLuint index
Definition: glext.h:6031

Referenced by device_clear_render_targets(), draw_primitive(), SetupForBlit(), state_init_default(), and surface_blt_fbo().

◆ wined3d_sampler_create()

HRESULT __cdecl wined3d_sampler_create ( struct wined3d_device device,
const struct wined3d_sampler_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_sampler **  sampler 
)

Definition at line 130 of file sampler.c.

132{
133 struct wined3d_sampler *object;
134
135 TRACE("device %p, desc %p, parent %p, sampler %p.\n", device, desc, parent, sampler);
136
137 if (desc->address_u < WINED3D_TADDRESS_WRAP || desc->address_u > WINED3D_TADDRESS_MIRROR_ONCE
138 || desc->address_v < WINED3D_TADDRESS_WRAP || desc->address_v > WINED3D_TADDRESS_MIRROR_ONCE
139 || desc->address_w < WINED3D_TADDRESS_WRAP || desc->address_w > WINED3D_TADDRESS_MIRROR_ONCE)
141
142 if (desc->mag_filter < WINED3D_TEXF_POINT || desc->mag_filter > WINED3D_TEXF_LINEAR
143 || desc->min_filter < WINED3D_TEXF_POINT || desc->min_filter > WINED3D_TEXF_LINEAR
144 || desc->mip_filter > WINED3D_TEXF_LINEAR)
146
147 if (!(object = heap_alloc_zero(sizeof(*object))))
148 return E_OUTOFMEMORY;
149
151
152 TRACE("Created sampler %p.\n", object);
153 *sampler = object;
154
155 return WINED3D_OK;
156}
static void wined3d_sampler_init(struct wined3d_sampler *sampler, struct wined3d_device *device, const struct wined3d_sampler_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: sampler.c:117
const struct wined3d_parent_ops * parent_ops

Referenced by create_default_samplers(), and sampler().

◆ wined3d_sampler_decref()

ULONG __cdecl wined3d_sampler_decref ( struct wined3d_sampler sampler)

Definition at line 53 of file sampler.c.

54{
55 ULONG refcount = InterlockedDecrement(&sampler->refcount);
56
57 TRACE("%p decreasing refcount to %u.\n", sampler, refcount);
58
59 if (!refcount)
60 {
61 sampler->parent_ops->wined3d_object_destroyed(sampler->parent);
63 }
64
65 return refcount;
66}
static void wined3d_sampler_destroy_object(void *object)
Definition: sampler.c:36

Referenced by destroy_default_samplers(), device_free_sampler(), sampler(), state_unbind_resources(), and wined3d_device_set_sampler().

◆ wined3d_sampler_get_parent()

void *__cdecl wined3d_sampler_get_parent ( const struct wined3d_sampler sampler)

Definition at line 68 of file sampler.c.

69{
70 TRACE("sampler %p.\n", sampler);
71
72 return sampler->parent;
73}

◆ wined3d_sampler_incref()

ULONG __cdecl wined3d_sampler_incref ( struct wined3d_sampler sampler)

Definition at line 27 of file sampler.c.

28{
29 ULONG refcount = InterlockedIncrement(&sampler->refcount);
30
31 TRACE("%p increasing refcount to %u.\n", sampler, refcount);
32
33 return refcount;
34}

Referenced by wined3d_device_set_sampler().

◆ wined3d_set_adapter_display_mode()

HRESULT __cdecl wined3d_set_adapter_display_mode ( struct wined3d wined3d,
UINT  adapter_idx,
const struct wined3d_display_mode mode 
)

Definition at line 4840 of file directx.c.

4842{
4843 struct wined3d_adapter *adapter;
4844 DEVMODEW new_mode, current_mode;
4845 RECT clip_rc;
4846 LONG ret;
4847 enum wined3d_format_id new_format_id;
4848
4849 TRACE("wined3d %p, adapter_idx %u, mode %p.\n", wined3d, adapter_idx, mode);
4850
4851 if (adapter_idx >= wined3d->adapter_count)
4853 adapter = &wined3d->adapters[adapter_idx];
4854
4855 memset(&new_mode, 0, sizeof(new_mode));
4856 new_mode.dmSize = sizeof(new_mode);
4857 memset(&current_mode, 0, sizeof(current_mode));
4858 current_mode.dmSize = sizeof(current_mode);
4859 if (mode)
4860 {
4861 const struct wined3d_format *format;
4862
4863 TRACE("mode %ux%u@%u %s %#x.\n", mode->width, mode->height, mode->refresh_rate,
4864 debug_d3dformat(mode->format_id), mode->scanline_ordering);
4865
4867
4869 new_mode.dmBitsPerPel = format->byte_count * CHAR_BIT;
4870 new_mode.dmPelsWidth = mode->width;
4871 new_mode.dmPelsHeight = mode->height;
4872
4873 new_mode.dmDisplayFrequency = mode->refresh_rate;
4874 if (mode->refresh_rate)
4875 new_mode.dmFields |= DM_DISPLAYFREQUENCY;
4876
4877 if (mode->scanline_ordering != WINED3D_SCANLINE_ORDERING_UNKNOWN)
4878 {
4879 new_mode.dmFields |= DM_DISPLAYFLAGS;
4880 if (mode->scanline_ordering == WINED3D_SCANLINE_ORDERING_INTERLACED)
4881 new_mode.u2.dmDisplayFlags |= DM_INTERLACED;
4882 }
4883 new_format_id = mode->format_id;
4884 }
4885 else
4886 {
4887 if (!EnumDisplaySettingsW(adapter->DeviceName, ENUM_REGISTRY_SETTINGS, &new_mode))
4888 {
4889 ERR("Failed to read mode from registry.\n");
4891 }
4892 new_format_id = pixelformat_for_depth(new_mode.dmBitsPerPel);
4893 }
4894
4895 /* Only change the mode if necessary. */
4896 if (!EnumDisplaySettingsW(adapter->DeviceName, ENUM_CURRENT_SETTINGS, &current_mode))
4897 {
4898 ERR("Failed to get current display mode.\n");
4899 }
4900 else if (current_mode.dmPelsWidth == new_mode.dmPelsWidth
4901 && current_mode.dmPelsHeight == new_mode.dmPelsHeight
4902 && current_mode.dmBitsPerPel == new_mode.dmBitsPerPel
4903 && (current_mode.dmDisplayFrequency == new_mode.dmDisplayFrequency
4904 || !(new_mode.dmFields & DM_DISPLAYFREQUENCY))
4905 && (current_mode.u2.dmDisplayFlags == new_mode.u2.dmDisplayFlags
4906 || !(new_mode.dmFields & DM_DISPLAYFLAGS)))
4907 {
4908 TRACE("Skipping redundant mode setting call.\n");
4909 adapter->screen_format = new_format_id;
4910 return WINED3D_OK;
4911 }
4912
4913 ret = ChangeDisplaySettingsExW(adapter->DeviceName, &new_mode, NULL, CDS_FULLSCREEN, NULL);
4915 {
4916 if (new_mode.dmFields & DM_DISPLAYFREQUENCY)
4917 {
4918 WARN("ChangeDisplaySettingsExW failed, trying without the refresh rate.\n");
4919 new_mode.dmFields &= ~DM_DISPLAYFREQUENCY;
4920 new_mode.dmDisplayFrequency = 0;
4921 ret = ChangeDisplaySettingsExW(adapter->DeviceName, &new_mode, NULL, CDS_FULLSCREEN, NULL);
4922 }
4925 }
4926
4927 /* Store the new values. */
4928 adapter->screen_format = new_format_id;
4929
4930 /* And finally clip mouse to our screen. */
4931 SetRect(&clip_rc, 0, 0, new_mode.dmPelsWidth, new_mode.dmPelsHeight);
4932 ClipCursor(&clip_rc);
4933
4934 return WINED3D_OK;
4935}
DWORD dmBitsPerPel
Definition: wingdi.h:1647
DWORD dmFields
Definition: wingdi.h:1622
DWORD dmPelsWidth
Definition: wingdi.h:1648
DWORD dmDisplayFlags
Definition: wingdi.h:1651
DWORD dmPelsHeight
Definition: wingdi.h:1649
DWORD dmDisplayFrequency
Definition: wingdi.h:1654
WORD dmSize
Definition: wingdi.h:1620
int ret
LONG WINAPI ChangeDisplaySettingsExW(LPCWSTR lpszDeviceName, LPDEVMODEW lpDevMode, HWND hwnd, DWORD dwflags, LPVOID lParam)
Definition: display.c:585
BOOL WINAPI EnumDisplaySettingsW(LPCWSTR lpszDeviceName, DWORD iModeNum, LPDEVMODEW lpDevMode)
Definition: display.c:408
#define DM_PELSWIDTH
Definition: wingdi.h:1269
#define DM_BITSPERPEL
Definition: wingdi.h:1268
#define DM_PELSHEIGHT
Definition: wingdi.h:1270
BOOL WINAPI ClipCursor(_In_opt_ LPCRECT)
#define DISP_CHANGE_SUCCESSFUL
Definition: winuser.h:190
#define CDS_FULLSCREEN
Definition: winuser.h:183
#define ENUM_REGISTRY_SETTINGS
Definition: winuser.h:180

Referenced by ddraw7_RestoreDisplayMode(), ddraw7_SetDisplayMode(), swapchain_cleanup(), swapchain_init(), wined3d_swapchain_activate(), and wined3d_swapchain_set_display_mode().

◆ wined3d_shader_create_cs()

HRESULT __cdecl wined3d_shader_create_cs ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4104 of file shader.c.

4106{
4107 struct wined3d_shader *object;
4108 HRESULT hr;
4109
4110 TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n",
4112
4113 if (!(object = heap_alloc_zero(sizeof(*object))))
4114 return E_OUTOFMEMORY;
4115
4117 {
4118 WARN("Failed to initialize compute shader, hr %#x.\n", hr);
4119 heap_free(object);
4120 return hr;
4121 }
4122
4123 TRACE("Created compute shader %p.\n", object);
4124 *shader = object;
4125
4126 return WINED3D_OK;
4127}
static HRESULT shader_init(struct wined3d_shader *shader, struct wined3d_device *device, const struct wined3d_shader_desc *desc, DWORD float_const_count, enum wined3d_shader_type type, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: shader.c:3582
const struct wined3d_parent_ops * parent_ops

◆ wined3d_shader_create_ds()

HRESULT __cdecl wined3d_shader_create_ds ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4129 of file shader.c.

4131{
4132 struct wined3d_shader *object;
4133 HRESULT hr;
4134
4135 TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n",
4137
4138 if (!(object = heap_alloc_zero(sizeof(*object))))
4139 return E_OUTOFMEMORY;
4140
4142 {
4143 WARN("Failed to initialize domain shader, hr %#x.\n", hr);
4144 heap_free(object);
4145 return hr;
4146 }
4147
4148 TRACE("Created domain shader %p.\n", object);
4149 *shader = object;
4150
4151 return WINED3D_OK;
4152}

◆ wined3d_shader_create_gs()

HRESULT __cdecl wined3d_shader_create_gs ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
const struct wined3d_stream_output_desc so_desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4154 of file shader.c.

4157{
4158 struct wined3d_shader *object;
4159 HRESULT hr;
4160
4161 TRACE("device %p, desc %p, so_desc %p, parent %p, parent_ops %p, shader %p.\n",
4162 device, desc, so_desc, parent, parent_ops, shader);
4163
4164 if (!(object = heap_alloc_zero(sizeof(*object))))
4165 return E_OUTOFMEMORY;
4166
4167 if (FAILED(hr = geometry_shader_init(object, device, desc, so_desc, parent, parent_ops)))
4168 {
4169 WARN("Failed to initialize geometry shader, hr %#x.\n", hr);
4170 heap_free(object);
4171 return hr;
4172 }
4173
4174 TRACE("Created geometry shader %p.\n", object);
4175 *shader = object;
4176
4177 return WINED3D_OK;
4178}
static HRESULT geometry_shader_init(struct wined3d_shader *shader, struct wined3d_device *device, const struct wined3d_shader_desc *desc, const struct wined3d_stream_output_desc *so_desc, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: shader.c:3722

◆ wined3d_shader_create_hs()

HRESULT __cdecl wined3d_shader_create_hs ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4180 of file shader.c.

4182{
4183 struct wined3d_shader *object;
4184 HRESULT hr;
4185
4186 TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n",
4188
4189 if (!(object = heap_alloc_zero(sizeof(*object))))
4190 return E_OUTOFMEMORY;
4191
4193 {
4194 WARN("Failed to initialize hull shader, hr %#x.\n", hr);
4195 heap_free(object);
4196 return hr;
4197 }
4198
4199 TRACE("Created hull shader %p.\n", object);
4200 *shader = object;
4201
4202 return WINED3D_OK;
4203}

◆ wined3d_shader_create_ps()

HRESULT __cdecl wined3d_shader_create_ps ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4205 of file shader.c.

4207{
4208 struct wined3d_shader *object;
4209 HRESULT hr;
4210
4211 TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n",
4213
4214 if (!(object = heap_alloc_zero(sizeof(*object))))
4215 return E_OUTOFMEMORY;
4216
4218 {
4219 WARN("Failed to initialize pixel shader, hr %#x.\n", hr);
4220 heap_free(object);
4221 return hr;
4222 }
4223
4224 TRACE("Created pixel shader %p.\n", object);
4225 *shader = object;
4226
4227 return WINED3D_OK;
4228}
static HRESULT pixel_shader_init(struct wined3d_shader *shader, struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: shader.c:4018

Referenced by d3d8_pixel_shader_init(), and pixelshader_init().

◆ wined3d_shader_create_vs()

HRESULT __cdecl wined3d_shader_create_vs ( struct wined3d_device device,
const struct wined3d_shader_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader **  shader 
)

Definition at line 4230 of file shader.c.

4232{
4233 struct wined3d_shader *object;
4234 HRESULT hr;
4235
4236 TRACE("device %p, desc %p, parent %p, parent_ops %p, shader %p.\n",
4238
4239 if (!(object = heap_alloc_zero(sizeof(*object))))
4240 return E_OUTOFMEMORY;
4241
4243 {
4244 WARN("Failed to initialize vertex shader, hr %#x.\n", hr);
4245 heap_free(object);
4246 return hr;
4247 }
4248
4249 TRACE("Created vertex shader %p.\n", object);
4250 *shader = object;
4251
4252 return WINED3D_OK;
4253}
static HRESULT vertex_shader_init(struct wined3d_shader *shader, struct wined3d_device *device, const struct wined3d_shader_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: shader.c:3693

Referenced by d3d8_vertex_shader_init(), and vertexshader_init().

◆ wined3d_shader_decref()

ULONG __cdecl wined3d_shader_decref ( struct wined3d_shader shader)

Definition at line 3364 of file shader.c.

3365{
3366 ULONG refcount = InterlockedDecrement(&shader->ref);
3367
3368 TRACE("%p decreasing refcount to %u.\n", shader, refcount);
3369
3370 if (!refcount)
3371 {
3372 shader->parent_ops->wined3d_object_destroyed(shader->parent);
3374 }
3375
3376 return refcount;
3377}
static void wined3d_shader_destroy_object(void *object)
Definition: shader.c:3358

Referenced by d3d8_pixel_shader_destroy(), d3d8_vertex_shader_destroy(), d3d9_pixelshader_Release(), d3d9_vertexshader_Release(), state_unbind_resources(), wined3d_device_set_compute_shader(), wined3d_device_set_domain_shader(), wined3d_device_set_geometry_shader(), wined3d_device_set_hull_shader(), wined3d_device_set_pixel_shader(), wined3d_device_set_vertex_shader(), and wined3d_stateblock_capture().

◆ wined3d_shader_get_byte_code()

HRESULT __cdecl wined3d_shader_get_byte_code ( const struct wined3d_shader shader,
void byte_code,
UINT byte_code_size 
)

Definition at line 3386 of file shader.c.

3388{
3389 TRACE("shader %p, byte_code %p, byte_code_size %p.\n", shader, byte_code, byte_code_size);
3390
3391 if (!byte_code)
3392 {
3393 *byte_code_size = shader->functionLength;
3394 return WINED3D_OK;
3395 }
3396
3397 if (*byte_code_size < shader->functionLength)
3398 {
3399 /* MSDN claims (for d3d8 at least) that if *byte_code_size is smaller
3400 * than the required size we should write the required size and
3401 * return D3DERR_MOREDATA. That's not actually true. */
3403 }
3404
3405 memcpy(byte_code, shader->function, shader->functionLength);
3406
3407 return WINED3D_OK;
3408}

Referenced by d3d8_device_GetPixelShaderFunction(), d3d8_device_GetVertexShaderFunction(), d3d9_pixelshader_GetFunction(), and d3d9_vertexshader_GetFunction().

◆ wined3d_shader_get_parent()

void *__cdecl wined3d_shader_get_parent ( const struct wined3d_shader shader)

Definition at line 3379 of file shader.c.

3380{
3381 TRACE("shader %p.\n", shader);
3382
3383 return shader->parent;
3384}

Referenced by d3d8_device_GetPixelShader(), d3d9_device_GetPixelShader(), and d3d9_device_GetVertexShader().

◆ wined3d_shader_incref()

◆ wined3d_shader_resource_view_create()

HRESULT __cdecl wined3d_shader_resource_view_create ( const struct wined3d_view_desc desc,
struct wined3d_resource resource,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_shader_resource_view **  view 
)

Definition at line 781 of file view.c.

784{
786 HRESULT hr;
787
788 TRACE("desc %p, resource %p, parent %p, parent_ops %p, view %p.\n",
790
791 if (!(object = heap_alloc_zero(sizeof(*object))))
792 return E_OUTOFMEMORY;
793
795 {
796 heap_free(object);
797 WARN("Failed to initialise view, hr %#x.\n", hr);
798 return hr;
799 }
800
801 TRACE("Created shader resource view %p.\n", object);
802 *view = object;
803
804 return WINED3D_OK;
805}
static HRESULT wined3d_shader_resource_view_init(struct wined3d_shader_resource_view *view, const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: view.c:759
const struct wined3d_parent_ops * parent_ops

Referenced by d3d9_texture_acquire_shader_resource_view().

◆ wined3d_shader_resource_view_decref()

ULONG __cdecl wined3d_shader_resource_view_decref ( struct wined3d_shader_resource_view view)

Definition at line 671 of file view.c.

672{
673 ULONG refcount = InterlockedDecrement(&view->refcount);
674
675 TRACE("%p decreasing refcount to %u.\n", view, refcount);
676
677 if (!refcount)
678 {
679 struct wined3d_resource *resource = view->resource;
680 struct wined3d_device *device = resource->device;
681
682 /* Call wined3d_object_destroyed() before releasing the resource,
683 * since releasing the resource may end up destroying the parent. */
684 view->parent_ops->wined3d_object_destroyed(view->parent);
687 }
688
689 return refcount;
690}
static void wined3d_shader_resource_view_destroy_object(void *object)
Definition: view.c:652

Referenced by d3d9_texture_cleanup(), state_unbind_resources(), and wined3d_device_set_shader_resource_view().

◆ wined3d_shader_resource_view_generate_mipmaps()

void __cdecl wined3d_shader_resource_view_generate_mipmaps ( struct wined3d_shader_resource_view view)

Definition at line 917 of file view.c.

918{
919 struct wined3d_texture *texture;
920
921 TRACE("view %p.\n", view);
922
923 if (view->resource->type == WINED3D_RTYPE_BUFFER)
924 {
925 WARN("Called on buffer resource %p.\n", view->resource);
926 return;
927 }
928
931 {
932 WARN("Texture without the WINED3D_TEXTURE_GENERATE_MIPMAPS flag, ignoring.\n");
933 return;
934 }
935
936 wined3d_cs_emit_generate_mipmaps(view->resource->device->cs, view);
937}
void wined3d_cs_emit_generate_mipmaps(struct wined3d_cs *cs, struct wined3d_shader_resource_view *view)
Definition: cs.c:2436
#define WINED3D_TEXTURE_GENERATE_MIPMAPS

Referenced by d3d9_texture_gen_auto_mipmap().

◆ wined3d_shader_resource_view_get_parent()

void *__cdecl wined3d_shader_resource_view_get_parent ( const struct wined3d_shader_resource_view view)

Definition at line 692 of file view.c.

693{
694 TRACE("view %p.\n", view);
695
696 return view->parent;
697}

◆ wined3d_shader_resource_view_incref()

ULONG __cdecl wined3d_shader_resource_view_incref ( struct wined3d_shader_resource_view view)

Definition at line 643 of file view.c.

644{
645 ULONG refcount = InterlockedIncrement(&view->refcount);
646
647 TRACE("%p increasing refcount to %u.\n", view, refcount);
648
649 return refcount;
650}

Referenced by wined3d_device_set_shader_resource_view().

◆ wined3d_shader_set_local_constants_float()

HRESULT __cdecl wined3d_shader_set_local_constants_float ( struct wined3d_shader shader,
UINT  start_idx,
const float src_data,
UINT  vector4f_count 
)

Definition at line 3411 of file shader.c.

3413{
3414 UINT end_idx = start_idx + count;
3415 UINT i;
3416
3417 TRACE("shader %p, start_idx %u, src_data %p, count %u.\n", shader, start_idx, src_data, count);
3418
3419 if (end_idx > shader->limits->constant_float)
3420 {
3421 WARN("end_idx %u > float constants limit %u.\n",
3422 end_idx, shader->limits->constant_float);
3423 end_idx = shader->limits->constant_float;
3424 }
3425
3426 for (i = start_idx; i < end_idx; ++i)
3427 {
3428 struct wined3d_shader_lconst *lconst;
3429 float *value;
3430
3431 if (!(lconst = heap_alloc(sizeof(*lconst))))
3432 return E_OUTOFMEMORY;
3433
3434 lconst->idx = i;
3435 value = (float *)lconst->value;
3436 memcpy(value, src_data + (i - start_idx) * 4 /* 4 components */, 4 * sizeof(float));
3437 list_add_head(&shader->constantsF, &lconst->entry);
3438
3439 if (isinf(value[0]) || isnan(value[0]) || isinf(value[1]) || isnan(value[1])
3440 || isinf(value[2]) || isnan(value[2]) || isinf(value[3]) || isnan(value[3]))
3441 {
3442 shader->lconst_inf_or_nan = TRUE;
3443 }
3444 }
3445
3446 return WINED3D_OK;
3447}
#define isinf(x)
Definition: mingw_math.h:94
#define isnan(x)
Definition: mingw_math.h:133

Referenced by load_local_constants().

◆ wined3d_stateblock_apply()

void __cdecl wined3d_stateblock_apply ( const struct wined3d_stateblock stateblock)

Definition at line 965 of file stateblock.c.

966{
967 struct wined3d_device *device = stateblock->device;
968 unsigned int i;
969 DWORD map;
970
971 TRACE("Applying stateblock %p to device %p.\n", stateblock, device);
972
973 if (stateblock->changed.vertexShader)
975
976 /* Vertex Shader Constants. */
977 for (i = 0; i < stateblock->num_contained_vs_consts_f; ++i)
978 {
980 1, &stateblock->state.vs_consts_f[stateblock->contained_vs_consts_f[i]]);
981 }
982 for (i = 0; i < stateblock->num_contained_vs_consts_i; ++i)
983 {
985 1, &stateblock->state.vs_consts_i[stateblock->contained_vs_consts_i[i]]);
986 }
987 for (i = 0; i < stateblock->num_contained_vs_consts_b; ++i)
988 {
990 1, &stateblock->state.vs_consts_b[stateblock->contained_vs_consts_b[i]]);
991 }
992
993 apply_lights(device, &stateblock->state);
994
995 if (stateblock->changed.pixelShader)
997
998 /* Pixel Shader Constants. */
999 for (i = 0; i < stateblock->num_contained_ps_consts_f; ++i)
1000 {
1002 1, &stateblock->state.ps_consts_f[stateblock->contained_ps_consts_f[i]]);
1003 }
1004 for (i = 0; i < stateblock->num_contained_ps_consts_i; ++i)
1005 {
1007 1, &stateblock->state.ps_consts_i[stateblock->contained_ps_consts_i[i]]);
1008 }
1009 for (i = 0; i < stateblock->num_contained_ps_consts_b; ++i)
1010 {
1012 1, &stateblock->state.ps_consts_b[stateblock->contained_ps_consts_b[i]]);
1013 }
1014
1015 /* Render states. */
1016 for (i = 0; i < stateblock->num_contained_render_states; ++i)
1017 {
1019 stateblock->state.render_states[stateblock->contained_render_states[i]]);
1020 }
1021
1022 /* Texture states. */
1023 for (i = 0; i < stateblock->num_contained_tss_states; ++i)
1024 {
1025 DWORD stage = stateblock->contained_tss_states[i].stage;
1026 DWORD state = stateblock->contained_tss_states[i].state;
1027
1028 wined3d_device_set_texture_stage_state(device, stage, state, stateblock->state.texture_states[stage][state]);
1029 }
1030
1031 /* Sampler states. */
1032 for (i = 0; i < stateblock->num_contained_sampler_states; ++i)
1033 {
1034 DWORD stage = stateblock->contained_sampler_states[i].stage;
1035 DWORD state = stateblock->contained_sampler_states[i].state;
1036 DWORD value = stateblock->state.sampler_states[stage][state];
1037
1040 }
1041
1042 /* Transform states. */
1043 for (i = 0; i < stateblock->num_contained_transform_states; ++i)
1044 {
1046 &stateblock->state.transforms[stateblock->contained_transform_states[i]]);
1047 }
1048
1049 if (stateblock->changed.indices)
1050 {
1051 wined3d_device_set_index_buffer(device, stateblock->state.index_buffer,
1052 stateblock->state.index_format, stateblock->state.index_offset);
1053 wined3d_device_set_base_vertex_index(device, stateblock->state.base_vertex_index);
1054 }
1055
1056 if (stateblock->changed.vertexDecl && stateblock->state.vertex_declaration)
1057 wined3d_device_set_vertex_declaration(device, stateblock->state.vertex_declaration);
1058
1059 if (stateblock->changed.material)
1060 wined3d_device_set_material(device, &stateblock->state.material);
1061
1062 if (stateblock->changed.viewport)
1063 wined3d_device_set_viewport(device, &stateblock->state.viewport);
1064
1065 if (stateblock->changed.scissorRect)
1066 wined3d_device_set_scissor_rect(device, &stateblock->state.scissor_rect);
1067
1068 map = stateblock->changed.streamSource;
1069 for (i = 0; map; map >>= 1, ++i)
1070 {
1071 if (map & 1)
1073 stateblock->state.streams[i].buffer,
1074 0, stateblock->state.streams[i].stride);
1075 }
1076
1077 map = stateblock->changed.streamFreq;
1078 for (i = 0; map; map >>= 1, ++i)
1079 {
1080 if (map & 1)
1082 stateblock->state.streams[i].frequency | stateblock->state.streams[i].flags);
1083 }
1084
1085 map = stateblock->changed.textures;
1086 for (i = 0; map; map >>= 1, ++i)
1087 {
1088 DWORD stage;
1089
1090 if (!(map & 1)) continue;
1091
1093 wined3d_device_set_texture(device, stage, stateblock->state.textures[i]);
1094 }
1095
1096 map = stateblock->changed.clipplane;
1097 for (i = 0; map; map >>= 1, ++i)
1098 {
1099 if (!(map & 1)) continue;
1100
1101 wined3d_device_set_clip_plane(device, i, &stateblock->state.clip_planes[i]);
1102 }
1103
1104 TRACE("Applied stateblock %p.\n", stateblock);
1105}
void CDECL wined3d_device_set_vertex_declaration(struct wined3d_device *device, struct wined3d_vertex_declaration *declaration)
Definition: device.c:2157
HRESULT CDECL wined3d_device_set_vs_consts_f(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants)
Definition: device.c:2463
HRESULT CDECL wined3d_device_set_stream_source_freq(struct wined3d_device *device, UINT stream_idx, UINT divider)
Definition: device.c:1451
void CDECL wined3d_device_set_base_vertex_index(struct wined3d_device *device, INT base_index)
Definition: device.c:1917
void CDECL wined3d_device_set_pixel_shader(struct wined3d_device *device, struct wined3d_shader *shader)
Definition: device.c:2509
void CDECL wined3d_device_set_material(struct wined3d_device *device, const struct wined3d_material *material)
Definition: device.c:1849
void CDECL wined3d_device_set_scissor_rect(struct wined3d_device *device, const RECT *rect)
Definition: device.c:2126
void CDECL wined3d_device_set_vertex_shader(struct wined3d_device *device, struct wined3d_shader *shader)
Definition: device.c:2186
HRESULT CDECL wined3d_device_set_ps_consts_f(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_vec4 *constants)
Definition: device.c:2679
HRESULT CDECL wined3d_device_set_texture(struct wined3d_device *device, UINT stage, struct wined3d_texture *texture)
Definition: device.c:3462
void CDECL wined3d_device_set_sampler_state(struct wined3d_device *device, UINT sampler_idx, enum wined3d_sampler_state state, DWORD value)
Definition: device.c:2071
void CDECL wined3d_device_set_index_buffer(struct wined3d_device *device, struct wined3d_buffer *buffer, enum wined3d_format_id format_id, unsigned int offset)
Definition: device.c:1874
void CDECL wined3d_device_set_viewport(struct wined3d_device *device, const struct wined3d_viewport *viewport)
Definition: device.c:1931
HRESULT CDECL wined3d_device_set_vs_consts_i(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_ivec4 *constants)
Definition: device.c:2415
void CDECL wined3d_device_set_texture_stage_state(struct wined3d_device *device, UINT stage, enum wined3d_texture_stage_state state, DWORD value)
Definition: device.c:3405
void CDECL wined3d_device_set_render_state(struct wined3d_device *device, enum wined3d_render_state state, DWORD value)
Definition: device.c:2027
HRESULT CDECL wined3d_device_set_clip_plane(struct wined3d_device *device, UINT plane_idx, const struct wined3d_vec4 *plane)
Definition: device.c:1783
HRESULT CDECL wined3d_device_set_ps_consts_i(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const struct wined3d_ivec4 *constants)
Definition: device.c:2630
HRESULT CDECL wined3d_device_set_stream_source(struct wined3d_device *device, UINT stream_idx, struct wined3d_buffer *buffer, UINT offset, UINT stride)
Definition: device.c:1378
HRESULT CDECL wined3d_device_set_ps_consts_b(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const BOOL *constants)
Definition: device.c:2581
HRESULT CDECL wined3d_device_set_vs_consts_b(struct wined3d_device *device, unsigned int start_idx, unsigned int count, const BOOL *constants)
Definition: device.c:2366
DWORD contained_vs_consts_f[WINED3D_MAX_VS_CONSTS_F]
unsigned int num_contained_sampler_states
struct wined3d_device * device
unsigned int num_contained_transform_states
DWORD contained_vs_consts_i[WINED3D_MAX_CONSTS_I]
unsigned int num_contained_vs_consts_i
DWORD contained_render_states[WINEHIGHEST_RENDER_STATE+1]
unsigned int num_contained_vs_consts_b
unsigned int num_contained_ps_consts_f
DWORD contained_transform_states[HIGHEST_TRANSFORMSTATE+1]
unsigned int num_contained_vs_consts_f
unsigned int num_contained_tss_states
unsigned int num_contained_ps_consts_b
struct StageState contained_tss_states[MAX_TEXTURES *(WINED3D_HIGHEST_TEXTURE_STATE+1)]
unsigned int num_contained_ps_consts_i
struct wined3d_saved_states changed
DWORD contained_ps_consts_i[WINED3D_MAX_CONSTS_I]
DWORD contained_vs_consts_b[WINED3D_MAX_CONSTS_B]
DWORD contained_ps_consts_f[WINED3D_MAX_PS_CONSTS_F]
struct StageState contained_sampler_states[MAX_COMBINED_SAMPLERS *WINED3D_HIGHEST_SAMPLER_STATE]
DWORD contained_ps_consts_b[WINED3D_MAX_CONSTS_B]
unsigned int num_contained_render_states
static void apply_lights(struct wined3d_device *device, const struct wined3d_state *state)
Definition: stateblock.c:947

Referenced by d3d8_device_ApplyStateBlock(), d3d9_stateblock_Apply(), d3d_device7_ApplyStateBlock(), and ddraw_set_cooperative_level().

◆ wined3d_stateblock_capture()

void __cdecl wined3d_stateblock_capture ( struct wined3d_stateblock stateblock)

Definition at line 684 of file stateblock.c.

685{
686 const struct wined3d_state *src_state = &stateblock->device->state;
687 unsigned int i;
688 DWORD map;
689
690 TRACE("stateblock %p.\n", stateblock);
691
692 TRACE("Capturing state %p.\n", src_state);
693
694 if (stateblock->changed.vertexShader && stateblock->state.shader[WINED3D_SHADER_TYPE_VERTEX]
695 != src_state->shader[WINED3D_SHADER_TYPE_VERTEX])
696 {
697 TRACE("Updating vertex shader from %p to %p\n",
698 stateblock->state.shader[WINED3D_SHADER_TYPE_VERTEX],
700
701 if (src_state->shader[WINED3D_SHADER_TYPE_VERTEX])
703 if (stateblock->state.shader[WINED3D_SHADER_TYPE_VERTEX])
705 stateblock->state.shader[WINED3D_SHADER_TYPE_VERTEX] = src_state->shader[WINED3D_SHADER_TYPE_VERTEX];
706 }
707
708 /* Vertex shader float constants. */
709 for (i = 0; i < stateblock->num_contained_vs_consts_f; ++i)
710 {
711 unsigned int idx = stateblock->contained_vs_consts_f[i];
712
713 TRACE("Setting vs_consts_f[%u] to %s.\n", idx, debug_vec4(&src_state->vs_consts_f[idx]));
714
715 stateblock->state.vs_consts_f[idx] = src_state->vs_consts_f[idx];
716 }
717
718 /* Vertex shader integer constants. */
719 for (i = 0; i < stateblock->num_contained_vs_consts_i; ++i)
720 {
721 unsigned int idx = stateblock->contained_vs_consts_i[i];
722
723 TRACE("Setting vs_consts[%u] to %s.\n", idx, debug_ivec4(&src_state->vs_consts_i[idx]));
724
725 stateblock->state.vs_consts_i[idx] = src_state->vs_consts_i[idx];
726 }
727
728 /* Vertex shader boolean constants. */
729 for (i = 0; i < stateblock->num_contained_vs_consts_b; ++i)
730 {
731 unsigned int idx = stateblock->contained_vs_consts_b[i];
732
733 TRACE("Setting vs_consts_b[%u] to %s.\n",
734 idx, src_state->vs_consts_b[idx] ? "TRUE" : "FALSE");
735
736 stateblock->state.vs_consts_b[idx] = src_state->vs_consts_b[idx];
737 }
738
739 /* Pixel shader float constants. */
740 for (i = 0; i < stateblock->num_contained_ps_consts_f; ++i)
741 {
742 unsigned int idx = stateblock->contained_ps_consts_f[i];
743
744 TRACE("Setting ps_consts_f[%u] to %s.\n", idx, debug_vec4(&src_state->ps_consts_f[idx]));
745
746 stateblock->state.ps_consts_f[idx] = src_state->ps_consts_f[idx];
747 }
748
749 /* Pixel shader integer constants. */
750 for (i = 0; i < stateblock->num_contained_ps_consts_i; ++i)
751 {
752 unsigned int idx = stateblock->contained_ps_consts_i[i];
753
754 TRACE("Setting ps_consts_i[%u] to %s.\n", idx, debug_ivec4(&src_state->ps_consts_i[idx]));
755
756 stateblock->state.ps_consts_i[idx] = src_state->ps_consts_i[idx];
757 }
758
759 /* Pixel shader boolean constants. */
760 for (i = 0; i < stateblock->num_contained_ps_consts_b; ++i)
761 {
762 unsigned int idx = stateblock->contained_ps_consts_b[i];
763 TRACE("Setting ps_consts_b[%u] to %s.\n",
764 idx, src_state->ps_consts_b[idx] ? "TRUE" : "FALSE");
765
766 stateblock->state.ps_consts_b[idx] = src_state->ps_consts_b[idx];
767 }
768
769 /* Others + Render & Texture */
770 for (i = 0; i < stateblock->num_contained_transform_states; ++i)
771 {
773
774 TRACE("Updating transform %#x.\n", transform);
775
776 stateblock->state.transforms[transform] = src_state->transforms[transform];
777 }
778
779 if (stateblock->changed.indices
780 && ((stateblock->state.index_buffer != src_state->index_buffer)
781 || (stateblock->state.base_vertex_index != src_state->base_vertex_index)
782 || (stateblock->state.index_format != src_state->index_format)
783 || (stateblock->state.index_offset != src_state->index_offset)))
784 {
785 TRACE("Updating index buffer to %p, base vertex index to %d.\n",
786 src_state->index_buffer, src_state->base_vertex_index);
787
788 if (src_state->index_buffer)
790 if (stateblock->state.index_buffer)
791 wined3d_buffer_decref(stateblock->state.index_buffer);
792 stateblock->state.index_buffer = src_state->index_buffer;
793 stateblock->state.base_vertex_index = src_state->base_vertex_index;
794 stateblock->state.index_format = src_state->index_format;
795 stateblock->state.index_offset = src_state->index_offset;
796 }
797
798 if (stateblock->changed.vertexDecl && stateblock->state.vertex_declaration != src_state->vertex_declaration)
799 {
800 TRACE("Updating vertex declaration from %p to %p.\n",
801 stateblock->state.vertex_declaration, src_state->vertex_declaration);
802
803 if (src_state->vertex_declaration)
805 if (stateblock->state.vertex_declaration)
806 wined3d_vertex_declaration_decref(stateblock->state.vertex_declaration);
807 stateblock->state.vertex_declaration = src_state->vertex_declaration;
808 }
809
810 if (stateblock->changed.material
811 && memcmp(&src_state->material, &stateblock->state.material, sizeof(stateblock->state.material)))
812 {
813 TRACE("Updating material.\n");
814
815 stateblock->state.material = src_state->material;
816 }
817
818 if (stateblock->changed.viewport
819 && memcmp(&src_state->viewport, &stateblock->state.viewport, sizeof(stateblock->state.viewport)))
820 {
821 TRACE("Updating viewport.\n");
822
823 stateblock->state.viewport = src_state->viewport;
824 }
825
826 if (stateblock->changed.scissorRect && memcmp(&src_state->scissor_rect,
827 &stateblock->state.scissor_rect, sizeof(stateblock->state.scissor_rect)))
828 {
829 TRACE("Updating scissor rect.\n");
830
831 stateblock->state.scissor_rect = src_state->scissor_rect;
832 }
833
834 map = stateblock->changed.streamSource;
835 for (i = 0; map; map >>= 1, ++i)
836 {
837 if (!(map & 1)) continue;
838
839 if (stateblock->state.streams[i].stride != src_state->streams[i].stride
840 || stateblock->state.streams[i].buffer != src_state->streams[i].buffer)
841 {
842 TRACE("Updating stream source %u to %p, stride to %u.\n",
843 i, src_state->streams[i].buffer,
844 src_state->streams[i].stride);
845
846 stateblock->state.streams[i].stride = src_state->streams[i].stride;
847 if (src_state->streams[i].buffer)
848 wined3d_buffer_incref(src_state->streams[i].buffer);
849 if (stateblock->state.streams[i].buffer)
850 wined3d_buffer_decref(stateblock->state.streams[i].buffer);
851 stateblock->state.streams[i].buffer = src_state->streams[i].buffer;
852 }
853 }
854
855 map = stateblock->changed.streamFreq;
856 for (i = 0; map; map >>= 1, ++i)
857 {
858 if (!(map & 1)) continue;
859
860 if (stateblock->state.streams[i].frequency != src_state->streams[i].frequency
861 || stateblock->state.streams[i].flags != src_state->streams[i].flags)
862 {
863 TRACE("Updating stream frequency %u to %u flags to %#x.\n",
864 i, src_state->streams[i].frequency, src_state->streams[i].flags);
865
866 stateblock->state.streams[i].frequency = src_state->streams[i].frequency;
867 stateblock->state.streams[i].flags = src_state->streams[i].flags;
868 }
869 }
870
871 map = stateblock->changed.clipplane;
872 for (i = 0; map; map >>= 1, ++i)
873 {
874 if (!(map & 1)) continue;
875
876 if (memcmp(&stateblock->state.clip_planes[i], &src_state->clip_planes[i], sizeof(src_state->clip_planes[i])))
877 {
878 TRACE("Updating clipplane %u.\n", i);
879 stateblock->state.clip_planes[i] = src_state->clip_planes[i];
880 }
881 }
882
883 /* Render */
884 for (i = 0; i < stateblock->num_contained_render_states; ++i)
885 {
886 enum wined3d_render_state rs = stateblock->contained_render_states[i];
887
888 TRACE("Updating render state %#x to %u.\n", rs, src_state->render_states[rs]);
889
890 stateblock->state.render_states[rs] = src_state->render_states[rs];
891 }
892
893 /* Texture states */
894 for (i = 0; i < stateblock->num_contained_tss_states; ++i)
895 {
896 DWORD stage = stateblock->contained_tss_states[i].stage;
897 DWORD state = stateblock->contained_tss_states[i].state;
898
899 TRACE("Updating texturestage state %u, %u to %#x (was %#x).\n", stage, state,
900 src_state->texture_states[stage][state], stateblock->state.texture_states[stage][state]);
901
902 stateblock->state.texture_states[stage][state] = src_state->texture_states[stage][state];
903 }
904
905 /* Samplers */
906 map = stateblock->changed.textures;
907 for (i = 0; map; map >>= 1, ++i)
908 {
909 if (!(map & 1)) continue;
910
911 TRACE("Updating texture %u to %p (was %p).\n",
912 i, src_state->textures[i], stateblock->state.textures[i]);
913
914 if (src_state->textures[i])
915 wined3d_texture_incref(src_state->textures[i]);
916 if (stateblock->state.textures[i])
917 wined3d_texture_decref(stateblock->state.textures[i]);
918 stateblock->state.textures[i] = src_state->textures[i];
919 }
920
921 for (i = 0; i < stateblock->num_contained_sampler_states; ++i)
922 {
923 DWORD stage = stateblock->contained_sampler_states[i].stage;
924 DWORD state = stateblock->contained_sampler_states[i].state;
925
926 TRACE("Updating sampler state %u, %u to %#x (was %#x).\n", stage, state,
927 src_state->sampler_states[stage][state], stateblock->state.sampler_states[stage][state]);
928
929 stateblock->state.sampler_states[stage][state] = src_state->sampler_states[stage][state];
930 }
931
932 if (stateblock->changed.pixelShader && stateblock->state.shader[WINED3D_SHADER_TYPE_PIXEL]
933 != src_state->shader[WINED3D_SHADER_TYPE_PIXEL])
934 {
935 if (src_state->shader[WINED3D_SHADER_TYPE_PIXEL])
937 if (stateblock->state.shader[WINED3D_SHADER_TYPE_PIXEL])
939 stateblock->state.shader[WINED3D_SHADER_TYPE_PIXEL] = src_state->shader[WINED3D_SHADER_TYPE_PIXEL];
940 }
941
942 wined3d_state_record_lights(&stateblock->state, src_state);
943
944 TRACE("Capture done.\n");
945}
GLuint GLenum GLenum transform
Definition: glext.h:9407
enum wined3d_format_id index_format
struct wined3d_vertex_declaration * vertex_declaration
struct wined3d_matrix transforms[HIGHEST_TRANSFORMSTATE+1]
BOOL ps_consts_b[WINED3D_MAX_CONSTS_B]
DWORD texture_states[MAX_TEXTURES][WINED3D_HIGHEST_TEXTURE_STATE+1]
struct wined3d_texture * textures[MAX_COMBINED_SAMPLERS]
struct wined3d_material material
struct wined3d_viewport viewport
struct wined3d_shader * shader[WINED3D_SHADER_TYPE_COUNT]
struct wined3d_ivec4 ps_consts_i[WINED3D_MAX_CONSTS_I]
struct wined3d_buffer * index_buffer
struct wined3d_stream_state streams[MAX_STREAMS+1]
BOOL vs_consts_b[WINED3D_MAX_CONSTS_B]
DWORD render_states[WINEHIGHEST_RENDER_STATE+1]
unsigned int index_offset
struct wined3d_vec4 ps_consts_f[WINED3D_MAX_PS_CONSTS_F]
struct wined3d_ivec4 vs_consts_i[WINED3D_MAX_CONSTS_I]
struct wined3d_vec4 vs_consts_f[WINED3D_MAX_VS_CONSTS_F]
struct wined3d_vec4 clip_planes[MAX_CLIP_DISTANCES]
DWORD sampler_states[MAX_COMBINED_SAMPLERS][WINED3D_HIGHEST_SAMPLER_STATE+1]
static void wined3d_state_record_lights(struct wined3d_state *dst_state, const struct wined3d_state *src_state)
Definition: stateblock.c:627
wined3d_render_state
Definition: wined3d.h:264
wined3d_transform_state
Definition: wined3d.h:647

Referenced by d3d8_device_CaptureStateBlock(), d3d9_stateblock_Capture(), d3d_device7_CaptureStateBlock(), ddraw_set_cooperative_level(), and stateblock_init().

◆ wined3d_stateblock_create()

HRESULT __cdecl wined3d_stateblock_create ( struct wined3d_device device,
enum wined3d_stateblock_type  type,
struct wined3d_stateblock **  stateblock 
)

Definition at line 1372 of file stateblock.c.

1374{
1375 struct wined3d_stateblock *object;
1376 HRESULT hr;
1377
1378 TRACE("device %p, type %#x, stateblock %p.\n",
1379 device, type, stateblock);
1380
1381 if (!(object = heap_alloc_zero(sizeof(*object))))
1382 return E_OUTOFMEMORY;
1383
1384 hr = stateblock_init(object, device, type);
1385 if (FAILED(hr))
1386 {
1387 WARN("Failed to initialize stateblock, hr %#x.\n", hr);
1388 heap_free(object);
1389 return hr;
1390 }
1391
1392 TRACE("Created stateblock %p.\n", object);
1393 *stateblock = object;
1394
1395 return WINED3D_OK;
1396}
static HRESULT stateblock_init(struct wined3d_stateblock *stateblock, struct wined3d_device *device, enum wined3d_stateblock_type type)
Definition: stateblock.c:1328

Referenced by d3d8_device_CreateStateBlock(), d3d_device7_CreateStateBlock(), ddraw_set_cooperative_level(), stateblock_init(), and wined3d_device_begin_stateblock().

◆ wined3d_stateblock_decref()

ULONG __cdecl wined3d_stateblock_decref ( struct wined3d_stateblock stateblock)

Definition at line 552 of file stateblock.c.

553{
554 ULONG refcount = InterlockedDecrement(&stateblock->ref);
555
556 TRACE("%p decreasing refcount to %u\n", stateblock, refcount);
557
558 if (!refcount)
559 {
560 state_cleanup(&stateblock->state);
561 heap_free(stateblock);
562 }
563
564 return refcount;
565}

Referenced by d3d8_device_CreateStateBlock(), d3d8_device_DeleteStateBlock(), d3d8_device_EndStateBlock(), d3d9_device_EndStateBlock(), d3d9_stateblock_Release(), d3d_device7_CreateStateBlock(), d3d_device7_DeleteStateBlock(), d3d_device7_EndStateBlock(), ddraw_set_cooperative_level(), wined3d_device_decref(), and wined3d_device_reset().

◆ wined3d_stateblock_incref()

ULONG __cdecl wined3d_stateblock_incref ( struct wined3d_stateblock stateblock)

Definition at line 420 of file stateblock.c.

421{
422 ULONG refcount = InterlockedIncrement(&stateblock->ref);
423
424 TRACE("%p increasing refcount to %u.\n", stateblock, refcount);
425
426 return refcount;
427}

◆ wined3d_swapchain_create()

HRESULT __cdecl wined3d_swapchain_create ( struct wined3d_device device,
struct wined3d_swapchain_desc desc,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_swapchain **  swapchain 
)

Definition at line 1023 of file swapchain.c.

1025{
1026 struct wined3d_swapchain *object;
1027 HRESULT hr;
1028
1029 TRACE("device %p, desc %p, parent %p, parent_ops %p, swapchain %p.\n",
1030 device, desc, parent, parent_ops, swapchain);
1031
1032 if (!(object = heap_alloc_zero(sizeof(*object))))
1033 return E_OUTOFMEMORY;
1034
1036 if (FAILED(hr))
1037 {
1038 WARN("Failed to initialize swapchain, hr %#x.\n", hr);
1039 heap_free(object);
1040 return hr;
1041 }
1042
1043 TRACE("Created swapchain %p.\n", object);
1044 *swapchain = object;
1045
1046 return WINED3D_OK;
1047}
const struct wined3d_parent_ops * parent_ops
static HRESULT swapchain_init(struct wined3d_swapchain *swapchain, struct wined3d_device *device, struct wined3d_swapchain_desc *desc, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: swapchain.c:776

Referenced by device_parent_create_swapchain(), and swapchain_init().

◆ wined3d_swapchain_decref()

ULONG __cdecl wined3d_swapchain_decref ( struct wined3d_swapchain swapchain)

Definition at line 113 of file swapchain.c.

114{
115 ULONG refcount = InterlockedDecrement(&swapchain->ref);
116
117 TRACE("%p decreasing refcount to %u.\n", swapchain, refcount);
118
119 if (!refcount)
120 {
121 struct wined3d_device *device = swapchain->device;
122
123 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
124
125 swapchain_cleanup(swapchain);
126 swapchain->parent_ops->wined3d_object_destroyed(swapchain->parent);
127 heap_free(swapchain);
128 }
129
130 return refcount;
131}
struct wined3d_device * device
static void swapchain_cleanup(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:39

Referenced by d3d8_swapchain_Release(), d3d9_swapchain_Release(), ddraw_destroy_swapchain(), wined3d_device_init_3d(), wined3d_device_init_gdi(), wined3d_device_uninit_3d(), wined3d_device_uninit_gdi(), and wined3d_texture_decref().

◆ wined3d_swapchain_get_back_buffer()

struct wined3d_texture *__cdecl wined3d_swapchain_get_back_buffer ( const struct wined3d_swapchain swapchain,
UINT  backbuffer_idx 
)

Definition at line 215 of file swapchain.c.

217{
218 TRACE("swapchain %p, back_buffer_idx %u.\n",
219 swapchain, back_buffer_idx);
220
221 /* Return invalid if there is no backbuffer array, otherwise it will
222 * crash when ddraw is used (there swapchain->back_buffers is always
223 * NULL). We need this because this function is called from
224 * stateblock_init_default_state() to get the default scissorrect
225 * dimensions. */
226 if (!swapchain->back_buffers || back_buffer_idx >= swapchain->desc.backbuffer_count)
227 {
228 WARN("Invalid back buffer index.\n");
229 /* Native d3d9 doesn't set NULL here, just as wine's d3d9. But set it
230 * here in wined3d to avoid problems in other libs. */
231 return NULL;
232 }
233
234 TRACE("Returning back buffer %p.\n", swapchain->back_buffers[back_buffer_idx]);
235
236 return swapchain->back_buffers[back_buffer_idx];
237}

Referenced by d3d8_device_GetBackBuffer(), d3d8_swapchain_GetBackBuffer(), and d3d9_swapchain_GetBackBuffer().

◆ wined3d_swapchain_get_desc()

void __cdecl wined3d_swapchain_get_desc ( const struct wined3d_swapchain swapchain,
struct wined3d_swapchain_desc desc 
)

◆ wined3d_swapchain_get_device()

struct wined3d_device *__cdecl wined3d_swapchain_get_device ( const struct wined3d_swapchain swapchain)

Definition at line 264 of file swapchain.c.

265{
266 TRACE("swapchain %p.\n", swapchain);
267
268 return swapchain->device;
269}

◆ wined3d_swapchain_get_display_mode()

HRESULT __cdecl wined3d_swapchain_get_display_mode ( const struct wined3d_swapchain swapchain,
struct wined3d_display_mode mode,
enum wined3d_display_rotation rotation 
)

Definition at line 248 of file swapchain.c.

250{
251 HRESULT hr;
252
253 TRACE("swapchain %p, mode %p, rotation %p.\n", swapchain, mode, rotation);
254
255 hr = wined3d_get_adapter_display_mode(swapchain->device->wined3d,
256 swapchain->device->adapter->ordinal, mode, rotation);
257
258 TRACE("Returning w %u, h %u, refresh rate %u, format %s.\n",
259 mode->width, mode->height, mode->refresh_rate, debug_d3dformat(mode->format_id));
260
261 return hr;
262}

Referenced by d3d9_swapchain_GetDisplayMode(), d3d9_swapchain_GetDisplayModeEx(), ddraw_surface7_Restore(), and wined3d_device_get_display_mode().

◆ wined3d_swapchain_get_front_buffer_data()

HRESULT __cdecl wined3d_swapchain_get_front_buffer_data ( const struct wined3d_swapchain swapchain,
struct wined3d_texture dst_texture,
unsigned int  sub_resource_idx 
)

Definition at line 194 of file swapchain.c.

196{
197 RECT src_rect, dst_rect;
198
199 TRACE("swapchain %p, dst_texture %p, sub_resource_idx %u.\n", swapchain, dst_texture, sub_resource_idx);
200
201 SetRect(&src_rect, 0, 0, swapchain->front_buffer->resource.width, swapchain->front_buffer->resource.height);
202 dst_rect = src_rect;
203
204 if (swapchain->desc.windowed)
205 {
206 MapWindowPoints(swapchain->win_handle, NULL, (POINT *)&dst_rect, 2);
207 FIXME("Using destination rect %s in windowed mode, this is likely wrong.\n",
208 wine_dbgstr_rect(&dst_rect));
209 }
210
211 return wined3d_texture_blt(dst_texture, sub_resource_idx, &dst_rect,
212 swapchain->front_buffer, 0, &src_rect, 0, NULL, WINED3D_TEXF_POINT);
213}
struct wined3d_texture * front_buffer
int WINAPI MapWindowPoints(_In_opt_ HWND hWndFrom, _In_opt_ HWND hWndTo, _Inout_updates_(cPoints) LPPOINT lpPoints, _In_ UINT cPoints)

Referenced by d3d8_device_GetFrontBuffer(), d3d9_device_GetFrontBufferData(), and d3d9_swapchain_GetFrontBufferData().

◆ wined3d_swapchain_get_gamma_ramp()

HRESULT __cdecl wined3d_swapchain_get_gamma_ramp ( const struct wined3d_swapchain swapchain,
struct wined3d_gamma_ramp ramp 
)

Definition at line 302 of file swapchain.c.

304{
305 HDC dc;
306
307 TRACE("swapchain %p, ramp %p.\n", swapchain, ramp);
308
309 dc = GetDCEx(swapchain->device_window, 0, DCX_USESTYLE | DCX_CACHE);
311 ReleaseDC(swapchain->device_window, dc);
312
313 return WINED3D_OK;
314}
#define DCX_USESTYLE
Definition: GetDCEx.c:10
static HDC
Definition: imagelist.c:92
BOOL WINAPI GetDeviceGammaRamp(_In_ HDC hdc, _Out_writes_bytes_(3 *256 *2) LPVOID lpRamp)
int WINAPI ReleaseDC(_In_opt_ HWND, _In_ HDC)
#define DCX_CACHE
Definition: winuser.h:2114
HDC WINAPI GetDCEx(_In_opt_ HWND, _In_opt_ HRGN, _In_ DWORD)

Referenced by swapchain_init(), and wined3d_device_get_gamma_ramp().

◆ wined3d_swapchain_get_parent()

void *__cdecl wined3d_swapchain_get_parent ( const struct wined3d_swapchain swapchain)

Definition at line 133 of file swapchain.c.

134{
135 TRACE("swapchain %p.\n", swapchain);
136
137 return swapchain->parent;
138}

Referenced by d3d9_device_get_swapchains(), and device_init().

◆ wined3d_swapchain_get_raster_status()

HRESULT __cdecl wined3d_swapchain_get_raster_status ( const struct wined3d_swapchain swapchain,
struct wined3d_raster_status raster_status 
)

Definition at line 239 of file swapchain.c.

241{
242 TRACE("swapchain %p, raster_status %p.\n", swapchain, raster_status);
243
244 return wined3d_get_adapter_raster_status(swapchain->device->wined3d,
245 swapchain->device->adapter->ordinal, raster_status);
246}
HRESULT CDECL wined3d_get_adapter_raster_status(const struct wined3d *wined3d, UINT adapter_idx, struct wined3d_raster_status *raster_status)
Definition: directx.c:4994

Referenced by d3d9_swapchain_GetRasterStatus(), and wined3d_device_get_raster_status().

◆ wined3d_swapchain_incref()

ULONG __cdecl wined3d_swapchain_incref ( struct wined3d_swapchain swapchain)

Definition at line 104 of file swapchain.c.

105{
106 ULONG refcount = InterlockedIncrement(&swapchain->ref);
107
108 TRACE("%p increasing refcount to %u.\n", swapchain, refcount);
109
110 return refcount;
111}

Referenced by d3d8_swapchain_AddRef(), d3d9_swapchain_AddRef(), ddraw_create_swapchain(), device_parent_create_swapchain(), and wined3d_texture_incref().

◆ wined3d_swapchain_present()

HRESULT __cdecl wined3d_swapchain_present ( struct wined3d_swapchain swapchain,
const RECT src_rect,
const RECT dst_rect,
HWND  dst_window_override,
DWORD  swap_interval,
DWORD  flags 
)

Definition at line 152 of file swapchain.c.

155{
156 static DWORD notified_flags = 0;
157 RECT s, d;
158
159 TRACE("swapchain %p, src_rect %s, dst_rect %s, dst_window_override %p, flags %#x.\n",
160 swapchain, wine_dbgstr_rect(src_rect), wine_dbgstr_rect(dst_rect),
161 dst_window_override, flags);
162
163 if (flags & ~notified_flags)
164 {
165 FIXME("Ignoring flags %#x.\n", flags & ~notified_flags);
166 notified_flags |= flags;
167 }
168
169 if (!swapchain->back_buffers)
170 {
171 WARN("Swapchain doesn't have a backbuffer, returning WINED3DERR_INVALIDCALL\n");
173 }
174
175 if (!src_rect)
176 {
177 SetRect(&s, 0, 0, swapchain->desc.backbuffer_width,
178 swapchain->desc.backbuffer_height);
179 src_rect = &s;
180 }
181
182 if (!dst_rect)
183 {
184 GetClientRect(swapchain->win_handle, &d);
185 dst_rect = &d;
186 }
187
188 wined3d_cs_emit_present(swapchain->device->cs, swapchain, src_rect,
189 dst_rect, dst_window_override, swap_interval, flags);
190
191 return WINED3D_OK;
192}
void wined3d_cs_emit_present(struct wined3d_cs *cs, struct wined3d_swapchain *swapchain, const RECT *src_rect, const RECT *dst_rect, HWND dst_window_override, DWORD swap_interval, DWORD flags)
Definition: cs.c:477
GLdouble s
Definition: gl.h:2039
BOOL WINAPI GetClientRect(_In_ HWND, _Out_ LPRECT)

Referenced by d3d8_swapchain_Present(), d3d9_device_Present(), d3d9_device_PresentEx(), d3d9_swapchain_Present(), and wined3d_surface_blt().

◆ wined3d_swapchain_resize_buffers()

HRESULT __cdecl wined3d_swapchain_resize_buffers ( struct wined3d_swapchain swapchain,
unsigned int  buffer_count,
unsigned int  width,
unsigned int  height,
enum wined3d_format_id  format_id,
enum wined3d_multisample_type  multisample_type,
unsigned int  multisample_quality 
)

Definition at line 1200 of file swapchain.c.

1203{
1204 struct wined3d_device *device = swapchain->device;
1205 BOOL update_desc = FALSE;
1206
1207 TRACE("swapchain %p, buffer_count %u, width %u, height %u, format %s, "
1208 "multisample_type %#x, multisample_quality %#x.\n",
1209 swapchain, buffer_count, width, height, debug_d3dformat(format_id),
1210 multisample_type, multisample_quality);
1211
1212 wined3d_swapchain_apply_sample_count_override(swapchain, format_id, &multisample_type, &multisample_quality);
1213
1214 if (buffer_count && buffer_count != swapchain->desc.backbuffer_count)
1215 FIXME("Cannot change the back buffer count yet.\n");
1216
1217 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
1218
1219 if (!width || !height)
1220 {
1221 /* The application is requesting that either the swapchain width or
1222 * height be set to the corresponding dimension in the window's
1223 * client rect. */
1224
1225 RECT client_rect;
1226
1227 if (!swapchain->desc.windowed)
1229
1230 if (!GetClientRect(swapchain->device_window, &client_rect))
1231 {
1232 ERR("Failed to get client rect, last error %#x.\n", GetLastError());
1234 }
1235
1236 if (!width)
1237 width = client_rect.right;
1238
1239 if (!height)
1240 height = client_rect.bottom;
1241 }
1242
1243 if (width != swapchain->desc.backbuffer_width
1244 || height != swapchain->desc.backbuffer_height)
1245 {
1246 swapchain->desc.backbuffer_width = width;
1247 swapchain->desc.backbuffer_height = height;
1248 update_desc = TRUE;
1249 }
1250
1252 {
1253 if (!swapchain->desc.windowed)
1255 format_id = swapchain->original_mode.format_id;
1256 }
1257
1258 if (format_id != swapchain->desc.backbuffer_format)
1259 {
1260 swapchain->desc.backbuffer_format = format_id;
1261 update_desc = TRUE;
1262 }
1263
1264 if (multisample_type != swapchain->desc.multisample_type
1265 || multisample_quality != swapchain->desc.multisample_quality)
1266 {
1267 swapchain->desc.multisample_type = multisample_type;
1268 swapchain->desc.multisample_quality = multisample_quality;
1269 update_desc = TRUE;
1270 }
1271
1272 if (update_desc)
1273 {
1274 HRESULT hr;
1275 UINT i;
1276
1277 if (FAILED(hr = wined3d_texture_update_desc(swapchain->front_buffer, swapchain->desc.backbuffer_width,
1278 swapchain->desc.backbuffer_height, swapchain->desc.backbuffer_format,
1279 swapchain->desc.multisample_type, swapchain->desc.multisample_quality, NULL, 0)))
1280 return hr;
1281
1282 for (i = 0; i < swapchain->desc.backbuffer_count; ++i)
1283 {
1284 if (FAILED(hr = wined3d_texture_update_desc(swapchain->back_buffers[i], swapchain->desc.backbuffer_width,
1285 swapchain->desc.backbuffer_height, swapchain->desc.backbuffer_format,
1286 swapchain->desc.multisample_type, swapchain->desc.multisample_quality, NULL, 0)))
1287 return hr;
1288 }
1289 }
1290
1293
1294 return WINED3D_OK;
1295}
HRESULT CDECL wined3d_texture_update_desc(struct wined3d_texture *texture, UINT width, UINT height, enum wined3d_format_id format_id, enum wined3d_multisample_type multisample_type, UINT multisample_quality, void *mem, UINT pitch)
Definition: texture.c:1356
LONG right
Definition: windef.h:308
LONG bottom
Definition: windef.h:309
void swapchain_update_draw_bindings(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:1132
static void wined3d_swapchain_apply_sample_count_override(const struct wined3d_swapchain *swapchain, enum wined3d_format_id format_id, enum wined3d_multisample_type *type, DWORD *quality)
Definition: swapchain.c:667
static void swapchain_update_render_to_fbo(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:651

Referenced by ddraw7_SetDisplayMode(), and wined3d_device_reset().

◆ wined3d_swapchain_resize_target()

HRESULT __cdecl wined3d_swapchain_resize_target ( struct wined3d_swapchain swapchain,
const struct wined3d_display_mode mode 
)

Definition at line 1322 of file swapchain.c.

1324{
1325 struct wined3d_device *device = swapchain->device;
1326 struct wined3d_display_mode actual_mode;
1327 RECT original_window_rect, window_rect;
1328 HRESULT hr;
1329
1330 TRACE("swapchain %p, mode %p.\n", swapchain, mode);
1331
1332 if (swapchain->desc.windowed)
1333 {
1334 SetRect(&window_rect, 0, 0, mode->width, mode->height);
1335 AdjustWindowRectEx(&window_rect,
1338 SetRect(&window_rect, 0, 0,
1339 window_rect.right - window_rect.left, window_rect.bottom - window_rect.top);
1340 GetWindowRect(swapchain->device_window, &original_window_rect);
1341 OffsetRect(&window_rect, original_window_rect.left, original_window_rect.top);
1342 }
1343 else if (swapchain->desc.flags & WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH)
1344 {
1345 actual_mode = *mode;
1346 if (FAILED(hr = wined3d_swapchain_set_display_mode(swapchain, &actual_mode)))
1347 return hr;
1348 SetRect(&window_rect, 0, 0, actual_mode.width, actual_mode.height);
1349 }
1350 else
1351 {
1352 if (FAILED(hr = wined3d_get_adapter_display_mode(device->wined3d, device->adapter->ordinal,
1353 &actual_mode, NULL)))
1354 {
1355 ERR("Failed to get display mode, hr %#x.\n", hr);
1357 }
1358
1359 SetRect(&window_rect, 0, 0, actual_mode.width, actual_mode.height);
1360 }
1361
1362 MoveWindow(swapchain->device_window, window_rect.left, window_rect.top,
1363 window_rect.right - window_rect.left,
1364 window_rect.bottom - window_rect.top, TRUE);
1365
1366 return WINED3D_OK;
1367}
static HRESULT wined3d_swapchain_set_display_mode(struct wined3d_swapchain *swapchain, struct wined3d_display_mode *mode)
Definition: swapchain.c:1297
#define WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH
Definition: wined3d.h:883
BOOL WINAPI GetWindowRect(_In_ HWND, _Out_ LPRECT)
BOOL WINAPI AdjustWindowRectEx(_Inout_ LPRECT, _In_ DWORD, _In_ BOOL, _In_ DWORD)
BOOL WINAPI MoveWindow(_In_ HWND, _In_ int, _In_ int, _In_ int, _In_ int, _In_ BOOL)

◆ wined3d_swapchain_set_fullscreen()

HRESULT __cdecl wined3d_swapchain_set_fullscreen ( struct wined3d_swapchain swapchain,
const struct wined3d_swapchain_desc desc,
const struct wined3d_display_mode mode 
)

Definition at line 1369 of file swapchain.c.

1371{
1372 struct wined3d_device *device = swapchain->device;
1373 struct wined3d_display_mode actual_mode;
1374 HRESULT hr;
1375
1376 TRACE("swapchain %p, desc %p, mode %p.\n", swapchain, swapchain_desc, mode);
1377
1378 if (swapchain->desc.flags & WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH)
1379 {
1380 if (mode)
1381 {
1382 actual_mode = *mode;
1383 }
1384 else
1385 {
1386 if (!swapchain_desc->windowed)
1387 {
1388 actual_mode.width = swapchain_desc->backbuffer_width;
1389 actual_mode.height = swapchain_desc->backbuffer_height;
1390 actual_mode.refresh_rate = swapchain_desc->refresh_rate;
1391 actual_mode.format_id = swapchain_desc->backbuffer_format;
1392 actual_mode.scanline_ordering = WINED3D_SCANLINE_ORDERING_UNKNOWN;
1393 }
1394 else
1395 {
1396 actual_mode = swapchain->original_mode;
1397 }
1398 }
1399
1400 if (FAILED(hr = wined3d_swapchain_set_display_mode(swapchain, &actual_mode)))
1401 return hr;
1402 }
1403 else
1404 {
1405 if (mode)
1406 WARN("WINED3D_SWAPCHAIN_ALLOW_MODE_SWITCH is not set, ignoring mode.\n");
1407
1408 if (FAILED(hr = wined3d_get_adapter_display_mode(device->wined3d, device->adapter->ordinal,
1409 &actual_mode, NULL)))
1410 {
1411 ERR("Failed to get display mode, hr %#x.\n", hr);
1413 }
1414 }
1415
1416 if (!swapchain_desc->windowed)
1417 {
1418 unsigned int width = actual_mode.width;
1419 unsigned int height = actual_mode.height;
1420
1421 if (swapchain->desc.windowed)
1422 {
1423 /* Switch from windowed to fullscreen */
1424 HWND focus_window = device->create_parms.focus_window;
1425 if (!focus_window)
1426 focus_window = swapchain->device_window;
1428 {
1429 ERR("Failed to acquire focus window, hr %#x.\n", hr);
1430 return hr;
1431 }
1432
1434 }
1435 else
1436 {
1437 /* Fullscreen -> fullscreen mode change */
1438 BOOL filter_messages = device->filter_messages;
1439 device->filter_messages = TRUE;
1440
1441 MoveWindow(swapchain->device_window, 0, 0, width, height, TRUE);
1442 ShowWindow(swapchain->device_window, SW_SHOW);
1443
1444 device->filter_messages = filter_messages;
1445 }
1446 swapchain->d3d_mode = actual_mode;
1447 }
1448 else if (!swapchain->desc.windowed)
1449 {
1450 /* Fullscreen -> windowed switch */
1451 RECT *window_rect = NULL;
1452 if (swapchain->desc.flags & WINED3D_SWAPCHAIN_RESTORE_WINDOW_RECT)
1453 window_rect = &swapchain->original_window_rect;
1456 }
1457
1458 swapchain->desc.windowed = swapchain_desc->windowed;
1459
1460 return WINED3D_OK;
1461}
HRESULT CDECL wined3d_device_acquire_focus_window(struct wined3d_device *device, HWND window)
Definition: device.c:938
void CDECL wined3d_device_restore_fullscreen_window(struct wined3d_device *device, HWND window, const RECT *window_rect)
Definition: device.c:885
void CDECL wined3d_device_release_focus_window(struct wined3d_device *device)
Definition: device.c:954
struct wined3d_display_mode original_mode d3d_mode
#define WINED3D_SWAPCHAIN_RESTORE_WINDOW_RECT
Definition: wined3d.h:885
BOOL WINAPI ShowWindow(_In_ HWND, _In_ int)
#define SW_SHOW
Definition: winuser.h:775

Referenced by wined3d_device_reset().

◆ wined3d_swapchain_set_gamma_ramp()

HRESULT __cdecl wined3d_swapchain_set_gamma_ramp ( const struct wined3d_swapchain swapchain,
DWORD  flags,
const struct wined3d_gamma_ramp ramp 
)

Definition at line 279 of file swapchain.c.

281{
282 HDC dc;
283
284 TRACE("swapchain %p, flags %#x, ramp %p.\n", swapchain, flags, ramp);
285
286 if (flags)
287 FIXME("Ignoring flags %#x.\n", flags);
288
289 dc = GetDCEx(swapchain->device_window, 0, DCX_USESTYLE | DCX_CACHE);
290 SetDeviceGammaRamp(dc, (void *)ramp);
291 ReleaseDC(swapchain->device_window, dc);
292
293 return WINED3D_OK;
294}
BOOL WINAPI SetDeviceGammaRamp(_In_ HDC hdc, _In_reads_bytes_(3 *256 *2) LPVOID lpRamp)

Referenced by swapchain_cleanup(), and wined3d_device_set_gamma_ramp().

◆ wined3d_swapchain_set_palette()

void __cdecl wined3d_swapchain_set_palette ( struct wined3d_swapchain swapchain,
struct wined3d_palette palette 
)

Definition at line 296 of file swapchain.c.

297{
298 TRACE("swapchain %p, palette %p.\n", swapchain, palette);
299 swapchain->palette = palette;
300}
struct wined3d_palette * palette

Referenced by ddraw_create_swapchain(), and ddraw_surface_set_palette().

◆ wined3d_swapchain_set_window()

void __cdecl wined3d_swapchain_set_window ( struct wined3d_swapchain swapchain,
HWND  window 
)

Definition at line 140 of file swapchain.c.

141{
142 if (!window)
143 window = swapchain->device_window;
144 if (window == swapchain->win_handle)
145 return;
146
147 TRACE("Setting swapchain %p window from %p to %p.\n",
148 swapchain, swapchain->win_handle, window);
149 swapchain->win_handle = window;
150}

Referenced by ddraw_surface7_SetClipper(), wined3d_cs_exec_present(), and wined3d_device_reset().

◆ wined3d_texture_add_dirty_region()

HRESULT __cdecl wined3d_texture_add_dirty_region ( struct wined3d_texture texture,
UINT  layer,
const struct wined3d_box dirty_region 
)

Definition at line 1677 of file texture.c.

1679{
1680 TRACE("texture %p, layer %u, dirty_region %s.\n", texture, layer, debug_box(dirty_region));
1681
1682 if (layer >= texture->layer_count)
1683 {
1684 WARN("Invalid layer %u specified.\n", layer);
1686 }
1687
1688 if (dirty_region)
1689 WARN("Ignoring dirty_region %s.\n", debug_box(dirty_region));
1690
1692
1693 return WINED3D_OK;
1694}
void wined3d_cs_emit_add_dirty_texture_region(struct wined3d_cs *cs, struct wined3d_texture *texture, unsigned int layer)
Definition: cs.c:2353
GLenum GLuint GLint GLint layer
Definition: glext.h:7007

Referenced by d3d8_texture_2d_AddDirtyRect(), d3d8_texture_3d_AddDirtyBox(), d3d8_texture_cube_AddDirtyRect(), d3d9_texture_2d_AddDirtyRect(), d3d9_texture_3d_AddDirtyBox(), and d3d9_texture_cube_AddDirtyRect().

◆ wined3d_texture_blt()

HRESULT __cdecl wined3d_texture_blt ( struct wined3d_texture dst_texture,
unsigned int  dst_idx,
const RECT dst_rect_in,
struct wined3d_texture src_texture,
unsigned int  src_idx,
const RECT src_rect_in,
DWORD  flags,
const struct wined3d_blt_fx fx,
enum wined3d_texture_filter_type  filter 
)

Definition at line 3262 of file texture.c.

3265{
3266 struct wined3d_box src_box = {src_rect->left, src_rect->top, src_rect->right, src_rect->bottom, 0, 1};
3267 struct wined3d_box dst_box = {dst_rect->left, dst_rect->top, dst_rect->right, dst_rect->bottom, 0, 1};
3268 unsigned int dst_format_flags, src_format_flags = 0;
3269 HRESULT hr;
3270
3271 TRACE("dst_texture %p, dst_sub_resource_idx %u, dst_rect %s, src_texture %p, "
3272 "src_sub_resource_idx %u, src_rect %s, flags %#x, fx %p, filter %s.\n",
3273 dst_texture, dst_sub_resource_idx, wine_dbgstr_rect(dst_rect), src_texture,
3274 src_sub_resource_idx, wine_dbgstr_rect(src_rect), flags, fx, debug_d3dtexturefiltertype(filter));
3275
3276 if (dst_sub_resource_idx >= dst_texture->level_count * dst_texture->layer_count
3277 || dst_texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
3279
3280 if (src_sub_resource_idx >= src_texture->level_count * src_texture->layer_count
3281 || src_texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
3283
3284 dst_format_flags = dst_texture->resource.format_flags;
3286 dst_sub_resource_idx % dst_texture->level_count, &dst_box)))
3287 return hr;
3288
3289 src_format_flags = src_texture->resource.format_flags;
3291 src_sub_resource_idx % src_texture->level_count, &src_box)))
3292 return hr;
3293
3294 if (dst_texture->sub_resources[dst_sub_resource_idx].map_count
3295 || src_texture->sub_resources[src_sub_resource_idx].map_count)
3296 {
3297#if !defined(STAGING_CSMT)
3298 WARN("Sub-resource is busy, returning WINEDDERR_SURFACEBUSY.\n");
3299 return WINEDDERR_SURFACEBUSY;
3300#else /* STAGING_CSMT */
3301 struct wined3d_device *device = dst_texture->resource.device;
3302 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
3303 if (dst_texture->sub_resources[dst_sub_resource_idx].map_count
3304 || (src_texture && src_texture->sub_resources[src_sub_resource_idx].map_count))
3305 {
3306 WARN("Sub-resource is busy, returning WINEDDERR_SURFACEBUSY.\n");
3307 return WINEDDERR_SURFACEBUSY;
3308 }
3309#endif /* STAGING_CSMT */
3310 }
3311
3312 if ((src_format_flags & (WINED3DFMT_FLAG_DEPTH | WINED3DFMT_FLAG_STENCIL))
3313 != (dst_format_flags & (WINED3DFMT_FLAG_DEPTH | WINED3DFMT_FLAG_STENCIL)))
3314 {
3315 WARN("Rejecting depth/stencil blit between incompatible formats.\n");
3317 }
3318
3319 wined3d_cs_emit_blt_sub_resource(dst_texture->resource.device->cs, &dst_texture->resource, dst_sub_resource_idx,
3320 &dst_box, &src_texture->resource, src_sub_resource_idx, &src_box, flags, fx, filter);
3321
3322 return WINED3D_OK;
3323}
const char * debug_d3dtexturefiltertype(enum wined3d_texture_filter_type filter_type)
Definition: utils.c:4539
GLint GLint GLint GLint GLint GLint GLint GLbitfield GLenum filter
Definition: glext.h:7005
GLfixed fx
Definition: tritemp.h:484

Referenced by copy_mipmap_chain(), d3d8_device_CopyRects(), d3d9_device_GetRenderTargetData(), d3d9_device_StretchRect(), d3d_texture2_Load(), ddraw_surface7_BltFast(), ddraw_surface_blt(), ddraw_surface_update_frontbuffer(), swapchain_gl_present(), wined3d_device_resolve_sub_resource(), and wined3d_swapchain_get_front_buffer_data().

◆ wined3d_texture_create()

HRESULT __cdecl wined3d_texture_create ( struct wined3d_device device,
const struct wined3d_resource_desc desc,
UINT  layer_count,
UINT  level_count,
DWORD  flags,
const struct wined3d_sub_resource_data data,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_texture **  texture 
)

Definition at line 3511 of file texture.c.

3514{
3515 struct wined3d_texture *object;
3516 HRESULT hr;
3517
3518 TRACE("device %p, desc %p, layer_count %u, level_count %u, flags %#x, data %p, "
3519 "parent %p, parent_ops %p, texture %p.\n",
3521
3522 if (!layer_count)
3523 {
3524 WARN("Invalid layer count.\n");
3525 return E_INVALIDARG;
3526 }
3527 if ((desc->usage & WINED3DUSAGE_LEGACY_CUBEMAP) && layer_count != 6)
3528 {
3529 ERR("Invalid layer count %u for legacy cubemap.\n", layer_count);
3530 layer_count = 6;
3531 }
3532
3533 if (!level_count)
3534 {
3535 WARN("Invalid level count.\n");
3537 }
3538
3539 if (desc->multisample_type != WINED3D_MULTISAMPLE_NONE)
3540 {
3541 const struct wined3d_format *format = wined3d_get_format(&device->adapter->gl_info,
3542 desc->format, desc->usage);
3543
3544 if (desc->multisample_type == WINED3D_MULTISAMPLE_NON_MASKABLE
3545 && desc->multisample_quality >= wined3d_popcount(format->multisample_types))
3546 {
3547 WARN("Unsupported quality level %u requested for WINED3D_MULTISAMPLE_NON_MASKABLE.\n",
3548 desc->multisample_quality);
3550 }
3551 if (desc->multisample_type != WINED3D_MULTISAMPLE_NON_MASKABLE
3552 && (!(format->multisample_types & 1u << (desc->multisample_type - 1))
3553 || desc->multisample_quality))
3554 {
3555 WARN("Unsupported multisample type %u quality %u requested.\n", desc->multisample_type,
3556 desc->multisample_quality);
3558 }
3559 }
3560
3561 if (!(object = heap_alloc_zero(FIELD_OFFSET(struct wined3d_texture,
3562 sub_resources[level_count * layer_count]))))
3563 return E_OUTOFMEMORY;
3564
3565 switch (desc->resource_type)
3566 {
3568 hr = texture1d_init(object, desc, layer_count, level_count, device, parent, parent_ops);
3569 break;
3570
3572 hr = texture_init(object, desc, layer_count, level_count, flags, device, parent, parent_ops);
3573 break;
3574
3576 hr = volumetexture_init(object, desc, layer_count, level_count, flags, device, parent, parent_ops);
3577 break;
3578
3579 default:
3580 ERR("Invalid resource type %s.\n", debug_d3dresourcetype(desc->resource_type));
3582 break;
3583 }
3584
3585 if (FAILED(hr))
3586 {
3587 WARN("Failed to initialize texture, returning %#x.\n", hr);
3588 heap_free(object);
3589 return hr;
3590 }
3591
3592 /* FIXME: We'd like to avoid ever allocating system memory for the texture
3593 * in this case. */
3594 if (data)
3595 {
3596 unsigned int sub_count = level_count * layer_count;
3597 unsigned int i;
3598
3599 for (i = 0; i < sub_count; ++i)
3600 {
3601 if (!data[i].data)
3602 {
3603 WARN("Invalid sub-resource data specified for sub-resource %u.\n", i);
3605 heap_free(object);
3606 return E_INVALIDARG;
3607 }
3608 }
3609
3610 for (i = 0; i < sub_count; ++i)
3611 {
3613 i, NULL, data[i].data, data[i].row_pitch, data[i].slice_pitch);
3614 }
3615 }
3616
3617 TRACE("Created texture %p.\n", object);
3618 *texture = object;
3619
3620 return WINED3D_OK;
3621}
void CDECL wined3d_device_update_sub_resource(struct wined3d_device *device, struct wined3d_resource *resource, unsigned int sub_resource_idx, const struct wined3d_box *box, const void *data, unsigned int row_pitch, unsigned int depth_pitch)
Definition: device.c:4281
static HRESULT texture_init(struct wined3d_texture *texture, const struct wined3d_resource_desc *desc, unsigned int layer_count, unsigned int level_count, DWORD flags, struct wined3d_device *device, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: texture.c:2641
static HRESULT volumetexture_init(struct wined3d_texture *texture, const struct wined3d_resource_desc *desc, UINT layer_count, UINT level_count, DWORD flags, struct wined3d_device *device, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: texture.c:3164
static HRESULT texture1d_init(struct wined3d_texture *texture, const struct wined3d_resource_desc *desc, UINT layer_count, UINT level_count, struct wined3d_device *device, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: texture.c:2518
static void wined3d_texture_cleanup_sync(struct wined3d_texture *texture)
Definition: texture.c:1009

Referenced by cubetexture_init(), d3d8_device_create_surface(), d3d9_device_create_surface(), ddraw_surface_create(), device_load_logo(), device_parent_create_swapchain_texture(), surface_convert_format(), texture_init(), volumetexture_init(), and wined3d_device_create_cursor_texture().

◆ wined3d_texture_decref()

ULONG __cdecl wined3d_texture_decref ( struct wined3d_texture texture)

Definition at line 1023 of file texture.c.

1024{
1025 ULONG refcount;
1026
1027 TRACE("texture %p, swapchain %p.\n", texture, texture->swapchain);
1028
1029 if (texture->swapchain)
1030 return wined3d_swapchain_decref(texture->swapchain);
1031
1032 refcount = InterlockedDecrement(&texture->resource.ref);
1033 TRACE("%p decreasing refcount to %u.\n", texture, refcount);
1034
1035 if (!refcount)
1036 {
1037 /* Wait for the texture to become idle if it's using user memory,
1038 * since the application is allowed to free that memory once the
1039 * texture is destroyed. Note that this implies that
1040 * wined3d_texture_destroy_object() can't access that memory either. */
1041 if (texture->user_memory)
1044 texture->resource.parent_ops->wined3d_object_destroyed(texture->resource.parent);
1045 resource_cleanup(&texture->resource);
1047 }
1048
1049 return refcount;
1050}
static void wined3d_texture_sub_resources_destroyed(struct wined3d_texture *texture)
Definition: texture.c:636
static void wined3d_texture_destroy_object(void *object)
Definition: texture.c:1017

Referenced by d3d8_device_create_surface(), d3d8_surface_Release(), d3d8_texture_2d_Release(), d3d8_texture_3d_Release(), d3d8_texture_cube_Release(), d3d9_device_create_surface(), d3d9_surface_Release(), d3d9_texture_cleanup(), ddraw_surface_cleanup(), ddraw_surface_create(), device_load_logo(), state_unbind_resources(), surface_cpu_blt(), swapchain_cleanup(), swapchain_init(), texture_resource_decref(), wined3d_device_reset(), wined3d_device_set_cursor_properties(), wined3d_device_set_texture(), wined3d_device_uninit_3d(), and wined3d_stateblock_capture().

◆ wined3d_texture_from_resource()

◆ wined3d_texture_get_dc()

HRESULT __cdecl wined3d_texture_get_dc ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
HDC dc 
)

Definition at line 3623 of file texture.c.

3624{
3625 struct wined3d_device *device = texture->resource.device;
3626 struct wined3d_texture_sub_resource *sub_resource;
3627 struct wined3d_surface *surface;
3628
3629 TRACE("texture %p, sub_resource_idx %u, dc %p.\n", texture, sub_resource_idx, dc);
3630
3631 if (!(texture->flags & WINED3D_TEXTURE_GET_DC))
3632 {
3633 WARN("Texture does not support GetDC\n");
3634 /* Don't touch the DC */
3636 }
3637
3638 if (!(sub_resource = wined3d_texture_get_sub_resource(texture, sub_resource_idx)))
3640
3641 if (texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
3642 {
3643 WARN("Not supported on %s resources.\n", debug_d3dresourcetype(texture->resource.type));
3645 }
3646
3647 surface = sub_resource->u.surface;
3648
3649 if (texture->resource.map_count && !(texture->flags & WINED3D_TEXTURE_GET_DC_LENIENT))
3651
3652 if (!surface->dc)
3653 {
3655 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
3656 }
3657 if (!surface->dc)
3659
3662 ++texture->resource.map_count;
3663 ++sub_resource->map_count;
3664
3665 *dc = surface->dc;
3666 TRACE("Returning dc %p.\n", *dc);
3667
3668 return WINED3D_OK;
3669}
void wined3d_cs_init_object(struct wined3d_cs *cs, void(*callback)(void *object), void *object)
Definition: cs.c:1890
static void texture2d_create_dc(void *object)
Definition: texture.c:1255
static struct wined3d_texture_sub_resource * wined3d_texture_get_sub_resource(struct wined3d_texture *texture, unsigned int sub_resource_idx)
Definition: texture.c:1661
#define WINED3D_TEXTURE_GET_DC_LENIENT
#define WINED3D_TEXTURE_GET_DC
#define WINED3D_TEXTURE_DC_IN_USE

Referenced by d3d9_surface_GetDC(), ddraw_surface7_GetDC(), ddraw_surface_update_frontbuffer(), and device_load_logo().

◆ wined3d_texture_get_level_count()

◆ wined3d_texture_get_lod()

DWORD __cdecl wined3d_texture_get_lod ( const struct wined3d_texture texture)

Definition at line 1221 of file texture.c.

1222{
1223 TRACE("texture %p, returning %u.\n", texture, texture->lod);
1224
1225 return texture->lod;
1226}

Referenced by d3d8_texture_2d_GetLOD(), d3d8_texture_3d_GetLOD(), d3d8_texture_cube_GetLOD(), d3d9_texture_2d_GetLOD(), d3d9_texture_3d_GetLOD(), d3d9_texture_cube_GetLOD(), and ddraw_surface7_GetLOD().

◆ wined3d_texture_get_overlay_position()

HRESULT __cdecl wined3d_texture_get_overlay_position ( const struct wined3d_texture texture,
unsigned int  sub_resource_idx,
LONG x,
LONG y 
)

Definition at line 3325 of file texture.c.

3327{
3328 struct wined3d_overlay_info *overlay;
3329
3330 TRACE("texture %p, sub_resource_idx %u, x %p, y %p.\n", texture, sub_resource_idx, x, y);
3331
3332 if (!(texture->resource.usage & WINED3DUSAGE_OVERLAY)
3333 || sub_resource_idx >= texture->level_count * texture->layer_count)
3334 {
3335 WARN("Invalid sub-resource specified.\n");
3337 }
3338
3339 overlay = &texture->overlay_info[sub_resource_idx];
3340 if (!overlay->dst)
3341 {
3342 TRACE("Overlay not visible.\n");
3343 *x = 0;
3344 *y = 0;
3346 }
3347
3348 *x = overlay->dst_rect.left;
3349 *y = overlay->dst_rect.top;
3350
3351 TRACE("Returning position %d, %d.\n", *x, *y);
3352
3353 return WINED3D_OK;
3354}
GLint GLint GLint GLint GLint GLint y
Definition: gl.h:1548
#define WINEDDERR_OVERLAYNOTVISIBLE
Definition: wined3d.h:53
#define WINED3DUSAGE_OVERLAY
Definition: wined3d.h:921
#define WINEDDERR_NOTAOVERLAYSURFACE
Definition: wined3d.h:49

Referenced by ddraw_surface7_GetOverlayPosition().

◆ wined3d_texture_get_parent()

◆ wined3d_texture_get_pitch()

◆ wined3d_texture_get_resource()

◆ wined3d_texture_get_sub_resource_desc()

HRESULT __cdecl wined3d_texture_get_sub_resource_desc ( const struct wined3d_texture texture,
unsigned int  sub_resource_idx,
struct wined3d_sub_resource_desc desc 
)

Definition at line 3480 of file texture.c.

3482{
3483 unsigned int sub_count = texture->level_count * texture->layer_count;
3484 const struct wined3d_resource *resource;
3485 unsigned int level_idx;
3486
3487 TRACE("texture %p, sub_resource_idx %u, desc %p.\n", texture, sub_resource_idx, desc);
3488
3489 if (sub_resource_idx >= sub_count)
3490 {
3491 WARN("sub_resource_idx %u >= sub_count %u.\n", sub_resource_idx, sub_count);
3493 }
3494
3495 resource = &texture->resource;
3496 desc->format = resource->format->id;
3497 desc->multisample_type = resource->multisample_type;
3498 desc->multisample_quality = resource->multisample_quality;
3499 desc->usage = resource->usage;
3500 desc->access = resource->access;
3501
3502 level_idx = sub_resource_idx % texture->level_count;
3503 desc->width = wined3d_texture_get_level_width(texture, level_idx);
3504 desc->height = wined3d_texture_get_level_height(texture, level_idx);
3505 desc->depth = wined3d_texture_get_level_depth(texture, level_idx);
3506 desc->size = texture->sub_resources[sub_resource_idx].size;
3507
3508 return WINED3D_OK;
3509}

Referenced by d3d8_device_CopyRects(), d3d8_device_SetRenderTarget(), d3d8_surface_GetDesc(), d3d8_texture_2d_GetLevelDesc(), d3d8_texture_3d_GetLevelDesc(), d3d8_texture_cube_GetLevelDesc(), d3d8_volume_GetDesc(), d3d9_device_ColorFill(), d3d9_device_GetRenderTargetData(), d3d9_device_StretchRect(), d3d9_device_UpdateSurface(), d3d9_surface_GetDesc(), d3d9_texture_2d_GetLevelDesc(), d3d9_texture_3d_GetLevelDesc(), d3d9_texture_acquire_shader_resource_view(), d3d9_texture_cube_GetLevelDesc(), d3d9_volume_GetDesc(), ddraw_surface7_Restore(), and ddraw_surface_create().

◆ wined3d_texture_get_sub_resource_parent()

◆ wined3d_texture_incref()

ULONG __cdecl wined3d_texture_incref ( struct wined3d_texture texture)

Definition at line 994 of file texture.c.

995{
996 ULONG refcount;
997
998 TRACE("texture %p, swapchain %p.\n", texture, texture->swapchain);
999
1000 if (texture->swapchain)
1001 return wined3d_swapchain_incref(texture->swapchain);
1002
1003 refcount = InterlockedIncrement(&texture->resource.ref);
1004 TRACE("%p increasing refcount to %u.\n", texture, refcount);
1005
1006 return refcount;
1007}
ULONG CDECL wined3d_swapchain_incref(struct wined3d_swapchain *swapchain)
Definition: swapchain.c:104

Referenced by d3d8_surface_AddRef(), d3d8_texture_2d_AddRef(), d3d8_texture_3d_AddRef(), d3d8_texture_cube_AddRef(), d3d9_surface_AddRef(), d3d9_texture_2d_AddRef(), d3d9_texture_3d_AddRef(), d3d9_texture_cube_AddRef(), ddraw_surface_add_iface(), ddraw_surface_init(), texture_resource_incref(), wined3d_device_set_texture(), and wined3d_stateblock_capture().

◆ wined3d_texture_release_dc()

HRESULT __cdecl wined3d_texture_release_dc ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
HDC  dc 
)

Definition at line 3671 of file texture.c.

3672{
3673 struct wined3d_device *device = texture->resource.device;
3674 struct wined3d_texture_sub_resource *sub_resource;
3675 struct wined3d_surface *surface;
3676
3677 TRACE("texture %p, sub_resource_idx %u, dc %p.\n", texture, sub_resource_idx, dc);
3678
3679 if (!(sub_resource = wined3d_texture_get_sub_resource(texture, sub_resource_idx)))
3681
3682 if (texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
3683 {
3684 WARN("Not supported on %s resources.\n", debug_d3dresourcetype(texture->resource.type));
3686 }
3687
3688 surface = sub_resource->u.surface;
3689
3692
3693 if (surface->dc != dc)
3694 {
3695 WARN("Application tries to release invalid DC %p, surface DC is %p.\n", dc, surface->dc);
3697 }
3698
3699 if (!(texture->resource.usage & WINED3DUSAGE_OWNDC) && !(device->wined3d->flags & WINED3D_NO3D))
3700 {
3702 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
3703 }
3704
3705 --sub_resource->map_count;
3706 if (!--texture->resource.map_count && texture->update_map_binding)
3709 texture->flags &= ~WINED3D_TEXTURE_DC_IN_USE;
3710
3711 return WINED3D_OK;
3712}
static void texture2d_destroy_dc(void *object)
Definition: texture.c:1316
static void wined3d_texture_update_map_binding(struct wined3d_texture *texture)
Definition: texture.c:437
#define WINED3DUSAGE_OWNDC
Definition: wined3d.h:919

Referenced by d3d9_surface_ReleaseDC(), ddraw_surface7_ReleaseDC(), ddraw_surface_update_frontbuffer(), and device_load_logo().

◆ wined3d_texture_set_color_key()

HRESULT __cdecl wined3d_texture_set_color_key ( struct wined3d_texture texture,
DWORD  flags,
const struct wined3d_color_key color_key 
)

Definition at line 1235 of file texture.c.

1237{
1238 struct wined3d_device *device = texture->resource.device;
1239 static const DWORD all_flags = WINED3D_CKEY_DST_BLT | WINED3D_CKEY_DST_OVERLAY
1241
1242 TRACE("texture %p, flags %#x, color_key %p.\n", texture, flags, color_key);
1243
1244 if (flags & ~all_flags)
1245 {
1246 WARN("Invalid flags passed, returning WINED3DERR_INVALIDCALL.\n");
1248 }
1249
1251
1252 return WINED3D_OK;
1253}
void wined3d_cs_emit_set_color_key(struct wined3d_cs *cs, struct wined3d_texture *texture, WORD flags, const struct wined3d_color_key *color_key)
Definition: cs.c:1657
#define WINED3D_CKEY_DST_BLT
Definition: wined3d.h:1334
#define WINED3D_CKEY_SRC_OVERLAY
Definition: wined3d.h:1337
#define WINED3D_CKEY_SRC_BLT
Definition: wined3d.h:1336
#define WINED3D_CKEY_DST_OVERLAY
Definition: wined3d.h:1335

Referenced by ddraw_surface_create(), ddraw_surface_set_color_key(), device_load_logo(), and ffp_blitter_blit().

◆ wined3d_texture_set_lod()

DWORD __cdecl wined3d_texture_set_lod ( struct wined3d_texture texture,
DWORD  lod 
)

Definition at line 1186 of file texture.c.

1187{
1188 DWORD old = texture->lod;
1189
1190 TRACE("texture %p, lod %u.\n", texture, lod);
1191
1192 /* The d3d9:texture test shows that SetLOD is ignored on non-managed
1193 * textures. The call always returns 0, and GetLOD always returns 0. */
1194 if (!wined3d_resource_access_is_managed(texture->resource.access))
1195 {
1196 TRACE("Ignoring LOD on texture with resource access %s.\n",
1197 wined3d_debug_resource_access(texture->resource.access));
1198 return 0;
1199 }
1200
1201 if (lod >= texture->level_count)
1202 lod = texture->level_count - 1;
1203
1204 if (texture->lod != lod)
1205 {
1206 struct wined3d_device *device = texture->resource.device;
1207
1209 texture->lod = lod;
1210
1211 texture->texture_rgb.base_level = ~0u;
1212 texture->texture_srgb.base_level = ~0u;
1213 if (texture->resource.bind_count)
1215 device->state.sampler_states[texture->sampler][WINED3D_SAMP_MAX_MIP_LEVEL]);
1216 }
1217
1218 return old;
1219}
const char * wined3d_debug_resource_access(DWORD access)
Definition: utils.c:4200
GLint lod
Definition: glext.h:7795

Referenced by d3d8_texture_2d_SetLOD(), d3d8_texture_3d_SetLOD(), d3d8_texture_cube_SetLOD(), d3d9_texture_2d_SetLOD(), d3d9_texture_3d_SetLOD(), d3d9_texture_cube_SetLOD(), and ddraw_surface7_SetLOD().

◆ wined3d_texture_set_overlay_position()

HRESULT __cdecl wined3d_texture_set_overlay_position ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
LONG  x,
LONG  y 
)

Definition at line 3356 of file texture.c.

3358{
3359 struct wined3d_overlay_info *overlay;
3360 LONG w, h;
3361
3362 TRACE("texture %p, sub_resource_idx %u, x %d, y %d.\n", texture, sub_resource_idx, x, y);
3363
3364 if (!(texture->resource.usage & WINED3DUSAGE_OVERLAY)
3365 || sub_resource_idx >= texture->level_count * texture->layer_count)
3366 {
3367 WARN("Invalid sub-resource specified.\n");
3369 }
3370
3371 overlay = &texture->overlay_info[sub_resource_idx];
3372 w = overlay->dst_rect.right - overlay->dst_rect.left;
3373 h = overlay->dst_rect.bottom - overlay->dst_rect.top;
3374 SetRect(&overlay->dst_rect, x, y, x + w, y + h);
3375
3376 return WINED3D_OK;
3377}

Referenced by ddraw_surface7_SetOverlayPosition().

◆ wined3d_texture_set_sub_resource_parent()

void __cdecl wined3d_texture_set_sub_resource_parent ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
void parent 
)

Definition at line 3464 of file texture.c.

3466{
3467 unsigned int sub_count = texture->level_count * texture->layer_count;
3468
3469 TRACE("texture %p, sub_resource_idx %u, parent %p.\n", texture, sub_resource_idx, parent);
3470
3471 if (sub_resource_idx >= sub_count)
3472 {
3473 WARN("sub_resource_idx %u >= sub_count %u.\n", sub_resource_idx, sub_count);
3474 return;
3475 }
3476
3477 texture->sub_resources[sub_resource_idx].parent = parent;
3478}

Referenced by ddraw_surface7_Flip().

◆ wined3d_texture_update_desc()

HRESULT __cdecl wined3d_texture_update_desc ( struct wined3d_texture texture,
UINT  width,
UINT  height,
enum wined3d_format_id  format_id,
enum wined3d_multisample_type  multisample_type,
UINT  multisample_quality,
void mem,
UINT  pitch 
)

Definition at line 1356 of file texture.c.

1359{
1360 struct wined3d_device *device = texture->resource.device;
1361 const struct wined3d_gl_info *gl_info = &device->adapter->gl_info;
1362 const struct wined3d_format *format = wined3d_get_format(gl_info, format_id, texture->resource.usage);
1363 UINT resource_size = wined3d_format_calculate_size(format, device->surface_alignment, width, height, 1);
1364 struct wined3d_texture_sub_resource *sub_resource;
1365 struct wined3d_surface *surface;
1366 DWORD valid_location = 0;
1368
1369 TRACE("texture %p, width %u, height %u, format %s, multisample_type %#x, multisample_quality %u, "
1370 "mem %p, pitch %u.\n",
1371 texture, width, height, debug_d3dformat(format_id), multisample_type, multisample_quality, mem, pitch);
1372
1373 if (!resource_size)
1375
1376 if (texture->level_count * texture->layer_count > 1)
1377 {
1378 WARN("Texture has multiple sub-resources, not supported.\n");
1380 }
1381
1382 if (texture->resource.type != WINED3D_RTYPE_TEXTURE_2D)
1383 {
1384 WARN("Not supported on %s.\n", debug_d3dresourcetype(texture->resource.type));
1386 }
1387
1388 if (texture->resource.type == WINED3D_RTYPE_TEXTURE_1D)
1389 {
1390 FIXME("Not yet supported for 1D textures.\n");
1392 }
1393
1394 if (texture->resource.map_count)
1395 {
1396 WARN("Texture is mapped.\n");
1398 }
1399
1400 /* We have no way of supporting a pitch that is not a multiple of the pixel
1401 * byte width short of uploading the texture row-by-row.
1402 * Fortunately that's not an issue since D3D9Ex doesn't allow a custom pitch
1403 * for user-memory textures (it always expects packed data) while DirectDraw
1404 * requires a 4-byte aligned pitch and doesn't support texture formats
1405 * larger than 4 bytes per pixel nor any format using 3 bytes per pixel.
1406 * This check is here to verify that the assumption holds. */
1407 if (pitch % texture->resource.format->byte_count)
1408 {
1409 WARN("Pitch unsupported, not a multiple of the texture format byte width.\n");
1411 }
1412
1413 if (device->d3d_initialized)
1416
1417 sub_resource = &texture->sub_resources[0];
1418 surface = sub_resource->u.surface;
1419 if (surface->dc)
1420 {
1422 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
1423 create_dib = TRUE;
1424 }
1425
1427
1428 if ((texture->row_pitch = pitch))
1429 texture->slice_pitch = height * pitch;
1430 else
1431 /* User memory surfaces don't have the regular surface alignment. */
1433 &texture->row_pitch, &texture->slice_pitch);
1434
1435 texture->resource.format = format;
1436 texture->resource.multisample_type = multisample_type;
1437 texture->resource.multisample_quality = multisample_quality;
1438 texture->resource.width = width;
1439 texture->resource.height = height;
1440 texture->resource.size = texture->slice_pitch;
1441 sub_resource->size = texture->slice_pitch;
1442 sub_resource->locations = WINED3D_LOCATION_DISCARDED;
1443
1444 if (multisample_type && gl_info->supported[ARB_TEXTURE_MULTISAMPLE])
1446 else
1447 texture->target = GL_TEXTURE_2D;
1448
1451 {
1453 texture->pow2_width = texture->pow2_height = 1;
1454 while (texture->pow2_width < width)
1455 texture->pow2_width <<= 1;
1456 while (texture->pow2_height < height)
1457 texture->pow2_height <<= 1;
1458 }
1459 else
1460 {
1461 texture->flags &= ~WINED3D_TEXTURE_COND_NP2_EMULATED;
1462 texture->pow2_width = width;
1463 texture->pow2_height = height;
1464 }
1465
1466 if ((texture->user_memory = mem))
1467 {
1468 texture->resource.map_binding = WINED3D_LOCATION_USER_MEMORY;
1469 valid_location = WINED3D_LOCATION_USER_MEMORY;
1470 }
1471 else
1472 {
1474 valid_location = WINED3D_LOCATION_SYSMEM;
1475 }
1476
1477 /* The format might be changed to a format that needs conversion.
1478 * If the surface didn't use PBOs previously but could now, don't
1479 * change it - whatever made us not use PBOs might come back, e.g.
1480 * color keys. */
1481 if (texture->resource.map_binding == WINED3D_LOCATION_BUFFER && !wined3d_texture_use_pbo(texture, gl_info))
1482 texture->resource.map_binding = WINED3D_LOCATION_SYSMEM;
1483
1484 wined3d_texture_validate_location(texture, 0, valid_location);
1485 wined3d_texture_invalidate_location(texture, 0, ~valid_location);
1486
1487 if (create_dib)
1488 {
1490 device->cs->ops->finish(device->cs, WINED3D_CS_QUEUE_DEFAULT);
1491 }
1492
1493 return WINED3D_OK;
1494}
void wined3d_resource_free_sysmem(struct wined3d_resource *resource)
Definition: resource.c:504
void wined3d_texture_invalidate_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, DWORD location)
Definition: texture.c:159
BOOL wined3d_texture_prepare_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, struct wined3d_context *context, DWORD location)
Definition: texture.c:1605
static BOOL is_power_of_two(UINT x)
Definition: texture.c:104
static BOOL wined3d_texture_use_pbo(const struct wined3d_texture *texture, const struct wined3d_gl_info *gl_info)
Definition: texture.c:33
void wined3d_texture_validate_location(struct wined3d_texture *texture, unsigned int sub_resource_idx, DWORD location)
Definition: texture.c:135
UINT wined3d_format_calculate_size(const struct wined3d_format *format, UINT alignment, UINT width, UINT height, UINT depth)
Definition: utils.c:3906
#define GL_TEXTURE_2D
Definition: gl.h:645
#define GL_TEXTURE_2D_MULTISAMPLE
Definition: glext.h:1939
static void create_dib(STGMEDIUM *med)
Definition: ole2.c:211
Definition: mem.c:156
@ ARB_TEXTURE_MULTISAMPLE
Definition: wined3d_gl.h:122
#define WINED3D_LOCATION_SYSMEM
#define WINED3D_LOCATION_BUFFER
#define WINED3D_TEXTURE_COND_NP2_EMULATED
#define WINED3D_LOCATION_USER_MEMORY
#define WINED3D_LOCATION_DISCARDED

Referenced by d3d9_device_create_surface(), d3d9_device_CreateTexture(), ddraw_surface7_SetSurfaceDesc(), ddraw_surface_create(), and wined3d_swapchain_resize_buffers().

◆ wined3d_texture_update_overlay()

HRESULT __cdecl wined3d_texture_update_overlay ( struct wined3d_texture texture,
unsigned int  sub_resource_idx,
const RECT src_rect,
struct wined3d_texture dst_texture,
unsigned int  dst_sub_resource_idx,
const RECT dst_rect,
DWORD  flags 
)

Definition at line 3379 of file texture.c.

3382{
3383 struct wined3d_texture_sub_resource *sub_resource, *dst_sub_resource;
3384 struct wined3d_surface *surface, *dst_surface;
3385 struct wined3d_overlay_info *overlay;
3386
3387 TRACE("texture %p, sub_resource_idx %u, src_rect %s, dst_texture %p, "
3388 "dst_sub_resource_idx %u, dst_rect %s, flags %#x.\n",
3389 texture, sub_resource_idx, wine_dbgstr_rect(src_rect), dst_texture,
3390 dst_sub_resource_idx, wine_dbgstr_rect(dst_rect), flags);
3391
3392 if (!(texture->resource.usage & WINED3DUSAGE_OVERLAY) || texture->resource.type != WINED3D_RTYPE_TEXTURE_2D
3393 || !(sub_resource = wined3d_texture_get_sub_resource(texture, sub_resource_idx)))
3394 {
3395 WARN("Invalid sub-resource specified.\n");
3397 }
3398
3399 if (!dst_texture || dst_texture->resource.type != WINED3D_RTYPE_TEXTURE_2D
3400 || !(dst_sub_resource = wined3d_texture_get_sub_resource(dst_texture, dst_sub_resource_idx)))
3401 {
3402 WARN("Invalid destination sub-resource specified.\n");
3404 }
3405
3406 overlay = &texture->overlay_info[sub_resource_idx];
3407
3408 surface = sub_resource->u.surface;
3409 if (src_rect)
3410 overlay->src_rect = *src_rect;
3411 else
3412 SetRect(&overlay->src_rect, 0, 0,
3415
3416 dst_surface = dst_sub_resource->u.surface;
3417 if (dst_rect)
3418 overlay->dst_rect = *dst_rect;
3419 else
3420 SetRect(&overlay->dst_rect, 0, 0,
3421 wined3d_texture_get_level_width(dst_texture, dst_surface->texture_level),
3422 wined3d_texture_get_level_height(dst_texture, dst_surface->texture_level));
3423
3424 if (overlay->dst && (overlay->dst != dst_surface || flags & WINEDDOVER_HIDE))
3425 {
3426 overlay->dst = NULL;
3427 list_remove(&overlay->entry);
3428 }
3429
3430 if (flags & WINEDDOVER_SHOW)
3431 {
3432 if (overlay->dst != dst_surface)
3433 {
3434 overlay->dst = dst_surface;
3435 list_add_tail(&texture->overlay_info[dst_sub_resource_idx].overlays, &overlay->entry);
3436 }
3437 }
3438 else if (flags & WINEDDOVER_HIDE)
3439 {
3440 /* Tests show that the rectangles are erased on hide. */
3441 SetRectEmpty(&overlay->src_rect);
3442 SetRectEmpty(&overlay->dst_rect);
3443 overlay->dst = NULL;
3444 }
3445
3446 return WINED3D_OK;
3447}
unsigned int texture_level
#define WINEDDOVER_HIDE
Definition: wined3d.h:1399
#define WINEDDOVER_SHOW
Definition: wined3d.h:1404
BOOL WINAPI SetRectEmpty(_Out_ LPRECT)

Referenced by ddraw_surface7_UpdateOverlay().

◆ wined3d_unordered_access_view_create()

HRESULT __cdecl wined3d_unordered_access_view_create ( const struct wined3d_view_desc desc,
struct wined3d_resource resource,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_unordered_access_view **  view 
)

Definition at line 1156 of file view.c.

1159{
1161 HRESULT hr;
1162
1163 TRACE("desc %p, resource %p, parent %p, parent_ops %p, view %p.\n",
1165
1166 if (!(object = heap_alloc_zero(sizeof(*object))))
1167 return E_OUTOFMEMORY;
1168
1170 {
1171 heap_free(object);
1172 WARN("Failed to initialise view, hr %#x.\n", hr);
1173 return hr;
1174 }
1175
1176 TRACE("Created unordered access view %p.\n", object);
1177 *view = object;
1178
1179 return WINED3D_OK;
1180}
static HRESULT wined3d_unordered_access_view_init(struct wined3d_unordered_access_view *view, const struct wined3d_view_desc *desc, struct wined3d_resource *resource, void *parent, const struct wined3d_parent_ops *parent_ops)
Definition: view.c:1134
const struct wined3d_parent_ops * parent_ops

◆ wined3d_unordered_access_view_decref()

ULONG __cdecl wined3d_unordered_access_view_decref ( struct wined3d_unordered_access_view view)

Definition at line 970 of file view.c.

971{
972 ULONG refcount = InterlockedDecrement(&view->refcount);
973
974 TRACE("%p decreasing refcount to %u.\n", view, refcount);
975
976 if (!refcount)
977 {
978 struct wined3d_resource *resource = view->resource;
979 struct wined3d_device *device = resource->device;
980
981 /* Call wined3d_object_destroyed() before releasing the resource,
982 * since releasing the resource may end up destroying the parent. */
983 view->parent_ops->wined3d_object_destroyed(view->parent);
986 }
987
988 return refcount;
989}
static void wined3d_unordered_access_view_destroy_object(void *object)
Definition: view.c:948

Referenced by state_unbind_resources(), and wined3d_device_set_pipeline_unordered_access_view().

◆ wined3d_unordered_access_view_get_parent()

void *__cdecl wined3d_unordered_access_view_get_parent ( const struct wined3d_unordered_access_view view)

Definition at line 991 of file view.c.

992{
993 TRACE("view %p.\n", view);
994
995 return view->parent;
996}

◆ wined3d_unordered_access_view_incref()

ULONG __cdecl wined3d_unordered_access_view_incref ( struct wined3d_unordered_access_view view)

Definition at line 939 of file view.c.

940{
941 ULONG refcount = InterlockedIncrement(&view->refcount);
942
943 TRACE("%p increasing refcount to %u.\n", view, refcount);
944
945 return refcount;
946}

Referenced by wined3d_device_set_pipeline_unordered_access_view().

◆ wined3d_vertex_declaration_create()

HRESULT __cdecl wined3d_vertex_declaration_create ( struct wined3d_device device,
const struct wined3d_vertex_element elements,
UINT  element_count,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_vertex_declaration **  declaration 
)

Definition at line 272 of file vertexdeclaration.c.

275{
277 HRESULT hr;
278
279 TRACE("device %p, elements %p, element_count %u, parent %p, parent_ops %p, declaration %p.\n",
281
282 if (!(object = heap_alloc_zero(sizeof(*object))))
283 return E_OUTOFMEMORY;
284
286 if (FAILED(hr))
287 {
288 WARN("Failed to initialize vertex declaration, hr %#x.\n", hr);
289 heap_free(object);
290 return hr;
291 }
292
293 TRACE("Created vertex declaration %p.\n", object);
295
296 return WINED3D_OK;
297}
struct wined3d_vertex_declaration_element * elements
const struct wined3d_parent_ops * parent_ops
static HRESULT vertexdeclaration_init(struct wined3d_vertex_declaration *declaration, struct wined3d_device *device, const struct wined3d_vertex_element *elements, UINT element_count, void *parent, const struct wined3d_parent_ops *parent_ops)

Referenced by d3d8_vertex_declaration_init(), vertexdeclaration_init(), and wined3d_vertex_declaration_create_from_fvf().

◆ wined3d_vertex_declaration_create_from_fvf()

HRESULT __cdecl wined3d_vertex_declaration_create_from_fvf ( struct wined3d_device device,
DWORD  fvf,
void parent,
const struct wined3d_parent_ops parent_ops,
struct wined3d_vertex_declaration **  declaration 
)

Definition at line 441 of file vertexdeclaration.c.

444{
445 struct wined3d_vertex_element *elements;
446 unsigned int size;
447 DWORD hr;
448
449 TRACE("device %p, fvf %#x, parent %p, parent_ops %p, declaration %p.\n",
450 device, fvf, parent, parent_ops, declaration);
451
452 size = convert_fvf_to_declaration(&device->adapter->gl_info, fvf, &elements);
453 if (size == ~0U) return E_OUTOFMEMORY;
454
456 heap_free(elements);
457 return hr;
458}
GLsizeiptr size
Definition: glext.h:5919
HRESULT CDECL wined3d_vertex_declaration_create(struct wined3d_device *device, const struct wined3d_vertex_element *elements, UINT element_count, void *parent, const struct wined3d_parent_ops *parent_ops, struct wined3d_vertex_declaration **declaration)
static unsigned int convert_fvf_to_declaration(const struct wined3d_gl_info *gl_info, DWORD fvf, struct wined3d_vertex_element **elements)

Referenced by d3d8_vertex_declaration_init_fvf(), and ddraw_find_decl().

◆ wined3d_vertex_declaration_decref()

ULONG __cdecl wined3d_vertex_declaration_decref ( struct wined3d_vertex_declaration declaration)

Definition at line 61 of file vertexdeclaration.c.

62{
63 ULONG refcount = InterlockedDecrement(&declaration->ref);
64
65 TRACE("%p decreasing refcount to %u.\n", declaration, refcount);
66
67 if (!refcount)
68 {
69 declaration->parent_ops->wined3d_object_destroyed(declaration->parent);
72 }
73
74 return refcount;
75}
static void wined3d_vertex_declaration_destroy_object(void *object)

Referenced by d3d8_vertex_declaration_destroy(), d3d9_device_Release(), d3d9_vertex_declaration_Release(), d3d_vertex_buffer7_Release(), ddraw_destroy_swapchain(), ddraw_find_decl(), state_unbind_resources(), wined3d_device_set_vertex_declaration(), and wined3d_stateblock_capture().

◆ wined3d_vertex_declaration_get_parent()

void *__cdecl wined3d_vertex_declaration_get_parent ( const struct wined3d_vertex_declaration declaration)

Definition at line 77 of file vertexdeclaration.c.

78{
79 TRACE("declaration %p.\n", declaration);
80
81 return declaration->parent;
82}

Referenced by d3d8_device_GetVertexShader(), d3d9_device_GetFVF(), and d3d9_device_GetVertexDeclaration().

◆ wined3d_vertex_declaration_incref()

ULONG __cdecl wined3d_vertex_declaration_incref ( struct wined3d_vertex_declaration declaration)

Definition at line 44 of file vertexdeclaration.c.

45{
46 ULONG refcount = InterlockedIncrement(&declaration->ref);
47
48 TRACE("%p increasing refcount to %u.\n", declaration, refcount);
49
50 return refcount;
51}

Referenced by d3d9_vertex_declaration_AddRef(), d3d_vertex_buffer_create(), device_get_fvf_declaration(), wined3d_device_set_vertex_declaration(), and wined3d_stateblock_capture().