// WARNING: Please don't edit this file. It was generated by Python/WinRT v1.0.0-beta.2

#include "pybase.h"
#include "py.Windows.Graphics.Display.h"

PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::AdvancedColorInfo>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::BrightnessOverride>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::BrightnessOverrideSettings>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::ColorOverrideSettings>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverride>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayInformation>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayProperties>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::DisplayServices>::python_type;
PyTypeObject* py::winrt_type<winrt::Windows::Graphics::Display::NitRange>::python_type;

PyObject* py::converter<winrt::Windows::Graphics::Display::NitRange>::convert(winrt::Windows::Graphics::Display::NitRange instance) noexcept
{
    return py::wrap_struct(instance, py::get_python_type<winrt::Windows::Graphics::Display::NitRange>());
}
winrt::Windows::Graphics::Display::NitRange py::converter<winrt::Windows::Graphics::Display::NitRange>::convert_to(PyObject* obj)
{
    throw_if_pyobj_null(obj);

    if (Py_TYPE(obj) == py::get_python_type<winrt::Windows::Graphics::Display::NitRange>())
    {
        return reinterpret_cast<py::winrt_struct_wrapper<winrt::Windows::Graphics::Display::NitRange>*>(obj)->obj;
    }

    if (!PyDict_Check(obj))
    {
        throw winrt::hresult_invalid_argument();
    }

    winrt::Windows::Graphics::Display::NitRange return_value{};

    PyObject* py_MinNits = PyDict_GetItemString(obj, "min_nits");
    if (!py_MinNits) { throw winrt::hresult_invalid_argument(); }
    return_value.MinNits = converter<float>::convert_to(py_MinNits);

    PyObject* py_MaxNits = PyDict_GetItemString(obj, "max_nits");
    if (!py_MaxNits) { throw winrt::hresult_invalid_argument(); }
    return_value.MaxNits = converter<float>::convert_to(py_MaxNits);

    PyObject* py_StepSizeNits = PyDict_GetItemString(obj, "step_size_nits");
    if (!py_StepSizeNits) { throw winrt::hresult_invalid_argument(); }
    return_value.StepSizeNits = converter<float>::convert_to(py_StepSizeNits);

    return return_value;
}

namespace py::cpp::Windows::Graphics::Display
{
    // ----- AdvancedColorInfo class --------------------
    constexpr const char* const _type_name_AdvancedColorInfo = "AdvancedColorInfo";

