refactor Windows classes to separate EGL/WGL/Backing Window

This commit is contained in:
Nick Fisher
2023-10-25 13:11:58 +11:00
parent c4245b0dd3
commit 8cea106b30
18 changed files with 972 additions and 996 deletions

View File

@@ -22,16 +22,22 @@ list(APPEND PLUGIN_SOURCES
"${CMAKE_CURRENT_SOURCE_DIR}/../ios/src/camutils/Bookmark.cpp"
)
set(USE_ANGLE TRUE)
set(USE_ANGLE FALSE)
if(!USE_ANGLE)
set(WGL_USE_BACKING_WINDOW TRUE)
endif()
if(USE_ANGLE)
add_compile_definitions(USE_ANGLE)
list(APPEND PLUGIN_SOURCES
# "PlatformAngle.cpp"
"flutter_angle_texture.cpp"
)
list(APPEND PLUGIN_SOURCES "flutter_angle_texture.cpp" "egl_context.cpp" )
else()
list(APPEND PLUGIN_SOURCES "opengl_texture_buffer.cpp")
list(APPEND PLUGIN_SOURCES "wgl_context.cpp")
if(WGL_USE_BACKING_WINDOW)
list(APPEND PLUGIN_SOURCES "utils.cc" "backing_window.cpp")
else()
list(APPEND PLUGIN_SOURCES "opengl_texture_buffer.cpp")
endif()
endif()
# Define the plugin library target. Its name must not be changed (see comment
@@ -74,9 +80,9 @@ if(USE_ANGLE)
else()
list(APPEND GL_LIBS
bluegl
# bluevk
# vkshaders
opengl32
dwmapi
comctl32
)
set(ANGLE_OR_OPENGL_DIR opengl)
add_library(bluegl SHARED IMPORTED)