diff --git a/library/private/window_impl.h b/library/private/window_impl.h index a050267885..2ec526ad65 100644 --- a/library/private/window_impl.h +++ b/library/private/window_impl.h @@ -31,7 +31,8 @@ class window_impl : public window * Create the internal vtkRenderWindow using the offscreen param * and store option ref for later usage */ - window_impl(const options& options, Type type, bool offscreen, const context::function& getProcAddress); + window_impl( + const options& options, Type type, bool offscreen, const context::function& getProcAddress); /** * Default destructor */ diff --git a/library/src/interactor_impl.cxx b/library/src/interactor_impl.cxx index 1a59229b35..9ebdd57bfe 100644 --- a/library/src/interactor_impl.cxx +++ b/library/src/interactor_impl.cxx @@ -41,7 +41,8 @@ class interactor_impl::internals , Window(window) , Loader(loader) { - if (window.getType() == window::Type::GLX || window.getType() == window::Type::WGL || window.getType() == window::Type::COCOA) + if (window.getType() == window::Type::GLX || window.getType() == window::Type::WGL || + window.getType() == window::Type::COCOA) { this->VTKInteractor = vtkRenderWindowInteractor::New(); } diff --git a/library/src/window_impl.cxx b/library/src/window_impl.cxx index 6e3c1249f1..a2f035c232 100644 --- a/library/src/window_impl.cxx +++ b/library/src/window_impl.cxx @@ -40,8 +40,8 @@ #endif #if VTK_VERSION_NUMBER >= VTK_VERSION_CHECK(9, 3, 20240914) -#include #include +#include #endif #if F3D_MODULE_EXTERNAL_RENDERING @@ -173,7 +173,8 @@ class window_impl::internals }; //---------------------------------------------------------------------------- -window_impl::window_impl(const options& options, Type type, bool offscreen, const context::function& getProcAddress) +window_impl::window_impl( + const options& options, Type type, bool offscreen, const context::function& getProcAddress) : Internals(std::make_unique(options)) { this->Internals->WindowType = type; @@ -239,8 +240,7 @@ window_impl::window_impl(const options& options, Type type, bool offscreen, cons #ifdef VTK_USE_X this->Internals->RenWin = vtkSmartPointer::New(); #else - throw engine::no_window_exception( - "Window type is GLX but VTK GLX support is not enabled"); + throw engine::no_window_exception("Window type is GLX but VTK GLX support is not enabled"); #endif } else if (type == Type::WGL) @@ -248,8 +248,7 @@ window_impl::window_impl(const options& options, Type type, bool offscreen, cons #ifdef _WIN32 this->Internals->RenWin = vtkSmartPointer::New(); #else - throw engine::no_window_exception( - "Window type is WGL but it is supported on Windows only"); + throw engine::no_window_exception("Window type is WGL but it is supported on Windows only"); #endif this->Internals->RenWin = vtkSmartPointer::New(); } @@ -258,8 +257,7 @@ window_impl::window_impl(const options& options, Type type, bool offscreen, cons #ifdef __APPLE__ this->Internals->RenWin = vtkSmartPointer::New(); #else - throw engine::no_window_exception( - "Window type is Cocoa but it is supported on macOS only"); + throw engine::no_window_exception("Window type is Cocoa but it is supported on macOS only"); #endif } else if (type == Type::AUTO) diff --git a/library/testing/TestSDKExternalWindowQT.cxx b/library/testing/TestSDKExternalWindowQT.cxx index 178c900c2f..634e8ccc1f 100644 --- a/library/testing/TestSDKExternalWindowQT.cxx +++ b/library/testing/TestSDKExternalWindowQT.cxx @@ -51,7 +51,9 @@ class F3DWindow : public QOpenGLWindow { this->QOpenGLWindow::initializeGL(); - f3d::context::function loadFunc = [this](const char* name) { return this->context()->getProcAddress(name); }; + f3d::context::function loadFunc = [this](const char* name) { + return this->context()->getProcAddress(name); + }; mEngine = std::make_unique(f3d::engine::createExternal(loadFunc)); f3d::loader& load = mEngine->getLoader(); diff --git a/python/F3DPythonBindings.cxx b/python/F3DPythonBindings.cxx index e46517cb3b..8c10d049bc 100644 --- a/python/F3DPythonBindings.cxx +++ b/python/F3DPythonBindings.cxx @@ -328,8 +328,7 @@ PYBIND11_MODULE(pyf3d, module) py::class_ engine(module, "Engine"); engine // - .def_static( - "create", &f3d::engine::create, "Create an engine with a automatic window") + .def_static("create", &f3d::engine::create, "Create an engine with a automatic window") .def_static("create_none", &f3d::engine::createNone, "Create an engine with no window") .def_static("create_egl", &f3d::engine::createEGL, "Create an engine with an EGL window (Windows/Linux only)") @@ -339,9 +338,11 @@ PYBIND11_MODULE(pyf3d, module) "Create an engine with an OSMesa window (Windows/Linux only)") .def_static("create_osmesa", &f3d::engine::createOSMesa, "Create an engine with an OSMesa window (Windows/Linux only)") - .def_static("create_external", [](){ return f3d::engine::createExternal(nullptr); }, + .def_static( + "create_external", []() { return f3d::engine::createExternal(nullptr); }, "Create an engine with an existing context (Windows/macOS only)") - .def_static("create_external_glx", [](){ return f3d::engine::createExternal(nullptr); }, + .def_static( + "create_external_glx", []() { return f3d::engine::createExternal(nullptr); }, "Create an engine with an existing GLX context (Linux only)") .def_static("create_external_egl", &f3d::engine::createExternalEGL, "Create an engine with an existing EGL context (Windows/Linux only)") @@ -368,7 +369,7 @@ PYBIND11_MODULE(pyf3d, module) py::arg("force_std_err") = false) .def_static("set_use_coloring", &f3d::log::setUseColoring) .def_static("print", - [](f3d::log::VerboseLevel& level, const std::string& message) + [](f3d::log::VerboseLevel& level, const std::string& message) { f3d::log::print(level, message); }); py::enum_(log, "VerboseLevel")