Commit Graph

75 Commits

Author SHA1 Message Date
bjorn 26d17fc402 boot.lua: exit successfully when printing help; 2024-03-12 13:32:26 -07:00
Ilya 994f623c5d
Fix boot.lua merge
boot.lua was broken during merging with stable branch.
2024-03-12 23:12:29 +03:00
bjorn 2b218d09d0 Merge branch 'stable' into dev 2024-03-12 11:58:34 -07:00
bjorn 66f6ee9bb9 v0.17.1; 2024-03-12 11:56:30 -07:00
bjorn 1f6904c04b Fix errhand loop when debug library is unavailable;
(cherry picked from commit dacc17e1b7)
2024-03-12 11:02:00 -07:00
bjorn a4c1d9fce6 Thread module initializes job system;
Worker count can be set from conf.lua.

A negative worker count is relative to the number of cores.

-1 is the default.
2024-02-28 12:31:34 -08:00
bjorn dacc17e1b7 Fix errhand loop when debug library is unavailable; 2024-01-24 17:54:07 -08:00
bjorn d29e6c2ec3 Fix warning message when requiring module fails; 2024-01-05 14:23:34 -08:00
bjorn 987c029479 Add back graphics module check to errhand; 2023-12-01 16:50:45 -08:00
bjorn afd11cf0b9 Fix pcall and only use nogame conf for nogame; 2023-11-27 19:02:31 -08:00
bjorn 0a17cc566d Add nogame bundle; CMake zips and concats nogame; 2023-11-27 18:42:49 -08:00
bjorn 4f67fa9a2e Fix coroutine error handling; 2023-11-27 18:42:49 -08:00
bjorn 6edd4ec049 Improve error messages; Add comments; 2023-11-27 18:42:49 -08:00
bjorn 427ad25120 Fix errhand alignment; 2023-11-27 18:42:49 -08:00
bjorn 3351f473f2 Rework boot process; 2023-11-27 18:42:49 -08:00
bjorn 9d55a5b222 boot.lua sets source instead of filesystem module; 2023-11-27 18:42:49 -08:00
bjorn a1309cfe87 Minor boot.lua refactors; 2023-11-27 18:42:49 -08:00
bjorn 703e9d3c36 boot.lua stores lovr in local; 2023-11-27 18:42:49 -08:00
bjorn 275b63a731 Change offset to seated in default conf;
This was innocuous, but incorrect.
2023-11-21 13:02:01 -08:00
bjorn ce4e07db1b Revert removal of lovr.graphics.initialize;
I forgot that graphics also needs to be initialized after headset,
otherwise the XR_KHR_vulkan_enable2 callbacks won't exist yet. Boo
2023-11-09 13:31:56 -08:00
bjorn 8d58ad8533 errhand doesn't use lovr.graphics.isInitialized; 2023-11-06 15:52:44 -08:00
bjorn 8ed5572b0e rm lovr.graphics.initialize/isInitialized;
This only existed because the graphics module had to know about the
window during initialization, but this is no longer the case.
2023-11-03 15:53:33 -07:00
bjorn 6a83ef9678 Fix lovr.quit to not get called twice when aborting quit; 2023-10-18 12:58:49 -07:00
bjorn 1d6f3afc34 v0.17.0; 2023-10-14 19:36:19 -07:00
bjorn 0fcbdcbf5d Fixup overlay order;
- state.features.overlay should remain a bool since it just indicates
  whether the extension is supported/enabled.
- split the config value into a bool/u32 pair so the full u32 range can
  be used for the order (seems important to coordinate with other apps).
  - Also you can use a boolean now like before, which uses 0 as the order.
2023-08-21 15:15:39 -07:00
Bjorn f8f9c833b1
Merge branch 'dev' into master 2023-08-21 14:59:53 -07:00
BabbleBones 6fbfc16f7d feat: overlay layers 2023-08-18 11:30:58 -04:00
bjorn 2e6f95f06a Fix errhand when headset module is disabled; 2023-07-17 00:10:02 -07:00
xiejiangzhi 8542624895 Fix boot.lua without math.globals 2023-07-17 10:11:22 +08:00
bjorn a723ec7c5c Update error screen;
The error screen uses an orthographic projection when rendered in a
window, so the text is always the same size instead of scaling with the
window size.

Also you can close it with escape.
2023-05-12 17:16:22 +01:00
bjorn 61fe0f3bc0 Default errhand uses transparent background in AR; 2023-05-12 14:31:31 +01:00
bjorn 264bfdeadf Use lovr.system.pollEvents in lovr.errhand; 2023-05-10 18:14:09 +01:00
bjorn da107f4387 Rename lovr.event.pump to lovr.system.pollEvents; 2023-05-10 18:14:09 +01:00
bjorn 43e796acd1 Fix --graphics-debug; 2023-05-03 23:08:45 -07:00
bjorn c717670a80 Add --graphics-debug command line argument; 2023-05-03 20:54:19 -07:00
bjorn 452ee5c7c6 Pass rework;
Pass stores draw commands rather than sending them to Vulkan
immediately.

The main motivation is to allow more flexibility in the Lua API.  Passes
are now regular objects, aren't invalidated whenever submit is called,
and can cache their draws across multiple frames.  Draws can also be
internally culled, sorted, and batched.

Some API methods (tallies) are missing, and there are still some bugs to
fix, notably with background color.
2023-05-02 00:06:01 -07:00
bjorn fe353ea243 Fix default lovr.log printing gsub result; 2022-12-30 21:40:27 -08:00
bjorn f9d7742dfd Add support for headless headset rendering;
Although the name is unfortunate, this allows access to lovr.headset
when no window is opened or when the graphics module is disabled.  This
requires the XR_MND_headless extension to be supported by the runtime.
2022-11-26 14:40:39 -08:00
bjorn 9783140725 Fix window resize; 2022-11-09 19:05:01 -08:00
bjorn 36e1471cf0 lovr.graphics.isInitialized;
Returns whether the graphics module is initialized.  Used by the default
error handler to know if it's safe to try to render the error screen.
2022-11-07 19:12:11 -08:00
bjorn 904fb282c2 v0.16.0; 2022-10-15 21:49:25 -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 f4f95a64d7 Pass blends by default; 2022-08-25 22:01:12 -07:00
bjorn ede1036694 Temporary Passes;
Sigh, back to getPass.  I don't even know at this point.  Basically now
that we came up with a half-solution for temp buffers, it makes sense to
apply this to passes as well, since we aren't going with the workstream
idea and temp passes are more convenient than retained passes.
2022-08-25 21:57:15 -07:00
bjorn 5799b0effb Rename setBackground back to setBackgroundColor;
The "fancy background" idea won't go here.
2022-08-13 21:10:58 -07:00
bjorn 3cbf85c98a Adjust error screen font size and default perspective; 2022-08-12 21:08:25 -07:00
bjorn 23932c6e7c Default errhand stops audio playback; 2022-08-12 20:46:59 -07:00
bjorn 016d3753d5 Further boot.lua cleanup; 2022-08-12 20:32:45 -07:00
bjorn ad6360d2fd Clean up boot.lua;
A lot of clean up can happen now that C doesn't push delayed errors to
Lua.  This was happening for Pico and WebVR, neither of which are used
anymore.

Also default vsync to true but force it off if VR is active.
2022-08-12 20:18:55 -07:00
bjorn 5324ae9a84 Fix error screen; 2022-08-12 19:28:25 -07:00