summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorVasco <[email protected]>2026-08-24 18:19:47 +0100
committerVasco <[email protected]>2026-08-24 18:21:55 +0100
commit5cdccf5559729b1abfbb097fca0eb0f22965704c (patch)
tree71177780e970b0fbc9b0e94615d40de15c46cbda
parentcc3429220b19df8c5ca6abf28a02cd38d08de32d (diff)
Peak 0.5.3main
-rw-r--r--Peak/peak.h7
-rw-r--r--Peak/src/p_linux.c4
-rw-r--r--Peak/src/peak_header.h.out7
-rwxr-xr-xdemos/teapot/rend_teapotbin845880 -> 845904 bytes
-rw-r--r--demos/teapot/rend_teapot.c2
5 files changed, 14 insertions, 6 deletions
diff --git a/Peak/peak.h b/Peak/peak.h
index f5cc83b..4ac857b 100644
--- a/Peak/peak.h
+++ b/Peak/peak.h
@@ -11,7 +11,7 @@
#define PEAK_MAJOR "0"
#define PEAK_MINOR "5"
-#define PEAK_PATCH "2"
+#define PEAK_PATCH "3"
/* CHANGE LOG
* 0.0.0 - @vasco - prototyping
@@ -24,6 +24,7 @@
* 0.5.0 - @vasco - audio start/stop, s16le pull callback
* 0.5.1 - @vasco - log, file, time, vulkan extensions
* 0.5.2 - @vasco - vulkan surface from window
+ * 0.5.3 - @vasco - skip XCloseDisplay after vulkan teardown
*/
#define NANOS_PER_SEC 1000000000ull
@@ -1145,9 +1146,11 @@ peak_platform_init(void)
static void
peak_platform_quit(void)
{
+ /* NOTE: NVIDIA's Vulkan ICD registers an XCloseDisplay hook, then
+ * vkDestroyInstance unloads the ICD. Closing afterwards is a SIGSEGV
+ * into unmapped memory. The connection is dropped on process exit. */
if (!peak_linux.display)
return;
- peak_x11.XCloseDisplay(peak_linux.display);
peak_linux.display = 0;
}
diff --git a/Peak/src/p_linux.c b/Peak/src/p_linux.c
index 9090b46..a93c236 100644
--- a/Peak/src/p_linux.c
+++ b/Peak/src/p_linux.c
@@ -199,9 +199,11 @@ peak_platform_init(void)
static void
peak_platform_quit(void)
{
+ /* NOTE: NVIDIA's Vulkan ICD registers an XCloseDisplay hook, then
+ * vkDestroyInstance unloads the ICD. Closing afterwards is a SIGSEGV
+ * into unmapped memory. The connection is dropped on process exit. */
if (!peak_linux.display)
return;
- peak_x11.XCloseDisplay(peak_linux.display);
peak_linux.display = 0;
}
diff --git a/Peak/src/peak_header.h.out b/Peak/src/peak_header.h.out
index f5cc83b..4ac857b 100644
--- a/Peak/src/peak_header.h.out
+++ b/Peak/src/peak_header.h.out
@@ -11,7 +11,7 @@
#define PEAK_MAJOR "0"
#define PEAK_MINOR "5"
-#define PEAK_PATCH "2"
+#define PEAK_PATCH "3"
/* CHANGE LOG
* 0.0.0 - @vasco - prototyping
@@ -24,6 +24,7 @@
* 0.5.0 - @vasco - audio start/stop, s16le pull callback
* 0.5.1 - @vasco - log, file, time, vulkan extensions
* 0.5.2 - @vasco - vulkan surface from window
+ * 0.5.3 - @vasco - skip XCloseDisplay after vulkan teardown
*/
#define NANOS_PER_SEC 1000000000ull
@@ -1145,9 +1146,11 @@ peak_platform_init(void)
static void
peak_platform_quit(void)
{
+ /* NOTE: NVIDIA's Vulkan ICD registers an XCloseDisplay hook, then
+ * vkDestroyInstance unloads the ICD. Closing afterwards is a SIGSEGV
+ * into unmapped memory. The connection is dropped on process exit. */
if (!peak_linux.display)
return;
- peak_x11.XCloseDisplay(peak_linux.display);
peak_linux.display = 0;
}
diff --git a/demos/teapot/rend_teapot b/demos/teapot/rend_teapot
index f9a4bb9..7cd6a11 100755
--- a/demos/teapot/rend_teapot
+++ b/demos/teapot/rend_teapot
Binary files differ
diff --git a/demos/teapot/rend_teapot.c b/demos/teapot/rend_teapot.c
index b4430e9..be102db 100644
--- a/demos/teapot/rend_teapot.c
+++ b/demos/teapot/rend_teapot.c
@@ -233,10 +233,10 @@ int main() {
rend_buffer_destroy(&vert_buf);
rend_buffer_destroy(&ind_buf);
rend_renderer_destroy(renderer);
- rend_quit();
peak_window_close(&win);
peak_quit();
+ rend_quit();
return 0;
}