Commit Graph

4509 Commits

Author SHA1 Message Date
bjorn cd04060467 Use correct roughness for indirect specular lighting; 2022-09-23 23:58:47 -07:00
bjorn d905b649a4 Lighting helper fixes; 2022-09-23 23:44:31 -07:00
bjorn a766bf4a35 Fix Quest hand model orientation; 2022-09-23 17:52:21 -07:00
bjorn d2ceb6b81a Fix skeletal animation on some GPUs;
The animation compute shader was not specializing the workgroup size
properly, so it was only working on GPUs with a subgroup size of 32.

The Quest 1 has a subgroup size of 32 and the Quest 2 has a subgroup
size of 64, so this resulted in hand models breaking on Quest 2 only!
2022-09-23 14:36:20 -07:00
bjorn 4316c39c5d Update Oculus OpenXR loader to v42; 2022-09-23 14:36:07 -07:00
bjorn 74218da271 Fix luax_checkendpoints when direction is not normalized; 2022-09-23 11:58:26 -07:00
bjorn ef407fd564 Add var shader helper;
Now you can write var(0) instead of layout(set = 2, binding = 0).
The advantage is less typing and resilience in the event that the
default set changes.
The disadvantage is that now you can't use var.
2022-09-22 20:44:06 -07:00
bjorn 2e0b5a4efa Flip msdf glyphs;
They don't look right when using a negative y scale for some reason,
even though the rendering was still working.
2022-09-22 20:30:04 -07:00
bjorn dd336b7473 Render target textures don't have mipmaps by default; 2022-09-21 21:18:32 -07:00
bjorn 952bff414a Add more oculus manifest permissions;
- Keyboard tracking
- Render model
- Passthrough
2022-09-21 14:58:30 -07:00
bjorn 311d1511bc Fix quest keyboard tracking; 2022-09-21 14:58:30 -07:00
Josip Miskovic da9328e72c Fix sending strings with \0 through channels
A null-char is valid part of Lua string. When such a string is sent
through the channel, its length should be stored as well to be able to
correctly reconstruct it on the other thread.

The bug was triggered with this code:

    s1 = 'a \0 b'
    print(#s1) -- 5
    ch:push(s1)
    s2 = ch:pop()
    print(#s2) -- 2
2022-09-21 09:15:20 -07:00
bjorn 72334cc1f2 Fix cubemaps being horizontally flipped; 2022-09-20 22:17:58 -07:00
bjorn ece73be868 lovr.headset.getPose works with keyboard device on Quest; 2022-09-20 20:16:58 -07:00
bjorn d1b6bd3d15 OpenXR: fall back to d24s8 when d32fs8 isn't supported;
Window was already doing this.

Quest currently doesn't work with stencil = true because of this.
2022-09-20 19:09:04 -07:00
bjorn 28869431fb Fix stereo mirror window; 2022-09-15 20:45:26 -07:00
bjorn 6444aba832 OpenXR: Map Index system buttons to menu;
SteamVR doesn't expose these, but monado does, so might as well bind them.
2022-09-14 21:35:43 -07:00
bjorn 4f4477b6c8 CMake: Fix plugins that use static libraries; 2022-09-14 21:33:24 -07:00
bjorn adaef45e2f tup: use -Os when invoking glslangValidator;
Saves a bit of space.
2022-09-14 20:53:42 -07:00
bjorn 5be425ddbe Fix Pass:clear(Texture); 2022-09-14 20:53:42 -07:00
Bjorn 382fab4ab1
Fix README; 2022-09-13 19:46:51 -07:00
Bjorn 44f9a0a3fb
Update README; 2022-09-13 19:46:17 -07:00
bjorn 1dd737d8a4 Make the logo a default shader;
Improves build system, improves filesize, seemingly improves startup time
2022-09-13 17:36:10 -07:00
bjorn a31ae6a68f Fix compileShader; 2022-09-13 17:22:48 -07:00
bjorn b5651f9193 Fix lod range of default samplers; 2022-09-12 18:09:29 -07:00
bjorn 68f3610d5e Fix stencil test; 2022-09-12 17:58:29 -07:00
bjorn d8c23bacec Source:setPitch;
Co-authored-by: Nevyn Bengtsson <nevyn@alloverse.com>
2022-09-11 20:41:58 -07:00
bjorn 1c9adea2e2 Simplify channel hash table; 2022-09-10 23:59:14 -07:00
bjorn bcde681710 Mark ASTC textures as sRGB;
They don't contain this metadata, but marking as sRGB is more reasonable
than not.
2022-09-10 23:55:15 -07:00
bjorn 76557eb6ed Add hand joint radius to getSkeleton; 2022-09-10 23:44:14 -07:00
bjorn 7636a3c5e9 Default window size matches conf.lua; 2022-09-10 21:10:01 -07:00
bjorn 860651e80c rm falsy variant of lovr.system.openWindow;
Probably vestigial from conf invocation.
2022-09-10 20:53:55 -07:00
bjorn 0da84894e8 Fix gamma correction of multicolor text; 2022-09-10 14:55:15 -07:00
bjorn 0191d29a45 Handle missing Vulkan error; 2022-09-10 13:06:32 -07:00
bjorn 0b544df470 Rename OS_EXPORT to avoid macOS clash; 2022-09-10 12:53:52 -07:00
bjorn d8c6c47e00 Add normal DefaultShader;
It's a pretty normal shader.
2022-09-10 11:07:55 -07:00
bjorn 5f921f1251 Unable to mipmap multisampled textures; 2022-09-10 11:02:03 -07:00
bjorn 7e1d9f1dd2 Fix desktop driver crash when window isn't open; 2022-09-10 10:58:11 -07:00
bjorn 931ffea17b Pass:getClear returns correct value for dontcare/load actions; 2022-09-10 10:28:54 -07:00
bjorn 5c4fc79242 mv lovr.graphics.init lovr.graphics.initialize;
init is undocumentable due to Lua conventions.
2022-09-10 10:22:52 -07:00
bjorn f30e37a2e3 Error if testing/writing non-existent stencil buffer; 2022-09-10 10:20:41 -07:00
bjorn 48ec18573a Pass:getClear only includes depth when depth buffer exists; 2022-09-10 10:17:24 -07:00
bjorn ee809ec31a Pass:mipmap base mipmap index is 1-indexed; 2022-09-10 10:14:46 -07:00
bjorn 7851f49910 Make blit layers 1-indexed;
Annoying for 3D textures, but matches layer indices most elsewhere.
2022-09-10 10:13:34 -07:00
bjorn a3beccb14e Fixup 3D texture blit validation; 2022-09-10 10:12:06 -07:00
bjorn a796c92556 Buffer:clear and Pass:clear(Buffer) use the same units; 2022-09-03 10:49:25 -07:00
bjorn 08f0ca7434 Font:getVertices wrap is optional; 2022-09-02 19:21:55 -07:00
bjorn ed035f9e81 Adjust; 2022-09-02 18:53:50 -07:00
bjorn 688c698808 Enable hand tracking 2.0 in AndroidManifest.xml; 2022-09-02 18:53:31 -07:00
bjorn 8697466009 Shader flag adjustments;
- glowTexture is on by default, but still requires the glow flag.
- occlusionTexture is named ambientOcclusion, and is on by default,
  but is still not used by any builtin shaders/helpers.
2022-09-02 15:33:18 -07:00