Commits

Anonymous committed ae285d3

Cleaned project structure

  • Participants
  • Parent commits 6a46410

Comments (0)

Files changed (45)

PolyMain/PolyMain.vcxproj

     <ClCompile Include="include\util\PolyHashUtil.cpp" />
     <ClCompile Include="include\util\PolyRandomUtil.cpp" />
     <ClCompile Include="include\util\PolyReflection.cpp" />
-    <ClCompile Include="include\util\PolyStringVariantMap.cpp" />
     <ClCompile Include="include\util\PolySystemUtil.cpp" />
     <ClCompile Include="include\util\PolyTimeUtil.cpp" />
   </ItemGroup>

PolyMain/PolyMain.vcxproj.filters

     <ClCompile Include="include\physics\PolyPhysicsSystem.cpp">
       <Filter>physics</Filter>
     </ClCompile>
-    <ClCompile Include="include\util\PolyStringVariantMap.cpp">
-      <Filter>util</Filter>
-    </ClCompile>
     <ClCompile Include="include\core\PolyEventHub.cpp">
       <Filter>core</Filter>
     </ClCompile>

PolyMain/include/PolyPrerequisites.h

 	using Ogre::SceneNode;
 	using Ogre::Math;
 
-#if POLY_USE_INTERNED_STRINGS
 	typedef boost::flyweight<String, boost::flyweights::no_tracking> InternString;
-#else
-	typedef String InternString;
-#endif
 
 	typedef uint8 SceneID;
 	typedef uint16 EntityID;

PolyMain/include/game/PolyLightComponent.cpp

 
 #include "PolyPrerequisites.h"
 #include "core/PolyEngine.h"
-#include "render/PolyRenderSubScene.h"
+#include "render/PolyRenderSubLevel.h"
 #include "render/PolyRenderSystem.h"
 #include "game/PolyTransformComponent.h"
 

PolyMain/include/game/PolyMeshComponent.cpp

 #include "PolyPrerequisites.h"
 #include "core/PolyEngine.h"
 #include "game/PolyTransformComponent.h"
-#include "render/PolyRenderSubScene.h"
+#include "render/PolyRenderSubLevel.h"
 #include "render/PolyRenderSystem.h"
 
 #include "game/PolyMeshComponent.h"

PolyMain/include/physics/PolyPhysicsSystem.cpp

 #include "game/PolyPhysicsEntityLogic.h"
 #include "PolyPhysicsRaycast.h"
 #include "PolyPhysicsUtil.h"
-#include "PolyPhysicsSubScene.h"
+#include "PolyPhysicsSubLevel.h"
 #include "PolyPhysicsUserInfo.h"
 
 #include "PolyPhysicsSystem.h"

PolyMain/include/util/PolyStringVariantMap.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyPrerequisites.h"
-
-#include "util/PolyStringVariantMap.h"
-
-
-namespace Poly {
-	StringVariantMap::StringVariantMap() {
-	}
-
-	StringVariantMap::StringVariantMap(const StringVariantMap& other) {
-		mProperties = other.mProperties;
-	}
-
-	void StringVariantMap::defaults(const StringVariantMap& other) {
-		BOOST_FOREACH(const KeyValuePair& pair, other.mProperties) {
-			KeyValueMap::const_iterator itr;
-			itr = mProperties.find(pair.first);
-
-			if(itr == mProperties.end()) {
-				mProperties.insert(pair);
-			}
-		}
-	}
-}

PolyMain/include/util/PolyStringVariantMap.h

 
 							StringVariantMap();
 							StringVariantMap(const StringVariantMap& other);
+		StringVariantMap&	operator=(const StringVariantMap& other);
 
 		template<typename T>
 		void				set(const KeyType& key, const T& value);
 		uint				size() const;
 
 		// Iterators
-		iterator			begin() { return mProperties.begin(); }
-		const_iterator		begin() const { return mProperties.begin(); }
-		iterator			end() { return mProperties.end(); }
-		const_iterator		end() const { return mProperties.end(); }
+		iterator			begin() { return mValues.begin(); }
+		const_iterator		begin() const { return mValues.begin(); }
+		iterator			end() { return mValues.end(); }
+		const_iterator		end() const { return mValues.end(); }
 
 	private:
-		KeyValueMap			mProperties;
+		KeyValueMap			mValues;
 	};
 
+	inline StringVariantMap::StringVariantMap() {
+	}
+
+	inline StringVariantMap::StringVariantMap(const StringVariantMap& other) {
+		mValues = other.mValues;
+	}
+
+	inline StringVariantMap& StringVariantMap::operator=(const StringVariantMap& other) {
+		mValues = other.mValues;
+		return *this;
+	}
 
 	template<typename T>
 	inline void StringVariantMap::set(const KeyType& key, const T& value) {
-		mProperties[key] = value;
+		mValues[key] = value;
 	}
 
 	template<typename T>
 		int PROPERTY_MAP_DOES_NOT_ACCEPT_PTR_VALUES[-1];
 	}
 
