diff --git a/CMakeLists.txt b/CMakeLists.txt index 7ec90d15b..276a517f1 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -3,7 +3,7 @@ cmake_minimum_required(VERSION 3.10.2 FATAL_ERROR) #============================================================================ # Initialize the project #============================================================================ -project(ignition-rendering5 VERSION 5.0.0) +project(ignition-rendering6 VERSION 6.0.0) #============================================================================ # Find ignition-cmake diff --git a/examples/ogre2_demo/CMakeLists.txt b/examples/ogre2_demo/CMakeLists.txt index d88ddd2d7..2ad666669 100644 --- a/examples/ogre2_demo/CMakeLists.txt +++ b/examples/ogre2_demo/CMakeLists.txt @@ -1,7 +1,7 @@ cmake_minimum_required(VERSION 3.5 FATAL_ERROR) project(ignition-rendering-ogre2-demo) -find_package(ignition-rendering5) +find_package(ignition-rendering6) include_directories(SYSTEM ${PROJECT_BINARY_DIR} diff --git a/ogre2/include/ignition/rendering/ogre2/Ogre2Conversions.hh b/ogre2/include/ignition/rendering/ogre2/Ogre2Conversions.hh index 9c07fff97..b7731db0f 100644 --- a/ogre2/include/ignition/rendering/ogre2/Ogre2Conversions.hh +++ b/ogre2/include/ignition/rendering/ogre2/Ogre2Conversions.hh @@ -32,7 +32,7 @@ #include #include -#include +#include #ifdef _MSC_VER #pragma warning(pop) diff --git a/ogre2/include/ignition/rendering/ogre2/Ogre2MaterialSwitcher.hh b/ogre2/include/ignition/rendering/ogre2/Ogre2MaterialSwitcher.hh index be4146d5b..1bd050700 100644 --- a/ogre2/include/ignition/rendering/ogre2/Ogre2MaterialSwitcher.hh +++ b/ogre2/include/ignition/rendering/ogre2/Ogre2MaterialSwitcher.hh @@ -29,8 +29,8 @@ #ifdef _MSC_VER #pragma warning(push, 0) #endif +#include #include -#include #ifdef _MSC_VER #pragma warning(pop) #endif diff --git a/ogre2/include/ignition/rendering/ogre2/Ogre2RenderEngine.hh b/ogre2/include/ignition/rendering/ogre2/Ogre2RenderEngine.hh index cc9ed8739..605c0be94 100644 --- a/ogre2/include/ignition/rendering/ogre2/Ogre2RenderEngine.hh +++ b/ogre2/include/ignition/rendering/ogre2/Ogre2RenderEngine.hh @@ -34,6 +34,7 @@ namespace Ogre { class LogManager; class Root; + class Window; namespace v1 { class OverlaySystem; diff --git a/ogre2/include/ignition/rendering/ogre2/Ogre2RenderTargetMaterial.hh b/ogre2/include/ignition/rendering/ogre2/Ogre2RenderTargetMaterial.hh index f1a11b887..5f586e0d7 100644 --- a/ogre2/include/ignition/rendering/ogre2/Ogre2RenderTargetMaterial.hh +++ b/ogre2/include/ignition/rendering/ogre2/Ogre2RenderTargetMaterial.hh @@ -25,7 +25,7 @@ #ifdef _MSC_VER #pragma warning(push, 0) #endif -#include +#include #include #ifdef _MSC_VER #pragma warning(pop) diff --git a/ogre2/src/Ogre2DepthCamera.cc b/ogre2/src/Ogre2DepthCamera.cc index 6581d4f32..b839db29e 100644 --- a/ogre2/src/Ogre2DepthCamera.cc +++ b/ogre2/src/Ogre2DepthCamera.cc @@ -944,13 +944,14 @@ void Ogre2DepthCamera::CreateWorkspaceInstance() auto ogreRoot = engine->OgreRoot(); Ogre::CompositorManager2 *ogreCompMgr = ogreRoot->getCompositorManager2(); - Ogre::RenderTarget *rt = - this->dataPtr->ogreDepthTexture->getBuffer()->getRenderTarget(); - // create compositor worksspace this->dataPtr->ogreCompositorWorkspace = - ogreCompMgr->addWorkspace(this->scene->OgreSceneManager(), - rt, this->ogreCamera, this->dataPtr->ogreCompositorWorkspaceDef, false); + ogreCompMgr->addWorkspace( + this->scene->OgreSceneManager(), + this->dataPtr->ogreDepthTexture, + this->ogreCamera, + this->dataPtr->ogreCompositorWorkspaceDef, + false); // add the listener Ogre::CompositorNode *node = diff --git a/ogre2/src/Ogre2DynamicRenderable.cc b/ogre2/src/Ogre2DynamicRenderable.cc index c300c5d6f..1bfa33351 100644 --- a/ogre2/src/Ogre2DynamicRenderable.cc +++ b/ogre2/src/Ogre2DynamicRenderable.cc @@ -40,6 +40,7 @@ #include #include #include +#include #ifdef _MSC_VER #pragma warning(pop) #endif diff --git a/ogre2/src/Ogre2GpuRays.cc b/ogre2/src/Ogre2GpuRays.cc index 7fb413dcf..5b7d73602 100644 --- a/ogre2/src/Ogre2GpuRays.cc +++ b/ogre2/src/Ogre2GpuRays.cc @@ -44,13 +44,10 @@ #include #include #include -#include #include -#include #include #include #include -#include #ifdef _MSC_VER #pragma warning(pop) #endif diff --git a/ogre2/src/Ogre2Material.cc b/ogre2/src/Ogre2Material.cc index 8625c2e55..fb863d753 100644 --- a/ogre2/src/Ogre2Material.cc +++ b/ogre2/src/Ogre2Material.cc @@ -26,6 +26,8 @@ #include #include #include +#include +#include #ifdef _MSC_VER #pragma warning(pop) #endif diff --git a/ogre2/src/Ogre2RenderTargetMaterial.cc b/ogre2/src/Ogre2RenderTargetMaterial.cc index 04ce3ac09..3bf470361 100644 --- a/ogre2/src/Ogre2RenderTargetMaterial.cc +++ b/ogre2/src/Ogre2RenderTargetMaterial.cc @@ -20,7 +20,7 @@ #ifdef _MSC_VER #pragma warning(push, 0) #endif -#include +#include #include #ifdef _MSC_VER #pragma warning(pop) diff --git a/ogre2/src/Ogre2Scene.cc b/ogre2/src/Ogre2Scene.cc index 302835291..e6ab8ceb1 100644 --- a/ogre2/src/Ogre2Scene.cc +++ b/ogre2/src/Ogre2Scene.cc @@ -430,9 +430,9 @@ void Ogre2Scene::CreateShadowNodeWithSettings( texDef->width = std::max(atlasRes.x, 1u); texDef->height = std::max(atlasRes.y, 1u); - texDef->formatList.push_back(Ogre::PF_D32_FLOAT); + texDef->format = Ogre::PFG_D32_FLOAT; texDef->depthBufferId = Ogre::DepthBuffer::POOL_NON_SHAREABLE; - texDef->depthBufferFormat = Ogre::PF_D32_FLOAT; + texDef->depthBufferFormat = Ogre::PFG_D32_FLOAT; texDef->preferDepthTexture = false; texDef->fsaa = false; } @@ -445,11 +445,11 @@ void Ogre2Scene::CreateShadowNodeWithSettings( texDef->width = pointLightCubemapResolution; texDef->height = pointLightCubemapResolution; - texDef->depth = 6u; - texDef->textureType = Ogre::TEX_TYPE_CUBE_MAP; - texDef->formatList.push_back(Ogre::PF_FLOAT32_R); + texDef->depthOrSlices = 6u; + texDef->textureType = Ogre::TextureTypes::TypeCube; + texDef->format = Ogre::PFG_R16_UNORM; texDef->depthBufferId = 1u; - texDef->depthBufferFormat = Ogre::PF_D32_FLOAT; + texDef->depthBufferFormat = Ogre::PFG_D32_FLOAT; texDef->preferDepthTexture = false; texDef->fsaa = false; } @@ -489,7 +489,7 @@ void Ogre2Scene::CreateShadowNodeWithSettings( Ogre::ShadowTextureDefinition *shadowTexDef = shadowNodeDef->addShadowTextureDefinition(lightIdx, j, texName, - 0, uvOffset, uvLength, 0); + uvOffset, uvLength, 0); shadowTexDef->shadowMapTechnique = shadowParam.technique; shadowTexDef->pssmLambda = pssmLambda; shadowTexDef->splitPadding = splitPadding; @@ -516,8 +516,8 @@ void Ogre2Scene::CreateShadowNodeWithSettings( Ogre::CompositorPassDef *passDef = targetDef->addPass(Ogre::PASS_CLEAR); Ogre::CompositorPassClearDef *passClear = static_cast(passDef); - passClear->mColourValue = Ogre::ColourValue::White; - passClear->mDepthValue = 1.0f; + passClear->setAllClearColours(Ogre::ColourValue::White); + passClear->mClearDepth = 1.0f; } // Pass scene for directional and spot lights first @@ -576,8 +576,8 @@ void Ogre2Scene::CreateShadowNodeWithSettings( targetDef->addPass(Ogre::PASS_CLEAR); Ogre::CompositorPassClearDef *passClear = static_cast(passDef); - passClear->mColourValue = Ogre::ColourValue::White; - passClear->mDepthValue = 1.0f; + passClear->setAllClearColours(Ogre::ColourValue::White); + passClear->mClearDepth = 1.0f; passClear->mShadowMapIdx = shadowMapIdx; } @@ -605,7 +605,7 @@ void Ogre2Scene::CreateShadowNodeWithSettings( static_cast(passDef); passQuad->mMaterialIsHlms = false; passQuad->mMaterialName = "Ogre/DPSM/CubeToDpsm"; - passQuad->addQuadTextureSource(0, "tmpCubemap", 0); + passQuad->addQuadTextureSource(0, "tmpCubemap"); passQuad->mShadowMapIdx = shadowMapIdx; } const size_t numSplits = shadowParam.technique == diff --git a/ogre2/src/Ogre2SelectionBuffer.cc b/ogre2/src/Ogre2SelectionBuffer.cc index 7d021b4ba..bfa2ad0c4 100644 --- a/ogre2/src/Ogre2SelectionBuffer.cc +++ b/ogre2/src/Ogre2SelectionBuffer.cc @@ -33,12 +33,10 @@ #include #include #include -#include #include -#include #include #include -#include +#include #include #ifdef _MSC_VER #pragma warning(pop)