From 5594a64c2ac73e0596ab1ada9d6250a445890724 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Vondru=C5=A1?= Date: Tue, 6 Oct 2020 13:06:17 +0200 Subject: [PATCH] python: add new clip distance features to gl.Renderer. --- doc/python/pages/changelog.rst | 2 ++ src/python/magnum/gl.cpp | 10 ++++++++++ 2 files changed, 12 insertions(+) diff --git a/doc/python/pages/changelog.rst b/doc/python/pages/changelog.rst index 6511ebe..b9beb35 100644 --- a/doc/python/pages/changelog.rst +++ b/doc/python/pages/changelog.rst @@ -37,6 +37,8 @@ Changelog - Exposed :ref:`gl.Renderer.set_blend_function()`, :ref:`gl.Renderer.set_blend_equation()` and related enums (:gh:`mosra/magnum-bindings#9`) +- Exposed :ref:`gl.Renderer.Feature.CLIP_DISTANCEn ` + values that are new since 2020.06 - Renamed all helper ``Python.h`` headers to ``PythonBindings.h`` to avoid issues with shitty IDE indexers such as Eclipse, confusing these with Python's ```` diff --git a/src/python/magnum/gl.cpp b/src/python/magnum/gl.cpp index 8d3cafd..77a4719 100644 --- a/src/python/magnum/gl.cpp +++ b/src/python/magnum/gl.cpp @@ -847,6 +847,16 @@ void gl(py::module& m) { .value("BLEND_ADVANCED_COHERENT", GL::Renderer::Feature::BlendAdvancedCoherent) #endif .value("BLENDING", GL::Renderer::Feature::Blending) + #if !(defined(MAGNUM_TARGET_GLES2) && defined(MAGNUM_TARGET_WEBGL)) + .value("CLIP_DISTANCE0", GL::Renderer::Feature::ClipDistance0) + .value("CLIP_DISTANCE1", GL::Renderer::Feature::ClipDistance1) + .value("CLIP_DISTANCE2", GL::Renderer::Feature::ClipDistance2) + .value("CLIP_DISTANCE3", GL::Renderer::Feature::ClipDistance3) + .value("CLIP_DISTANCE4", GL::Renderer::Feature::ClipDistance4) + .value("CLIP_DISTANCE5", GL::Renderer::Feature::ClipDistance5) + .value("CLIP_DISTANCE6", GL::Renderer::Feature::ClipDistance6) + .value("CLIP_DISTANCE7", GL::Renderer::Feature::ClipDistance7) + #endif #ifndef MAGNUM_TARGET_WEBGL .value("DEBUG_OUTPUT", GL::Renderer::Feature::DebugOutput) .value("DEBUG_OUTPUT_SYNCHRONOUS", GL::Renderer::Feature::DebugOutputSynchronous)