    static PyObject* _new_AdvancedColorInfo(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_AdvancedColorInfo);
        return nullptr;
    }

    static void _dealloc_AdvancedColorInfo(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* AdvancedColorInfo_IsAdvancedColorKindAvailable(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::AdvancedColorKind>(args, 0);

                return py::convert(self->obj.IsAdvancedColorKindAvailable(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_IsHdrMetadataFormatCurrentlySupported(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::HdrMetadataFormat>(args, 0);

                return py::convert(self->obj.IsHdrMetadataFormatCurrentlySupported(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_BluePrimary(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.BluePrimary());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_CurrentAdvancedColorKind(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CurrentAdvancedColorKind());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_GreenPrimary(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.GreenPrimary());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_MaxAverageFullFrameLuminanceInNits(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaxAverageFullFrameLuminanceInNits());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_MaxLuminanceInNits(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaxLuminanceInNits());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_MinLuminanceInNits(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MinLuminanceInNits());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_RedPrimary(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.RedPrimary());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_SdrWhiteLevelInNits(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.SdrWhiteLevelInNits());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* AdvancedColorInfo_get_WhitePoint(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.WhitePoint());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_AdvancedColorInfo(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::AdvancedColorInfo>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_AdvancedColorInfo[] = {
        { "is_advanced_color_kind_available", reinterpret_cast<PyCFunction>(AdvancedColorInfo_IsAdvancedColorKindAvailable), METH_VARARGS, nullptr },
        { "is_hdr_metadata_format_currently_supported", reinterpret_cast<PyCFunction>(AdvancedColorInfo_IsHdrMetadataFormatCurrentlySupported), METH_VARARGS, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_AdvancedColorInfo), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_AdvancedColorInfo[] = {
        { "blue_primary", reinterpret_cast<getter>(AdvancedColorInfo_get_BluePrimary), nullptr, nullptr, nullptr },
        { "current_advanced_color_kind", reinterpret_cast<getter>(AdvancedColorInfo_get_CurrentAdvancedColorKind), nullptr, nullptr, nullptr },
        { "green_primary", reinterpret_cast<getter>(AdvancedColorInfo_get_GreenPrimary), nullptr, nullptr, nullptr },
        { "max_average_full_frame_luminance_in_nits", reinterpret_cast<getter>(AdvancedColorInfo_get_MaxAverageFullFrameLuminanceInNits), nullptr, nullptr, nullptr },
        { "max_luminance_in_nits", reinterpret_cast<getter>(AdvancedColorInfo_get_MaxLuminanceInNits), nullptr, nullptr, nullptr },
        { "min_luminance_in_nits", reinterpret_cast<getter>(AdvancedColorInfo_get_MinLuminanceInNits), nullptr, nullptr, nullptr },
        { "red_primary", reinterpret_cast<getter>(AdvancedColorInfo_get_RedPrimary), nullptr, nullptr, nullptr },
        { "sdr_white_level_in_nits", reinterpret_cast<getter>(AdvancedColorInfo_get_SdrWhiteLevelInNits), nullptr, nullptr, nullptr },
        { "white_point", reinterpret_cast<getter>(AdvancedColorInfo_get_WhitePoint), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_AdvancedColorInfo[] = 
    {
        { Py_tp_new, _new_AdvancedColorInfo },
        { Py_tp_dealloc, _dealloc_AdvancedColorInfo },
        { Py_tp_methods, _methods_AdvancedColorInfo },
        { Py_tp_getset, _getset_AdvancedColorInfo },
        { },
    };

    static PyType_Spec _type_spec_AdvancedColorInfo =
    {
        "_winsdk_Windows_Graphics_Display.AdvancedColorInfo",
        sizeof(py::wrapper::Windows::Graphics::Display::AdvancedColorInfo),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_AdvancedColorInfo
    };

    // ----- BrightnessOverride class --------------------
    constexpr const char* const _type_name_BrightnessOverride = "BrightnessOverride";

    static PyObject* _new_BrightnessOverride(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_BrightnessOverride);
        return nullptr;
    }

    static void _dealloc_BrightnessOverride(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* BrightnessOverride_GetDefaultForSystem(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverride::GetDefaultForSystem());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_GetForCurrentView(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverride::GetForCurrentView());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_GetLevelForScenario(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayBrightnessScenario>(args, 0);

                return py::convert(self->obj.GetLevelForScenario(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_SaveForSystemAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::BrightnessOverride>(args, 0);

                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverride::SaveForSystemAsync(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_SetBrightnessLevel(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<double>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Graphics::Display::DisplayBrightnessOverrideOptions>(args, 1);

                self->obj.SetBrightnessLevel(param0, param1);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_SetBrightnessScenario(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 2)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayBrightnessScenario>(args, 0);
                auto param1 = py::convert_to<winrt::Windows::Graphics::Display::DisplayBrightnessOverrideOptions>(args, 1);

                self->obj.SetBrightnessScenario(param0, param1);
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_StartOverride(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.StartOverride();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_StopOverride(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.StopOverride();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_get_BrightnessLevel(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.BrightnessLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_get_IsOverrideActive(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsOverrideActive());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_get_IsSupported(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsSupported());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_add_BrightnessLevelChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::BrightnessOverride, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.BrightnessLevelChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_remove_BrightnessLevelChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.BrightnessLevelChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_add_IsOverrideActiveChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::BrightnessOverride, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.IsOverrideActiveChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_remove_IsOverrideActiveChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.IsOverrideActiveChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_add_IsSupportedChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::BrightnessOverride, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.IsSupportedChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverride_remove_IsSupportedChanged(py::wrapper::Windows::Graphics::Display::BrightnessOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.IsSupportedChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_BrightnessOverride(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::BrightnessOverride>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_BrightnessOverride[] = {
        { "get_default_for_system", reinterpret_cast<PyCFunction>(BrightnessOverride_GetDefaultForSystem), METH_VARARGS | METH_STATIC, nullptr },
        { "get_for_current_view", reinterpret_cast<PyCFunction>(BrightnessOverride_GetForCurrentView), METH_VARARGS | METH_STATIC, nullptr },
        { "get_level_for_scenario", reinterpret_cast<PyCFunction>(BrightnessOverride_GetLevelForScenario), METH_VARARGS, nullptr },
        { "save_for_system_async", reinterpret_cast<PyCFunction>(BrightnessOverride_SaveForSystemAsync), METH_VARARGS | METH_STATIC, nullptr },
        { "set_brightness_level", reinterpret_cast<PyCFunction>(BrightnessOverride_SetBrightnessLevel), METH_VARARGS, nullptr },
        { "set_brightness_scenario", reinterpret_cast<PyCFunction>(BrightnessOverride_SetBrightnessScenario), METH_VARARGS, nullptr },
        { "start_override", reinterpret_cast<PyCFunction>(BrightnessOverride_StartOverride), METH_VARARGS, nullptr },
        { "stop_override", reinterpret_cast<PyCFunction>(BrightnessOverride_StopOverride), METH_VARARGS, nullptr },
        { "add_brightness_level_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_add_BrightnessLevelChanged), METH_O, nullptr },
        { "remove_brightness_level_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_remove_BrightnessLevelChanged), METH_O, nullptr },
        { "add_is_override_active_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_add_IsOverrideActiveChanged), METH_O, nullptr },
        { "remove_is_override_active_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_remove_IsOverrideActiveChanged), METH_O, nullptr },
        { "add_is_supported_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_add_IsSupportedChanged), METH_O, nullptr },
        { "remove_is_supported_changed", reinterpret_cast<PyCFunction>(BrightnessOverride_remove_IsSupportedChanged), METH_O, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_BrightnessOverride), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_BrightnessOverride[] = {
        { "brightness_level", reinterpret_cast<getter>(BrightnessOverride_get_BrightnessLevel), nullptr, nullptr, nullptr },
        { "is_override_active", reinterpret_cast<getter>(BrightnessOverride_get_IsOverrideActive), nullptr, nullptr, nullptr },
        { "is_supported", reinterpret_cast<getter>(BrightnessOverride_get_IsSupported), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_BrightnessOverride[] = 
    {
        { Py_tp_new, _new_BrightnessOverride },
        { Py_tp_dealloc, _dealloc_BrightnessOverride },
        { Py_tp_methods, _methods_BrightnessOverride },
        { Py_tp_getset, _getset_BrightnessOverride },
        { },
    };

    static PyType_Spec _type_spec_BrightnessOverride =
    {
        "_winsdk_Windows_Graphics_Display.BrightnessOverride",
        sizeof(py::wrapper::Windows::Graphics::Display::BrightnessOverride),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_BrightnessOverride
    };

    // ----- BrightnessOverrideSettings class --------------------
    constexpr const char* const _type_name_BrightnessOverrideSettings = "BrightnessOverrideSettings";

    static PyObject* _new_BrightnessOverrideSettings(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_BrightnessOverrideSettings);
        return nullptr;
    }

    static void _dealloc_BrightnessOverrideSettings(py::wrapper::Windows::Graphics::Display::BrightnessOverrideSettings* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* BrightnessOverrideSettings_CreateFromDisplayBrightnessOverrideScenario(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayBrightnessOverrideScenario>(args, 0);

                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverrideSettings::CreateFromDisplayBrightnessOverrideScenario(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverrideSettings_CreateFromLevel(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<double>(args, 0);

                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverrideSettings::CreateFromLevel(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverrideSettings_CreateFromNits(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<float>(args, 0);

                return py::convert(winrt::Windows::Graphics::Display::BrightnessOverrideSettings::CreateFromNits(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* BrightnessOverrideSettings_get_DesiredLevel(py::wrapper::Windows::Graphics::Display::BrightnessOverrideSettings* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DesiredLevel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* BrightnessOverrideSettings_get_DesiredNits(py::wrapper::Windows::Graphics::Display::BrightnessOverrideSettings* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DesiredNits());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_BrightnessOverrideSettings(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::BrightnessOverrideSettings>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_BrightnessOverrideSettings[] = {
        { "create_from_display_brightness_override_scenario", reinterpret_cast<PyCFunction>(BrightnessOverrideSettings_CreateFromDisplayBrightnessOverrideScenario), METH_VARARGS | METH_STATIC, nullptr },
        { "create_from_level", reinterpret_cast<PyCFunction>(BrightnessOverrideSettings_CreateFromLevel), METH_VARARGS | METH_STATIC, nullptr },
        { "create_from_nits", reinterpret_cast<PyCFunction>(BrightnessOverrideSettings_CreateFromNits), METH_VARARGS | METH_STATIC, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_BrightnessOverrideSettings), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_BrightnessOverrideSettings[] = {
        { "desired_level", reinterpret_cast<getter>(BrightnessOverrideSettings_get_DesiredLevel), nullptr, nullptr, nullptr },
        { "desired_nits", reinterpret_cast<getter>(BrightnessOverrideSettings_get_DesiredNits), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_BrightnessOverrideSettings[] = 
    {
        { Py_tp_new, _new_BrightnessOverrideSettings },
        { Py_tp_dealloc, _dealloc_BrightnessOverrideSettings },
        { Py_tp_methods, _methods_BrightnessOverrideSettings },
        { Py_tp_getset, _getset_BrightnessOverrideSettings },
        { },
    };

    static PyType_Spec _type_spec_BrightnessOverrideSettings =
    {
        "_winsdk_Windows_Graphics_Display.BrightnessOverrideSettings",
        sizeof(py::wrapper::Windows::Graphics::Display::BrightnessOverrideSettings),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_BrightnessOverrideSettings
    };

    // ----- ColorOverrideSettings class --------------------
    constexpr const char* const _type_name_ColorOverrideSettings = "ColorOverrideSettings";

    static PyObject* _new_ColorOverrideSettings(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_ColorOverrideSettings);
        return nullptr;
    }

    static void _dealloc_ColorOverrideSettings(py::wrapper::Windows::Graphics::Display::ColorOverrideSettings* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* ColorOverrideSettings_CreateFromDisplayColorOverrideScenario(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 1)
        {
            try
            {
                auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayColorOverrideScenario>(args, 0);

                return py::convert(winrt::Windows::Graphics::Display::ColorOverrideSettings::CreateFromDisplayColorOverrideScenario(param0));
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* ColorOverrideSettings_get_DesiredDisplayColorOverrideScenario(py::wrapper::Windows::Graphics::Display::ColorOverrideSettings* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DesiredDisplayColorOverrideScenario());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_ColorOverrideSettings(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::ColorOverrideSettings>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_ColorOverrideSettings[] = {
        { "create_from_display_color_override_scenario", reinterpret_cast<PyCFunction>(ColorOverrideSettings_CreateFromDisplayColorOverrideScenario), METH_VARARGS | METH_STATIC, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_ColorOverrideSettings), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_ColorOverrideSettings[] = {
        { "desired_display_color_override_scenario", reinterpret_cast<getter>(ColorOverrideSettings_get_DesiredDisplayColorOverrideScenario), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_ColorOverrideSettings[] = 
    {
        { Py_tp_new, _new_ColorOverrideSettings },
        { Py_tp_dealloc, _dealloc_ColorOverrideSettings },
        { Py_tp_methods, _methods_ColorOverrideSettings },
        { Py_tp_getset, _getset_ColorOverrideSettings },
        { },
    };

    static PyType_Spec _type_spec_ColorOverrideSettings =
    {
        "_winsdk_Windows_Graphics_Display.ColorOverrideSettings",
        sizeof(py::wrapper::Windows::Graphics::Display::ColorOverrideSettings),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_ColorOverrideSettings
    };

    // ----- DisplayEnhancementOverride class --------------------
    constexpr const char* const _type_name_DisplayEnhancementOverride = "DisplayEnhancementOverride";

    static PyObject* _new_DisplayEnhancementOverride(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayEnhancementOverride);
        return nullptr;
    }

    static void _dealloc_DisplayEnhancementOverride(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* DisplayEnhancementOverride_GetCurrentDisplayEnhancementOverrideCapabilities(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetCurrentDisplayEnhancementOverrideCapabilities());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_GetForCurrentView(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::DisplayEnhancementOverride::GetForCurrentView());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_RequestOverride(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.RequestOverride();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_StopOverride(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                self->obj.StopOverride();
                Py_RETURN_NONE;
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_get_ColorOverrideSettings(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ColorOverrideSettings());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int DisplayEnhancementOverride_put_ColorOverrideSettings(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::ColorOverrideSettings>(arg);

            self->obj.ColorOverrideSettings(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* DisplayEnhancementOverride_get_BrightnessOverrideSettings(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.BrightnessOverrideSettings());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int DisplayEnhancementOverride_put_BrightnessOverrideSettings(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::BrightnessOverrideSettings>(arg);

            self->obj.BrightnessOverrideSettings(param0);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* DisplayEnhancementOverride_get_CanOverride(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CanOverride());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_get_IsOverrideActive(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsOverrideActive());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_add_CanOverrideChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayEnhancementOverride, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.CanOverrideChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_remove_CanOverrideChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.CanOverrideChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_add_DisplayEnhancementOverrideCapabilitiesChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayEnhancementOverride, winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs>>(arg);

            return py::convert(self->obj.DisplayEnhancementOverrideCapabilitiesChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_remove_DisplayEnhancementOverrideCapabilitiesChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.DisplayEnhancementOverrideCapabilitiesChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_add_IsOverrideActiveChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayEnhancementOverride, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.IsOverrideActiveChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverride_remove_IsOverrideActiveChanged(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.IsOverrideActiveChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_DisplayEnhancementOverride(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::DisplayEnhancementOverride>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayEnhancementOverride[] = {
        { "get_current_display_enhancement_override_capabilities", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_GetCurrentDisplayEnhancementOverrideCapabilities), METH_VARARGS, nullptr },
        { "get_for_current_view", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_GetForCurrentView), METH_VARARGS | METH_STATIC, nullptr },
        { "request_override", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_RequestOverride), METH_VARARGS, nullptr },
        { "stop_override", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_StopOverride), METH_VARARGS, nullptr },
        { "add_can_override_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_add_CanOverrideChanged), METH_O, nullptr },
        { "remove_can_override_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_remove_CanOverrideChanged), METH_O, nullptr },
        { "add_display_enhancement_override_capabilities_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_add_DisplayEnhancementOverrideCapabilitiesChanged), METH_O, nullptr },
        { "remove_display_enhancement_override_capabilities_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_remove_DisplayEnhancementOverrideCapabilitiesChanged), METH_O, nullptr },
        { "add_is_override_active_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_add_IsOverrideActiveChanged), METH_O, nullptr },
        { "remove_is_override_active_changed", reinterpret_cast<PyCFunction>(DisplayEnhancementOverride_remove_IsOverrideActiveChanged), METH_O, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_DisplayEnhancementOverride), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayEnhancementOverride[] = {
        { "color_override_settings", reinterpret_cast<getter>(DisplayEnhancementOverride_get_ColorOverrideSettings), reinterpret_cast<setter>(DisplayEnhancementOverride_put_ColorOverrideSettings), nullptr, nullptr },
        { "brightness_override_settings", reinterpret_cast<getter>(DisplayEnhancementOverride_get_BrightnessOverrideSettings), reinterpret_cast<setter>(DisplayEnhancementOverride_put_BrightnessOverrideSettings), nullptr, nullptr },
        { "can_override", reinterpret_cast<getter>(DisplayEnhancementOverride_get_CanOverride), nullptr, nullptr, nullptr },
        { "is_override_active", reinterpret_cast<getter>(DisplayEnhancementOverride_get_IsOverrideActive), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_DisplayEnhancementOverride[] = 
    {
        { Py_tp_new, _new_DisplayEnhancementOverride },
        { Py_tp_dealloc, _dealloc_DisplayEnhancementOverride },
        { Py_tp_methods, _methods_DisplayEnhancementOverride },
        { Py_tp_getset, _getset_DisplayEnhancementOverride },
        { },
    };

    static PyType_Spec _type_spec_DisplayEnhancementOverride =
    {
        "_winsdk_Windows_Graphics_Display.DisplayEnhancementOverride",
        sizeof(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverride),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayEnhancementOverride
    };

    // ----- DisplayEnhancementOverrideCapabilities class --------------------
    constexpr const char* const _type_name_DisplayEnhancementOverrideCapabilities = "DisplayEnhancementOverrideCapabilities";

    static PyObject* _new_DisplayEnhancementOverrideCapabilities(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayEnhancementOverrideCapabilities);
        return nullptr;
    }

    static void _dealloc_DisplayEnhancementOverrideCapabilities(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* DisplayEnhancementOverrideCapabilities_GetSupportedNitRanges(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetSupportedNitRanges());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverrideCapabilities_get_IsBrightnessControlSupported(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsBrightnessControlSupported());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayEnhancementOverrideCapabilities_get_IsBrightnessNitsControlSupported(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.IsBrightnessNitsControlSupported());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_DisplayEnhancementOverrideCapabilities(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayEnhancementOverrideCapabilities[] = {
        { "get_supported_nit_ranges", reinterpret_cast<PyCFunction>(DisplayEnhancementOverrideCapabilities_GetSupportedNitRanges), METH_VARARGS, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_DisplayEnhancementOverrideCapabilities), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayEnhancementOverrideCapabilities[] = {
        { "is_brightness_control_supported", reinterpret_cast<getter>(DisplayEnhancementOverrideCapabilities_get_IsBrightnessControlSupported), nullptr, nullptr, nullptr },
        { "is_brightness_nits_control_supported", reinterpret_cast<getter>(DisplayEnhancementOverrideCapabilities_get_IsBrightnessNitsControlSupported), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_DisplayEnhancementOverrideCapabilities[] = 
    {
        { Py_tp_new, _new_DisplayEnhancementOverrideCapabilities },
        { Py_tp_dealloc, _dealloc_DisplayEnhancementOverrideCapabilities },
        { Py_tp_methods, _methods_DisplayEnhancementOverrideCapabilities },
        { Py_tp_getset, _getset_DisplayEnhancementOverrideCapabilities },
        { },
    };

    static PyType_Spec _type_spec_DisplayEnhancementOverrideCapabilities =
    {
        "_winsdk_Windows_Graphics_Display.DisplayEnhancementOverrideCapabilities",
        sizeof(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayEnhancementOverrideCapabilities
    };

    // ----- DisplayEnhancementOverrideCapabilitiesChangedEventArgs class --------------------
    constexpr const char* const _type_name_DisplayEnhancementOverrideCapabilitiesChangedEventArgs = "DisplayEnhancementOverrideCapabilitiesChangedEventArgs";

    static PyObject* _new_DisplayEnhancementOverrideCapabilitiesChangedEventArgs(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayEnhancementOverrideCapabilitiesChangedEventArgs);
        return nullptr;
    }

    static void _dealloc_DisplayEnhancementOverrideCapabilitiesChangedEventArgs(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* DisplayEnhancementOverrideCapabilitiesChangedEventArgs_get_Capabilities(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.Capabilities());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_DisplayEnhancementOverrideCapabilitiesChangedEventArgs(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayEnhancementOverrideCapabilitiesChangedEventArgs[] = {
        { "_from", reinterpret_cast<PyCFunction>(_from_DisplayEnhancementOverrideCapabilitiesChangedEventArgs), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayEnhancementOverrideCapabilitiesChangedEventArgs[] = {
        { "capabilities", reinterpret_cast<getter>(DisplayEnhancementOverrideCapabilitiesChangedEventArgs_get_Capabilities), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_DisplayEnhancementOverrideCapabilitiesChangedEventArgs[] = 
    {
        { Py_tp_new, _new_DisplayEnhancementOverrideCapabilitiesChangedEventArgs },
        { Py_tp_dealloc, _dealloc_DisplayEnhancementOverrideCapabilitiesChangedEventArgs },
        { Py_tp_methods, _methods_DisplayEnhancementOverrideCapabilitiesChangedEventArgs },
        { Py_tp_getset, _getset_DisplayEnhancementOverrideCapabilitiesChangedEventArgs },
        { },
    };

    static PyType_Spec _type_spec_DisplayEnhancementOverrideCapabilitiesChangedEventArgs =
    {
        "_winsdk_Windows_Graphics_Display.DisplayEnhancementOverrideCapabilitiesChangedEventArgs",
        sizeof(py::wrapper::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayEnhancementOverrideCapabilitiesChangedEventArgs
    };

    // ----- DisplayInformation class --------------------
    constexpr const char* const _type_name_DisplayInformation = "DisplayInformation";

    static PyObject* _new_DisplayInformation(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayInformation);
        return nullptr;
    }

    static void _dealloc_DisplayInformation(py::wrapper::Windows::Graphics::Display::DisplayInformation* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* DisplayInformation_GetAdvancedColorInfo(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetAdvancedColorInfo());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_GetColorProfileAsync(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(self->obj.GetColorProfileAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_GetForCurrentView(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::DisplayInformation::GetForCurrentView());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_CurrentOrientation(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.CurrentOrientation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_LogicalDpi(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.LogicalDpi());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_NativeOrientation(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.NativeOrientation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_RawDpiX(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.RawDpiX());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_RawDpiY(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.RawDpiY());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_ResolutionScale(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ResolutionScale());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_StereoEnabled(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StereoEnabled());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_RawPixelsPerViewPixel(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.RawPixelsPerViewPixel());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_DiagonalSizeInInches(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.DiagonalSizeInInches());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_ScreenHeightInRawPixels(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ScreenHeightInRawPixels());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_ScreenWidthInRawPixels(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.ScreenWidthInRawPixels());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_get_AutoRotationPreferences(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayInformation::AutoRotationPreferences());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_put_AutoRotationPreferences(PyObject* /*unused*/, PyObject* arg, void* /*unused*/) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayOrientations>(arg);

            winrt::Windows::Graphics::Display::DisplayInformation::AutoRotationPreferences(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_ColorProfileChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.ColorProfileChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_ColorProfileChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.ColorProfileChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_DpiChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.DpiChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_DpiChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.DpiChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_OrientationChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.OrientationChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_OrientationChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.OrientationChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_StereoEnabledChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.StereoEnabledChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_StereoEnabledChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.StereoEnabledChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_AdvancedColorInfoChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(self->obj.AdvancedColorInfoChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_AdvancedColorInfoChanged(py::wrapper::Windows::Graphics::Display::DisplayInformation* self, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            self->obj.AdvancedColorInfoChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_add_DisplayContentsInvalidated(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Foundation::TypedEventHandler<winrt::Windows::Graphics::Display::DisplayInformation, winrt::Windows::Foundation::IInspectable>>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayInformation::DisplayContentsInvalidated(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayInformation_remove_DisplayContentsInvalidated(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayInformation::DisplayContentsInvalidated(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* _from_DisplayInformation(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::DisplayInformation>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayInformation[] = {
        { "get_advanced_color_info", reinterpret_cast<PyCFunction>(DisplayInformation_GetAdvancedColorInfo), METH_VARARGS, nullptr },
        { "get_color_profile_async", reinterpret_cast<PyCFunction>(DisplayInformation_GetColorProfileAsync), METH_VARARGS, nullptr },
        { "get_for_current_view", reinterpret_cast<PyCFunction>(DisplayInformation_GetForCurrentView), METH_VARARGS | METH_STATIC, nullptr },
        { "get_auto_rotation_preferences", reinterpret_cast<PyCFunction>(DisplayInformation_get_AutoRotationPreferences), METH_NOARGS | METH_STATIC, nullptr },
        { "put_auto_rotation_preferences", reinterpret_cast<PyCFunction>(DisplayInformation_put_AutoRotationPreferences), METH_O | METH_STATIC, nullptr },
        { "add_color_profile_changed", reinterpret_cast<PyCFunction>(DisplayInformation_add_ColorProfileChanged), METH_O, nullptr },
        { "remove_color_profile_changed", reinterpret_cast<PyCFunction>(DisplayInformation_remove_ColorProfileChanged), METH_O, nullptr },
        { "add_dpi_changed", reinterpret_cast<PyCFunction>(DisplayInformation_add_DpiChanged), METH_O, nullptr },
        { "remove_dpi_changed", reinterpret_cast<PyCFunction>(DisplayInformation_remove_DpiChanged), METH_O, nullptr },
        { "add_orientation_changed", reinterpret_cast<PyCFunction>(DisplayInformation_add_OrientationChanged), METH_O, nullptr },
        { "remove_orientation_changed", reinterpret_cast<PyCFunction>(DisplayInformation_remove_OrientationChanged), METH_O, nullptr },
        { "add_stereo_enabled_changed", reinterpret_cast<PyCFunction>(DisplayInformation_add_StereoEnabledChanged), METH_O, nullptr },
        { "remove_stereo_enabled_changed", reinterpret_cast<PyCFunction>(DisplayInformation_remove_StereoEnabledChanged), METH_O, nullptr },
        { "add_advanced_color_info_changed", reinterpret_cast<PyCFunction>(DisplayInformation_add_AdvancedColorInfoChanged), METH_O, nullptr },
        { "remove_advanced_color_info_changed", reinterpret_cast<PyCFunction>(DisplayInformation_remove_AdvancedColorInfoChanged), METH_O, nullptr },
        { "add_display_contents_invalidated", reinterpret_cast<PyCFunction>(DisplayInformation_add_DisplayContentsInvalidated), METH_O | METH_STATIC, nullptr },
        { "remove_display_contents_invalidated", reinterpret_cast<PyCFunction>(DisplayInformation_remove_DisplayContentsInvalidated), METH_O | METH_STATIC, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_DisplayInformation), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayInformation[] = {
        { "current_orientation", reinterpret_cast<getter>(DisplayInformation_get_CurrentOrientation), nullptr, nullptr, nullptr },
        { "logical_dpi", reinterpret_cast<getter>(DisplayInformation_get_LogicalDpi), nullptr, nullptr, nullptr },
        { "native_orientation", reinterpret_cast<getter>(DisplayInformation_get_NativeOrientation), nullptr, nullptr, nullptr },
        { "raw_dpi_x", reinterpret_cast<getter>(DisplayInformation_get_RawDpiX), nullptr, nullptr, nullptr },
        { "raw_dpi_y", reinterpret_cast<getter>(DisplayInformation_get_RawDpiY), nullptr, nullptr, nullptr },
        { "resolution_scale", reinterpret_cast<getter>(DisplayInformation_get_ResolutionScale), nullptr, nullptr, nullptr },
        { "stereo_enabled", reinterpret_cast<getter>(DisplayInformation_get_StereoEnabled), nullptr, nullptr, nullptr },
        { "raw_pixels_per_view_pixel", reinterpret_cast<getter>(DisplayInformation_get_RawPixelsPerViewPixel), nullptr, nullptr, nullptr },
        { "diagonal_size_in_inches", reinterpret_cast<getter>(DisplayInformation_get_DiagonalSizeInInches), nullptr, nullptr, nullptr },
        { "screen_height_in_raw_pixels", reinterpret_cast<getter>(DisplayInformation_get_ScreenHeightInRawPixels), nullptr, nullptr, nullptr },
        { "screen_width_in_raw_pixels", reinterpret_cast<getter>(DisplayInformation_get_ScreenWidthInRawPixels), nullptr, nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_DisplayInformation[] = 
    {
        { Py_tp_new, _new_DisplayInformation },
        { Py_tp_dealloc, _dealloc_DisplayInformation },
        { Py_tp_methods, _methods_DisplayInformation },
        { Py_tp_getset, _getset_DisplayInformation },
        { },
    };

    static PyType_Spec _type_spec_DisplayInformation =
    {
        "_winsdk_Windows_Graphics_Display.DisplayInformation",
        sizeof(py::wrapper::Windows::Graphics::Display::DisplayInformation),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayInformation
    };

    // ----- DisplayProperties class --------------------
    constexpr const char* const _type_name_DisplayProperties = "DisplayProperties";

    static PyObject* _new_DisplayProperties(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayProperties);
        return nullptr;
    }

    static PyObject* DisplayProperties_GetColorProfileAsync(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::GetColorProfileAsync());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_AutoRotationPreferences(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::AutoRotationPreferences());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_put_AutoRotationPreferences(PyObject* /*unused*/, PyObject* arg, void* /*unused*/) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayOrientations>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::AutoRotationPreferences(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_CurrentOrientation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::CurrentOrientation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_LogicalDpi(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::LogicalDpi());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_NativeOrientation(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::NativeOrientation());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_ResolutionScale(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::ResolutionScale());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_get_StereoEnabled(PyObject* /*unused*/, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::StereoEnabled());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_add_ColorProfileChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayPropertiesEventHandler>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::ColorProfileChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_remove_ColorProfileChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::ColorProfileChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_add_DisplayContentsInvalidated(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayPropertiesEventHandler>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::DisplayContentsInvalidated(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_remove_DisplayContentsInvalidated(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::DisplayContentsInvalidated(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_add_LogicalDpiChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayPropertiesEventHandler>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::LogicalDpiChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_remove_LogicalDpiChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::LogicalDpiChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_add_OrientationChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayPropertiesEventHandler>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::OrientationChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_remove_OrientationChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::OrientationChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_add_StereoEnabledChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::Windows::Graphics::Display::DisplayPropertiesEventHandler>(arg);

            return py::convert(winrt::Windows::Graphics::Display::DisplayProperties::StereoEnabledChanged(param0));
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyObject* DisplayProperties_remove_StereoEnabledChanged(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto param0 = py::convert_to<winrt::event_token>(arg);

            winrt::Windows::Graphics::Display::DisplayProperties::StereoEnabledChanged(param0);
            Py_RETURN_NONE;
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayProperties[] = {
        { "get_color_profile_async", reinterpret_cast<PyCFunction>(DisplayProperties_GetColorProfileAsync), METH_VARARGS | METH_STATIC, nullptr },
        { "get_auto_rotation_preferences", reinterpret_cast<PyCFunction>(DisplayProperties_get_AutoRotationPreferences), METH_NOARGS | METH_STATIC, nullptr },
        { "put_auto_rotation_preferences", reinterpret_cast<PyCFunction>(DisplayProperties_put_AutoRotationPreferences), METH_O | METH_STATIC, nullptr },
        { "get_current_orientation", reinterpret_cast<PyCFunction>(DisplayProperties_get_CurrentOrientation), METH_NOARGS | METH_STATIC, nullptr },
        { "get_logical_dpi", reinterpret_cast<PyCFunction>(DisplayProperties_get_LogicalDpi), METH_NOARGS | METH_STATIC, nullptr },
        { "get_native_orientation", reinterpret_cast<PyCFunction>(DisplayProperties_get_NativeOrientation), METH_NOARGS | METH_STATIC, nullptr },
        { "get_resolution_scale", reinterpret_cast<PyCFunction>(DisplayProperties_get_ResolutionScale), METH_NOARGS | METH_STATIC, nullptr },
        { "get_stereo_enabled", reinterpret_cast<PyCFunction>(DisplayProperties_get_StereoEnabled), METH_NOARGS | METH_STATIC, nullptr },
        { "add_color_profile_changed", reinterpret_cast<PyCFunction>(DisplayProperties_add_ColorProfileChanged), METH_O | METH_STATIC, nullptr },
        { "remove_color_profile_changed", reinterpret_cast<PyCFunction>(DisplayProperties_remove_ColorProfileChanged), METH_O | METH_STATIC, nullptr },
        { "add_display_contents_invalidated", reinterpret_cast<PyCFunction>(DisplayProperties_add_DisplayContentsInvalidated), METH_O | METH_STATIC, nullptr },
        { "remove_display_contents_invalidated", reinterpret_cast<PyCFunction>(DisplayProperties_remove_DisplayContentsInvalidated), METH_O | METH_STATIC, nullptr },
        { "add_logical_dpi_changed", reinterpret_cast<PyCFunction>(DisplayProperties_add_LogicalDpiChanged), METH_O | METH_STATIC, nullptr },
        { "remove_logical_dpi_changed", reinterpret_cast<PyCFunction>(DisplayProperties_remove_LogicalDpiChanged), METH_O | METH_STATIC, nullptr },
        { "add_orientation_changed", reinterpret_cast<PyCFunction>(DisplayProperties_add_OrientationChanged), METH_O | METH_STATIC, nullptr },
        { "remove_orientation_changed", reinterpret_cast<PyCFunction>(DisplayProperties_remove_OrientationChanged), METH_O | METH_STATIC, nullptr },
        { "add_stereo_enabled_changed", reinterpret_cast<PyCFunction>(DisplayProperties_add_StereoEnabledChanged), METH_O | METH_STATIC, nullptr },
        { "remove_stereo_enabled_changed", reinterpret_cast<PyCFunction>(DisplayProperties_remove_StereoEnabledChanged), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayProperties[] = {
        { }
    };

    static PyType_Slot _type_slots_DisplayProperties[] = 
    {
        { Py_tp_new, _new_DisplayProperties },
        { Py_tp_methods, _methods_DisplayProperties },
        { Py_tp_getset, _getset_DisplayProperties },
        { },
    };

    static PyType_Spec _type_spec_DisplayProperties =
    {
        "_winsdk_Windows_Graphics_Display.DisplayProperties",
        0,
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayProperties
    };

    // ----- DisplayServices class --------------------
    constexpr const char* const _type_name_DisplayServices = "DisplayServices";

    static PyObject* _new_DisplayServices(PyTypeObject* type, PyObject* args, PyObject* kwds) noexcept
    {
        py::set_invalid_activation_error(_type_name_DisplayServices);
        return nullptr;
    }

    static void _dealloc_DisplayServices(py::wrapper::Windows::Graphics::Display::DisplayServices* self)
    {
        auto hash_value = std::hash<winrt::Windows::Foundation::IInspectable>{}(self->obj);
        py::wrapped_instance(hash_value, nullptr);
        self->obj = nullptr;
    }

    static PyObject* DisplayServices_FindAll(PyObject* /*unused*/, PyObject* args) noexcept
    {
        Py_ssize_t arg_count = PyTuple_Size(args);

        if (arg_count == 0)
        {
            try
            {
                return py::convert(winrt::Windows::Graphics::Display::DisplayServices::FindAll());
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }
        else
        {
            py::set_invalid_arg_count_error(arg_count);
            return nullptr;
        }
    }

    static PyObject* _from_DisplayServices(PyObject* /*unused*/, PyObject* arg) noexcept
    {
        try
        {
            auto return_value = py::convert_to<winrt::Windows::Foundation::IInspectable>(arg);
            return py::convert(return_value.as<winrt::Windows::Graphics::Display::DisplayServices>());
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static PyMethodDef _methods_DisplayServices[] = {
        { "find_all", reinterpret_cast<PyCFunction>(DisplayServices_FindAll), METH_VARARGS | METH_STATIC, nullptr },
        { "_from", reinterpret_cast<PyCFunction>(_from_DisplayServices), METH_O | METH_STATIC, nullptr },
        { }
    };

    static PyGetSetDef _getset_DisplayServices[] = {
        { }
    };

    static PyType_Slot _type_slots_DisplayServices[] = 
    {
        { Py_tp_new, _new_DisplayServices },
        { Py_tp_dealloc, _dealloc_DisplayServices },
        { Py_tp_methods, _methods_DisplayServices },
        { Py_tp_getset, _getset_DisplayServices },
        { },
    };

    static PyType_Spec _type_spec_DisplayServices =
    {
        "_winsdk_Windows_Graphics_Display.DisplayServices",
        sizeof(py::wrapper::Windows::Graphics::Display::DisplayServices),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_DisplayServices
    };

    // ----- NitRange struct --------------------
    constexpr const char* const _type_name_NitRange = "NitRange";

    PyObject* _new_NitRange(PyTypeObject* type, PyObject* args, PyObject* kwds)
    {
        auto tuple_size = PyTuple_Size(args);

        if ((tuple_size == 0) && (kwds == nullptr))
        {
            try
            {
                winrt::Windows::Graphics::Display::NitRange return_value{};
                return py::convert(return_value);
            }
            catch (...)
            {
                py::to_PyErr();
                return nullptr;
            }
        }

        if ((tuple_size == 1) && (kwds == nullptr))
        {
            auto arg = PyTuple_GetItem(args, 0);
            if (PyDict_Check(arg))
            {
                try
                {
                    auto return_value = py::convert_to<winrt::Windows::Graphics::Display::NitRange>(arg);
                    return py::convert(return_value);
                }
                catch (...)
                {
                    py::to_PyErr();
                    return nullptr;
                }
            }
        }

        float _MinNits{};
        float _MaxNits{};
        float _StepSizeNits{};

        static const char* kwlist[] = {"min_nits", "max_nits", "step_size_nits", nullptr};
        if (!PyArg_ParseTupleAndKeywords(args, kwds, "fff", const_cast<char**>(kwlist), &_MinNits, &_MaxNits, &_StepSizeNits))
        {
            return nullptr;
        }

        try
        {
            winrt::Windows::Graphics::Display::NitRange return_value{ _MinNits, _MaxNits, _StepSizeNits };
            return py::convert(return_value);
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static void _dealloc_NitRange(py::wrapper::Windows::Graphics::Display::NitRange* self)
    {
    }

    static PyObject* NitRange_get_MinNits(py::wrapper::Windows::Graphics::Display::NitRange* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MinNits);
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int NitRange_set_MinNits(py::wrapper::Windows::Graphics::Display::NitRange* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            self->obj.MinNits = py::converter<float>::convert_to(arg);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* NitRange_get_MaxNits(py::wrapper::Windows::Graphics::Display::NitRange* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.MaxNits);
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int NitRange_set_MaxNits(py::wrapper::Windows::Graphics::Display::NitRange* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            self->obj.MaxNits = py::converter<float>::convert_to(arg);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyObject* NitRange_get_StepSizeNits(py::wrapper::Windows::Graphics::Display::NitRange* self, void* /*unused*/) noexcept
    {
        try
        {
            return py::convert(self->obj.StepSizeNits);
        }
        catch (...)
        {
            py::to_PyErr();
            return nullptr;
        }
    }

    static int NitRange_set_StepSizeNits(py::wrapper::Windows::Graphics::Display::NitRange* self, PyObject* arg, void* /*unused*/) noexcept
    {
        if (arg == nullptr)
        {
            PyErr_SetString(PyExc_TypeError, "property delete not supported");
            return -1;
        }

        try
        {
            self->obj.StepSizeNits = py::converter<float>::convert_to(arg);
            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyGetSetDef _getset_NitRange[] = {
        { "min_nits", reinterpret_cast<getter>(NitRange_get_MinNits), reinterpret_cast<setter>(NitRange_set_MinNits), nullptr, nullptr },
        { "max_nits", reinterpret_cast<getter>(NitRange_get_MaxNits), reinterpret_cast<setter>(NitRange_set_MaxNits), nullptr, nullptr },
        { "step_size_nits", reinterpret_cast<getter>(NitRange_get_StepSizeNits), reinterpret_cast<setter>(NitRange_set_StepSizeNits), nullptr, nullptr },
        { }
    };

    static PyType_Slot _type_slots_NitRange[] = 
    {
        { Py_tp_new, _new_NitRange },
        { Py_tp_dealloc, _dealloc_NitRange },
        { Py_tp_getset, _getset_NitRange },
        { },
    };

    static PyType_Spec _type_spec_NitRange =
    {
        "_winsdk_Windows_Graphics_Display.NitRange",
        sizeof(py::wrapper::Windows::Graphics::Display::NitRange),
        0,
        Py_TPFLAGS_DEFAULT,
        _type_slots_NitRange
    };

    // ----- Windows.Graphics.Display Initialization --------------------
    static int module_exec(PyObject* module) noexcept
    {
        try
        {
            py::pyobj_handle bases { PyTuple_Pack(1, py::winrt_type<py::Object>::python_type) };

            py::winrt_type<winrt::Windows::Graphics::Display::AdvancedColorInfo>::python_type = py::register_python_type(module, _type_name_AdvancedColorInfo, &_type_spec_AdvancedColorInfo, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::BrightnessOverride>::python_type = py::register_python_type(module, _type_name_BrightnessOverride, &_type_spec_BrightnessOverride, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::BrightnessOverrideSettings>::python_type = py::register_python_type(module, _type_name_BrightnessOverrideSettings, &_type_spec_BrightnessOverrideSettings, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::ColorOverrideSettings>::python_type = py::register_python_type(module, _type_name_ColorOverrideSettings, &_type_spec_ColorOverrideSettings, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverride>::python_type = py::register_python_type(module, _type_name_DisplayEnhancementOverride, &_type_spec_DisplayEnhancementOverride, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilities>::python_type = py::register_python_type(module, _type_name_DisplayEnhancementOverrideCapabilities, &_type_spec_DisplayEnhancementOverrideCapabilities, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayEnhancementOverrideCapabilitiesChangedEventArgs>::python_type = py::register_python_type(module, _type_name_DisplayEnhancementOverrideCapabilitiesChangedEventArgs, &_type_spec_DisplayEnhancementOverrideCapabilitiesChangedEventArgs, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayInformation>::python_type = py::register_python_type(module, _type_name_DisplayInformation, &_type_spec_DisplayInformation, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayProperties>::python_type = py::register_python_type(module, _type_name_DisplayProperties, &_type_spec_DisplayProperties, nullptr);
            py::winrt_type<winrt::Windows::Graphics::Display::DisplayServices>::python_type = py::register_python_type(module, _type_name_DisplayServices, &_type_spec_DisplayServices, bases.get());
            py::winrt_type<winrt::Windows::Graphics::Display::NitRange>::python_type = py::register_python_type(module, _type_name_NitRange, &_type_spec_NitRange, bases.get());

            return 0;
        }
        catch (...)
        {
            py::to_PyErr();
            return -1;
        }
    }

    static PyModuleDef_Slot module_slots[] = {{Py_mod_exec, module_exec}, {}};

    PyDoc_STRVAR(module_doc, "Windows.Graphics.Display");

    static PyModuleDef module_def
        = {PyModuleDef_HEAD_INIT,
           "_winsdk_Windows_Graphics_Display",
           module_doc,
           0,
           nullptr,
           module_slots,
           nullptr,
           nullptr,
           nullptr};
} // py::cpp::Windows::Graphics::Display

PyMODINIT_FUNC
PyInit__winsdk_Windows_Graphics_Display (void) noexcept
{
    return PyModuleDef_Init(&py::cpp::Windows::Graphics::Display::module_def);
}
