Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMonique Dewanchand <m.dewanchand@atmind.nl>2012-06-01 14:20:24 +0400
committerMonique Dewanchand <m.dewanchand@atmind.nl>2012-06-01 14:20:24 +0400
commit285a24b3e07b3441e98a0a502c42af50b9738f3a (patch)
tree8b767dd73e3d5317c29f07621663fb8f0d4cf3f5 /source/blender/compositor/intern/COM_MemoryProxy.h
parenta78dca27a22d1d434dcde6d589cc7969c5039565 (diff)
Replaced tile based memory manager with a single aligned buffer
- should increase speed with large node setups - enables caching of buffers in the node editor (in the future) - OpenCL part still needs some work
Diffstat (limited to 'source/blender/compositor/intern/COM_MemoryProxy.h')
-rw-r--r--source/blender/compositor/intern/COM_MemoryProxy.h33
1 files changed, 17 insertions, 16 deletions
diff --git a/source/blender/compositor/intern/COM_MemoryProxy.h b/source/blender/compositor/intern/COM_MemoryProxy.h
index 276ebeed1e2..e0ac72de0d3 100644
--- a/source/blender/compositor/intern/COM_MemoryProxy.h
+++ b/source/blender/compositor/intern/COM_MemoryProxy.h
@@ -26,7 +26,6 @@ class MemoryProxy;
#ifndef _COM_MemoryProxy_h
#define _COM_MemoryProxy_h
#include "COM_ExecutionGroup.h"
-#include "COM_MemoryManagerState.h"
class ExecutionGroup;
@@ -49,12 +48,6 @@ private:
ExecutionGroup *executor;
/**
- * @brief data of the different chunks.
- * @note state is part of this class due to optimization in the MemoryManager
- */
- MemoryManagerState * state;
-
- /**
* @brief datatype of this MemoryProxy
*/
DataType datatype;
@@ -63,9 +56,14 @@ private:
* @brief channel information of this buffer
*/
ChannelInfo channelInfo[COM_NUMBER_OF_CHANNELS];
+
+ /**
+ * @brief the allocated memory
+ */
+ MemoryBuffer* buffer;
+
public:
MemoryProxy();
- ~MemoryProxy();
/**
* @brief set the ExecutionGroup that can be scheduled to calculate a certain chunk.
@@ -89,18 +87,21 @@ public:
* @return WriteBufferOperation
*/
WriteBufferOperation *getWriteBufferOperation() {return this->writeBufferOperation;}
-
+
/**
- * @brief set the memorymanager state of this MemoryProxy, this is set from the MemoryManager
- * @param state the state to set
+ * @brief allocate memory of size widht x height
*/
- void setState(MemoryManagerState *state) {this->state = state;}
-
+ void allocate(unsigned int width, unsigned int height);
+
+ /**
+ * @brief free the allocated memory
+ */
+ void free();
+
/**
- * @brief get the state of this MemoryProxy
- * @return MemoryManagerState reference to the state of this MemoryProxy.
+ * @brief get the allocated memory
*/
- MemoryManagerState *getState() {return this->state;}
+ inline MemoryBuffer* getBuffer() {return this->buffer;}
};
#endif