World textures displaying for viewport in BI.
This patch supports "Image or Movie" and "Environment map" types of world texture for the viewport. It supports: - "View", "AngMap" and "Equirectangular" types of mapping. - Different types of texture blending (according to BI world render). - Same color blending as when it lacked textures (but render via glsl). {F207734} {F207735} Example: {F275180} Original author: @valentin_b4w Regards, Alexander (Blend4Web Team). Reviewers: sergey, valentin_b4w, brecht, merwin Reviewed By: merwin Subscribers: campbellbarton, merwin, blueprintrandom, youle, a.romanov, yurikovelenov, AlexKowel, Evgeny_Rodygin Projects: #rendering, #opengl_gfx, #bf_blender:_next Differential Revision: https://developer.blender.org/D1414
This commit is contained in:
@@ -78,6 +78,7 @@ typedef enum GPUType {
|
||||
|
||||
GPU_TEX2D = 1002,
|
||||
GPU_SHADOW2D = 1003,
|
||||
GPU_TEXCUBE = 1004,
|
||||
GPU_ATTRIB = 3001
|
||||
} GPUType;
|
||||
|
||||
@@ -179,6 +180,7 @@ typedef enum GPUDynamicType {
|
||||
|
||||
GPU_DYNAMIC_HORIZON_COLOR = 1 | GPU_DYNAMIC_GROUP_WORLD,
|
||||
GPU_DYNAMIC_AMBIENT_COLOR = 2 | GPU_DYNAMIC_GROUP_WORLD,
|
||||
GPU_DYNAMIC_ZENITH_COLOR = 3 | GPU_DYNAMIC_GROUP_WORLD,
|
||||
|
||||
GPU_DYNAMIC_MAT_DIFFRGB = 1 | GPU_DYNAMIC_GROUP_MAT,
|
||||
GPU_DYNAMIC_MAT_REF = 2 | GPU_DYNAMIC_GROUP_MAT,
|
||||
@@ -194,6 +196,7 @@ GPUNodeLink *GPU_attribute(CustomDataType type, const char *name);
|
||||
GPUNodeLink *GPU_uniform(float *num);
|
||||
GPUNodeLink *GPU_dynamic_uniform(float *num, GPUDynamicType dynamictype, void *data);
|
||||
GPUNodeLink *GPU_image(struct Image *ima, struct ImageUser *iuser, bool is_data);
|
||||
GPUNodeLink *GPU_cube_map(struct Image *ima, struct ImageUser *iuser, bool is_data);
|
||||
GPUNodeLink *GPU_image_preview(struct PreviewImage *prv);
|
||||
GPUNodeLink *GPU_texture(int size, float *pixels);
|
||||
GPUNodeLink *GPU_dynamic_texture(struct GPUTexture *tex, GPUDynamicType dynamictype, void *data);
|
||||
|
Reference in New Issue
Block a user