Changeset View
Changeset View
Standalone View
Standalone View
source/blender/editors/include/ED_view3d.h
| Show First 20 Lines • Show All 157 Lines • ▼ Show 20 Lines | |||||
| /* Projection */ | /* Projection */ | ||||
| #define IS_CLIPPED 12000 | #define IS_CLIPPED 12000 | ||||
| /* return values for ED_view3d_project_...() */ | /* return values for ED_view3d_project_...() */ | ||||
| typedef enum { | typedef enum { | ||||
| V3D_PROJ_RET_OK = 0, | V3D_PROJ_RET_OK = 0, | ||||
| /** can't avoid this when in perspective mode, (can't avoid) */ | /** can't avoid this when in perspective mode, (can't avoid) */ | ||||
| V3D_PROJ_RET_CLIP_NEAR = 1, | V3D_PROJ_RET_CLIP_NEAR = 1, | ||||
| /** After clip_end. */ | |||||
| V3D_PROJ_RET_CLIP_FAR = 2, | |||||
| /** so close to zero we can't apply a perspective matrix usefully */ | /** so close to zero we can't apply a perspective matrix usefully */ | ||||
| V3D_PROJ_RET_CLIP_ZERO = 2, | V3D_PROJ_RET_CLIP_ZERO = 3, | ||||
| /** bounding box clip - RV3D_CLIPPING */ | /** bounding box clip - RV3D_CLIPPING */ | ||||
| V3D_PROJ_RET_CLIP_BB = 3, | V3D_PROJ_RET_CLIP_BB = 4, | ||||
| /** outside window bounds */ | /** outside window bounds */ | ||||
| V3D_PROJ_RET_CLIP_WIN = 4, | V3D_PROJ_RET_CLIP_WIN = 5, | ||||
| /** outside range (mainly for short), (can't avoid) */ | /** outside range (mainly for short), (can't avoid) */ | ||||
| V3D_PROJ_RET_OVERFLOW = 5, | V3D_PROJ_RET_OVERFLOW = 6, | ||||
| } eV3DProjStatus; | } eV3DProjStatus; | ||||
| /* some clipping tests are optional */ | /* some clipping tests are optional */ | ||||
| typedef enum { | typedef enum { | ||||
| V3D_PROJ_TEST_NOP = 0, | V3D_PROJ_TEST_NOP = 0, | ||||
| V3D_PROJ_TEST_CLIP_BB = (1 << 0), | V3D_PROJ_TEST_CLIP_BB = (1 << 0), | ||||
| V3D_PROJ_TEST_CLIP_WIN = (1 << 1), | V3D_PROJ_TEST_CLIP_WIN = (1 << 1), | ||||
| V3D_PROJ_TEST_CLIP_NEAR = (1 << 2), | V3D_PROJ_TEST_CLIP_NEAR = (1 << 2), | ||||
| V3D_PROJ_TEST_CLIP_ZERO = (1 << 3), | V3D_PROJ_TEST_CLIP_FAR = (1 << 3), | ||||
| V3D_PROJ_TEST_CLIP_ZERO = (1 << 4), | |||||
| } eV3DProjTest; | } eV3DProjTest; | ||||
| #define V3D_PROJ_TEST_CLIP_DEFAULT \ | #define V3D_PROJ_TEST_CLIP_DEFAULT \ | ||||
| (V3D_PROJ_TEST_CLIP_BB | V3D_PROJ_TEST_CLIP_WIN | V3D_PROJ_TEST_CLIP_NEAR) | (V3D_PROJ_TEST_CLIP_BB | V3D_PROJ_TEST_CLIP_WIN | V3D_PROJ_TEST_CLIP_NEAR) | ||||
| #define V3D_PROJ_TEST_ALL \ | #define V3D_PROJ_TEST_ALL \ | ||||
| (V3D_PROJ_TEST_CLIP_BB | V3D_PROJ_TEST_CLIP_WIN | V3D_PROJ_TEST_CLIP_NEAR | \ | (V3D_PROJ_TEST_CLIP_DEFAULT | V3D_PROJ_TEST_CLIP_FAR | V3D_PROJ_TEST_CLIP_ZERO) | ||||
| V3D_PROJ_TEST_CLIP_ZERO) | |||||
| /* view3d_iterators.c */ | /* view3d_iterators.c */ | ||||
| /* foreach iterators */ | /* foreach iterators */ | ||||
| void meshobject_foreachScreenVert( | void meshobject_foreachScreenVert( | ||||
| struct ViewContext *vc, | struct ViewContext *vc, | ||||
| void (*func)(void *userData, struct MVert *eve, const float screen_co[2], int index), | void (*func)(void *userData, struct MVert *eve, const float screen_co[2], int index), | ||||
| void *userData, | void *userData, | ||||
| ▲ Show 20 Lines • Show All 544 Lines • Show Last 20 Lines | |||||