From add0b882481e3da910607947a39df44572e88b26 Mon Sep 17 00:00:00 2001 From: ecker Date: Sun, 10 Aug 2025 19:07:57 -0500 Subject: [PATCH] re-added libext.dll being compiled separately (to serve as a way to segregate non-engine into here) --- Makefile | 2 +- client/main.cpp | 14 +++++++------- engine/inc/uf/engine/graph/mesh.inl | 24 ++++++++++++------------ ext/main.cpp | 15 +++++++++++++++ 4 files changed, 35 insertions(+), 20 deletions(-) create mode 100644 ext/main.cpp diff --git a/Makefile b/Makefile index 9ddac9eb..461d0deb 100644 --- a/Makefile +++ b/Makefile @@ -245,7 +245,7 @@ ifneq (,$(findstring xz,$(REQ_DEPS))) DEPS += -lxz -llzma endif -SRCS_DLL := $(shell find $(ENGINE_SRC_DIR) -name "*.cpp") $(shell find $(EXT_SRC_DIR) -name "*.cpp") $(shell find $(DEP_SRC_DIR) -name "*.cpp") +SRCS_DLL := $(shell find $(ENGINE_SRC_DIR) -name "*.cpp") $(shell find $(DEP_SRC_DIR) -name "*.cpp") OBJS_DLL += $(patsubst %.cpp,%.$(PREFIX).o,$(SRCS_DLL)) BASE_DLL += lib$(LIB_NAME) IM_DLL += $(ENGINE_LIB_DIR)/$(PREFIX_PATH)/$(BASE_DLL).$(TARGET_LIB_EXTENSION).a diff --git a/client/main.cpp b/client/main.cpp index 3225cf3c..b3c74bd9 100644 --- a/client/main.cpp +++ b/client/main.cpp @@ -36,7 +36,7 @@ namespace { client::terminated = true; - //ext::terminate(); + ext::terminate(); uf::terminate(); client::terminate(); } @@ -85,7 +85,7 @@ int main(int argc, char** argv){ signal(SIGSEGV, ::handlers::segv); client::initialize(); - //ext::initialize(); + ext::initialize(); uf::initialize(); // For Multithreaded initialization @@ -109,22 +109,22 @@ int main(int argc, char** argv){ // auto& thread = uf::thread::fetchWorker(); auto& thread = uf::thread::get("Render"); uf::thread::queue(thread, [&]{ - //ext::render(); + ext::render(); uf::render(); client::render(); }); client::tick(); - //ext::tick(); + ext::tick(); uf::tick(); uf::thread::wait( thread ); } else { client::tick(); uf::tick(); - //ext::tick(); + ext::tick(); - //ext::render(); + ext::render(); uf::render(); client::render(); } @@ -149,7 +149,7 @@ int main(int argc, char** argv){ if ( !client::terminated ) { client::terminated = true; UF_MSG_INFO("Natural termination!"); - //ext::terminate(); + ext::terminate(); uf::terminate(); client::terminate(); } diff --git a/engine/inc/uf/engine/graph/mesh.inl b/engine/inc/uf/engine/graph/mesh.inl index eef6733d..e7964d94 100644 --- a/engine/inc/uf/engine/graph/mesh.inl +++ b/engine/inc/uf/engine/graph/mesh.inl @@ -10,8 +10,8 @@ namespace uf { pod::Vector3f tangent{}; pod::Vector id{}; - static UF_API uf::stl::vector descriptor; - static UF_API Base interpolate( const Base& p1, const Base& p2, float t ) { + static uf::stl::vector descriptor; + static Base interpolate( const Base& p1, const Base& p2, float t ) { return { uf::vector::lerp( p1.position, p2.position, t ), uf::vector::lerp( p1.uv, p2.uv, t ), @@ -36,8 +36,8 @@ namespace uf { pod::Vector joints{}; pod::Vector4f weights{}; - static UF_API uf::stl::vector descriptor; - static UF_API Skinned interpolate( const Skinned& p1, const Skinned& p2, float t ) { + static uf::stl::vector descriptor; + static Skinned interpolate( const Skinned& p1, const Skinned& p2, float t ) { return { uf::vector::lerp( p1.position, p2.position, t ), uf::vector::lerp( p1.uv, p2.uv, t ), @@ -64,8 +64,8 @@ namespace uf { pod::Vector3f16 tangent{}; pod::Vector id{}; - static UF_API uf::stl::vector descriptor; - static UF_API Base_16f interpolate( const Base_16f& p1, const Base_16f& p2, float t ) { + static uf::stl::vector descriptor; + static Base_16f interpolate( const Base_16f& p1, const Base_16f& p2, float t ) { return t < 0.5 ? p1 : p2; /* return { @@ -91,8 +91,8 @@ namespace uf { pod::Vector joints{}; pod::Vector3f16 weights{}; - static UF_API uf::stl::vector descriptor; - static UF_API Skinned_16f interpolate( const Skinned_16f& p1, const Skinned_16f& p2, float t ) { + static uf::stl::vector descriptor; + static Skinned_16f interpolate( const Skinned_16f& p1, const Skinned_16f& p2, float t ) { return t < 0.5 ? p1 : p2; /* return { @@ -119,8 +119,8 @@ namespace uf { pod::Vector tangent{}; pod::Vector id{}; - static UF_API uf::stl::vector descriptor; - static UF_API Base_u16q interpolate( const Base_u16q& p1, const Base_u16q& p2, float t ) { + static uf::stl::vector descriptor; + static Base_u16q interpolate( const Base_u16q& p1, const Base_u16q& p2, float t ) { return t < 0.5 ? p1 : p2; /* return { @@ -146,8 +146,8 @@ namespace uf { pod::Vector joints{}; pod::Vector weights{}; - static UF_API uf::stl::vector descriptor; - static UF_API Skinned_u16q interpolate( const Skinned_u16q& p1, const Skinned_u16q& p2, float t ) { + static uf::stl::vector descriptor; + static Skinned_u16q interpolate( const Skinned_u16q& p1, const Skinned_u16q& p2, float t ) { return t < 0.5 ? p1 : p2; /* return { diff --git a/ext/main.cpp b/ext/main.cpp new file mode 100644 index 00000000..f88edd76 --- /dev/null +++ b/ext/main.cpp @@ -0,0 +1,15 @@ +#include +#include + +void EXT_API ext::initialize() { + +} +void EXT_API ext::tick() { + +} +void EXT_API ext::render() { + +} +void EXT_API ext::terminate() { + +} \ No newline at end of file