From edbd3ebcdc86cb1e5e20759fc7ad71ea41b0faf9 Mon Sep 17 00:00:00 2001 From: Sergey Sharybin Date: Fri, 19 May 2017 10:55:26 +0200 Subject: Compositor: Remove unused funciton --- .../compositor/operations/COM_TextureOperation.cpp | 28 ---------------------- .../compositor/operations/COM_TextureOperation.h | 2 -- 2 files changed, 30 deletions(-) (limited to 'source/blender/compositor') diff --git a/source/blender/compositor/operations/COM_TextureOperation.cpp b/source/blender/compositor/operations/COM_TextureOperation.cpp index 6bfd8ae3888..5d465df99ca 100644 --- a/source/blender/compositor/operations/COM_TextureOperation.cpp +++ b/source/blender/compositor/operations/COM_TextureOperation.cpp @@ -155,31 +155,3 @@ void TextureBaseOperation::executePixelSampled(float output[4], float x, float y output[0] = output[1] = output[2] = output[3]; } } - -MemoryBuffer *TextureBaseOperation::createMemoryBuffer(rcti * /*rect2*/) -{ - int height = getHeight(); - int width = getWidth(); - DataType datatype = this->getOutputSocket()->getDataType(); - int add = 4; - if (datatype == COM_DT_VALUE) { - add = 1; - } - - rcti rect; - rect.xmin = 0; - rect.ymin = 0; - rect.xmax = width; - rect.ymax = height; - MemoryBuffer *result = new MemoryBuffer(datatype, &rect); - - float *data = result->getBuffer(); - - for (int y = 0; y < height; y++) { - for (int x = 0; x < width; x++, data += add) { - this->executePixelSampled(data, x, y, COM_PS_NEAREST); - } - } - - return result; -} diff --git a/source/blender/compositor/operations/COM_TextureOperation.h b/source/blender/compositor/operations/COM_TextureOperation.h index 4cc203b54a2..59ff58a7289 100644 --- a/source/blender/compositor/operations/COM_TextureOperation.h +++ b/source/blender/compositor/operations/COM_TextureOperation.h @@ -59,8 +59,6 @@ protected: * Constructor */ TextureBaseOperation(); - - MemoryBuffer *createMemoryBuffer(rcti *rect2); public: void executePixelSampled(float output[4], float x, float y, PixelSampler sampler); -- cgit v1.2.3