Diez B. Roggisch wrote:
> 
> And obviously enough, compiling my wrapper fails because there is an
> argument missing.
> 
> So, I'm in need for a guide on how to use PyBuffer_FillInfo properly -
> all I've got is a void* and a total size of the buffer.

The second argument points to the (optional) object for that you are
creating the view. The code in Object/stringobject.c is a good example:

static int
string_buffer_getbuffer(PyStringObject *self, Py_buffer *view, int flags)
{
        return PyBuffer_FillInfo(view, (PyObject*)self,
                                 (void *)self->ob_sval, Py_SIZE(self),
                                 1, flags);
}

Christian

-- 
http://mail.python.org/mailman/listinfo/python-list

Reply via email to