Skip to content

Commit

Permalink
Merge pull request #932 from floooh/feature/issue-931
Browse files Browse the repository at this point in the history
sokol_gfx.h: expose backend-specific resources and resource injection tweaks
  • Loading branch information
floooh committed Oct 30, 2023
2 parents 9e0f1b4 + fbcb001 commit bd7fa93
Show file tree
Hide file tree
Showing 2 changed files with 694 additions and 111 deletions.
26 changes: 26 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,31 @@
## Updates

#### 30-Oct-2023

Some sokol_gfx.h backend-specific updates and tweaks (very minor chance that this is breaking if you are injecting textures into the D3D11 backend).

- a new set of public API functions to access the native backend 3D-API resource objects of
sokol-gfx resource objects:

```
sg_[api]_[type]_info sg_[api]_query_[type]_info(sg_[type])
```
...where `[api]` is any of `[gl, d3d11, mtl, wgpu]` and `[type]` is any of `[buffer, image, sampler, shader, pipeline, pass]`.

This is mainly useful when mixing native 3D-API code with sokol-gfx code.

See issue https://github.com/floooh/sokol/issues/931 for details.

- WebGPU backend: `sg_make_image()` will no longer automatically create a WebGPU texture-view object when injecting a WebGPU texture object, instead
this must now be explicitly provided.

- D3D11 backend: `sg_make_image()` will no longer automatically create a
shader-resource-view object when injecting a D3D11 texture object, and
vice versa, a texture object will no longer be looked up from an injected
shader-resource-view object (e.g. the injection rules are now more straightforward and explicit). See issue https://github.com/floooh/sokol/issues/930 for details.

For the detailed changes, see PR https://github.com/floooh/sokol/pull/932.

#### 27-Oct-2023

Fix broken render-to-mipmap in the sokol_gfx.h GL backend.
Expand Down
Loading

0 comments on commit bd7fa93

Please sign in to comment.