diff --git a/Samples/2.0/CMakeLists.txt b/Samples/2.0/CMakeLists.txt index 7402d56f72..d5c2a4f403 100644 --- a/Samples/2.0/CMakeLists.txt +++ b/Samples/2.0/CMakeLists.txt @@ -206,7 +206,7 @@ if( OGRE_BUILD_SAMPLES2 AND NOT OGRE_BUILD_SAMPLES2_SKIP ) add_subdirectory(Tutorials/Tutorial_Hlms02_CustomizationPerObj) add_subdirectory(Tutorials/Tutorial_Hlms03_AlwaysOnTopA) add_subdirectory(Tutorials/Tutorial_Hlms04_AlwaysOnTopB) - add_subdirectory(Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData) + add_subdirectory(Tutorials/Tutorial_Hlms05_CustomizationPerObjData) if( OGRE_BUILD_COMPONENT_SCENE_FORMAT ) add_subdirectory(Tutorials/Tutorial_Memory) endif() diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.h b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.h deleted file mode 100644 index c57437d441..0000000000 --- a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.h +++ /dev/null @@ -1,23 +0,0 @@ - -#ifndef Demo_Hlms05CustomizationPerObjArbitraryDataGameState_H -#define Demo_Hlms05CustomizationPerObjArbitraryDataGameState_H - -#include "OgrePrerequisites.h" -#include "TutorialGameState.h" - -namespace Demo -{ - class Hlms05CustomizationPerObjArbitraryDataGameState : public TutorialGameState - { - std::vector mChangingItems; - - public: - Hlms05CustomizationPerObjArbitraryDataGameState( const Ogre::String &helpDescription ); - - void createScene01() override; - - void update( float timeSinceLast ) override; - }; -} // namespace Demo - -#endif diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/CMakeLists.txt b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/CMakeLists.txt similarity index 64% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/CMakeLists.txt rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/CMakeLists.txt index 2f2d18aa8e..ccfaf35d22 100644 --- a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/CMakeLists.txt +++ b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/CMakeLists.txt @@ -18,8 +18,8 @@ ogre_add_component_include_dir(Hlms/Pbs) add_recursive( ./ SOURCE_FILES ) -ogre_add_executable(Tutorial_Hlms05_CustomizationPerObjArbitraryData WIN32 MACOSX_BUNDLE ${SOURCE_FILES} ${SAMPLE_COMMON_RESOURCES}) +ogre_add_executable(Tutorial_Hlms05_CustomizationPerObjData WIN32 MACOSX_BUNDLE ${SOURCE_FILES} ${SAMPLE_COMMON_RESOURCES}) -target_link_libraries(Tutorial_Hlms05_CustomizationPerObjArbitraryData ${OGRE_LIBRARIES} ${OGRE_SAMPLES_LIBRARIES}) -ogre_config_sample_lib(Tutorial_Hlms05_CustomizationPerObjArbitraryData) -ogre_config_sample_pkg(Tutorial_Hlms05_CustomizationPerObjArbitraryData) +target_link_libraries(Tutorial_Hlms05_CustomizationPerObjData ${OGRE_LIBRARIES} ${OGRE_SAMPLES_LIBRARIES}) +ogre_config_sample_lib(Tutorial_Hlms05_CustomizationPerObjData) +ogre_config_sample_pkg(Tutorial_Hlms05_CustomizationPerObjData) diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.cpp b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.cpp similarity index 85% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.cpp rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.cpp index 8225efe6cb..9ca830a8f8 100644 --- a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.cpp +++ b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.cpp @@ -1,7 +1,7 @@ -#include "Tutorial_Hlms05_CustomizationPerObjArbitraryData.h" +#include "Tutorial_Hlms05_CustomizationPerObjData.h" -#include "Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.h" +#include "Tutorial_Hlms05_CustomizationPerObjDataGameState.h" // Declares WinMain / main #include "MainEntryPointHelper.h" @@ -25,9 +25,9 @@ namespace Demo GraphicsSystem **outGraphicsSystem, GameState **outLogicGameState, LogicSystem **outLogicSystem ) { - Hlms05CustomizationPerObjArbitraryDataGameState *gfxGameState = - new Hlms05CustomizationPerObjArbitraryDataGameState( - "Tutorial_Hlms02_CustomizationPerObj showed how to show send a custom colour.\n" + Hlms05CustomizationPerObjDataGameState *gfxGameState = + new Hlms05CustomizationPerObjDataGameState( + "Tutorial_Hlms05_CustomizationPerObjData showed how to show send a custom colour.\n" "However such sample forces all customized objects to share the same colour\n" "(or at most, a limited number of multiple colours).\n" "\n" @@ -53,10 +53,9 @@ namespace Demo "\n" "\n" "This sample depends on the media files:\n" - " * Samples/Media/2.0/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData\n" ); + " * Samples/Media/2.0/materials/Tutorial_Hlms05_CustomizationPerObjData\n" ); - GraphicsSystem *graphicsSystem = - new Hlms05CustomizationPerObjArbitraryDataGraphicsSystem( gfxGameState ); + GraphicsSystem *graphicsSystem = new Hlms05CustomizationPerObjDataGraphicsSystem( gfxGameState ); gfxGameState->_notifyGraphicsSystem( graphicsSystem ); diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.h b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.h similarity index 91% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.h rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.h index 21d5ef63cc..b249332b20 100644 --- a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryData.h +++ b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjData.h @@ -1,6 +1,6 @@ -#ifndef Demo_Tutorial_Hlms05_CustomizationPerObjArbitraryData_H -#define Demo_Tutorial_Hlms05_CustomizationPerObjArbitraryData_H +#ifndef Demo_Tutorial_Hlms05_CustomizationPerObjData_H +#define Demo_Tutorial_Hlms05_CustomizationPerObjData_H #include "GraphicsSystem.h" @@ -20,7 +20,7 @@ namespace Demo { - class Hlms05CustomizationPerObjArbitraryDataGraphicsSystem final : public GraphicsSystem + class Hlms05CustomizationPerObjDataGraphicsSystem final : public GraphicsSystem { Ogre::CompositorWorkspace *setupCompositor() override { @@ -110,8 +110,7 @@ namespace Demo // The order in which we push to archivePbsLibraryFolders DOES matter // since script order parsing matters. Ogre::Archive *archiveLibrary = archiveManager.load( - rootHlmsFolder + - "2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData", + rootHlmsFolder + "2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData", archiveType, true ); archivePbsLibraryFolders.push_back( archiveLibrary ); } @@ -137,8 +136,7 @@ namespace Demo } public: - Hlms05CustomizationPerObjArbitraryDataGraphicsSystem( GameState *gameState ) : - GraphicsSystem( gameState ) + Hlms05CustomizationPerObjDataGraphicsSystem( GameState *gameState ) : GraphicsSystem( gameState ) { } }; diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.cpp b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.cpp similarity index 94% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.cpp rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.cpp index 558661835b..3777653699 100644 --- a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.cpp +++ b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.cpp @@ -1,7 +1,7 @@ -#include "Tutorial_Hlms05_CustomizationPerObjArbitraryDataGameState.h" +#include "Tutorial_Hlms05_CustomizationPerObjDataGameState.h" -#include "Tutorial_Hlms05_CustomizationPerObjArbitraryData.h" +#include "Tutorial_Hlms05_CustomizationPerObjData.h" #include "Tutorial_Hlms05_MyHlmsPbs.h" #include "CameraController.h" @@ -23,13 +23,13 @@ using namespace Demo; -Hlms05CustomizationPerObjArbitraryDataGameState::Hlms05CustomizationPerObjArbitraryDataGameState( +Hlms05CustomizationPerObjDataGameState::Hlms05CustomizationPerObjDataGameState( const Ogre::String &helpDescription ) : TutorialGameState( helpDescription ) { } //----------------------------------------------------------------------------- -void Hlms05CustomizationPerObjArbitraryDataGameState::createScene01() +void Hlms05CustomizationPerObjDataGameState::createScene01() { Ogre::SceneManager *sceneManager = mGraphicsSystem->getSceneManager(); @@ -153,7 +153,7 @@ void Hlms05CustomizationPerObjArbitraryDataGameState::createScene01() TutorialGameState::createScene01(); } //----------------------------------------------------------------------------- -void Hlms05CustomizationPerObjArbitraryDataGameState::update( float timeSinceLast ) +void Hlms05CustomizationPerObjDataGameState::update( float timeSinceLast ) { for( Ogre::Item *item : mChangingItems ) { diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.h b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.h new file mode 100644 index 0000000000..77a219eb8e --- /dev/null +++ b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_CustomizationPerObjDataGameState.h @@ -0,0 +1,23 @@ + +#ifndef Demo_Hlms05CustomizationPerObjDataGameState_H +#define Demo_Hlms05CustomizationPerObjDataGameState_H + +#include "OgrePrerequisites.h" +#include "TutorialGameState.h" + +namespace Demo +{ + class Hlms05CustomizationPerObjDataGameState : public TutorialGameState + { + std::vector mChangingItems; + + public: + Hlms05CustomizationPerObjDataGameState( const Ogre::String &helpDescription ); + + void createScene01() override; + + void update( float timeSinceLast ) override; + }; +} // namespace Demo + +#endif diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_MyHlmsPbs.cpp b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_MyHlmsPbs.cpp similarity index 100% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_MyHlmsPbs.cpp rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_MyHlmsPbs.cpp diff --git a/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_MyHlmsPbs.h b/Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_MyHlmsPbs.h similarity index 100% rename from Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/Tutorial_Hlms05_MyHlmsPbs.h rename to Samples/2.0/Tutorials/Tutorial_Hlms05_CustomizationPerObjData/Tutorial_Hlms05_MyHlmsPbs.h diff --git a/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_all.any b/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_all.any similarity index 100% rename from Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_all.any rename to Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_all.any diff --git a/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_ps.any b/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_ps.any similarity index 100% rename from Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_ps.any rename to Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_ps.any diff --git a/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_vs.any b/Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_vs.any similarity index 100% rename from Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjArbitraryData/MyCustom_piece_vs.any rename to Samples/Media/2.0/scripts/materials/Tutorial_Hlms05_CustomizationPerObjData/MyCustom_piece_vs.any