Browse Source

Only enable effects sample with supported backends

Michael Ragazzon 1 năm trước cách đây
mục cha
commit
8fe85b55b3

+ 1 - 1
Samples/basic/CMakeLists.txt

@@ -17,7 +17,7 @@ if(RMLUI_FONT_ENGINE_ENABLED)
 	if(RMLUI_HARFBUZZ_SAMPLE)
 	if(RMLUI_HARFBUZZ_SAMPLE)
 		add_subdirectory("harfbuzz")
 		add_subdirectory("harfbuzz")
 	else()
 	else()
-		message(STATUS "Harfbuzz sample disabled due to RMLUI_HARFBUZZ_SAMPLE=OFF")
+		message(STATUS "HarfBuzz sample disabled due to RMLUI_HARFBUZZ_SAMPLE=OFF")
 	endif()
 	endif()
 	if(RMLUI_LOTTIE_PLUGIN)
 	if(RMLUI_LOTTIE_PLUGIN)
 		add_subdirectory("lottie")
 		add_subdirectory("lottie")

+ 5 - 0
Samples/basic/effects/CMakeLists.txt

@@ -1,3 +1,8 @@
+if(NOT RMLUI_BACKEND MATCHES "GL3$")
+	message(STATUS "Effects sample disabled - only available on GL3 backends")
+	return()
+endif()
+
 set(SAMPLE_NAME "effects")
 set(SAMPLE_NAME "effects")
 set(TARGET_NAME "${RMLUI_SAMPLE_PREFIX}${SAMPLE_NAME}")
 set(TARGET_NAME "${RMLUI_SAMPLE_PREFIX}${SAMPLE_NAME}")
 
 

+ 2 - 1
Samples/readme.md

@@ -19,7 +19,8 @@ This directory contains basic applications that demonstrate initialisation, usag
 -  `data_binding`  Setting up and using data bindings.
 -  `data_binding`  Setting up and using data bindings.
 -  `demo`  Demonstrates a variety of features in RmlUi and includes a sandbox for playing with RML/RCSS.
 -  `demo`  Demonstrates a variety of features in RmlUi and includes a sandbox for playing with RML/RCSS.
 -  `drag`  Dragging elements between containers.
 -  `drag`  Dragging elements between containers.
--  `harfbuzz`  Advanced text shaping, only enabled when [HarfBuzz](https://harfbuzz.github.io/) is enabled .
+- `effects` Advanced rendering effects, including filters, gradients and box shadows. Only enabled with supported backends.
+-  `harfbuzz`  Advanced text shaping. Only enabled when [HarfBuzz](https://harfbuzz.github.io/) is enabled.
 -  `load_document`  Loading your first document.
 -  `load_document`  Loading your first document.
 -  `lottie`  Playing Lottie animations, only enabled with the [Lottie plugin](https://mikke89.github.io/RmlUiDoc/pages/cpp_manual/lottie.html).
 -  `lottie`  Playing Lottie animations, only enabled with the [Lottie plugin](https://mikke89.github.io/RmlUiDoc/pages/cpp_manual/lottie.html).
 -  `svg`  Render SVG images, only enabled with the [SVG plugin](https://mikke89.github.io/RmlUiDoc/pages/cpp_manual/svg.html).
 -  `svg`  Render SVG images, only enabled with the [SVG plugin](https://mikke89.github.io/RmlUiDoc/pages/cpp_manual/svg.html).