SDL3 support

This commit is contained in:
alex committed 2024-08-03 23:28:29 -07:00
1 parent ca3957398d
commit 50f4f02f85
8 files changed
+26 -4

No files matched your search

+1 -1
View File
@@ -1,2 +1,2 @@
add_executable(SwiftFrontend main.swift)
target_link_libraries(SwiftFrontend PRIVATE CppBackend)
target_link_libraries(SwiftFrontend PRIVATE CppBackend SDL3)
+8 -3
View File
@@ -1,4 +1,9 @@
import CppBackend
import Foundation
import SDL3
backend_init()
print("Hello World")
guard SDL_Init(SDL_INIT_VIDEO) >= 0 else {
print("SDL init failed.")
exit(0)
}
print("SDL init success.")
SDL_Quit()