Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

sokol_gfx.h: expose backend-specific resources and resource injection tweaks #932

Merged
merged 13 commits into from
Oct 30, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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