Commit Graph

524 Commits

Author SHA1 Message Date
Бранимир Караџић
959cab248e Added ability to configure backbuffer depth/stencil. 2025-10-29 12:10:41 -07:00
Бранимир Караџић
cd3749dac9 Cleanup. 2025-10-25 22:18:15 -07:00
Gary Hsu
e7c2c69edb Add optional layerIndex argument to overrideInternal (#3477)
* Add optional layerIndex argument to overrideInternal

* Run genie idl
2025-10-26 05:12:34 +00:00
IchorDev
af31da1d3a D bindings: Fix nested struct methods, formatting, and Memory mutability (#3471)
Co-authored-by: IchorDev <ichordev@noreply.git.sleeping.town>
2025-10-10 16:01:41 +00:00
nathanstouffer
b4dbc129f3 Remove FloatFast option for glsl-optimizer (#3469)
* remove FloatFast option for shaderc

* scope removing FloatFast to glsl-optimizer

* correct comment
2025-10-03 17:25:00 +00:00
Jaziel Guerrero
9dfcab69f7 Add bindings for C3 Lang (#3456)
* Added bindings for C3 lang

* Fix sub-struct generation. Fix empty struct. Fix doc comments. These issues didn't allow the c3 compilation

* Add @extern for each function to match C API

* Add gen suffix to keep naming consistency
2025-08-31 02:44:28 +00:00
Aleš Mlakar
7cce5fb12d Beef bindings int as int32 (#3415)
* Updated README (with World Of Goo 2).

* Updated README (with World Of Goo 2).

* Updated cgltf.

* Updated meshoptimizer.

* Updated ImGui.

* Updated glslang.

* Updated spirv-headers.

* Updated spirv-tools.

* Updated spirv-cross.

* Updated Vulkan headers.

* Fix a crash in renderer_d3d12.cpp (#3349)

If querying the debug1 interface fails, don't attempt to release it.

* D bindings: Fix a casing error (#3350)

* Fix error in dynamic version of D bindings

Dazed and confused but trying to continue

* Fix dispatch_indirect still using uint16_t in bgfx.idl

* D bindings: Mark enum conv. functions `nothrow @nogc pure @safe`

* D bindings: Fix a casing error

* fix typo (scrach -> scratch) (#3353)

* Imgui: Add ability to link external STB libs.

* Revert "Updated spirv-tools."

This reverts commit 7cda7c988f.

* Rebuilt spir-v shaders.

* Properly support Wayland under EGL and Vulkan. (#3358)

* Improve NX Vulkan support. (#3357)

This change was developed using publicly available information found in Vulkan headers and official documentation. No proprietary NX resources were used.

Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>

* Dynamically load libwayland-egl.so.1 when dealing with Wayland to remove dependencies at program startup. (#3359)

* Cleanup.

* Cleanup.

* Support both X11 and Wayland in the same build. (#3360)

* Support both X11 and Wayland in the same build.

 - Works for both Vulkan and OpenGL.
 - Remove --with-wayland from genie options.
 - Vulkan loads all three extensions for surface creation instead of only one.
 - Add width and height parameter to GlContext::createSwapChain(), which is needed for EGL to create
   a SwapChain with the given window size.
 - Dirty-fix the example-22-windows to recreate the FrameBuffer by first destroying and then
   recreating to make sure the window is released of its swapchain.
 - Fix dbgText glitch in example-22-windows.
 - Remove old X11-related dependencies for GLFW3.

* Formatting.

* Build documentation improvements (#3362)

* Some documentation improvements: extra info on using GENie.

* Some grammer.

* Bump minimum GLFW version to 3.4.

* Insert vkDeviceWaitIdle to prevent VK_DEVICE_LOST. (#3363)

* Cleanup.

* Updated version.

* Updated meshoptimizer.

* Updated glslang.

* Updated spirv-headers.

* Updated spirv-tools.

* Updated spirv-cross.

* Updated Vulkan headers.

* Cleanup.

* Updated ImGui.

* shaderc: Fixed build.

* wasm: Fixed build.

* Cleanup.

* Fixed clang-debug target trying to build with gcc. (#3368)

Co-authored-by: -- <-->

* Fix compiling entry_noop (#3369)

* Updated GHA containers.

* Use DXGI_SWAP_CHAIN_DESC1 if available for additional scaling options. (#3370)

* Fix: Fix Uniform buffer doing too many iterations when updating renderer uniforms (#3372)

* Fixed IDL, added C++ IDL template.

* Updated version.

* Cleanup.

* Silent clang warnings.

* Updated README.md, fix typo(s) (#3376)

* Disable mingw-clang due broken winnt.h header.

* Fix various typos (#3377)

Found via `codespell -q 3 -S "./3rdparty,*.ttf,*.bin,./examples/common/imgui,./examples/common/font" -L attribut,ba,clude,conly,constan,espace,hashin,indext,inout,lod,nclude,retur,ser,sroll,struc,te,truct,unknwn,usin,utput,varyin`

* Assert on OOM.

* Fix Vulkan swapchain invalidation issue. (#3379)

* Fix Vulkan swapchain invalidation issue.

* Always clamp render pass to frame buffer size.

* Fix formatting.

* Cleanup.

* shaderc: Show correct error line.

* Cleanup.

* Format files to remove trailing spaces (#3384)

* Updated bindings.

* Updated docs.

* Cleanup.

* Cleanup.

* Fixed MSVC warnings.

* Removing alloca compat include.

* Fixed build.

* Fixed warning.

* Updated ImGui.

* Updated cgltf.

* Updated meshoptimizer.

* Updated glslang.

* Updated spirv-headers.

* Updated spirv-tools.

* Updated spirv-cross.

* Updated version.

* Revert "Fix: Fix Uniform buffer doing too many iterations when updating rende…" (#3391)

This reverts commit 4bc652939f.

* Happy New Year!

* Update README.md (#3394)

Added Off The Road 2

* Fix #3344 (#3399)

* Fix UniformBuffer UB regarding UniformType::Enum with extra bits. (#3398)

* Fix only one frame rendered in mobile opengles with intermediate frame buffer (#3405)

* Another fix for crashing with VK_DEVICE_LOST (#3404)

* Fix wasm tinystl compile error (#3406)

* utilize bx::strLen instead of C function

* utilize bx::strCopy instead of C function

* Updated ImGui.

* Updated meshoptimizer.

* Updated cgltf.

* Updated glslang.

* Updated spirv-headers.

* Updated spirv-tools.

* Updated spirv-cross.

* mini-fix: update docs config for doxygen (#3411)

* Remove STB nonsense todo assert.

* docs: clarify Android API version requirement in README (#3414)

Change Android version notation from "14+" to "4.0+ (API 14 or later)" for better clarity among Android developers

* Fixed C++20 deprecated lambda capture.

* Updated cgltf.

* Updated meshoptimizer.

* Updated glslang.

* Updated spirv-headers.

* Updated spirv-tools.

* Updated spirv-cross.

* Rebuilt metal & spir-v shaders.

* Add a file formatting script (#3383)

* Updated version.

* Beef bindings: Fix int32_t as int32

---------

Co-authored-by: Aleš Mlakar <ales.ambits@gmail.com>
Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>
Co-authored-by: Daniel Kalmar <1355747+kalmard0@users.noreply.github.com>
Co-authored-by: IchorDev <15670465+ichordev@users.noreply.github.com>
Co-authored-by: James Fulop <40307536+jamesfAnet@users.noreply.github.com>
Co-authored-by: Martijn Courteaux <courteauxmartijn@gmail.com>
Co-authored-by: imaginaryPineapple <hannespalomaki@gmail.com>
Co-authored-by: Raziel Alphadios <64050682+RazielXYZ@users.noreply.github.com>
Co-authored-by: Matt Tytel <matt@vital.audio>
Co-authored-by: Nuno Silva <little.coding.fox@gmail.com>
Co-authored-by: Bob Conan <sufssl03@gmail.com>
Co-authored-by: luzpaz <luzpaz@users.noreply.github.com>
Co-authored-by: Aaron Franke <arnfranke@yahoo.com>
Co-authored-by: attilaz <kocsisa78@gmail.com>
Co-authored-by: nathanstouffer <nathanstouffer1999@gmail.com>
Co-authored-by: Kevin J. <jerebicakevin@gmail.com>
Co-authored-by: Dipendra Sharma <17643682+dipendra-sharma@users.noreply.github.com>
2025-07-11 08:34:29 +01:00
Бранимир Караџић
5cb08f414f Updated shaderc. 2025-05-10 19:57:30 -07:00
Luigi Malomo
c8f237a39b Add u_invModelView uniform to shader and documentation (#3421) 2025-04-11 23:54:42 +00:00
Kevin J.
ee8664e068 mini-fix: update docs config for doxygen (#3411) 2025-02-26 18:05:45 -08:00
Бранимир Караџић
860bafb23f Happy New Year! 2025-01-13 15:45:40 -08:00
Aaron Franke
40961806bd Format files to remove trailing spaces (#3384) 2024-12-09 22:01:16 -08:00
Бранимир Караџић
042ebe8814 Cleanup. 2024-12-07 22:49:45 -08:00
Бранимир Караџић
fe41532c40 Fixed IDL, added C++ IDL template. 2024-11-12 20:19:52 -08:00
Бранимир Караџић
76dde5d0b2 shaderc: Fixed build. 2024-10-20 09:17:51 -07:00
Martijn Courteaux
e488a07f1b Support both X11 and Wayland in the same build. (#3360)
* Support both X11 and Wayland in the same build.

 - Works for both Vulkan and OpenGL.
 - Remove --with-wayland from genie options.
 - Vulkan loads all three extensions for surface creation instead of only one.
 - Add width and height parameter to GlContext::createSwapChain(), which is needed for EGL to create
   a SwapChain with the given window size.
 - Dirty-fix the example-22-windows to recreate the FrameBuffer by first destroying and then
   recreating to make sure the window is released of its swapchain.
 - Fix dbgText glitch in example-22-windows.
 - Remove old X11-related dependencies for GLFW3.

* Formatting.
2024-10-05 14:33:22 -07:00
Martijn Courteaux
a6e372ead9 Dynamically load libwayland-egl.so.1 when dealing with Wayland to remove dependencies at program startup. (#3359) 2024-10-01 11:06:56 -07:00
IchorDev
f29c1b7cde D bindings: Fix a casing error (#3350)
* Fix error in dynamic version of D bindings

Dazed and confused but trying to continue

* Fix dispatch_indirect still using uint16_t in bgfx.idl

* D bindings: Mark enum conv. functions `nothrow @nogc pure @safe`

* D bindings: Fix a casing error
2024-09-04 09:01:09 -07:00
Бранимир Караџић
e41cbebf16 Set define for USE_ENTRY. 2024-07-09 07:28:59 -07:00
Бранимир Караџић
2529e1abc7 Sorted caps. 2024-06-28 08:16:09 -07:00
Бранимир Караџић
61c770b0f5 Added option to build bimg with libheif. 2024-06-11 17:58:57 -07:00
Бранимир Караџић
2ad67a4dfd Cleanup. 2024-03-29 16:36:55 -07:00
IchorDev
e1077e376e D bindings: Mark enum conversion functions nothrow @nogc pure @safe (#3272)
* Fix error in dynamic version of D bindings

Dazed and confused but trying to continue

* Fix dispatch_indirect still using uint16_t in bgfx.idl

* D bindings: Mark enum conv. functions `nothrow @nogc pure @safe`
2024-03-21 07:49:01 -07:00
IchorDev
4cb7b7138a Fix dispatch_indirect still using uint16_t in bgfx.idl (#3268)
* Fix error in dynamic version of D bindings

Dazed and confused but trying to continue

* Fix dispatch_indirect still using uint16_t in bgfx.idl
2024-03-12 08:01:27 -07:00
Branimir Karadžić
98d88d9fc6 Fixed draw indirect. 2024-02-09 20:55:44 -08:00
Бранимир Караџић
b927f9e187 Use 32-bit arguments for indirect draw APIs. 2024-01-26 20:18:24 -08:00
Бранимир Караџић
83dfadf673 Happy New Year! 2024-01-14 01:56:36 -08:00
Бранимир Караџић
0555b5d297 Updated docs. 2023-12-26 13:18:09 -08:00
Бранимир Караџић
1c73c1a64a Fixed wasm build. 2023-12-15 07:55:48 -08:00
Бранимир Караџић
5b8a8ba3da Fix wasm build. 2023-12-15 07:37:08 -08:00
IchorDev
07be0f213a Fix error in dynamic version of D bindings (#3215)
Dazed and confused but trying to continue
2023-12-06 07:39:24 -08:00
IchorDev
ae4b0cd5a9 Fix random, erroneous D binding type generation; add missing IDL defaults (#3210)
* Reformatted comments; fixed a couple of oversights

* D bindings: deterministic sub-struct order

* Added missing default to IDL

* Fixed sub-struct linkage; regenerate D binds

* Culled D bindings for header-only C++ functions

* Added missing default to bgfx.idl

* cppinline now supported by all auto-gen bindings

The pattern "func.cppinline and not func.conly" is to make sure that C bindings for `bgfx_vertex_layout_has` are still generated.

* Fix mangling issue; use updated BindBC-Common API

* Add missing default to setTransform in IDL

* Fix erroneous generation of `uc_int64`

Non-deterministic ordering of hash-maps were the culprit all along!

* Add missing default to overrideInternal IDL & re-generate
2023-12-02 10:19:45 -08:00
Бранимир Караџић
1a329595aa Clarified docs about requirement to use command line tool to compile shaders. 2023-11-22 23:14:48 -08:00
IchorDev
9612f6d147 D bindings: fix mangling error, use improved BindBC-Common API (#3201)
* Reformatted comments; fixed a couple of oversights

* D bindings: deterministic sub-struct order

* Added missing default to IDL

* Fixed sub-struct linkage; regenerate D binds

* Culled D bindings for header-only C++ functions

* Added missing default to bgfx.idl

* cppinline now supported by all auto-gen bindings

The pattern "func.cppinline and not func.conly" is to make sure that C bindings for `bgfx_vertex_layout_has` are still generated.

* Fix mangling issue; use updated BindBC-Common API
2023-11-12 09:28:41 -08:00
Бранимир Караџић
49c0e49527 Removed WebGPU. (#3198) 2023-11-09 17:15:22 -08:00
Бранимир Караџић
f14c14a485 Removed D3D9. (#3191) 2023-11-03 21:15:42 -07:00
Gareth Fare
7c440b339f Small fix on soname defining on ldflags for Android examples. (#3184)
* Add linker options to add SONAME to the linked target so Android apps can dynamically resolve the library location from known locations (as opposed to a hard coded location often residing on the host cross compiling filesystem.

linked issue is,

https://github.com/bkaradzic/bgfx/pull/2176

* Kepp orginal code for linkoptions in the previous configuration block and add the additional linker flags for each Debug/Release configuration.

* Add comma character to EOL to match orginal code.
2023-10-16 09:48:50 -07:00
Branimir Karadžić
99439d296a shader.mk specify profile for all shaders. 2023-09-30 16:55:00 -07:00
Nuno Silva
b68dc2b13e Fix Native Window Type IDL/Bindings; (#3163) 2023-08-26 20:50:34 +02:00
Jamil Halabi
f059531885 Added a new capability to check for PrimitiveID support (#3154) 2023-08-04 16:42:33 +02:00
Julian Sikorski
8b6a6bdf0e Fix building for glfw and wayland (#3151)
Co-authored-by: Julian Sikorski <belegdol@fedoraproject.org>
2023-07-31 07:14:04 -07:00
IchorDev
878767e751 Culled D bindings for header-only C++ functions (#3130)
* Reformatted comments; fixed a couple of oversights

* D bindings: deterministic sub-struct order

* Added missing default to IDL

* Fixed sub-struct linkage; regenerate D binds

* Culled D bindings for header-only C++ functions

* Added missing default to bgfx.idl

* cppinline now supported by all auto-gen bindings

The pattern "func.cppinline and not func.conly" is to make sure that C bindings for `bgfx_vertex_layout_has` are still generated.
2023-07-19 20:53:42 -07:00
IchorDev
c3dab115a8 D bindings: deterministic sub-struct order (#3127)
* Reformatted comments; fixed a couple of oversights

* D bindings: deterministic sub-struct order

* Added missing default to IDL

* Fixed sub-struct linkage; regenerate D binds
2023-07-09 08:11:39 -07:00
IchorDev
d485a56f61 Reformatted comments; fixed a couple of oversights (#3125) 2023-07-07 12:40:22 -07:00
Branimir Karadžić
787ecc1138 Cleanup. 2023-06-29 09:26:04 -07:00
IchorDev
e74c3a82dd Made struct order deterministic (hopefully) (#3118) 2023-06-27 09:23:48 -07:00
IchorDev
cbd83f57ca New auto-generated D bindings (#3114)
* Added shaderc default defines to docs

* Update tools.rst

* Update tools.rst

* WIP new D bindings

* New bindings "nearly done"

* More unfinished changes

* Nearly done; ctors still don't work

* Bindings auto-generation is done

* New auto-generated D bindings

* Reduced D bindings file count back to 2

---------

Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>
2023-06-26 11:21:22 -07:00
Бранимир Караџић
322fc55251 Updated scripts. 2023-06-24 08:27:25 -07:00
Бранимир Караџић
6c8700d70c Removed non-existing C++ overloads from IDL. 2023-06-20 09:25:01 -07:00
Бранимир Караџић
02e67ff404 Cleanup. 2023-06-13 18:27:31 -07:00