Commit Graph

3229 Commits

Author SHA1 Message Date
Branimir Karadžić
cea9c033fc D3D12: Fixed R5G6B5 format. 2022-08-22 20:14:34 -07:00
Sandy
c334d7c8f1
metal: Fix BGR to RGB swizzle (#2879) 2022-08-22 19:42:19 -07:00
Sandy
054a9ecd83
Texture format info: Invert R and B in RGBA4 (#2878)
* texture format info: Invert R and B in RGBA4

d3d9: Revert 06c08adc9e to force software
      conversion because the format doesn't exist
d3d11: Force software conversion because the format doesn't exist
gl: Revert 3e3e655262 to swizzle R and B
mtl: Swizzle channels

* metal: Remove explicit conversion of RGBA4 and RGB5A1 in osx

* metal: Set alpha bit to correct end of short
2022-08-22 19:03:22 -07:00
Бранимир Караџић
31c92ece0a VK: Fixed A8 format. 2022-08-22 19:02:57 -07:00
Sandy
58aeeaf155
texture format info: Invert R and B in RGB5A1 (#2876)
d3d9: Revert 76db2ed38d to force software
      conversion and use the format that does exist
d3d11: Force software conversion because the format doesn't exist
gl: Revert b36aa71403 to swizzle R and B
mtl: Swizzle R and B
2022-08-22 17:36:50 -07:00
Бранимир Караџић
2d313f46ad Cleanup. 2022-08-21 16:26:45 -07:00
Paul Gruenbacher
f99f972c17
Fix invalid boolean logic of texture validation (#2871)
I noticed that this 0363560934
broke b5e7a4cccd/examples/16-shadowmaps/shadowmaps.cpp (L1750)
which shouldn't be the case. The validation was meant for only multisample flags.
my boolean logic assumes that it must be BGFX_TEXTURE_RT in the flag or BGFX_TEXTURE_RT_MSAA_XX in the flag.
2022-08-20 18:04:10 -07:00
Бранимир Караџић
b5e7a4cccd MTL: Added texture format component mapping from PR #2869. 2022-08-20 09:31:53 -07:00
Бранимир Караџић
ec00fa1bc2 GL: Added component mapping stub. 2022-08-19 19:11:13 -07:00
Branimir Karadžić
186c95fd29 D3D12: Added texture format component mapping from PR #2869. 2022-08-19 18:50:02 -07:00
Branimir Karadžić
99770c9f43 Overallocate dynamic buffers on resize. 2022-08-19 18:21:11 -07:00
Бранимир Караџић
6b5b50c2cf VK: Fixed RGB10A2, and RGB5A1 swizzle. 2022-08-19 11:29:59 -07:00
Бранимир Караџић
130ac64a0b VK: Fixed RGBA4 swizzle. 2022-08-19 11:25:11 -07:00
Бранимир Караџић
280cae73af VK: Fixed swizzle macro. 2022-08-19 10:57:49 -07:00
Бранимир Караџић
67f27573b9 Cleanup. 2022-08-19 10:40:00 -07:00
Branimir Karadžić
b35b3fa2a7 Fixed dynamic buffer leak. Issue #2867. 2022-08-19 09:51:23 -07:00
Бранимир Караџић
8abb86801f Cleanup. 2022-08-18 21:14:35 -07:00
Бранимир Караџић
51f89e3510 VK: Made swizzle component table more readable. 2022-08-18 20:43:59 -07:00
Branimir Karadžić
0363560934 Added depth MSAA texture validation. Issue #2862. 2022-08-17 17:00:21 -07:00
Бранимир Караџић
2449610af7
Revert "Resolve texture format correctly on D3D11/D3D12 (#2859)" (#2865)
This reverts commit 8358bf6ecf.
2022-08-17 16:44:30 -07:00
Julian Xhokaxhiu
8358bf6ecf
Resolve texture format correctly on D3D11/D3D12 (#2859)
* D3D12: Fix ResolveSubresource texture format parameter

For depth textures this always returned the TYPELESS one, but instead it should have passed the FLOAT.

* D3D11: Fix ResolveSubresource texture format parameter

For depth textures this always returned the TYPELESS one, but instead it should have passed the FLOAT.
2022-08-09 11:37:44 -07:00
Cedric Guillemet
6aad365c9e
Enable MSAA setting at context creation for Android (#2854) 2022-08-04 06:51:38 -07:00
Cedric Guillemet
bedab93431
Fix D3D12 InputSlot when having streams w/ instances (#2853) 2022-08-03 08:02:03 -07:00
Бранимир Караџић
484a5f0c25 Updated version number. 2022-07-23 10:59:37 -07:00
Бранимир Караџић
e34ae05cdf Cleanup. 2022-07-19 10:36:18 -07:00
Бранимир Караџић
9022ffcb64 Add warning when calling RESET with unusupported feature. 2022-07-18 19:25:50 -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
Бранимир Караџић
d0a4672307 Cleanup. 2022-07-10 23:26:39 -07:00
Бранимир Караџић
c066251750 Cleanup. 2022-07-10 20:46:11 -07:00
Бранимир Караџић
32192450c4 WebGL2: Fixed missing glReadBuffer import. 2022-07-10 19:03:28 -07:00
bdunkin
f9ab3b5c68
Increase the buffer size if necessary before adding markers (#2838) 2022-07-08 11:46:03 -07:00
Gary Hsu
db44d5675f
Fixes when running in WinRT (#2827)
* Use ResizeBuffers for WinRT

* Set maximum frame latency for WinRT

* Remove extra space
2022-06-23 22:13:38 -07:00
Бранимир Караџић
a153458735 Cleanup. 2022-06-20 05:58:22 -07:00
Cedric Guillemet
607a775009
FS Quad/MSAA for GLES3 (#2820) 2022-06-15 07:44:25 -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
Бранимир Караџић
24765f8967 Cleanup. 2022-05-21 18:02:37 -07:00
Бранимир Караџић
05b9355ac2 Discard state before touch. Fixed issue #2803. 2022-05-21 08:48:24 -07:00
Branimir Karadžić
8e7774f735 Fixed build. 2022-05-17 11:30:10 -07:00
Julian Xhokaxhiu
89ae74122c
OpenGL: Enable sRGB texture format support for BC7 (#2800) 2022-05-17 10:54:37 -07:00
Бранимир Караџић
6601b01430 Cleanup. 2022-05-17 07:07:10 -07:00
Alexander Knorre
7b1d6a98a9
Compute kSortKeyViewNumBits automatically. (#2796)
Compute kSortKeyViewNumBits automatically via log2(BGFX_CONFIG_MAX_VIEWS), so that we could change BGFX_CONFIG_MAX_VIEWS to be above 2^10 = 1024 without changing the `bgfx` source code.
One possible problem with this approach is running out of bits, so maybe we could assert for that, I am not sure where to do it and how many bits we can use though.
Using `bx::uint32_cntlz` because `bx::log2` is not constexpr.
Tested on linux opengl with BGFX_CONFIG_MAX_VIEWS=4096, seems to work.
2022-05-15 19:24:53 -07:00
Бранимир Караџић
36be8a72cc Fixed blit key encoding. 2022-05-14 21:26:20 -07:00
Бранимир Караџић
ae5706693f Cleanup. 2022-05-13 17:41:30 -07:00
slewicki
bd8ed86009
Changed WGL_STENCIL_BITS_ARB to match what gets used in createContext (#2791)
On Mesa, the pixel format would match the 0 stencil bits as requested. This change helps bring the pixel format to match what `createContext` would use.
2022-05-06 09:21:05 -07:00
Branimir Karadžić
fe8cab2522 Manually merged PR #2710. 2022-04-26 19:15:15 -07:00
Бранимир Караџић
b8fdc3f8be Cleanup. 2022-04-25 21:13:29 -07:00
Kitchen
35c27cda3d
Metal merge texture format (#2785)
* need check texture format is support read/write

* move read write check to s_textureFormat

* add check BGFX_CAPS_IMAGE_RW

* remove custom read write mask as MTLReadWriteTextureTier

* remove ReadWriteTierMask struct
2022-04-25 19:21:20 -07:00
Бранимир Караџић
ed5e2694dc Cleanup. 2022-04-25 07:19:18 -07:00