Comprobando la compatibilidad con las características de hardware
En esta sección se explica cómo comprobar la compatibilidad con formato para hardware de nivel de características de Direct3D mediante llamadas API.
Para D3D11, use ID3D11Device::CheckFormatSupport para comprobar mediante programación la información de las secciones anteriores. Para D3D12, use ID3D12::CheckFeatureSupport.
Formato de destino | D3D12 | D3D11 |
---|---|---|
Buffer | D3D12_FORMAT_SUPPORT1_BUFFER (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_BUFFER (D3D11_FORMAT_SUPPORT) |
Búfer de vértices del ensamblador de entrada | D3D12_FORMAT_SUPPORT1_IA_VERTEX_BUFFER (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_IA_VERTEX_BUFFER (D3D11_FORMAT_SUPPORT) |
Búfer de índice del ensamblador de entrada | D3D12_FORMAT_SUPPORT1_IA_INDEX_BUFFER (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_IA_INDEX_BUFFER (D3D11_FORMAT_SUPPORT) |
Búfer de salida de flujo | D3D12_FORMAT_SUPPORT1_SO_BUFFER (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SO_BUFFER (D3D11_FORMAT_SUPPORT) |
Texture1D | D3D12_FORMAT_SUPPORT1_TEXTURE1D (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_TEXTURE1D (D3D11_FORMAT_SUPPORT) |
Texture2D | D3D12_FORMAT_SUPPORT1_TEXTURE2D (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_TEXTURE2D (D3D11_FORMAT_SUPPORT) |
Texture3D | D3D12_FORMAT_SUPPORT1_TEXTURE3D (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_TEXTURE3D (D3D11_FORMAT_SUPPORT) |
TextureCube | D3D12_FORMAT_SUPPORT1_TEXTURECUBE (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_TEXTURECUBE (D3D11_FORMAT_SUPPORT) |
Sombreador ld | D3D12_FORMAT_SUPPORT1_SHADER_LOAD (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_LOAD (D3D11_FORMAT_SUPPORT) |
Ejemplo de sombreador (cualquier filtro) | D3D12_FORMAT_SUPPORT1_SHADER_SAMPLE (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_SAMPLE (D3D11_FORMAT_SUPPORT) |
Sample_c del sombreador (filtro de comparación) | D3D12_FORMAT_SUPPORT1_SHADER_SAMPLE_COMPARISON (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_SAMPLE_COMPARISON (D3D11_FORMAT_SUPPORT) |
Ejemplo de sombreador (mono 1_bit_filter) | D3D12_FORMAT_SUPPORT1_SHADER_SAMPLE_MONO_TEXT (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_SAMPLE_MONO_TEXT (D3D11_FORMAT_SUPPORT) |
Shader gather4 | D3D12_FORMAT_SUPPORT1_SHADER_GATHER (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_GATHER (D3D11_FORMAT_SUPPORT) |
Gather4_c del sombreador | D3D12_FORMAT_SUPPORT1_SHADER_GATHER_COMPARISON (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_SHADER_GATHER_COMPARISON (D3D11_FORMAT_SUPPORT) |
Mapa mip | D3D12_FORMAT_SUPPORT1_MIP (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MIP (D3D11_FORMAT_SUPPORT) |
Generación automática de mapas Mip |
Nota: D3D12 ya no tiene una funcionalidad dedicada de generación de mapas MIP. Las aplicaciones deben implementarla por su cuenta mediante sombreadores. |
D3D11_FORMAT_SUPPORT_MIP_AUTOGEN (D3D11_FORMAT_SUPPORT) |
RenderTarget | D3D12_FORMAT_SUPPORT1_RENDER_TARGET (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_RENDER_TARGET (D3D11_FORMAT_SUPPORT) |
Blendable RenderTarget | D3D12_FORMAT_SUPPORT1_BLENDABLE (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_BLENDABLE (D3D11_FORMAT_SUPPORT) |
Operación lógica de fusión de salida | D3D12_FORMAT_SUPPORT2_OUTPUT_MERGER_LOGIC_OP | D3D11_FORMAT_SUPPORT2_OUTPUT_MERGER_LOGIC_OP (D3D11_FORMAT_SUPPORT2) |
Destino de profundidad/galería de símbolos | D3D12_FORMAT_SUPPORT1_DEPTH_STENCIL (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_DEPTH_STENCIL (D3D11_FORMAT_SUPPORT) |
UAV sin formato y SRV | ||
UAV estructurado y SRV | ||
UAV con tipo | D3D12_FORMAT_SUPPORT1_TYPED_UNORDERED_ACCESS_VIEW (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_TYPED_UNORDERED_ACCESS_VIEW (D3D11_FORMAT_SUPPORT) |
Almacén con tipo UAV | D3D12_FORMAT_SUPPORT2_UAV_TYPED_STORE (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_TYPED_STORE (D3D11_FORMAT_SUPPORT2) |
Carga con tipo UAV | D3D12_FORMAT_SUPPORT2_UAV_TYPED_LOAD (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_TYPED_LOAD (D3D11_FORMAT_SUPPORT2) |
Adición atómica de UAV | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_ADD (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_ADD (D3D11_FORMAT_SUPPORT2) |
UAV Atomic Bitwise Ops | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_BITWISE_OPS (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_BITWISE_OPS (D3D11_FORMAT_SUPPORT2) |
UAV Atomic Cmp&Store/ Cmp&Exch | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_COMPARE_STORE_OR_COMPARE_EXCHANGE (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_COMPARE_STORE_OR_COMPARE_EXCHANGE (D3D11_FORMAT_SUPPORT2) |
Intercambio atómico UAV | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_EXCHANGE (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_EXCHANGE (D3D11_FORMAT_SUPPORT2) |
UAV Atomic Signed Min/Max | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_SIGNED_MIN_OR_MAX (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_SIGNED_MIN_OR_MAX (D3D11_FORMAT_SUPPORT2) |
UAV Atomic Unsigned Min/Max | D3D12_FORMAT_SUPPORT2_UAV_ATOMIC_UNSIGNED_MIN_OR_MAX (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_UAV_ATOMIC_UNSIGNED_MIN_OR_MAX (D3D11_FORMAT_SUPPORT2) |
CPU bloqueable |
Nota: Solo un formato impide el acceso a la CPU (420_OPAQUE). |
D3D11_FORMAT_SUPPORT_CPU_LOCKABLE (D3D11_FORMAT_SUPPORT) |
4x RenderTarget multisample | D3D12_FORMAT_SUPPORT1_MULTISAMPLE_RENDERTARGET (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MULTISAMPLE_RENDERTARGET (D3D11_FORMAT_SUPPORT) |
8x RenderTarget multisample | D3D12_FORMAT_SUPPORT1_MULTISAMPLE_RENDERTARGET (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MULTISAMPLE_RENDERTARGET (D3D11_FORMAT_SUPPORT) |
Otros recuentos de varios ejemplos RT | D3D12_FORMAT_SUPPORT1_MULTISAMPLE_RENDERTARGET (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MULTISAMPLE_RENDERTARGET (D3D11_FORMAT_SUPPORT) |
Resolución de varias muestras | D3D12_FORMAT_SUPPORT1_MULTISAMPLE_RESOLVE (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MULTISAMPLE_RESOLVE (D3D11_FORMAT_SUPPORT) |
Carga multisample | D3D12_FORMAT_SUPPORT1_MULTISAMPLE_LOAD (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_MULTISAMPLE_LOAD (D3D11_FORMAT_SUPPORT) |
Mostrar Scan-Out | D3D12_FORMAT_SUPPORT1_DISPLAY (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_DISPLAY (D3D11_FORMAT_SUPPORT) |
Conversión dentro del diseño de bits | D3D12_FORMAT_SUPPORT1_CAST_WITHIN_BIT_LAYOUT (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_CAST_WITHIN_BIT_LAYOUT (D3D11_FORMAT_SUPPORT) |
Compatibilidad con descodificador de vídeo | D3D12_FORMAT_SUPPORT1_DECODER_OUTPUT (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_DECODER_OUTPUT (D3D11_FORMAT_SUPPORT) |
Entrada del procesador de vídeo | D3D12_FORMAT_SUPPORT1_VIDEO_PROCESSOR_INPUT (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_VIDEO_PROCESSOR_INPUT (D3D11_FORMAT_SUPPORT) |
Salida del procesador de vídeo | D3D12_FORMAT_SUPPORT1_VIDEO_PROCESSOR_OUTPUT (D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_VIDEO_PROCESSOR_OUTPUT (D3D11_FORMAT_SUPPORT) |
Recurso compartido |
Nota: Las texturas de todos los formatos pueden compartirse recursos confirmados o colocarse en montones compartidos. |
D3D11_FORMAT_SUPPORT2_SHAREABLE (D3D11_FORMAT_SUPPORT2) |
BackBuffer castable incluso con tipo completo | D3D12_FORMAT_SUPPORT1_BACK_BUFFER_CAST (D3D12_FORMAT_SUPPORT1) |
Nota: Ninguna API disponible. |
Recurso en mosaico | D3D12_FORMAT_SUPPORT2_TILED (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_TILED (D3D11_FORMAT_SUPPORT2) |
Codificador de vídeo | D3D12_FORMAT_SUPPORT1_VIDEO_ENCODER(D3D12_FORMAT_SUPPORT1) | D3D11_FORMAT_SUPPORT_VIDEO_ENCODER (D3D11_FORMAT_SUPPORT) |
Superposición multiplano | D3D12_FORMAT_SUPPORT2_MULTIPLANE_OVERLAY (D3D12_FORMAT_SUPPORT2) | D3D11_FORMAT_SUPPORT2_MULTIPLANE_OVERLAY (D3D11_FORMAT_SUPPORT2) |