Parcourir la source

Updated texture and viewport

Marko Pintera il y a 13 ans
Parent
commit
850f128ccc

+ 1 - 0
CamelotRenderer/CamelotRenderer.vcxproj

@@ -84,6 +84,7 @@
     </Link>
     </Link>
   </ItemDefinitionGroup>
   </ItemDefinitionGroup>
   <ItemGroup>
   <ItemGroup>
+    <Text Include="HighLevelTODO.txt" />
     <Text Include="ReadMe.txt" />
     <Text Include="ReadMe.txt" />
     <Text Include="TODO.txt" />
     <Text Include="TODO.txt" />
   </ItemGroup>
   </ItemGroup>

+ 1 - 0
CamelotRenderer/CamelotRenderer.vcxproj.filters

@@ -62,6 +62,7 @@
   <ItemGroup>
   <ItemGroup>
     <Text Include="ReadMe.txt" />
     <Text Include="ReadMe.txt" />
     <Text Include="TODO.txt" />
     <Text Include="TODO.txt" />
+    <Text Include="HighLevelTODO.txt" />
   </ItemGroup>
   </ItemGroup>
   <ItemGroup>
   <ItemGroup>
     <ClInclude Include="stdafx.h">
     <ClInclude Include="stdafx.h">

+ 43 - 0
CamelotRenderer/HighLevelTODO.txt

@@ -0,0 +1,43 @@
+Camelot use case:
+ Application::startUp("RenderSystem", "RenderManager") <- Initializes all modules. Provide Reference render system and render manager
+ RenderWindow* window = new RenderWindow(width, height, /*etc*/); <- Automatically registers with Application
+ 
+
+ GameObject cameraObj = new GameObject("MainCamera"); // Automatically registers with SceneManager
+ Camera* newCamera = new Camera(cameraObj, renderTarget (i.e. window), Rect area, aspect, FOV, iso/proj, /*etc*/); // Component
+ 
+ Application::renderLoop();
+
+
+ Application::shutDown()
+
+------------------------------------------
+
+ Application::renderLoop INTERNALS: // TODO - Most of this should be a part of a RenderManager, so we can employ better rendering 

+techniques like deferred and forward rendering, transparently
+  Query scene manager and get all cameras
+  Sort cameras based on render targets
+  For each render target
+  Render cameras one by one
+    - Each camera queries scene manager for all visible entities // Scene manager employs spatial partitioning and frustum culling to 

+speed up the search
+    - Objects are sorted according to a render queue
+    - And sent to the render system one by one
+      - Set object pass
+      - Set object vertex/index buffer
+      - Render
+  Swap frame buffers if needed
+
+--------------------------------------------
+
+ Create shader simply by just providing source and setting parameters. No additional calls to createParameters and such shit.
+
+--------------------------------------------
+
+ Loading of mesh/texture/material should be a simple Resource.Load. Returns a ResourcePtr which is a managed ptr to resource. Resource 

+holds a pointer to its source, and it can be in a loaded or unloaded state. If we try to use an unloaded resource, a dummy resource is 

+provided.
+
+--------------------------------------------
+
+ IMPORTANT: Develop scene manager and rest of things mentioned here in CamelotRenderer project, and then port it all together to 

+ 1 - 3
CamelotRenderer/OgreD3D9RenderSystem.cpp

@@ -2693,7 +2693,7 @@ namespace Ogre
 	//---------------------------------------------------------------------
 	//---------------------------------------------------------------------
 	void D3D9RenderSystem::_setViewport( Viewport *vp )
 	void D3D9RenderSystem::_setViewport( Viewport *vp )
 	{
 	{
-		if( vp != mActiveViewport || vp->_isUpdated() )
+		if( vp != mActiveViewport)
 		{
 		{
 			mActiveViewport = vp;
 			mActiveViewport = vp;
 
 
@@ -2728,8 +2728,6 @@ namespace Ogre
 
 
 			// Set sRGB write mode
 			// Set sRGB write mode
 			__SetRenderState(D3DRS_SRGBWRITEENABLE, target->isHardwareGammaEnabled());
 			__SetRenderState(D3DRS_SRGBWRITEENABLE, target->isHardwareGammaEnabled());
-
-			vp->_clearUpdatedFlag();
 		}
 		}
 	}
 	}
 	//---------------------------------------------------------------------
 	//---------------------------------------------------------------------

