Changeset View
Changeset View
Standalone View
Standalone View
source/blender/gpu/GPU_material.h
| Show First 20 Lines • Show All 55 Lines • ▼ Show 20 Lines | |||||
| struct GPUNodeLink; | struct GPUNodeLink; | ||||
| struct GPUNodeStack; | struct GPUNodeStack; | ||||
| struct GPUMaterial; | struct GPUMaterial; | ||||
| struct GPUTexture; | struct GPUTexture; | ||||
| struct GPULamp; | struct GPULamp; | ||||
| struct PreviewImage; | struct PreviewImage; | ||||
| struct World; | struct World; | ||||
| typedef struct GPUNode GPUNode; | typedef struct GPUNode GPUNode; | ||||
hg1: I will remove the struct GPUWorldand and typedef struct GPUWorld GPUWorld. I don't use the… | |||||
| typedef struct GPUNodeLink GPUNodeLink; | typedef struct GPUNodeLink GPUNodeLink; | ||||
| typedef struct GPUMaterial GPUMaterial; | typedef struct GPUMaterial GPUMaterial; | ||||
| typedef struct GPULamp GPULamp; | typedef struct GPULamp GPULamp; | ||||
| /* Functions to create GPU Materials nodes */ | /* Functions to create GPU Materials nodes */ | ||||
| typedef enum GPUType { | typedef enum GPUType { | ||||
| /* The value indicates the number of elements in each type */ | /* The value indicates the number of elements in each type */ | ||||
| ▲ Show 20 Lines • Show All 71 Lines • ▼ Show 20 Lines | typedef enum GPUDynamicType { | ||||
| GPU_DYNAMIC_SAMPLER_2DBUFFER = 12, | GPU_DYNAMIC_SAMPLER_2DBUFFER = 12, | ||||
| GPU_DYNAMIC_SAMPLER_2DIMAGE = 13, | GPU_DYNAMIC_SAMPLER_2DIMAGE = 13, | ||||
| GPU_DYNAMIC_SAMPLER_2DSHADOW = 14, | GPU_DYNAMIC_SAMPLER_2DSHADOW = 14, | ||||
| GPU_DYNAMIC_LAMP_DISTANCE = 16, | GPU_DYNAMIC_LAMP_DISTANCE = 16, | ||||
| GPU_DYNAMIC_LAMP_ATT1 = 17, | GPU_DYNAMIC_LAMP_ATT1 = 17, | ||||
| GPU_DYNAMIC_LAMP_ATT2 = 18, | GPU_DYNAMIC_LAMP_ATT2 = 18, | ||||
| GPU_DYNAMIC_LAMP_SPOTSIZE = 19, | GPU_DYNAMIC_LAMP_SPOTSIZE = 19, | ||||
| GPU_DYNAMIC_LAMP_SPOTBLEND = 20, | GPU_DYNAMIC_LAMP_SPOTBLEND = 20, | ||||
| GPU_DYNAMIC_MIST_ENABLE = 21, | |||||
| GPU_DYNAMIC_MIST_START = 22, | |||||
| GPU_DYNAMIC_MIST_DISTANCE = 23, | |||||
| GPU_DYNAMIC_MIST_INTENSITY = 24, | |||||
| GPU_DYNAMIC_MIST_TYPE = 25, | |||||
| GPU_DYNAMIC_MIST_COLOR = 26, | |||||
| GPU_DYNAMIC_HORIZON_COLOR = 27, | |||||
| GPU_DYNAMIC_AMBIENT_COLOR = 28, | |||||
| } GPUDynamicType; | } GPUDynamicType; | ||||
| GPUNodeLink *GPU_attribute(CustomDataType type, const char *name); | GPUNodeLink *GPU_attribute(CustomDataType type, const char *name); | ||||
| GPUNodeLink *GPU_uniform(float *num); | GPUNodeLink *GPU_uniform(float *num); | ||||
| GPUNodeLink *GPU_dynamic_uniform(float *num, GPUDynamicType dynamictype, void *data); | GPUNodeLink *GPU_dynamic_uniform(float *num, GPUDynamicType dynamictype, void *data); | ||||
| GPUNodeLink *GPU_image(struct Image *ima, struct ImageUser *iuser, bool is_data); | GPUNodeLink *GPU_image(struct Image *ima, struct ImageUser *iuser, bool is_data); | ||||
| GPUNodeLink *GPU_image_preview(struct PreviewImage *prv); | GPUNodeLink *GPU_image_preview(struct PreviewImage *prv); | ||||
| GPUNodeLink *GPU_texture(int size, float *pixels); | GPUNodeLink *GPU_texture(int size, float *pixels); | ||||
| ▲ Show 20 Lines • Show All 108 Lines • ▼ Show 20 Lines | |||||
| void GPU_lamp_update(GPULamp *lamp, int lay, int hide, float obmat[4][4]); | void GPU_lamp_update(GPULamp *lamp, int lay, int hide, float obmat[4][4]); | ||||
| void GPU_lamp_update_colors(GPULamp *lamp, float r, float g, float b, float energy); | void GPU_lamp_update_colors(GPULamp *lamp, float r, float g, float b, float energy); | ||||
| void GPU_lamp_update_distance(GPULamp *lamp, float distance, float att1, float att2); | void GPU_lamp_update_distance(GPULamp *lamp, float distance, float att1, float att2); | ||||
| void GPU_lamp_update_spot(GPULamp *lamp, float spotsize, float spotblend); | void GPU_lamp_update_spot(GPULamp *lamp, float spotsize, float spotblend); | ||||
| int GPU_lamp_shadow_layer(GPULamp *lamp); | int GPU_lamp_shadow_layer(GPULamp *lamp); | ||||
| GPUNodeLink *GPU_lamp_get_data(GPUMaterial *mat, GPULamp *lamp, GPUNodeLink **col, GPUNodeLink **lv, GPUNodeLink **dist, GPUNodeLink **shadow, GPUNodeLink **energy); | GPUNodeLink *GPU_lamp_get_data(GPUMaterial *mat, GPULamp *lamp, GPUNodeLink **col, GPUNodeLink **lv, GPUNodeLink **dist, GPUNodeLink **shadow, GPUNodeLink **energy); | ||||
| /* World */ | |||||
| void GPU_mist_update_enable(short enable); | |||||
| void GPU_mist_update_values(int type, float start, float dist, float inten, float color[3]); | |||||
| void GPU_horizon_update_color(float color[3]); | |||||
| void GPU_ambient_update_color(float color[3]); | |||||
| #ifdef __cplusplus | #ifdef __cplusplus | ||||
| } | } | ||||
| #endif | #endif | ||||
| #endif /*__GPU_MATERIAL_H__*/ | #endif /*__GPU_MATERIAL_H__*/ | ||||
I will remove the struct GPUWorldand and typedef struct GPUWorld GPUWorld. I don't use the structure in the header or somewhere else, so the definition is not necessary.