Blender V5.3
mathutils_Matrix.hh File Reference
#include <Python.h>
#include "mathutils.hh"

Go to the source code of this file.

Classes

struct  blender::MatrixObject

Namespaces

namespace  blender
 BMesh Iterators.

Macros

#define MatrixObject_Check(v)
#define MatrixObject_CheckExact(v)
#define MATRIX_MAX_DIM   4
#define MATRIX_ITEM_ASSERT(_mat, _row, _col)
#define MATRIX_ITEM_INDEX_NUMROW(_totrow, _row, _col)
#define MATRIX_ITEM_INDEX(_mat, _row, _col)
#define MATRIX_ITEM_PTR(_mat, _row, _col)
#define MATRIX_ITEM(_mat, _row, _col)
#define MATRIX_COL_INDEX(_mat, _col)
#define MATRIX_COL_PTR(_mat, _col)

Functions

Matrix Type: C/API Constructors
PyObject * blender::Matrix_CreatePyObject (const float *mat, const ushort col_num, const ushort row_num, PyTypeObject *base_type)
PyObject * blender::Matrix_CreatePyObject_wrap (float *mat, const ushort col_num, const ushort row_num, PyTypeObject *base_type)
PyObject * blender::Matrix_CreatePyObject_cb (PyObject *cb_user, const ushort col_num, const ushort row_num, uchar cb_type, uchar cb_subtype)
PyObject * blender::Matrix_CreatePyObject_alloc (float *mat, const ushort col_num, const ushort row_num, PyTypeObject *base_type)
Matrix Type: C/API Parse Utilities
int blender::Matrix_ParseAny (PyObject *o, void *p)
int blender::Matrix_Parse2x2 (PyObject *o, void *p)
int blender::Matrix_Parse3x3 (PyObject *o, void *p)
int blender::Matrix_Parse4x4 (PyObject *o, void *p)
Utilities
void blender::matrix_as_3x3 (float mat[3][3], MatrixObject *self)

Macro Definition Documentation

◆ MATRIX_COL_INDEX

#define MATRIX_COL_INDEX ( _mat,
_col )
Value:
(MATRIX_ITEM_INDEX(_mat, 0, _col))
#define MATRIX_ITEM_INDEX(_mat, _row, _col)

Definition at line 42 of file mathutils_Matrix.hh.

◆ MATRIX_COL_PTR

#define MATRIX_COL_PTR ( _mat,
_col )
Value:
((_mat)->matrix + MATRIX_COL_INDEX(_mat, _col))
#define MATRIX_COL_INDEX(_mat, _col)

Definition at line 43 of file mathutils_Matrix.hh.

Referenced by blender::matrix_as_3x3(), blender::Matrix_resize_4x4(), blender::Matrix_to_NxN(), and blender::Matrix_to_translation().

◆ MATRIX_ITEM

◆ MATRIX_ITEM_ASSERT

#define MATRIX_ITEM_ASSERT ( _mat,
_row,
_col )
Value:
(BLI_assert(_row < (_mat)->row_num && _col < (_mat)->col_num))
#define BLI_assert(a)

Definition at line 30 of file mathutils_Matrix.hh.

◆ MATRIX_ITEM_INDEX

#define MATRIX_ITEM_INDEX ( _mat,
_row,
_col )
Value:
(MATRIX_ITEM_ASSERT(_mat, _row, _col), (((_mat)->row_num * (_col)) + (_row)))
#define MATRIX_ITEM_ASSERT(_mat, _row, _col)

Definition at line 37 of file mathutils_Matrix.hh.

◆ MATRIX_ITEM_INDEX_NUMROW

#define MATRIX_ITEM_INDEX_NUMROW ( _totrow,
_row,
_col )
Value:
(((_totrow) * (_col)) + (_row))

Definition at line 36 of file mathutils_Matrix.hh.

Referenced by blender::matrix_invert_with_det_n_internal().

◆ MATRIX_ITEM_PTR

#define MATRIX_ITEM_PTR ( _mat,
_row,
_col )
Value:
((_mat)->matrix + MATRIX_ITEM_INDEX(_mat, _row, _col))

Definition at line 39 of file mathutils_Matrix.hh.

◆ MATRIX_MAX_DIM

◆ MatrixObject_Check

◆ MatrixObject_CheckExact

#define MatrixObject_CheckExact ( v)
Value:
(Py_TYPE(v) == &matrix_Type)

Definition at line 23 of file mathutils_Matrix.hh.