+ 0 - 17
CamelotRenderer/OgreRenderTarget.cpp

@@ -83,7 +83,6 @@ namespace Ogre {
     void RenderTarget::updateImpl(void)
     void RenderTarget::updateImpl(void)
     {
     {
 		_beginUpdate();
 		_beginUpdate();
-		_updateAutoUpdatedViewports(true);
 		_endUpdate();
 		_endUpdate();
     }
     }
 
 
@@ -91,22 +90,6 @@ namespace Ogre {
 	{
 	{
 	}
 	}
 
 
-	void RenderTarget::_updateAutoUpdatedViewports(bool updateStatistics)
-	{
-		// Go through viewports in Z-order
-        // Tell each to refresh
-		ViewportList::iterator it = mViewportList.begin();
-        while (it != mViewportList.end())
-        {
-			Viewport* viewport = (*it).second;
-			if(viewport->isAutoUpdated())
-			{
-				_updateViewport(viewport,updateStatistics);
-			}
-			++it;
-		}
-	}
-
 	void RenderTarget::_endUpdate()
 	void RenderTarget::_endUpdate()
 	{
 	{
 	}
 	}

+ 0 - 10
CamelotRenderer/OgreRenderTarget.h

@@ -313,16 +313,6 @@ namespace Ogre {
 		@param updateStatistics Whether you want to update statistics or not.
 		@param updateStatistics Whether you want to update statistics or not.
 		*/
 		*/
 		virtual void _updateViewport(Viewport* viewport, bool updateStatistics = true);
 		virtual void _updateViewport(Viewport* viewport, bool updateStatistics = true);
-
-		/** Method for manual management of rendering - renders only viewports that are auto updated
-		@remarks
-		This also fires preViewportUpdate and postViewportUpdate, and manages statistics.
-		You should call it between _beginUpdate() and _endUpdate().
-		See _beginUpdate for more details.
-		@param updateStatistics Whether you want to update statistics or not.
-		@see _beginUpdate()
-		*/
-		virtual void _updateAutoUpdatedViewports(bool updateStatistics = true);
 		
 		
 		/** Method for manual management of rendering - finishes statistics calculation 
 		/** Method for manual management of rendering - finishes statistics calculation 
 			and fires 'postRenderTargetUpdate'.
 			and fires 'postRenderTargetUpdate'.

+ 0 - 11
CamelotRenderer/OgreTexture.cpp

@@ -52,7 +52,6 @@ namespace Ogre {
             mDesiredFormat(PF_UNKNOWN),
             mDesiredFormat(PF_UNKNOWN),
             mDesiredIntegerBitDepth(0),
             mDesiredIntegerBitDepth(0),
             mDesiredFloatBitDepth(0),
             mDesiredFloatBitDepth(0),
-            mTreatLuminanceAsAlpha(false),
             mInternalResourcesCreated(false)
             mInternalResourcesCreated(false)
     {
     {
         
         
@@ -95,16 +94,6 @@ namespace Ogre {
         mDesiredIntegerBitDepth = integerBits;
         mDesiredIntegerBitDepth = integerBits;
         mDesiredFloatBitDepth = floatBits;
         mDesiredFloatBitDepth = floatBits;
     }
     }
-    //--------------------------------------------------------------------------
-    void Texture::setTreatLuminanceAsAlpha(bool asAlpha)
-    {
-        mTreatLuminanceAsAlpha = asAlpha;
-    }
-    //--------------------------------------------------------------------------
-    bool Texture::getTreatLuminanceAsAlpha(void) const
-    {
-        return mTreatLuminanceAsAlpha;
-    }
     //--------------------------------------------------------------------------
     //--------------------------------------------------------------------------
 	size_t Texture::calculateSize(void) const
 	size_t Texture::calculateSize(void) const
 	{
 	{

+ 0 - 9
CamelotRenderer/OgreTexture.h

@@ -306,14 +306,6 @@ namespace Ogre {
         */
         */
         virtual void setDesiredBitDepths(ushort integerBits, ushort floatBits);
         virtual void setDesiredBitDepths(ushort integerBits, ushort floatBits);
 
 
-        /** Sets whether luminace pixel format will treated as alpha format when load this texture.
-        */
-        virtual void setTreatLuminanceAsAlpha(bool asAlpha);
-
-        /** Gets whether luminace pixel format will treated as alpha format when load this texture.
-        */
-        virtual bool getTreatLuminanceAsAlpha(void) const;
-
         /** Return the number of faces this texture has. This will be 6 for a cubemap
         /** Return the number of faces this texture has. This will be 6 for a cubemap
         	texture and 1 for a 1D, 2D or 3D one.
         	texture and 1 for a 1D, 2D or 3D one.
         */
         */
@@ -363,7 +355,6 @@ namespace Ogre {
         PixelFormat mDesiredFormat;
         PixelFormat mDesiredFormat;
         unsigned short mDesiredIntegerBitDepth;
         unsigned short mDesiredIntegerBitDepth;
         unsigned short mDesiredFloatBitDepth;
         unsigned short mDesiredFloatBitDepth;
-        bool mTreatLuminanceAsAlpha;
 
 
 		bool mInternalResourcesCreated;
 		bool mInternalResourcesCreated;
 
 

+ 0 - 148
CamelotRenderer/OgreViewport.cpp

@@ -34,7 +34,6 @@ THE SOFTWARE.
 #include "CmRenderSystemManager.h"
 #include "CmRenderSystemManager.h"
 
 
 namespace Ogre {
 namespace Ogre {
-    OrientationMode Viewport::mDefaultOrientationMode = OR_DEGREE_0;
     //---------------------------------------------------------------------
     //---------------------------------------------------------------------
     Viewport::Viewport(RenderTarget* target, Real left, Real top, Real width, Real height, int ZOrder)
     Viewport::Viewport(RenderTarget* target, Real left, Real top, Real width, Real height, int ZOrder)
          :mTarget(target)
          :mTarget(target)
@@ -47,17 +46,7 @@ namespace Ogre {
         , mBackColour(ColourValue::Black)
         , mBackColour(ColourValue::Black)
         , mClearEveryFrame(true)
         , mClearEveryFrame(true)
 		, mClearBuffers(FBT_COLOUR | FBT_DEPTH)
 		, mClearBuffers(FBT_COLOUR | FBT_DEPTH)
-        , mUpdated(false)
-        , mShowOverlays(true)
-        , mShowSkies(true)
-		, mShowShadows(true)
-		, mVisibilityMask(0xFFFFFFFF)
-		, mMaterialSchemeName("NotUsedInPort")
-		, mIsAutoUpdated(true)
     {
     {
-        // Set the default orientation mode
-        mOrientationMode = mDefaultOrientationMode;     
-
         // Calculate actual dimensions
         // Calculate actual dimensions
         _updateDimensions();
         _updateDimensions();
     }
     }
@@ -65,16 +54,6 @@ namespace Ogre {
     Viewport::~Viewport()
     Viewport::~Viewport()
     {
     {
 
 
-    }
-    //---------------------------------------------------------------------
-    bool Viewport::_isUpdated(void) const
-    {
-        return mUpdated;
-    }
-    //---------------------------------------------------------------------
-    void Viewport::_clearUpdatedFlag(void)
-    {
-        mUpdated = false;
     }
     }
     //---------------------------------------------------------------------
     //---------------------------------------------------------------------
     void Viewport::_updateDimensions(void)
     void Viewport::_updateDimensions(void)
@@ -86,8 +65,6 @@ namespace Ogre {
         mActTop = (int) (mRelTop * height);
         mActTop = (int) (mRelTop * height);
         mActWidth = (int) (mRelWidth * width);
         mActWidth = (int) (mRelWidth * width);
         mActHeight = (int) (mRelHeight * height);
         mActHeight = (int) (mRelHeight * height);
-
-        mUpdated = true;
     }
     }
 	//---------------------------------------------------------------------
 	//---------------------------------------------------------------------
 	int Viewport::getZOrder(void) const
 	int Viewport::getZOrder(void) const
@@ -152,60 +129,6 @@ namespace Ogre {
     void Viewport::update(void)
     void Viewport::update(void)
     {
     {
 
 
-    }
-    //---------------------------------------------------------------------
-    void Viewport::setOrientationMode(OrientationMode orientationMode, bool setDefault)
-    {
-#if OGRE_NO_VIEWPORT_ORIENTATIONMODE != 0
-        OGRE_EXCEPT(Exception::ERR_NOT_IMPLEMENTED,
-                    "Setting Viewport orientation mode is not supported",
-                    __FUNCTION__);
-#endif
-        mOrientationMode = orientationMode;
-
-        if (setDefault)
-        {
-            setDefaultOrientationMode(orientationMode);
-        }
-
-		// Update the render system config
-        RenderSystem* rs = CamelotEngine::RenderSystemManager::getActive();
-        if(mOrientationMode == OR_LANDSCAPELEFT)
-            rs->setConfigOption("Orientation", "Landscape Left");
-        else if(mOrientationMode == OR_LANDSCAPERIGHT)
-            rs->setConfigOption("Orientation", "Landscape Right");
-        else if(mOrientationMode == OR_PORTRAIT)
-            rs->setConfigOption("Orientation", "Portrait");
-    }
-    //---------------------------------------------------------------------
-    OrientationMode Viewport::getOrientationMode() const
-    {
-#if OGRE_NO_VIEWPORT_ORIENTATIONMODE != 0
-        OGRE_EXCEPT(Exception::ERR_NOT_IMPLEMENTED,
-                    "Getting Viewport orientation mode is not supported",
-                    __FUNCTION__);
-#endif
-        return mOrientationMode;
-    }
-    //---------------------------------------------------------------------
-    void Viewport::setDefaultOrientationMode(OrientationMode orientationMode)
-    {
-#if OGRE_NO_VIEWPORT_ORIENTATIONMODE != 0
-        OGRE_EXCEPT(Exception::ERR_NOT_IMPLEMENTED,
-                    "Setting default Viewport orientation mode is not supported",
-                    __FUNCTION__);
-#endif
-        mDefaultOrientationMode = orientationMode;
-    }
-    //---------------------------------------------------------------------
-    OrientationMode Viewport::getDefaultOrientationMode()
-    {
-#if OGRE_NO_VIEWPORT_ORIENTATIONMODE != 0
-        OGRE_EXCEPT(Exception::ERR_NOT_IMPLEMENTED,
-                    "Getting default Viewport orientation mode is not supported",
-                    __FUNCTION__);
-#endif
-        return mDefaultOrientationMode;
     }
     }
     //---------------------------------------------------------------------
     //---------------------------------------------------------------------
     void Viewport::setBackgroundColour(const ColourValue& colour)
     void Viewport::setBackgroundColour(const ColourValue& colour)
@@ -259,77 +182,6 @@ namespace Ogre {
         width = mActWidth;
         width = mActWidth;
         height = mActHeight;
         height = mActHeight;
 
 
-    }
-    //---------------------------------------------------------------------
-	void Viewport::setAutoUpdated(bool inAutoUpdated)
-	{
-		mIsAutoUpdated = inAutoUpdated;
-	}
-	//---------------------------------------------------------------------
-	bool Viewport::isAutoUpdated() const
-	{
-		return mIsAutoUpdated;
-	}
-	//---------------------------------------------------------------------
-    void Viewport::setOverlaysEnabled(bool enabled)
-    {
-        mShowOverlays = enabled;
-    }
-    //---------------------------------------------------------------------
-    bool Viewport::getOverlaysEnabled(void) const
-    {
-        return mShowOverlays;
-    }
-    //---------------------------------------------------------------------
-    void Viewport::setSkiesEnabled(bool enabled)
-    {
-        mShowSkies = enabled;
-    }
-    //---------------------------------------------------------------------
-    bool Viewport::getSkiesEnabled(void) const
-    {
-        return mShowSkies;
-    }
-    //---------------------------------------------------------------------
-    void Viewport::setShadowsEnabled(bool enabled)
-    {
-        mShowShadows = enabled;
-    }
-    //---------------------------------------------------------------------
-    bool Viewport::getShadowsEnabled(void) const
-    {
-        return mShowShadows;
-    }
-	//-----------------------------------------------------------------------
-    void Viewport::pointOrientedToScreen(const Vector2 &v, int orientationMode, Vector2 &outv)
-    {
-        pointOrientedToScreen(v.x, v.y, orientationMode, outv.x, outv.y);
-    }
-	//-----------------------------------------------------------------------
-    void Viewport::pointOrientedToScreen(Real orientedX, Real orientedY, int orientationMode,
-                                         Real &screenX, Real &screenY)
-    {
-        Real orX = orientedX;
-        Real orY = orientedY;
-        switch (orientationMode)
-        {
-        case 1:
-            screenX = orY;
-            screenY = Real(1.0) - orX;
-            break;
-        case 2:
-            screenX = Real(1.0) - orX;
-            screenY = Real(1.0) - orY;
-            break;
-        case 3:
-            screenX = Real(1.0) - orY;
-            screenY = orX;
-            break;
-        default:
-            screenX = orX;
-            screenY = orY;
-            break;
-        }
     }
     }
 	//-----------------------------------------------------------------------
 	//-----------------------------------------------------------------------
 }
 }

+ 0 - 131
CamelotRenderer/OgreViewport.h

@@ -177,22 +177,6 @@ namespace Ogre {
         */
         */
         void setDimensions(Real left, Real top, Real width, Real height);
         void setDimensions(Real left, Real top, Real width, Real height);
 
 
-        /** Set the orientation mode of the viewport.
-        */
-        void setOrientationMode(OrientationMode orientationMode, bool setDefault = true);
-
-        /** Get the orientation mode of the viewport.
-        */
-        OrientationMode getOrientationMode() const;
-
-        /** Set the initial orientation mode of viewports.
-        */
-        static void setDefaultOrientationMode(OrientationMode orientationMode);
-
-        /** Get the initial orientation mode of viewports.
-        */
-        static OrientationMode getDefaultOrientationMode();
-
         /** Sets the initial background colour of the viewport (before
         /** Sets the initial background colour of the viewport (before
             rendering).
             rendering).
         */
         */
@@ -220,113 +204,11 @@ namespace Ogre {
 		/** Gets which buffers are to be cleared each frame. */
 		/** Gets which buffers are to be cleared each frame. */
         unsigned int getClearBuffers(void) const;
         unsigned int getClearBuffers(void) const;
 
 
-		/** Sets whether this viewport should be automatically updated 
-			if Ogre's rendering loop or RenderTarget::update is being used.
-        @remarks
-            By default, if you use Ogre's own rendering loop (Root::startRendering)
-            or call RenderTarget::update, all viewports are updated automatically.
-            This method allows you to control that behaviour, if for example you 
-			have a viewport which you only want to update periodically.
-        @param autoupdate If true, the viewport is updated during the automatic
-            render loop or when RenderTarget::update() is called. If false, the 
-            viewport is only updated when its update() method is called explicitly.
-        */
-		void setAutoUpdated(bool autoupdate);
-		/** Gets whether this viewport is automatically updated if 
-			Ogre's rendering loop or RenderTarget::update is being used.
-        */
-		bool isAutoUpdated() const;
-
-		/** Set the material scheme which the viewport should use.
-		@remarks
-			This allows you to tell the system to use a particular
-			material scheme when rendering this viewport, which can 
-			involve using different techniques to render your materials.
-		@see Technique::setSchemeName
-		*/
-		void setMaterialScheme(const String& schemeName)
-		{ mMaterialSchemeName = schemeName; }
-		
-		/** Get the material scheme which the viewport should use.
-		*/
-		const String& getMaterialScheme(void) const
-		{ return mMaterialSchemeName; }
-
 		/** Access to actual dimensions (based on target size).
 		/** Access to actual dimensions (based on target size).
         */
         */
         void getActualDimensions(
         void getActualDimensions(
             int &left, int &top, int &width, int &height ) const;
             int &left, int &top, int &width, int &height ) const;
 
 
-        bool _isUpdated(void) const;
-        void _clearUpdatedFlag(void);
-
-        /** Tells this viewport whether it should display Overlay objects.
-        @remarks
-            Overlay objects are layers which appear on top of the scene. They are created via
-            SceneManager::createOverlay and every viewport displays these by default.
-            However, you probably don't want this if you're using multiple viewports,
-            because one of them is probably a picture-in-picture which is not supposed to
-            have overlays of it's own. In this case you can turn off overlays on this viewport
-            by calling this method.
-        @param enabled If true, any overlays are displayed, if false they are not.
-        */
-        void setOverlaysEnabled(bool enabled);
-
-        /** Returns whether or not Overlay objects (created in the SceneManager) are displayed in this
-            viewport. */
-        bool getOverlaysEnabled(void) const;
-
-        /** Tells this viewport whether it should display skies.
-        @remarks
-            Skies are layers which appear on background of the scene. They are created via
-            SceneManager::setSkyBox, SceneManager::setSkyPlane and SceneManager::setSkyDome and
-            every viewport displays these by default. However, you probably don't want this if
-            you're using multiple viewports, because one of them is probably a picture-in-picture
-            which is not supposed to have skies of it's own. In this case you can turn off skies
-            on this viewport by calling this method.
-        @param enabled If true, any skies are displayed, if false they are not.
-        */
-        void setSkiesEnabled(bool enabled);
-
-        /** Returns whether or not skies (created in the SceneManager) are displayed in this
-            viewport. */
-        bool getSkiesEnabled(void) const;
-
-        /** Tells this viewport whether it should display shadows.
-        @remarks
-            This setting enables you to disable shadow rendering for a given viewport. The global
-			shadow technique set on SceneManager still controls the type and nature of shadows,
-			but this flag can override the setting so that no shadows are rendered for a given
-			viewport to save processing time where they are not required.
-        @param enabled If true, any shadows are displayed, if false they are not.
-        */
-        void setShadowsEnabled(bool enabled);
-
-        /** Returns whether or not shadows (defined in the SceneManager) are displayed in this
-            viewport. */
-        bool getShadowsEnabled(void) const;
-
-
-		/** Sets a per-viewport visibility mask.
-		@remarks
-			The visibility mask is a way to exclude objects from rendering for
-			a given viewport. For each object in the frustum, a check is made
-			between this mask and the objects visibility flags 
-			(@see MovableObject::setVisibilityFlags), and if a binary 'and'
-			returns zero, the object will not be rendered.
-		*/
-		void setVisibilityMask(uint32 mask) { mVisibilityMask = mask; }
-
-		/** Gets a per-viewport visibility mask.
-		@see Viewport::setVisibilityMask
-		*/
-		uint getVisibilityMask(void) const { return mVisibilityMask; }
-
-        /** Convert oriented input point coordinates to screen coordinates. */
-        void pointOrientedToScreen(const Vector2 &v, int orientationMode, Vector2 &outv);
-        void pointOrientedToScreen(Real orientedX, Real orientedY, int orientationMode,
-                                   Real &screenX, Real &screenY);
-
     protected:
     protected:
         RenderTarget* mTarget;
         RenderTarget* mTarget;
         // Relative dimensions, irrespective of target dimensions (0..1)
         // Relative dimensions, irrespective of target dimensions (0..1)
@@ -339,19 +221,6 @@ namespace Ogre {
         ColourValue mBackColour;
         ColourValue mBackColour;
         bool mClearEveryFrame;
         bool mClearEveryFrame;
 		unsigned int mClearBuffers;
 		unsigned int mClearBuffers;
-        bool mUpdated;
-        bool mShowOverlays;
-        bool mShowSkies;
-		bool mShowShadows;
-		uint32 mVisibilityMask;
-		/// Material scheme
-		String mMaterialSchemeName;
-        /// Viewport orientation mode
-        OrientationMode mOrientationMode;
-        static OrientationMode mDefaultOrientationMode;
-
-		/// Automatic rendering on/off
-		bool mIsAutoUpdated;
     };
     };
 	/** @} */
 	/** @} */
 	/** @} */
 	/** @} */

+ 1 - 3
CamelotRenderer/RenderSystemGL/Source/OgreGLRenderSystem.cpp

@@ -1781,7 +1781,7 @@ namespace Ogre {
 	void GLRenderSystem::_setViewport(Viewport *vp)
 	void GLRenderSystem::_setViewport(Viewport *vp)
 	{
 	{
 		// Check if viewport is different
 		// Check if viewport is different
-		if (vp != mActiveViewport || vp->_isUpdated())
+		if (vp != mActiveViewport)
 		{
 		{
 			RenderTarget* target;
 			RenderTarget* target;
 			target = vp->getTarget();
 			target = vp->getTarget();
@@ -1804,8 +1804,6 @@ namespace Ogre {
 
 
 			// Configure the viewport clipping
 			// Configure the viewport clipping
 			glScissor(x, y, w, h);
 			glScissor(x, y, w, h);
-
-			vp->_clearUpdatedFlag();
 		}
 		}
 	}
 	}
 
 

+ 7 - 21
CamelotRenderer/TODO.txt

@@ -4,6 +4,9 @@ GpuProgram - PARSED!
 TextureState - PARSED!
 TextureState - PARSED!
  - This is just an utility class representing texture state
  - This is just an utility class representing texture state
 HardwareVertexBuffer - PARSED!
 HardwareVertexBuffer - PARSED!
+Viewport - PARSED!
+HardwareBufferManager - PARSED!
+HighLevelGpuProgram - PARSED!
 VertexIndexData - Just data structures
 VertexIndexData - Just data structures
  - VertexCacheProfiler is a weird one, but I think I don't have to remove it as it might come in handy
  - VertexCacheProfiler is a weird one, but I think I don't have to remove it as it might come in handy
 RenderTexture - Everything OK
 RenderTexture - Everything OK
@@ -12,20 +15,19 @@ HardwareIndexBuffer - Everything OK
 RenderSystemCapabilities - I think I need all of that
 RenderSystemCapabilities - I think I need all of that
 HardwareBuffer - Base class for all buffers
 HardwareBuffer - Base class for all buffers
  - Everything seems fine although I /might/ want to explore how the shadow buffer works and if I want to implement it differently?
  - Everything seems fine although I /might/ want to explore how the shadow buffer works and if I want to implement it differently?
+DefaultHardwareBufferManager - Provides emulation of hardware buffers
+ - I think this class is okay to stay, although I'm not sure where its used, but its simple enough
+Texture - PARSED!
 
 
 TODO FILES:
 TODO FILES:
 
 
-Camera:
+Camera - MERGE WITH VIEWPORT
  - Remove auto tracking
  - Remove auto tracking
- - Merge with Viewport
  - Lod stuff? Probably need to remove as well
  - Lod stuff? Probably need to remove as well
  - Num render batches and other statistics
  - Num render batches and other statistics
  - Position/rotation should be inherit from transform
  - Position/rotation should be inherit from transform
  - Listeners
  - Listeners
 
 
-DefaultHardwareBufferManager - Provides emulation of hardware buffers
- - I think this class is okay to stay, although I'm not sure where its used, but its simple enough
-
 Frustum
 Frustum
  - Reflect plane/matrix/methods need to be removed
  - Reflect plane/matrix/methods need to be removed
  - Oblique plane/matrix/methods need to be removed (AKA custom clip plane)
  - Oblique plane/matrix/methods need to be removed (AKA custom clip plane)
@@ -35,33 +37,17 @@ Frustum
 GpuProgramParams - Holds all parameters used in a shader program and allows us to set them by index or name
 GpuProgramParams - Holds all parameters used in a shader program and allows us to set them by index or name
  - Explore if we can remove GpuSharedParameters. I'm not exactly sure what they're used for
  - Explore if we can remove GpuSharedParameters. I'm not exactly sure what they're used for
 
 
-HardwareBufferManager - Abstracts whether I'm creating D3D9 or OpenGL buffers
- - License stuff needs to be removed. I'm not sure what it's used for
-
 HardwareOcclusionQuery - OK, but I might consider a more generic interface for queries (I'll need profiling queries too for example)
 HardwareOcclusionQuery - OK, but I might consider a more generic interface for queries (I'll need profiling queries too for example)
 
 
 HardwarePixelBuffer 
 HardwarePixelBuffer 
  - I might consider giving PixelBox a better name. Also rename PixelFormat.h to PixelUtil.h or similar. Makes more sense.
  - I might consider giving PixelBox a better name. Also rename PixelFormat.h to PixelUtil.h or similar. Makes more sense.
  - _clearSliceRTT method I'm not sure what is it used for, but I might want to remove it
  - _clearSliceRTT method I'm not sure what is it used for, but I might want to remove it
 
 
-HighLevelGpuProgram - Mostly okay
- - Has some methods for loading from a file, which I wont do
-
 RenderTarget:
 RenderTarget:
  - update() causes rendering to start - This probably need to be moved to camera, as I want it to be responsible for rendering
  - update() causes rendering to start - This probably need to be moved to camera, as I want it to be responsible for rendering
  - keeps a viewport list, which I also don't think I'll need
  - keeps a viewport list, which I also don't think I'll need
  - autoUpdate and various update methods that I probably don't need
  - autoUpdate and various update methods that I probably don't need
 
 
-Texture
- - mTreatLuminanceAsAlpha and corresponding methods - I dont think I need that or that it's used
-
-Viewport - MERGE WITH CAMERA
- - Remove orientation mode
- - Remove various update/clearEveryFrame methods
- - Remove material scheme
- - Remove Overlays/skies/shadows/visibility mask (I'll be needing all at some point but not now)
- - Remove renderqueue invoication sequence
-
 TODO:
 TODO:
  - Make sure to parse D3D9 implementations of above classes and see what needs removing there as well
  - Make sure to parse D3D9 implementations of above classes and see what needs removing there as well
  - OpenGL too
  - OpenGL too