Blender V2.61 - r43446
Functions | Variables

ImageBuff.cpp File Reference

#include <PyObjectPlus.h>
#include <structmember.h>
#include "ImageBuff.h"
#include "Exception.h"
#include "ImageBase.h"
#include "FilterSource.h"
#include "IMB_imbuf_types.h"
#include "IMB_imbuf.h"
#include "bgl.h"

Go to the source code of this file.

Functions

static int ImageBuff_init (PyObject *pySelf, PyObject *args, PyObject *kwds)
ImageBuffgetImageBuff (PyImage *self)
static bool testPyBuffer (Py_buffer *buffer, int width, int height, unsigned int pixsize)
static bool testBGLBuffer (Buffer *buffer, int width, int height, unsigned int pixsize)
static PyObject * load (PyImage *self, PyObject *args)
static PyObject * plot (PyImage *self, PyObject *args)

Variables

FilterRGB24 defFilter
PyTypeObject ImageBuffType
static PyMethodDef imageBuffMethods []
static PyGetSetDef imageBuffGetSets []

Detailed Description

Definition in file ImageBuff.cpp.


Function Documentation

ImageBuff* getImageBuff ( PyImage self) [inline]

Definition at line 193 of file ImageBuff.cpp.

Referenced by load(), and plot().

static int ImageBuff_init ( PyObject *  pySelf,
PyObject *  args,
PyObject *  kwds 
) [static]
static PyObject* load ( PyImage self,
PyObject *  args 
) [static]
static PyObject* plot ( PyImage self,
PyObject *  args 
) [static]
static bool testBGLBuffer ( Buffer buffer,
int  width,
int  height,
unsigned int  pixsize 
) [static]

Definition at line 231 of file ImageBuff.cpp.

References BGL_typeSize(), _Buffer::dimensions, i, _Buffer::ndimensions, size(), and _Buffer::type.

Referenced by load(), and plot().

static bool testPyBuffer ( Py_buffer *  buffer,
int  width,
int  height,
unsigned int  pixsize 
) [static]

Definition at line 199 of file ImageBuff.cpp.

References i, NULL, and size().

Referenced by load(), and plot().


Variable Documentation

Definition at line 42 of file ImageBuff.cpp.

PyGetSetDef imageBuffGetSets[] [static]
Initial value:
{   
    {(char*)"valid", (getter)Image_valid, NULL, (char*)"bool to tell if an image is available", NULL},
    {(char*)"image", (getter)Image_getImage, NULL, (char*)"image data", NULL},
    {(char*)"size", (getter)Image_getSize, NULL, (char*)"image size", NULL},
    {(char*)"scale", (getter)Image_getScale, (setter)Image_setScale, (char*)"fast scale of image (near neighbour)", NULL},
    {(char*)"flip", (getter)Image_getFlip, (setter)Image_setFlip, (char*)"flip image vertically", NULL},
    {(char*)"filter", (getter)Image_getFilter, (setter)Image_setFilter, (char*)"pixel filter", NULL},
    {NULL}
}

Definition at line 368 of file ImageBuff.cpp.

PyMethodDef imageBuffMethods[] [static]
Initial value:
{ 
    {"load", (PyCFunction)load, METH_VARARGS, "Load image from buffer"},
    {"plot", (PyCFunction)plot, METH_VARARGS, "update image buffer"},
    {NULL}
}

Definition at line 361 of file ImageBuff.cpp.

PyTypeObject ImageBuffType

Definition at line 381 of file ImageBuff.cpp.