mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-22 09:19:03 +00:00
Everywhere: Remove GPU painter and AccelGfx
GPU painter that uses AccelGfx is slower and way less complete compared to both default Gfx::Painter and Skia painter. It does not make much sense to keep it, considering Skia painter already uses Metal backend on macOS by default and there is an option to enable GPU-accelerated backend on linux.
This commit is contained in:
committed by
Andreas Kling
parent
9dd14c6a7f
commit
830b287c46
@@ -1,19 +0,0 @@
|
||||
if (NOT ENABLE_ACCELERATED_GRAPHICS OR EMSCRIPTEN)
|
||||
# FIXME: Enable GL emulation in emscripten: https://emscripten.org/docs/porting/multimedia_and_graphics/OpenGL-support.html
|
||||
set(HAS_ACCELERATED_GRAPHICS OFF CACHE BOOL "" FORCE)
|
||||
return()
|
||||
endif()
|
||||
|
||||
if (APPLE AND NOT IOS)
|
||||
set(HAS_ACCELERATED_GRAPHICS ON CACHE BOOL "" FORCE)
|
||||
set(ACCEL_GFX_LIBS "-framework OpenGL" CACHE STRING "" FORCE)
|
||||
else()
|
||||
find_package(OpenGL QUIET COMPONENTS OpenGL EGL)
|
||||
|
||||
if (OPENGL_FOUND)
|
||||
set(HAS_ACCELERATED_GRAPHICS ON CACHE BOOL "" FORCE)
|
||||
set(ACCEL_GFX_LIBS OpenGL::OpenGL OpenGL::EGL CACHE STRING "" FORCE)
|
||||
else()
|
||||
set(HAS_ACCELERATED_GRAPHICS OFF CACHE BOOL "" FORCE)
|
||||
endif()
|
||||
endif()
|
||||
@@ -20,7 +20,6 @@ serenity_option(ENABLE_PUBLIC_SUFFIX_DOWNLOAD ON CACHE BOOL "Enable download of
|
||||
serenity_option(INCLUDE_WASM_SPEC_TESTS OFF CACHE BOOL "Download and include the WebAssembly spec testsuite")
|
||||
serenity_option(INCLUDE_FLAC_SPEC_TESTS OFF CACHE BOOL "Download and include the FLAC spec testsuite")
|
||||
serenity_option(ENABLE_CACERT_DOWNLOAD ON CACHE BOOL "Enable download of cacert.pem at build time")
|
||||
serenity_option(ENABLE_ACCELERATED_GRAPHICS ON CACHE BOOL "Enable use of accelerated graphics APIs")
|
||||
|
||||
serenity_option(SERENITY_CACHE_DIR "${PROJECT_BINARY_DIR}/../caches" CACHE PATH "Location of shared cache of downloaded files")
|
||||
serenity_option(ENABLE_NETWORK_DOWNLOADS ON CACHE BOOL "Allow downloads of required files. If OFF, required files must already be present in SERENITY_CACHE_DIR")
|
||||
|
||||
@@ -384,7 +384,6 @@ endif()
|
||||
|
||||
# Lagom Libraries
|
||||
set(lagom_standard_libraries
|
||||
AccelGfx
|
||||
Archive
|
||||
Audio
|
||||
Compress
|
||||
|
||||
@@ -359,7 +359,6 @@ if (current_os != "mac") {
|
||||
bundle_data("ladybird_bundle_libs") {
|
||||
public_deps = [
|
||||
"//AK",
|
||||
"//Userland/Libraries/LibAccelGfx",
|
||||
"//Userland/Libraries/LibAudio",
|
||||
"//Userland/Libraries/LibCompress",
|
||||
"//Userland/Libraries/LibCore",
|
||||
@@ -389,7 +388,6 @@ if (current_os != "mac") {
|
||||
"//Userland/Libraries/LibXML",
|
||||
]
|
||||
sources = [
|
||||
"$root_out_dir/lib/liblagom-accelgfx.dylib",
|
||||
"$root_out_dir/lib/liblagom-ak.dylib",
|
||||
"$root_out_dir/lib/liblagom-audio.dylib",
|
||||
"$root_out_dir/lib/liblagom-compress.dylib",
|
||||
|
||||
@@ -94,9 +94,5 @@ executable("WebContent") {
|
||||
deps += [ ":generate_moc" ]
|
||||
}
|
||||
|
||||
if (current_os == "linux" || current_os == "mac") {
|
||||
cflags_cc = [ "-DHAS_ACCELERATED_GRAPHICS" ]
|
||||
deps += [ "//Userland/Libraries/LibAccelGfx" ]
|
||||
}
|
||||
output_dir = "$root_out_dir/libexec"
|
||||
}
|
||||
|
||||
@@ -1,33 +0,0 @@
|
||||
shared_library("LibAccelGfx") {
|
||||
output_name = "accelgfx"
|
||||
include_dirs = [ "//Userland/Libraries" ]
|
||||
|
||||
deps = [
|
||||
"//AK",
|
||||
"//Userland/Libraries/LibCore",
|
||||
"//Userland/Libraries/LibGfx",
|
||||
]
|
||||
|
||||
if (current_os == "linux") {
|
||||
libs = [
|
||||
"GL",
|
||||
"EGL",
|
||||
]
|
||||
} else if (current_os == "mac") {
|
||||
frameworks = [ "OpenGL.framework" ]
|
||||
}
|
||||
|
||||
sources = [
|
||||
"Canvas.h",
|
||||
"Context.cpp",
|
||||
"Context.h",
|
||||
"Forward.h",
|
||||
"GL.cpp",
|
||||
"GL.h",
|
||||
"GlyphAtlas.cpp",
|
||||
"Painter.cpp",
|
||||
"Painter.h",
|
||||
"Program.cpp",
|
||||
"Program.h",
|
||||
]
|
||||
}
|
||||
@@ -46,9 +46,4 @@ source_set("Painting") {
|
||||
"VideoPaintable.cpp",
|
||||
"ViewportPaintable.cpp",
|
||||
]
|
||||
|
||||
if (current_os == "linux" || current_os == "mac") {
|
||||
sources += [ "DisplayListPlayerGPU.cpp" ]
|
||||
public_deps = [ "//Userland/Libraries/LibAccelGfx" ]
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user