floooh / sokol

minimal cross-platform standalone C headers
https://floooh.github.io/sokol-html5
zlib License
6.55k stars 469 forks source link

D3D11 backend: allow injected textures to not have a shader-resource-view. #930

Closed floooh closed 8 months ago

floooh commented 8 months ago

Some injected texture types are incompatible with shader-resource-views. Currently when no injected SRV is provided, _sg_d3d11_create_image() will create one anyway (as a sort of convenience service).

Instead, if no injected SRV is provided, no attempt should be made to create one.

Long term it may make sense to introduce sg_image_view objects (would especially make sense if baked sg_pass objects are ditched, see: https://github.com/floooh/sokol/issues/904)