diff --git a/src/play_clj/core_utils.clj b/src/play_clj/core_utils.clj index 8c5c336..73383ec 100644 --- a/src/play_clj/core_utils.clj +++ b/src/play_clj/core_utils.clj @@ -1,5 +1,12 @@ (in-ns 'play-clj.core) +(defmacro on-gl + "Runs the macro body on the GL thread. + + (on-gl (set-screen! hello-world main-screen))" + [& body] + `(app! :post-runnable (fn [] ~@body))) + ; static fields (defmacro scaling