Commit Graph

473 Commits

Author SHA1 Message Date
Бранимир Караџић
f5297105fa shaderc: Simplified build script. 2023-01-14 18:40:27 -08:00
Бранимир Караџић
35996c46cb Updated shaderc build script. 2023-01-14 18:28:09 -08:00
Бранимир Караџић
466c6a4e95 Happy New Year! 2023-01-14 10:05:12 -08:00
Ali Seyedof
877cdb8b1f
shaderc HLSL profile switch fix (#3005)
* shaderc HLSL profile switch fix

* shader makefiles changed to match new hlsl profile switches

Co-authored-by: Ali Seyedof <ali.seyedof@xyzreality.com>
2022-12-28 10:16:37 -08:00
Бранимир Караџић
3b9b2aa130 Uncomment embedded SPIR-V compute shader script. 2022-11-24 08:32:18 -08:00
Raziel Alphadios
c2bc5177b5
Add support for remaining unsupported ASTC formats (#2963)
* Add support for remaining unsupported ASTC formats
Add new ASTC formats into pixelformats example and ninja scripts
Rebuild ASTC textures

* Update idl and generate
Move comma in pixelformats

Co-authored-by: Raziel Alphadios <raziely@gmail.com>
2022-10-25 17:03:40 -07:00
Michał Cichoń
04732d89e3
Android NDK update, bgfx side (#2960)
* Android: Add local copy of native_app_glue, patched to compile as C++.

* Android: List android-x86_64 configuration in makefile

* Android: Build shared-lib and examples by default

* Docs: Update Android build prerequisites

* CI: Add Android builds

* CI: **DO NOT MERGE** pick bx/PR with android support update
2022-10-22 12:02:34 -07:00
Бранимир Караџић
39c8d091f4 Cleanup. 2022-10-21 09:13:51 -07:00
Raziel Alphadios
4f76738e96
Add astc to ninja scripts (#2959)
Co-authored-by: Raziel Alphadios <raziely@gmail.com>
2022-10-20 22:16:44 -07:00
Бранимир Караџић
24c5c2f096 shaderc: Updated to new glslang. 2022-10-02 23:18:33 -07:00
Biswapriyo Nath
adf5c354b7
scripts: Fix unknown compiler flag for clang (#2934)
This fixes the following warnings with clang based toolchain

warning: unknown warning option '-Wno-logical-op'; did you mean '-Wno-long-long'? [-Wunknown-warning-option]
warning: unknown warning option '-Wno-maybe-uninitialized'; did you mean '-Wno-uninitialized'? [-Wunknown-warning-option]
2022-09-29 07:52:17 -07:00
Biswapriyo Nath
82ad2eac7a
clang-mingw: Enable building tools and examples (#2928)
Add comdlg32 library for GetOpenFileNameA API.
2022-09-18 20:11:51 -07:00
Бранимир Караџић
e4be44e92b Updated API version. 2022-09-18 19:11:58 -07:00
jwdevel
f1f77a6cd3
Record frame num in view stats (#2908)
* Add 'frameNumber' to Frame struct

Previously, the frame number returned from bgfx::frame() was tracked separately in the Context. Now,
we store that information in the Frame. This will allow us to attach the frame number to ViewStats.

* Add frame number to ViewStats

When ViewStats are enabled, we tag each timer query with the current frame number, then include
that information in the final results. In this way, clients can correlate specific work that they
submitted to specific GPU timing information.

NOTE: Some backends not implemented, yet. They will always have 0 for frame number.
The ones which are implemented are:
 * OpenGL
 * Vulkan
 * D3D 9,11,12
 * Noop
2022-09-18 19:09:48 -07:00
Бранимир Караџић
7ffeaefad2 API version 116. 2022-09-17 18:18:51 -07:00
pezcode
ba467be036
Add support for indirect draw with indirect count (#2925)
* Add indirect draw with indirect count (BGFX_CAPS_DRAW_INDIRECT_COUNT)

* Update bindings

* VK: Add support for BGFX_CAPS_DRAW_INDIRECT_COUNT

* D3D12: Add support for BGFX_CAPS_DRAW_INDIRECT_COUNT

* GL: Add support for BGFX_CAPS_DRAW_INDIRECT_COUNT

* 48-drawindirect: Use BGFX_CAPS_DRAW_INDIRECT_COUNT if available

* 48-drawindirect: Update shaders
2022-09-17 18:16:19 -07:00
blackhole
a8a10b0b89
Adds example 49-hextile (#2922)
* First commit - tested with dx11 on windows

* Minor changes & adding some comments.

* Update hextile.cpp

* update some bin files

* rename texture

* minor comment update

* Added support to configure tile rate as well as tile rotation strength, update bin files & screenshot

* use texture from polyhaven, updated screenshot, updated bin files & minor changes to shader.

* missed pushing texture

* update license

* Update hextile.cpp

* Fix regular tiling

* use ktx with mipmaps

* minor change to ensure that regular tiling & hextile matches with default tile rate.

* minor c

Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>
2022-09-15 19:03:07 -07:00
Бранимир Караџић
9ad3825cee D3D12: Linux build. 2022-09-14 20:59:59 -07:00
Branimir Karadžić
358f48879a Updated directx-headers. 2022-09-12 20:19:21 -07:00
SnapperTT
135dc7fa27
Adds example 48-multidrawindirect (#2894)
* Added example 48-multidrawindirect

* Added example 48-multidrawindirect

* enable shader.mk to build directories that only have compute shaders

* compiled shaders for example 48

* MultidrawIndirect example renamed to DrawIndirect, sets draw mtx in compute

* update 48-drawindirect shaders

* fix typos

* fixed bgfx::setPlatformData change for example48

* fix docs

* added name to cs_drawindirect.sc

* style updates for example 44

* add slider to example 48-drawindirect
2022-08-26 21:32:15 -07:00
Sandy
85910e9778
Add BGR versions of 16 bit formats (#2897)
* pixelformats: Add BGRA4

* pixelformats: Add BGR5A1

* pixelformats: Add B5G6R5

* make idl
2022-08-25 16:08:06 -07:00
Michał Cichoń
549077fc0b
Pixelformats example mupltiple sources (#2889)
* Added texture conversion for pixelformat to runtime asset.

* pixelformats: Support multiple sources, cleanup
2022-08-23 12:51:00 -07:00
ichordev
e9e9605304
Updated BGFX_PCI_ID docs to reflect GPU priority & added missing enums (#2888)
* Add new BGFX_PCI_ID enums

* Updated BGFX_PCI_ID docs to reflect GPU priority & added missing enums

* Updated bgx.idl; minor corrections; ran GENie
2022-08-23 09:30:01 -07:00
Sandy
651432df1d
examples: Add imageformats example (#2872)
* examples: Add imageformats example

Example which renders RGBA color wheel, alpha gradient and full value channel textures to
catch conversion errors and bad internal type representations between different backend
renderers.

The example uses bimg to convert from a master texture to different textures.

Each texture is rendered in an ImGui list using `ImGui::Image`. A close-up is visible
when hovering over each image.

U and I textures are skipped because they don't work for sampling.
Compressed textures are skipped because they don't have conversion functions.
Depth textures are not rendered because they don't work with channels.

* pixelformats: Present texture format in table

* Update pixelformats.cpp

* Update pixelformats.cpp

* pixelformats: Update screenshot

* pixelformats: Add checkerboard background

Co-authored-by: Michał Cichoń <michcic@gmail.com>
Co-authored-by: Бранимир Караџић <branimirkaradzic@gmail.com>
2022-08-22 12:16:58 -07:00
Бранимир Караџић
758d02db1e Updated spirv-tools. 2022-07-29 21:41:54 -07:00
Cedric Guillemet
a3d52fab32
premultiplied backbuffer for UWP/SwapchainPanel (#2837)
* premultiplied backbuffer for UWP/SwapchainPanel

* init flag

* caps and feedback/opengl premul

* reduced #ifdef form

* removed ifdef
2022-07-18 09:23:57 -07:00
luzpaz
e7936efa6a
Fix typos (#2839)
Found via `codespell -q 3 -S ./3rdparty,*.ttf -L attribut,ba,clude,conly,indext,inout,lod,nclude,retur,struc,unknwn,utput`
2022-07-12 14:21:31 -07:00
Бранимир Караџић
f06d7257b2 Fixed docs. 2022-07-11 05:45:02 -07:00
Cedric Guillemet
f0cf1794e7
Fix MSAA with ARM Mali OpenGL ES (#2818)
* Fix MSAA with ARM Mali OpenGL ES

* indenting
2022-06-15 03:35:19 -07:00
Бранимир Караџић
6cf243f469 Cleanup. 2022-06-04 11:03:41 -07:00
Бранимир Караџић
05b60be3c2 Remove 17-drawstress from Emscripten build. 2022-06-02 12:03:01 -07:00
Catalin Moldovan
9204a536dd
Fixed indentation on zig wrapper functions and converted to uppercase 2D/3D (#2809) 2022-05-29 07:50:14 -07:00
Catalin Moldovan
f0741047d8
more idiomatic zig bindings (#2804) 2022-05-22 18:43:03 -07:00
Jared Miller
c084dd2616
Update Zig binding generation (#2765) 2022-04-08 06:41:00 -07:00
Catalin Moldovan
21f5f941bb
Added zig bindings generation (#2757) 2022-04-03 18:42:43 -07:00
Бранимир Караџић
6940ddd85e Cleanup. 2022-03-31 20:21:32 -07:00
ichordev
81c6610293
Minor rewording & increase of clarity (#2752)
* Minor rewording & increase of clarity

* Corrected a noun that was being used as a verb

* Slight rewording of the C99 bindings notices

* Actually, this sounds better & looks nicer
2022-03-31 18:07:21 -07:00
ichordev
6bc813fb76
Updated D bindings: enums expanded; added some C++ pre-processor functions (#2742)
* D binds: expanded enums; added some C++ pre-processor functions

* Updated D bindings files
2022-03-08 11:25:54 -08:00
ichordev
630890f5de
Fixed uint8_t being bound to byte instead of ubyte (#2735) 2022-03-05 16:32:38 -08:00
luzpaz
6875e96bcb
Fix various typos (#2719)
Found via `codespell -q 3 -S ./3rdparty,*.ttf -L attribut,ba,clude,conly,indext,inout,lod,nclude,retur,utput`
2022-02-05 11:34:15 -08:00
Бранимир Караџић
4581f14cd4 Happy New Year! 2022-01-15 11:59:06 -08:00
Бранимир Караџић
949142a75f Metal: Added GPU vendorId/deviceId detection. Fixed #2688. 2021-12-19 23:11:33 -08:00
Бранимир Караџић
1e2ca25424 Added Apple vendor id. 2021-12-19 21:05:20 -08:00
jwdevel
fd9bcf541a
Enhance docs for BGFX_DEBUG_PROFILER, showing relation to per-view stats. (#2683)
Current docs are a little ambiguous with the term "profiling"; sometimes it means
bgfx::CallbackI functions, and sometimes per-view stats collection. This makes it a little clearer.
2021-12-13 12:46:06 -08:00
Бранимир Караџић
60c64a3f77 Cleanup. 2021-12-01 11:22:36 -08:00
Cedric Guillemet
64a28415a8
Disable Batch indirect mode for Microsoft WARP (#2672)
* Disable Batch indirect mode for Microsoft WARP

* idl

Co-authored-by: Cedric Guillemet <ceguille@microsoft.com>
2021-12-01 11:19:47 -08:00
Branimir Karadžić
00df353f0b Fixed project groups. 2021-10-26 20:13:30 -07:00
Бранимир Караџић
8392a44b3a Fixed assert macros, and improved error handling. 2021-10-25 18:59:32 -07:00
Branimir Karadžić
b7213445db Added 46-fsr example. 2021-10-06 17:40:57 -07:00
Daniel Collin
0a4ed20b59
Cleanup bgfx.idl (#2597) 2021-08-29 11:07:02 -07:00