+	inline void StringVariantMap::defaults(const StringVariantMap& other) {
+		BOOST_FOREACH(const KeyValuePair& pair, other.mValues) {
+			KeyValueMap::const_iterator itr;
+			itr = mValues.find(pair.first);
+
+			if(itr == mValues.end()) {
+				mValues.insert(pair);
+			}
+		}
+	}
+
 	template<typename T> 
 	T StringVariantMap::get(const KeyType& key) const {
 		try {
 			KeyValueMap::const_iterator itr;
-			itr = mProperties.find(key);
+			itr = mValues.find(key);
 
-			if(itr != mProperties.end()) {
+			if(itr != mValues.end()) {
 				detail::StringVariantHelper<T> helper;
 				if(!boost::apply_visitor(helper, itr->second)) {
 					POLY_EXCEPT(Exception::ERR_ITEM_NOT_FOUND,
 	T StringVariantMap::get(const KeyType& key, T default) const {
 		try {
 			KeyValueMap::const_iterator itr;
-			itr = mProperties.find(key);
+			itr = mValues.find(key);
 
-			if(itr != mProperties.end()) {
+			if(itr != mValues.end()) {
 				detail::StringVariantHelper<T> helper;
 				return boost::apply_visitor(helper, itr->second) ? helper.result : default;
 			}
 
 	inline bool StringVariantMap::contains(const KeyType& key) const {
 		KeyValueMap::const_iterator itr;
-		itr = mProperties.find(key);
-		return itr != mProperties.end();
+		itr = mValues.find(key);
+		return itr != mValues.end();
 	}
 
 	inline StringVariantMap::PropertyType& StringVariantMap::operator[](const KeyType& key) {
-		return mProperties[key];
+		return mValues[key];
 	}
 
 	inline uint StringVariantMap::size() const {
-		return mProperties.size();
+		return mValues.size();
 	}
 
 	namespace detail {

PolyMain/lib/PolyConfig.h.default

 #define PolyConfig_h
 
 // Configuration
-#define POLY_USE_INTERNED_STRINGS 1
 #define POLY_ASSERT_ENABLED 1
 
 // Version

extensions/PolyAudioIrrKlang/CMakeLists.txt

 
 file(GLOB_RECURSE HEADER_FILES "include/*.h")
 
-file(GLOB_RECURSE SOURCE_FILES "src/*.cpp")
+file(GLOB_RECURSE SOURCE_FILES "include/*.cpp")
 
 set(LIBRARIES
 	debug OgreMain_d.lib

extensions/PolyAudioIrrKlang/PolyAudioIrrKlang.vcxproj

     <ClInclude Include="include\PolyAudioIrrKlangUtil.h" />
   </ItemGroup>
   <ItemGroup>
-    <ClCompile Include="src\PolyAudioIrrKlangPlugin.cpp" />
-    <ClCompile Include="src\PolyAudioIrrKlangPrerequisites.cpp">
+    <ClCompile Include="include\PolyAudioIrrKlangPlugin.cpp" />
+    <ClCompile Include="include\PolyAudioIrrKlangPrerequisites.cpp">
       <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
       <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
     </ClCompile>
-    <ClCompile Include="src\PolyAudioIrrKlangSystem.cpp" />
-    <ClCompile Include="src\PolyAudioIrrKlangSystemFactory.cpp" />
+    <ClCompile Include="include\PolyAudioIrrKlangSystem.cpp" />
+    <ClCompile Include="include\PolyAudioIrrKlangSystemFactory.cpp" />
   </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{85251406-509B-45CE-A359-7CBF34F5C650}</ProjectGuid>

extensions/PolyAudioIrrKlang/include/PolyAudioIrrKlangPlugin.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyAudioIrrKlangPrerequisites.h"
+#include "PolyAudioIrrKlangSystemFactory.h"
+
+#include "PolyAudioIrrKlangPlugin.h"
+
+
+Poly::AudioIrrKlangPlugin* plugin = POLY_NULLPTR;
+
+namespace Poly {
+	AudioIrrKlangPlugin::AudioIrrKlangPlugin()
+	:	mPluginName("Input OIS Plugin") {
+	}
+
+	const String& AudioIrrKlangPlugin::getName() const {
+		return mPluginName;
+	}
+
+	void AudioIrrKlangPlugin::install() {
+		AudioSystemFactoryPtr factory(new AudioIrrKlangSystemFactory());
+
+		gEnv.systemMgr->addAudioSystemFactory(factory);
+	}
+}
+
+extern "C" void __declspec(dllexport) dllStartPlugin() {
+	plugin = new Poly::AudioIrrKlangPlugin();
+
+	Poly::gEnv.pluginMgr->installPlugin(plugin);
+}
+
+extern "C" void __declspec(dllexport) dllStopPlugin() {
+	Poly::gEnv.pluginMgr->uninstallPlugin(plugin);
+
+	POLY_DELETE(plugin);
+}

extensions/PolyAudioIrrKlang/include/PolyAudioIrrKlangPrerequisites.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyAudioIrrKlangPrerequisites.h"

extensions/PolyAudioIrrKlang/include/PolyAudioIrrKlangSystem.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyAudioIrrKlangPrerequisites.h"
+#include "PolyAudioIrrKlangFileInterface.h"
+#include "PolyAudioIrrKlangUtil.h"
+#include "PolyAudioIrrKlangSound.h"
+
+#include "PolyAudioIrrKlangSystem.h"
+
+
+namespace Poly {
+	AudioIrrKlangSystem::AudioIrrKlangSystem() {
+		POLY_LOG("IrrKlang Audio - startup...");
+
+		mSDK = irrklang::createIrrKlangDevice();
+		mSDK->setSoundVolume(0.4f);
+
+		mFileInterface = new AudioIrrKlangFileInterface();
+		mSDK->addFileFactory(mFileInterface);
+
+		gEnv.componentMgr->addComponentType<AudioListenerComponent>();
+
+		gEnv.engine->addListener(this);
+
+		POLY_LOG("IrrKlang Audio - startup done");
+	}
+
+	AudioIrrKlangSystem::~AudioIrrKlangSystem() {
+		POLY_LOG("IrrKlang Audio - shutdown...");
+
+		gEnv.engine->removeListener(this);
+
+		POLY_LOG_TRIVIAL("Deleting all remaining sounds...");
+
+		BOOST_FOREACH(SoundPtr sound, mSounds) {
+			sound.reset();
+		}
+
+		mFileInterface->drop();
+		mSDK->drop();
+
+		POLY_LOG("IrrKlang Audio - shutdown done");
+	}
+
+	void AudioIrrKlangSystem::setListenerPosition(	const Vector3& position,
+		const Vector3& viewDir,
+		const Vector3& velocity) {
+			mSDK->setListenerPosition(AudioIrrKlangUtil::convert(position),
+				AudioIrrKlangUtil::convert(viewDir),
+				AudioIrrKlangUtil::convert(velocity));
+	}
+
+	SoundPtr AudioIrrKlangSystem::play2D(	const String& fileName,
+		bool loop,
+		bool pause,
+		AudioStreamMode stream) {
+		irrklang::ISound* sound = mSDK->play2D(fileName.c_str(),
+			loop, 
+			pause, 
+			true, 
+			(irrklang::E_STREAM_MODE)stream.underlying());
+
+		SoundPtr soundContainer = SoundPtr(new IrrKlangSound(sound));
+		mSounds.push_back(soundContainer);
+
+		return soundContainer;
+	}
+
+	SoundPtr AudioIrrKlangSystem::play3D(	const String& fileName,
+		const Vector3& position,
+		bool loop, 
+		bool pause,
+		AudioStreamMode stream) {
+		irrklang::ISound* sound = mSDK->play3D(fileName.c_str(),
+			AudioIrrKlangUtil::convert(position),
+			loop, 
+			pause,
+			true, 
+			(irrklang::E_STREAM_MODE)stream.underlying());
+
+		SoundPtr soundContainer = SoundPtr(new IrrKlangSound(sound));
+		mSounds.push_back(soundContainer);
+
+		return soundContainer;
+	}
+
+	void AudioIrrKlangSystem::_registerComponent(AudioListenerComponent* component) {
+		mComponents.push_back(component);
+	}
+
+	void AudioIrrKlangSystem::_unregisterComponent(AudioListenerComponent* component) {
+		// TODO
+	}
+
+	void AudioIrrKlangSystem::updateGameplay() {
+		// TODO issue warning with more than one AudioListenerComponent
+
+		BOOST_FOREACH(AudioListenerComponent* component, mComponents) {
+			Entity entity = component->getEntity();
+
+			TransformComponent* transform = entity.getComponent<TransformComponent>();
+			if(transform) {
+				Vector3 viewDir = transform->sceneNode->getOrientation() * Vector3::NEGATIVE_UNIT_Z;
+
+				setListenerPosition(transform->sceneNode->getPosition(), viewDir, Vector3::ZERO); // velocity missing!
+			}
+
+		}
+
+		mSDK->update();
+	}
+
+	uint AudioIrrKlangSystem::getUpdateBitMask() const {
+		return UpdateType::GAMEPLAY;
+	}
+}

extensions/PolyAudioIrrKlang/include/PolyAudioIrrKlangSystemFactory.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyAudioIrrKlangPrerequisites.h"
+#include "PolyAudioIrrKlangSystem.h"
+
+#include "PolyAudioIrrKlangSystemFactory.h"
+
+
+namespace Poly {
+	AudioIrrKlangSystemFactory::AudioIrrKlangSystemFactory()
+	:	mSystemName("IrrKlang Audio System") {
+	}
+
+	IAudioSystem* AudioIrrKlangSystemFactory::create() const {
+		return new AudioIrrKlangSystem();
+	}
+
+	void AudioIrrKlangSystemFactory::destroy(IAudioSystem* system) const {
+		POLY_ASSERT(system);
+
+		POLY_DELETE(system);
+	}
+}

extensions/PolyAudioIrrKlang/src/PolyAudioIrrKlangPlugin.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyAudioIrrKlangPrerequisites.h"
-#include "PolyAudioIrrKlangSystemFactory.h"
-
-#include "PolyAudioIrrKlangPlugin.h"
-
-
-Poly::AudioIrrKlangPlugin* plugin = POLY_NULLPTR;
-
-namespace Poly {
-	AudioIrrKlangPlugin::AudioIrrKlangPlugin()
-	:	mPluginName("Input OIS Plugin") {
-	}
-
-	const String& AudioIrrKlangPlugin::getName() const {
-		return mPluginName;
-	}
-
-	void AudioIrrKlangPlugin::install() {
-		AudioSystemFactoryPtr factory(new AudioIrrKlangSystemFactory());
-
-		gEnv.systemMgr->addAudioSystemFactory(factory);
-	}
-}
-
-extern "C" void __declspec(dllexport) dllStartPlugin() {
-	plugin = new Poly::AudioIrrKlangPlugin();
-
-	Poly::gEnv.pluginMgr->installPlugin(plugin);
-}
-
-extern "C" void __declspec(dllexport) dllStopPlugin() {
-	Poly::gEnv.pluginMgr->uninstallPlugin(plugin);
-
-	POLY_DELETE(plugin);
-}

extensions/PolyAudioIrrKlang/src/PolyAudioIrrKlangPrerequisites.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyAudioIrrKlangPrerequisites.h"

extensions/PolyAudioIrrKlang/src/PolyAudioIrrKlangSystem.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyAudioIrrKlangPrerequisites.h"
-#include "PolyAudioIrrKlangFileInterface.h"
-#include "PolyAudioIrrKlangUtil.h"
-#include "PolyAudioIrrKlangSound.h"
-
-#include "PolyAudioIrrKlangSystem.h"
-
-
-namespace Poly {
-	AudioIrrKlangSystem::AudioIrrKlangSystem() {
-		POLY_LOG("IrrKlang Audio - startup...");
-
-		mSDK = irrklang::createIrrKlangDevice();
-		mSDK->setSoundVolume(0.4f);
-
-		mFileInterface = new AudioIrrKlangFileInterface();
-		mSDK->addFileFactory(mFileInterface);
-
-		gEnv.componentMgr->addComponentType<AudioListenerComponent>();
-
-		gEnv.engine->addListener(this);
-
-		POLY_LOG("IrrKlang Audio - startup done");
-	}
-
-	AudioIrrKlangSystem::~AudioIrrKlangSystem() {
-		POLY_LOG("IrrKlang Audio - shutdown...");
-
-		gEnv.engine->removeListener(this);
-
-		POLY_LOG_TRIVIAL("Deleting all remaining sounds...");
-
-		BOOST_FOREACH(SoundPtr sound, mSounds) {
-			sound.reset();
-		}
-
-		mFileInterface->drop();
-		mSDK->drop();
-
-		POLY_LOG("IrrKlang Audio - shutdown done");
-	}
-
-	void AudioIrrKlangSystem::setListenerPosition(	const Vector3& position,
-		const Vector3& viewDir,
-		const Vector3& velocity) {
-			mSDK->setListenerPosition(AudioIrrKlangUtil::convert(position),
-				AudioIrrKlangUtil::convert(viewDir),
-				AudioIrrKlangUtil::convert(velocity));
-	}
-
-	SoundPtr AudioIrrKlangSystem::play2D(	const String& fileName,
-		bool loop,
-		bool pause,
-		AudioStreamMode stream) {
-		irrklang::ISound* sound = mSDK->play2D(fileName.c_str(),
-			loop, 
-			pause, 
-			true, 
-			(irrklang::E_STREAM_MODE)stream.underlying());
-
-		SoundPtr soundContainer = SoundPtr(new IrrKlangSound(sound));
-		mSounds.push_back(soundContainer);
-
-		return soundContainer;
-	}
-
-	SoundPtr AudioIrrKlangSystem::play3D(	const String& fileName,
-		const Vector3& position,
-		bool loop, 
-		bool pause,
-		AudioStreamMode stream) {
-		irrklang::ISound* sound = mSDK->play3D(fileName.c_str(),
-			AudioIrrKlangUtil::convert(position),
-			loop, 
-			pause,
-			true, 
-			(irrklang::E_STREAM_MODE)stream.underlying());
-
-		SoundPtr soundContainer = SoundPtr(new IrrKlangSound(sound));
-		mSounds.push_back(soundContainer);
-
-		return soundContainer;
-	}
-
-	void AudioIrrKlangSystem::_registerComponent(AudioListenerComponent* component) {
-		mComponents.push_back(component);
-	}
-
-	void AudioIrrKlangSystem::_unregisterComponent(AudioListenerComponent* component) {
-		// TODO
-	}
-
-	void AudioIrrKlangSystem::updateGameplay() {
-		// TODO issue warning with more than one AudioListenerComponent
-
-		BOOST_FOREACH(AudioListenerComponent* component, mComponents) {
-			Entity entity = component->getEntity();
-
-			TransformComponent* transform = entity.getComponent<TransformComponent>();
-			if(transform) {
-				Vector3 viewDir = transform->sceneNode->getOrientation() * Vector3::NEGATIVE_UNIT_Z;
-
-				setListenerPosition(transform->sceneNode->getPosition(), viewDir, Vector3::ZERO); // velocity missing!
-			}
-
-		}
-
-		mSDK->update();
-	}
-
-	uint AudioIrrKlangSystem::getUpdateBitMask() const {
-		return UpdateType::GAMEPLAY;
-	}
-}

extensions/PolyAudioIrrKlang/src/PolyAudioIrrKlangSystemFactory.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyAudioIrrKlangPrerequisites.h"
-#include "PolyAudioIrrKlangSystem.h"
-
-#include "PolyAudioIrrKlangSystemFactory.h"
-
-
-namespace Poly {
-	AudioIrrKlangSystemFactory::AudioIrrKlangSystemFactory()
-	:	mSystemName("IrrKlang Audio System") {
-	}
-
-	IAudioSystem* AudioIrrKlangSystemFactory::create() const {
-		return new AudioIrrKlangSystem();
-	}
-
-	void AudioIrrKlangSystemFactory::destroy(IAudioSystem* system) const {
-		POLY_ASSERT(system);
-
-		POLY_DELETE(system);
-	}
-}

extensions/PolyInputOIS/CMakeLists.txt

 
 file(GLOB_RECURSE HEADER_FILES "include/*.h")
 
-file(GLOB_RECURSE SOURCE_FILES "src/*.cpp")
+file(GLOB_RECURSE SOURCE_FILES "include/*.cpp")
 
 set(LIBRARIES
 	debug OgreMain_d.lib

extensions/PolyInputOIS/PolyInputOIS.vcxproj

       <Platform>Win32</Platform>
     </ProjectConfiguration>
   </ItemGroup>
+  <ItemGroup>
+    <ClInclude Include="include\PolyInputOISExtension.h" />
+    <ClInclude Include="include\PolyInputOISKeyboard.h" />
+    <ClInclude Include="include\PolyInputOISMouse.h" />
+    <ClInclude Include="include\PolyInputOISPlugin.h" />
+    <ClInclude Include="include\PolyInputOISPrerequisites.h" />
+    <ClInclude Include="include\PolyInputOISSystem.h" />
+    <ClInclude Include="include\PolyInputOISSystemFactory.h" />
+  </ItemGroup>
+  <ItemGroup>
+    <ClCompile Include="include\PolyInputOISKeyboard.cpp" />
+    <ClCompile Include="include\PolyInputOISMouse.cpp" />
+    <ClCompile Include="include\PolyInputOISPlugin.cpp" />
+    <ClCompile Include="include\PolyInputOISPrerequisites.cpp">
+      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
+      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
+    </ClCompile>
+    <ClCompile Include="include\PolyInputOISSystem.cpp" />
+    <ClCompile Include="include\PolyInputOISSystemFactory.cpp" />
+  </ItemGroup>
   <PropertyGroup Label="Globals">
     <ProjectGuid>{4FF9B70A-FF96-435B-885E-1115D5514C33}</ProjectGuid>
     <RootNamespace>PolyOISInput</RootNamespace>
       <Command>copy $(TargetPath) ..\..\bin\plugins\*.*</Command>
     </PostBuildEvent>
   </ItemDefinitionGroup>
-  <ItemGroup>
-    <ClInclude Include="include\PolyInputOISExtension.h" />
-    <ClInclude Include="include\PolyInputOISKeyboard.h" />
-    <ClInclude Include="include\PolyInputOISPlugin.h" />
-    <ClInclude Include="include\PolyInputOISPrerequisites.h" />
-    <ClInclude Include="include\PolyInputOISSystem.h" />
-    <ClInclude Include="include\PolyInputOISMouse.h" />
-    <ClInclude Include="include\PolyInputOISSystemFactory.h" />
-  </ItemGroup>
-  <ItemGroup>
-    <ClCompile Include="src\PolyInputOISKeyboard.cpp" />
-    <ClCompile Include="src\PolyInputOISPlugin.cpp" />
-    <ClCompile Include="src\PolyInputOISPrerequisites.cpp">
-      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">Create</PrecompiledHeader>
-      <PrecompiledHeader Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Create</PrecompiledHeader>
-    </ClCompile>
-    <ClCompile Include="src\PolyInputOISSystem.cpp" />
-    <ClCompile Include="src\PolyInputOISMouse.cpp" />
-    <ClCompile Include="src\PolyInputOISSystemFactory.cpp" />
-  </ItemGroup>
   <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
   <ImportGroup Label="ExtensionTargets">
   </ImportGroup>

extensions/PolyInputOIS/include/PolyInputOISKeyboard.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"
+#include "OIS/OISKeyboard.h"
+
+#include "PolyInputOISKeyboard.h"
+
+
+namespace Poly {
+	InputOISKeyboard::InputOISKeyboard(OIS::Keyboard* device)
+	:	mDevice(device) {
+	}
+
+	bool InputOISKeyboard::isKeyDown(KeyCode key) {
+		return mDevice->isKeyDown((OIS::KeyCode)key);
+	}
+
+	bool InputOISKeyboard::isModifierDown(KeyModifier key) {
+		return mDevice->isModifierDown((OIS::Keyboard::Modifier)key);
+	}
+
+	void InputOISKeyboard::setEventCallback(OIS::KeyListener* keyListener) {
+		mDevice->setEventCallback(keyListener);
+	}
+
+	void InputOISKeyboard::capture() {
+		mDevice->capture();
+	}
+}

extensions/PolyInputOIS/include/PolyInputOISMouse.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"
+#include "input/PolyInputMouse.h"
+#include "OIS/OISMouse.h"
+
+#include "PolyInputOISMouse.h"
+
+
+namespace Poly {
+	InputOISMouse::InputOISMouse(OIS::Mouse* device)
+	:	mDevice(device) {
+	}
+
+	bool InputOISMouse::isButtonDown(MouseButtonID buttonID) {
+		return mState.buttonDown(buttonID);
+	}
+
+	const MouseState& InputOISMouse::getState() {
+		return mState;
+	}
+
+	void InputOISMouse::setEventCallback(OIS::MouseListener* keyListener) {
+		mDevice->setEventCallback(keyListener);
+	}
+
+	void InputOISMouse::setWindowWidth(uint width) {
+		mDevice->getMouseState().width = width;
+	}
+
+	void InputOISMouse::setWindowHeight(uint height) {
+		mDevice->getMouseState().height = height;
+	}
+
+	void InputOISMouse::capture() {
+		mDevice->capture();
+
+		const OIS::MouseState& state = mDevice->getMouseState();
+
+ 		mState.buttons = state.buttons;
+		mState.x.abs = state.X.abs;
+		mState.y.abs = state.Y.abs;
+		mState.z.abs = state.Z.abs;
+		mState.x.rel = state.X.rel;
+		mState.y.rel = state.Y.rel;
+		mState.z.rel = state.Z.rel;
+	}
+}

extensions/PolyInputOIS/include/PolyInputOISPlugin.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"
+#include "PolyInputOISSystemFactory.h"
+
+#include "PolyInputOISPlugin.h"
+
+
+Poly::InputOISPlugin* plugin = POLY_NULLPTR;
+
+namespace Poly {
+	InputOISPlugin::InputOISPlugin()
+	:	mPluginName("Input OIS Plugin") {
+	}
+
+	const String& InputOISPlugin::getName() const {
+		return mPluginName;
+	}
+
+	void InputOISPlugin::install() {
+		InputSystemFactoryPtr factory(new InputOISSystemFactory());
+
+		gEnv.systemMgr->addInputSystemFactory(factory);
+	}
+}
+
+extern "C" void __declspec(dllexport) dllStartPlugin() {
+	plugin = new Poly::InputOISPlugin();
+
+	Poly::gEnv.pluginMgr->installPlugin(plugin);
+}
+
+extern "C" void __declspec(dllexport) dllStopPlugin() {
+	Poly::gEnv.pluginMgr->uninstallPlugin(plugin);
+
+	POLY_DELETE(plugin);
+}

extensions/PolyInputOIS/include/PolyInputOISPrerequisites.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"

extensions/PolyInputOIS/include/PolyInputOISSystem.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"
+#include "core/PolyEngine.h"
+#include "core/PolyConfigurationManager.h"
+#include "input/PolyInputListener.h"
+#include "PolyInputOISKeyboard.h"
+#include "PolyInputOISMouse.h"
+#include "render/PolyRenderSystem.h"
+#include <OIS/OIS.h>
+
+#include "PolyInputOISSystem.h"
+
+
+namespace Poly {
+	InputOISSystem::InputOISSystem() {
+		POLY_LOG("OIS Input - startup...");
+
+		Ogre::RenderWindow* renderingWindow = gEnv.render->getRenderWindow();
+
+		OIS::ParamList params;
+		if(!gEnv.configMgr->has("Engine.Input", "ExternalWindowHandle")) {
+			size_t hWnd = 0;
+			renderingWindow->getCustomAttribute("WINDOW", &hWnd);
+			
+			params.insert(std::make_pair("WINDOW", StringConverter::toString(hWnd)));
+		}
+		else {
+			const String& externalWindowHandel = gEnv.configMgr->get("Engine.Input", "ExternalWindowHandle", "");
+
+			POLY_LOG("Input using external window handle '" << externalWindowHandel << "'");
+
+			params.insert(std::make_pair("WINDOW", externalWindowHandel));
+		}
+
+		if(!gEnv.configMgr->getBool("Engine.Input", "Exclusive", true)) {
+			params.insert(std::make_pair(String("w32_mouse"), String("DISCL_FOREGROUND" )));
+			params.insert(std::make_pair(String("w32_mouse"), String("DISCL_NONEXCLUSIVE")));
+		}
+
+		mInputManager = OIS::InputManager::createInputSystem(params);
+
+
+		// Create individual devices
+		mKeyboard = new InputOISKeyboard((OIS::Keyboard*)mInputManager->createInputObject(OIS::OISKeyboard, true));
+		mKeyboard->setEventCallback(this);
+
+		mMouse = new InputOISMouse((OIS::Mouse*)mInputManager->createInputObject(OIS::OISMouse, true));
+		mMouse->setEventCallback(this);
+		mMouse->setWindowWidth(renderingWindow->getWidth());
+		mMouse->setWindowHeight(renderingWindow->getHeight());
+
+		mListeners.reserve(32);
+
+		gEnv.engine->addListener(this);
+		gEnv.render->addListener(this);
+
+		POLY_LOG("OIS Input - startup done");
+	}
+
+	InputOISSystem::~InputOISSystem() {
+		POLY_LOG("OIS Input - shutdown ...");
+
+		gEnv.render->removeListener(this);
+		gEnv.engine->removeListener(this);
+
+		OIS::InputManager::destroyInputSystem(mInputManager);
+
+		POLY_LOG("OIS Input - shutdown done");
+	}
+
+	void InputOISSystem::addListener(IInputListener* listener) {
+		mListeners.push_back(listener);
+	}
+
+	void InputOISSystem::removeListener(IInputListener* listener) {
+		ListenerContainer::iterator itr, end = mListeners.end();
+		for(itr = mListeners.begin(); itr != end; ++itr) {
+			if(*itr == listener) {
+				mListeners.erase(itr);
+				break;
+			}
+		}
+	}
+
+	void InputOISSystem::updateGameplay() {
+		mKeyboard->capture();
+		mMouse->capture();
+	}
+
+	bool InputOISSystem::keyPressed(const OIS::KeyEvent &arg) {
+		InputKeyEvent evt;
+		evt.key = (KeyCode)arg.key;
+		evt.text = arg.text;
+
+		BOOST_FOREACH(IInputListener* listener, mListeners) {
+			listener->keyPressed(evt);
+		}
+
+		return true;
+	}
+
+	bool InputOISSystem::keyReleased(const OIS::KeyEvent &arg) {
+		InputKeyEvent evt;
+		evt.key = (KeyCode)arg.key;
+		evt.text = arg.text;
+
+		BOOST_FOREACH(IInputListener* listener, mListeners) {
+			listener->keyReleased(evt);
+		}
+
+		return true;
+	}
+
+	bool InputOISSystem::mouseMoved(const OIS::MouseEvent &arg) {
+		InputMouseEvent evt;
+		evt.state.buttons = arg.state.buttons;
+		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
+		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
+		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
+
+		BOOST_FOREACH(IInputListener* listener, mListeners) {
+			listener->mouseMoved(evt);
+		}
+
+		return true;
+	}
+
+	bool InputOISSystem::mousePressed(const OIS::MouseEvent &arg, OIS::MouseButtonID id) {
+		InputMouseEvent evt;
+		evt.state.buttons = arg.state.buttons;
+		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
+		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
+		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
+
+		BOOST_FOREACH(IInputListener* listener, mListeners) {
+			listener->mousePressed(evt, (MouseButtonID)id);
+		}
+
+		return true;
+	}
+
+	bool InputOISSystem::mouseReleased(const OIS::MouseEvent &arg, OIS::MouseButtonID id) {
+		InputMouseEvent evt;
+		evt.state.buttons = arg.state.buttons;
+		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
+		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
+		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
+
+		BOOST_FOREACH(IInputListener* listener, mListeners) {
+			listener->mouseReleased(evt, (MouseButtonID)id);
+		}
+
+		return true;
+	}
+
+	void InputOISSystem::windowResized(Ogre::RenderWindow* rw) {
+		mMouse->setWindowWidth(rw->getWidth());
+		mMouse->setWindowHeight(rw->getHeight());
+	}
+}

extensions/PolyInputOIS/include/PolyInputOISSystemFactory.cpp

+/*
+    Copyright (c) Oliver 'SirPolly' Weitzel
+                                                                                  
+    Permission is hereby granted, free of charge, to any person obtaining a copy
+    of this software and associated documentation files (the "Software"), to deal
+    in the Software without restriction, including without limitation the rights
+    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
+    copies of the Software, and to permit persons to whom the Software is
+    furnished to do so, subject to the following conditions:
+                                                                                  
+    The above copyright notice and this permission notice shall be included in
+    all copies or substantial portions of the Software.
+                                                                                  
+    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
+    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
+    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
+    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
+    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
+    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
+    THE SOFTWARE. 
+    
+*/
+
+#include "PolyInputOISPrerequisites.h"
+#include "PolyInputOISSystem.h"
+
+#include "PolyInputOISSystemFactory.h"
+
+
+namespace Poly {
+	InputOISSystemFactory::InputOISSystemFactory()
+		:	mSystemName("OIS Input System") {
+	}
+
+	IInputSystem* InputOISSystemFactory::create() const {
+		return new InputOISSystem();
+	}
+	
+	void InputOISSystemFactory::destroy(IInputSystem* system) const {
+		POLY_ASSERT(system);
+
+		POLY_DELETE(system);
+	}
+}

extensions/PolyInputOIS/src/PolyInputOISKeyboard.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"
-#include "OIS/OISKeyboard.h"
-
-#include "PolyInputOISKeyboard.h"
-
-
-namespace Poly {
-	InputOISKeyboard::InputOISKeyboard(OIS::Keyboard* device)
-	:	mDevice(device) {
-	}
-
-	bool InputOISKeyboard::isKeyDown(KeyCode key) {
-		return mDevice->isKeyDown((OIS::KeyCode)key);
-	}
-
-	bool InputOISKeyboard::isModifierDown(KeyModifier key) {
-		return mDevice->isModifierDown((OIS::Keyboard::Modifier)key);
-	}
-
-	void InputOISKeyboard::setEventCallback(OIS::KeyListener* keyListener) {
-		mDevice->setEventCallback(keyListener);
-	}
-
-	void InputOISKeyboard::capture() {
-		mDevice->capture();
-	}
-}

extensions/PolyInputOIS/src/PolyInputOISMouse.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"
-#include "input/PolyInputMouse.h"
-#include "OIS/OISMouse.h"
-
-#include "PolyInputOISMouse.h"
-
-
-namespace Poly {
-	InputOISMouse::InputOISMouse(OIS::Mouse* device)
-	:	mDevice(device) {
-	}
-
-	bool InputOISMouse::isButtonDown(MouseButtonID buttonID) {
-		return mState.buttonDown(buttonID);
-	}
-
-	const MouseState& InputOISMouse::getState() {
-		return mState;
-	}
-
-	void InputOISMouse::setEventCallback(OIS::MouseListener* keyListener) {
-		mDevice->setEventCallback(keyListener);
-	}
-
-	void InputOISMouse::setWindowWidth(uint width) {
-		mDevice->getMouseState().width = width;
-	}
-
-	void InputOISMouse::setWindowHeight(uint height) {
-		mDevice->getMouseState().height = height;
-	}
-
-	void InputOISMouse::capture() {
-		mDevice->capture();
-
-		const OIS::MouseState& state = mDevice->getMouseState();
-
- 		mState.buttons = state.buttons;
-		mState.x.abs = state.X.abs;
-		mState.y.abs = state.Y.abs;
-		mState.z.abs = state.Z.abs;
-		mState.x.rel = state.X.rel;
-		mState.y.rel = state.Y.rel;
-		mState.z.rel = state.Z.rel;
-	}
-}

extensions/PolyInputOIS/src/PolyInputOISPlugin.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"
-#include "PolyInputOISSystemFactory.h"
-
-#include "PolyInputOISPlugin.h"
-
-
-Poly::InputOISPlugin* plugin = POLY_NULLPTR;
-
-namespace Poly {
-	InputOISPlugin::InputOISPlugin()
-	:	mPluginName("Input OIS Plugin") {
-	}
-
-	const String& InputOISPlugin::getName() const {
-		return mPluginName;
-	}
-
-	void InputOISPlugin::install() {
-		InputSystemFactoryPtr factory(new InputOISSystemFactory());
-
-		gEnv.systemMgr->addInputSystemFactory(factory);
-	}
-}
-
-extern "C" void __declspec(dllexport) dllStartPlugin() {
-	plugin = new Poly::InputOISPlugin();
-
-	Poly::gEnv.pluginMgr->installPlugin(plugin);
-}
-
-extern "C" void __declspec(dllexport) dllStopPlugin() {
-	Poly::gEnv.pluginMgr->uninstallPlugin(plugin);
-
-	POLY_DELETE(plugin);
-}

extensions/PolyInputOIS/src/PolyInputOISPrerequisites.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"

extensions/PolyInputOIS/src/PolyInputOISSystem.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"
-#include "core/PolyEngine.h"
-#include "core/PolyConfigurationManager.h"
-#include "input/PolyInputListener.h"
-#include "PolyInputOISKeyboard.h"
-#include "PolyInputOISMouse.h"
-#include "render/PolyRenderSystem.h"
-#include <OIS/OIS.h>
-
-#include "PolyInputOISSystem.h"
-
-
-namespace Poly {
-	InputOISSystem::InputOISSystem() {
-		POLY_LOG("OIS Input - startup...");
-
-		Ogre::RenderWindow* renderingWindow = gEnv.render->getRenderWindow();
-
-		OIS::ParamList params;
-		if(!gEnv.configMgr->has("Engine.Input", "ExternalWindowHandle")) {
-			size_t hWnd = 0;
-			renderingWindow->getCustomAttribute("WINDOW", &hWnd);
-			
-			params.insert(std::make_pair("WINDOW", StringConverter::toString(hWnd)));
-		}
-		else {
-			const String& externalWindowHandel = gEnv.configMgr->get("Engine.Input", "ExternalWindowHandle", "");
-
-			POLY_LOG("Input using external window handle '" << externalWindowHandel << "'");
-
-			params.insert(std::make_pair("WINDOW", externalWindowHandel));
-		}
-
-		if(!gEnv.configMgr->getBool("Engine.Input", "Exclusive", true)) {
-			params.insert(std::make_pair(String("w32_mouse"), String("DISCL_FOREGROUND" )));
-			params.insert(std::make_pair(String("w32_mouse"), String("DISCL_NONEXCLUSIVE")));
-		}
-
-		mInputManager = OIS::InputManager::createInputSystem(params);
-
-
-		// Create individual devices
-		mKeyboard = new InputOISKeyboard((OIS::Keyboard*)mInputManager->createInputObject(OIS::OISKeyboard, true));
-		mKeyboard->setEventCallback(this);
-
-		mMouse = new InputOISMouse((OIS::Mouse*)mInputManager->createInputObject(OIS::OISMouse, true));
-		mMouse->setEventCallback(this);
-		mMouse->setWindowWidth(renderingWindow->getWidth());
-		mMouse->setWindowHeight(renderingWindow->getHeight());
-
-		mListeners.reserve(32);
-
-		gEnv.engine->addListener(this);
-		gEnv.render->addListener(this);
-
-		POLY_LOG("OIS Input - startup done");
-	}
-
-	InputOISSystem::~InputOISSystem() {
-		POLY_LOG("OIS Input - shutdown ...");
-
-		gEnv.render->removeListener(this);
-		gEnv.engine->removeListener(this);
-
-		OIS::InputManager::destroyInputSystem(mInputManager);
-
-		POLY_LOG("OIS Input - shutdown done");
-	}
-
-	void InputOISSystem::addListener(IInputListener* listener) {
-		mListeners.push_back(listener);
-	}
-
-	void InputOISSystem::removeListener(IInputListener* listener) {
-		ListenerContainer::iterator itr, end = mListeners.end();
-		for(itr = mListeners.begin(); itr != end; ++itr) {
-			if(*itr == listener) {
-				mListeners.erase(itr);
-				break;
-			}
-		}
-	}
-
-	void InputOISSystem::updateGameplay() {
-		mKeyboard->capture();
-		mMouse->capture();
-	}
-
-	bool InputOISSystem::keyPressed(const OIS::KeyEvent &arg) {
-		InputKeyEvent evt;
-		evt.key = (KeyCode)arg.key;
-		evt.text = arg.text;
-
-		BOOST_FOREACH(IInputListener* listener, mListeners) {
-			listener->keyPressed(evt);
-		}
-
-		return true;
-	}
-
-	bool InputOISSystem::keyReleased(const OIS::KeyEvent &arg) {
-		InputKeyEvent evt;
-		evt.key = (KeyCode)arg.key;
-		evt.text = arg.text;
-
-		BOOST_FOREACH(IInputListener* listener, mListeners) {
-			listener->keyReleased(evt);
-		}
-
-		return true;
-	}
-
-	bool InputOISSystem::mouseMoved(const OIS::MouseEvent &arg) {
-		InputMouseEvent evt;
-		evt.state.buttons = arg.state.buttons;
-		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
-		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
-		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
-
-		BOOST_FOREACH(IInputListener* listener, mListeners) {
-			listener->mouseMoved(evt);
-		}
-
-		return true;
-	}
-
-	bool InputOISSystem::mousePressed(const OIS::MouseEvent &arg, OIS::MouseButtonID id) {
-		InputMouseEvent evt;
-		evt.state.buttons = arg.state.buttons;
-		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
-		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
-		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
-
-		BOOST_FOREACH(IInputListener* listener, mListeners) {
-			listener->mousePressed(evt, (MouseButtonID)id);
-		}
-
-		return true;
-	}
-
-	bool InputOISSystem::mouseReleased(const OIS::MouseEvent &arg, OIS::MouseButtonID id) {
-		InputMouseEvent evt;
-		evt.state.buttons = arg.state.buttons;
-		evt.state.x.abs = arg.state.X.abs; evt.state.x.rel = arg.state.X.rel;
-		evt.state.y.abs = arg.state.Y.abs; evt.state.y.rel = arg.state.Y.rel;
-		evt.state.z.abs = arg.state.Z.abs; evt.state.z.rel = arg.state.Z.rel;
-
-		BOOST_FOREACH(IInputListener* listener, mListeners) {
-			listener->mouseReleased(evt, (MouseButtonID)id);
-		}
-
-		return true;
-	}
-
-	void InputOISSystem::windowResized(Ogre::RenderWindow* rw) {
-		mMouse->setWindowWidth(rw->getWidth());
-		mMouse->setWindowHeight(rw->getHeight());
-	}
-}

extensions/PolyInputOIS/src/PolyInputOISSystemFactory.cpp

-/*
-    Copyright (c) Oliver 'SirPolly' Weitzel
-                                                                                  
-    Permission is hereby granted, free of charge, to any person obtaining a copy
-    of this software and associated documentation files (the "Software"), to deal
-    in the Software without restriction, including without limitation the rights
-    to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
-    copies of the Software, and to permit persons to whom the Software is
-    furnished to do so, subject to the following conditions:
-                                                                                  
-    The above copyright notice and this permission notice shall be included in
-    all copies or substantial portions of the Software.
-                                                                                  
-    THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
-    IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
-    FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
-    AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
-    LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
-    OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
-    THE SOFTWARE. 
-    
-*/
-
-#include "PolyInputOISPrerequisites.h"
-#include "PolyInputOISSystem.h"
-
-#include "PolyInputOISSystemFactory.h"
-
-
-namespace Poly {
-	InputOISSystemFactory::InputOISSystemFactory()
-		:	mSystemName("OIS Input System") {
-	}
-
-	IInputSystem* InputOISSystemFactory::create() const {
-		return new InputOISSystem();
-	}
-	
-	void InputOISSystemFactory::destroy(IInputSystem* system) const {
-		POLY_ASSERT(system);
-
-		POLY_DELETE(system);
-	}
-}

extensions/PolyNetworkRaknet/CMakeLists.txt

 
 file(GLOB_RECURSE HEADER_FILES "include/*.h")
 
-file(GLOB_RECURSE SOURCE_FILES "src/*.cpp")
+file(GLOB_RECURSE SOURCE_FILES "include/*.cpp")
 
 set(LIBRARIES
 	debug OgreMain_d.lib

extensions/PolyNet