mirror of
https://github.com/libsdl-org/SDL.git
synced 2025-05-31 08:57:40 +00:00
gpu: Warn about Direct3D 12 texture alignment requirements.
Fixes #12835.
This commit is contained in:
parent
2e45198299
commit
faa2e40406
2 changed files with 16 additions and 1 deletions
|
@ -1347,6 +1347,12 @@ typedef struct SDL_GPUViewport
|
|||
* SDL_DownloadFromGPUTexture are used as default values respectively and data
|
||||
* is considered to be tightly packed.
|
||||
*
|
||||
* **WARNING**: Direct3D 12 requires texture data row pitch to be 256 byte
|
||||
* aligned, and offsets to be aligned to 512 bytes. If they are not, SDL will
|
||||
* make a temporary copy of the data that is properly aligned, but this adds
|
||||
* overhead to the transfer process. Apps can avoid this by aligning their
|
||||
* data appropriately, or using a different GPU backend than Direct3D 12.
|
||||
*
|
||||
* \since This struct is available since SDL 3.2.0.
|
||||
*
|
||||
* \sa SDL_UploadToGPUTexture
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue