Cleanup: clang format

This commit is contained in:
2021-04-01 11:15:47 +11:00
parent 93972c8910
commit d5c6485372
16 changed files with 63 additions and 36 deletions

View File

@@ -30,8 +30,8 @@ extern PyTypeObject BPyGPUBatch_Type;
typedef struct BPyGPUBatch {
PyObject_VAR_HEAD
/* The batch is owned, we may support thin wrapped batches later. */
struct GPUBatch *batch;
/* The batch is owned, we may support thin wrapped batches later. */
struct GPUBatch *batch;
#ifdef USE_GPU_PY_REFERENCES
/* Just to keep a user to prevent freeing buf's we're using */
PyObject *references;

View File

@@ -30,7 +30,8 @@ extern PyTypeObject BPyGPU_BufferType;
* For Python access to GPU functions requiring a pointer.
*/
typedef struct BPyGPUBuffer {
PyObject_VAR_HEAD PyObject *parent;
PyObject_VAR_HEAD
PyObject *parent;
int format;
int shape_len;

View File

@@ -25,7 +25,8 @@ extern PyTypeObject BPyGPUIndexBuf_Type;
#define BPyGPUIndexBuf_Check(v) (Py_TYPE(v) == &BPyGPUIndexBuf_Type)
typedef struct BPyGPUIndexBuf {
PyObject_VAR_HEAD struct GPUIndexBuf *elem;
PyObject_VAR_HEAD
struct GPUIndexBuf *elem;
} BPyGPUIndexBuf;
PyObject *BPyGPUIndexBuf_CreatePyObject(struct GPUIndexBuf *elem);

View File

@@ -25,7 +25,8 @@ extern PyTypeObject BPyGPUShader_Type;
#define BPyGPUShader_Check(v) (Py_TYPE(v) == &BPyGPUShader_Type)
typedef struct BPyGPUShader {
PyObject_VAR_HEAD struct GPUShader *shader;
PyObject_VAR_HEAD
struct GPUShader *shader;
bool is_builtin;
} BPyGPUShader;

View File

@@ -28,8 +28,8 @@ extern PyTypeObject BPyGPUVertBuf_Type;
typedef struct BPyGPUVertBuf {
PyObject_VAR_HEAD
/* The buf is owned, we may support thin wrapped batches later. */
struct GPUVertBuf *buf;
/* The buf is owned, we may support thin wrapped batches later. */
struct GPUVertBuf *buf;
} BPyGPUVertBuf;
PyObject *BPyGPUVertBuf_CreatePyObject(struct GPUVertBuf *buf) ATTR_NONNULL(1);

View File

@@ -27,7 +27,8 @@ extern PyTypeObject BPyGPUVertFormat_Type;
#define BPyGPUVertFormat_Check(v) (Py_TYPE(v) == &BPyGPUVertFormat_Type)
typedef struct BPyGPUVertFormat {
PyObject_VAR_HEAD struct GPUVertFormat fmt;
PyObject_VAR_HEAD
struct GPUVertFormat fmt;
} BPyGPUVertFormat;
PyObject *BPyGPUVertFormat_CreatePyObject(struct GPUVertFormat *fmt);