Blender  V3.3
COM_MemoryProxy.cc
Go to the documentation of this file.
1 /* SPDX-License-Identifier: GPL-2.0-or-later
2  * Copyright 2011 Blender Foundation. */
3 
4 #include "COM_MemoryProxy.h"
5 #include "COM_MemoryBuffer.h"
6 
7 namespace blender::compositor {
8 
10 {
11  write_buffer_operation_ = nullptr;
12  executor_ = nullptr;
13  buffer_ = nullptr;
14  datatype_ = datatype;
15 }
16 
17 void MemoryProxy::allocate(unsigned int width, unsigned int height)
18 {
19  rcti result;
20  result.xmin = 0;
21  result.xmax = width;
22  result.ymin = 0;
23  result.ymax = height;
24 
25  buffer_ = new MemoryBuffer(this, result, MemoryBufferState::Default);
26 }
27 
29 {
30  if (buffer_) {
31  delete buffer_;
32  buffer_ = nullptr;
33  }
34 }
35 
36 } // namespace blender::compositor
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei height
_GL_VOID GLfloat value _GL_VOID_RET _GL_VOID const GLuint GLboolean *residences _GL_BOOL_RET _GL_VOID GLsizei GLfloat GLfloat GLfloat GLfloat const GLubyte *bitmap _GL_VOID_RET _GL_VOID GLenum const void *lists _GL_VOID_RET _GL_VOID const GLdouble *equation _GL_VOID_RET _GL_VOID GLdouble GLdouble blue _GL_VOID_RET _GL_VOID GLfloat GLfloat blue _GL_VOID_RET _GL_VOID GLint GLint blue _GL_VOID_RET _GL_VOID GLshort GLshort blue _GL_VOID_RET _GL_VOID GLubyte GLubyte blue _GL_VOID_RET _GL_VOID GLuint GLuint blue _GL_VOID_RET _GL_VOID GLushort GLushort blue _GL_VOID_RET _GL_VOID GLbyte GLbyte GLbyte alpha _GL_VOID_RET _GL_VOID GLdouble GLdouble GLdouble alpha _GL_VOID_RET _GL_VOID GLfloat GLfloat GLfloat alpha _GL_VOID_RET _GL_VOID GLint GLint GLint alpha _GL_VOID_RET _GL_VOID GLshort GLshort GLshort alpha _GL_VOID_RET _GL_VOID GLubyte GLubyte GLubyte alpha _GL_VOID_RET _GL_VOID GLuint GLuint GLuint alpha _GL_VOID_RET _GL_VOID GLushort GLushort GLushort alpha _GL_VOID_RET _GL_VOID GLenum mode _GL_VOID_RET _GL_VOID GLint GLsizei width
a MemoryBuffer contains access to the data of a chunk
void free()
free the allocated memory
void allocate(unsigned int width, unsigned int height)
allocate memory of size width x height
@ Default
memory has been allocated on creator device and CPU machine, but kernel has not been executed
DataType
possible data types for sockets
Definition: COM_defines.h:30