diff options
author | Miika Hamalainen <blender@miikah.org> | 2011-09-20 21:51:04 +0400 |
---|---|---|
committer | Miika Hamalainen <blender@miikah.org> | 2011-09-20 21:51:04 +0400 |
commit | 15cb47bf91820aac3a3881e94378067472c07e1b (patch) | |
tree | f8db8dd34c6a0b660ad1816e002c9ef3af939b00 /source/blender/render/intern/include | |
parent | 9de082dbf4130b48d59e673ed276a046d97cc1e4 (diff) | |
parent | bc788a3607eda1889c7f0fe2201116826a9394ee (diff) |
Merge with trunk r40409
Diffstat (limited to 'source/blender/render/intern/include')
10 files changed, 25 insertions, 25 deletions
diff --git a/source/blender/render/intern/include/pixelshading.h b/source/blender/render/intern/include/pixelshading.h index 0298f90c0d0..feabfea9319 100644 --- a/source/blender/render/intern/include/pixelshading.h +++ b/source/blender/render/intern/include/pixelshading.h @@ -58,10 +58,10 @@ int shadeHaloFloat(HaloRen *har, /** * Render the sky at pixel (x, y). */ -void shadeSkyPixel(float *collector, float fx, float fy, short thread); -void shadeSkyView(float *colf, float *rco, float *view, float *dxyview, short thread); +void shadeSkyPixel(float collector[4], float fx, float fy, short thread); +void shadeSkyView(float col_r[3], const float rco[3], const float view[3], const float dxyview[2], short thread); void shadeAtmPixel(struct SunSky *sunsky, float *collector, float fx, float fy, float distance); -void shadeSunView(float *colf, float *view); +void shadeSunView(float col_r[3], const float view[3]); /* ------------------------------------------------------------------------- */ #endif diff --git a/source/blender/render/intern/include/render_types.h b/source/blender/render/intern/include/render_types.h index 13ca40bfd20..0b339d285ce 100644 --- a/source/blender/render/intern/include/render_types.h +++ b/source/blender/render/intern/include/render_types.h @@ -338,7 +338,7 @@ typedef struct ObjectInstanceRen { struct VolumePrecache *volume_precache; - float *vectors; + float *vectors; /* (RE_WINSPEED_ELEMS * VertRen.index) */ int totvector; /* used on makeraytree */ @@ -354,8 +354,8 @@ typedef struct VertRen float co[3]; float n[3]; float *orco; - short clip; - unsigned short flag; /* in use for clipping zbuffer parts, temp setting stuff in convertblender.c */ + unsigned int flag; /* in use for clipping zbuffer parts, temp setting stuff in convertblender.c + * only an 'int' because of alignment, could be a char too */ float accum; /* accum for radio weighting, and for strand texco static particles */ int index; /* index allows extending vertren with any property */ } VertRen; diff --git a/source/blender/render/intern/include/rendercore.h b/source/blender/render/intern/include/rendercore.h index 67c3cbcebe2..f9486b5d5c0 100644 --- a/source/blender/render/intern/include/rendercore.h +++ b/source/blender/render/intern/include/rendercore.h @@ -81,8 +81,8 @@ float mistfactor(float zcor, float *co); /* dist and height, return alpha */ void renderspothalo(struct ShadeInput *shi, float *col, float alpha); void add_halo_flare(Render *re); -void calc_renderco_zbuf(float *co, float *view, int z); -void calc_renderco_ortho(float *co, float x, float y, int z); +void calc_renderco_zbuf(float co[3], float *view, int z); +void calc_renderco_ortho(float co[3], float x, float y, int z); int count_mask(unsigned short mask); diff --git a/source/blender/render/intern/include/renderdatabase.h b/source/blender/render/intern/include/renderdatabase.h index e1fa208d0b6..06185d0ae74 100644 --- a/source/blender/render/intern/include/renderdatabase.h +++ b/source/blender/render/intern/include/renderdatabase.h @@ -91,7 +91,7 @@ void free_renderdata_vertnodes(struct VertTableNode *vertnodes); void free_renderdata_vlaknodes(struct VlakTableNode *vlaknodes); void set_normalflags(struct Render *re, struct ObjectRen *obr); -void project_renderdata(struct Render *re, void (*projectfunc)(float *, float mat[][4], float *), int do_pano, float xoffs, int do_buckets); +void project_renderdata(struct Render *re, void (*projectfunc)(const float *, float mat[][4], float *), int do_pano, float xoffs, int do_buckets); int clip_render_object(float boundbox[][3], float *bounds, float mat[][4]); /* functions are not exported... so wrong names */ diff --git a/source/blender/render/intern/include/shadbuf.h b/source/blender/render/intern/include/shadbuf.h index 2dca9963e4f..5bed39db3e9 100644 --- a/source/blender/render/intern/include/shadbuf.h +++ b/source/blender/render/intern/include/shadbuf.h @@ -59,13 +59,13 @@ void threaded_makeshadowbufs(struct Render *re); * @param inp The inproduct between viewvector and ? * */ -float testshadowbuf(struct Render *re, struct ShadBuf *shb, float *rco, float *dxco, float *dyco, float inp, float mat_bias); +float testshadowbuf(struct Render *re, struct ShadBuf *shb, const float rco[3], const float dxco[3], const float dyco[3], float inp, float mat_bias); /** * Determines the shadow factor for lamp <lar>, between <p1> * and <p2>. (Which CS?) */ -float shadow_halo(LampRen *lar, float *p1, float *p2); +float shadow_halo(LampRen *lar, const float p1[3], const float p2[3]); /** * Irregular shadowbuffer diff --git a/source/blender/render/intern/include/shading.h b/source/blender/render/intern/include/shading.h index 07d24ea6d66..91507ef3f98 100644 --- a/source/blender/render/intern/include/shading.h +++ b/source/blender/render/intern/include/shading.h @@ -63,7 +63,7 @@ void shade_volume_loop(struct ShadeInput *shi, struct ShadeResult *shr); void shade_input_set_triangle_i(struct ShadeInput *shi, struct ObjectInstanceRen *obi, struct VlakRen *vlr, short i1, short i2, short i3); void shade_input_set_triangle(struct ShadeInput *shi, volatile int obi, volatile int facenr, int normal_flip); void shade_input_copy_triangle(struct ShadeInput *shi, struct ShadeInput *from); -void shade_input_calc_viewco(struct ShadeInput *shi, float x, float y, float z, float *view, float *dxyview, float *co, float *dxco, float *dyco); +void shade_input_calc_viewco(struct ShadeInput *shi, float x, float y, float z, float view[3], float *dxyview, float *co, float *dxco, float *dyco); void shade_input_set_viewco(struct ShadeInput *shi, float x, float y, float sx, float sy, float z); void shade_input_set_uv(struct ShadeInput *shi); void shade_input_set_normals(struct ShadeInput *shi); @@ -96,7 +96,7 @@ void ambient_occlusion(struct ShadeInput *shi); void environment_lighting_apply(struct ShadeInput *shi, struct ShadeResult *shr); ListBase *get_lights(struct ShadeInput *shi); -float lamp_get_visibility(struct LampRen *lar, float *co, float *lv, float *dist); +float lamp_get_visibility(struct LampRen *lar, const float co[3], float *lv, float *dist); void lamp_get_shadow(struct LampRen *lar, ShadeInput *shi, float inp, float *shadfac, int do_real); float fresnel_fac(float *view, float *vn, float fresnel, float fac); diff --git a/source/blender/render/intern/include/texture.h b/source/blender/render/intern/include/texture.h index 1da144a099f..294c7b53766 100644 --- a/source/blender/render/intern/include/texture.h +++ b/source/blender/render/intern/include/texture.h @@ -64,11 +64,11 @@ struct ImBuf; /* texture.h */ -void do_halo_tex(struct HaloRen *har, float xn, float yn, float *colf); -void do_sky_tex(float *rco, float *lo, float *dxyview, float *hor, float *zen, float *blend, int skyflag, short thread); +void do_halo_tex(struct HaloRen *har, float xn, float yn, float col_r[4]); +void do_sky_tex(const float rco[3], float lo[3], const float dxyview[2], float hor[3], float zen[3], float *blend, int skyflag, short thread); void do_material_tex(struct ShadeInput *shi); -void do_lamp_tex(LampRen *la, float *lavec, struct ShadeInput *shi, float *colf, int effect); -void do_volume_tex(struct ShadeInput *shi, float *xyz, int mapto_flag, float *col, float *val, struct Render *re); +void do_lamp_tex(LampRen *la, const float lavec[3], struct ShadeInput *shi, float col_r[3], int effect); +void do_volume_tex(struct ShadeInput *shi, const float *xyz, int mapto_flag, float *col, float *val, struct Render *re); void init_render_textures(Render *re); void end_render_textures(Render *re); @@ -77,8 +77,8 @@ void render_realtime_texture(struct ShadeInput *shi, struct Image *ima); /* imagetexture.h */ -int imagewraposa(struct Tex *tex, struct Image *ima, struct ImBuf *ibuf, float *texvec, float *dxt, float *dyt, struct TexResult *texres); -int imagewrap(struct Tex *tex, struct Image *ima, struct ImBuf *ibuf, float *texvec, struct TexResult *texres); +int imagewraposa(struct Tex *tex, struct Image *ima, struct ImBuf *ibuf, const float texvec[3], const float dxt[3], const float dyt[3], struct TexResult *texres); +int imagewrap(struct Tex *tex, struct Image *ima, struct ImBuf *ibuf, const float texvec[3], struct TexResult *texres); void image_sample(struct Image *ima, float fx, float fy, float dx, float dy, float *result); #endif /* TEXTURE_EXT_H */ diff --git a/source/blender/render/intern/include/volumetric.h b/source/blender/render/intern/include/volumetric.h index 6d8d4cbe0f2..87d74de9134 100644 --- a/source/blender/render/intern/include/volumetric.h +++ b/source/blender/render/intern/include/volumetric.h @@ -35,8 +35,8 @@ struct Isect; struct ShadeInput; struct ShadeResult; -float vol_get_density(struct ShadeInput *shi, float *co); -void vol_get_scattering(ShadeInput *shi, float *scatter_col, float *co_); +float vol_get_density(struct ShadeInput *shi, const float co[3]); +void vol_get_scattering(ShadeInput *shi, float scatter_col[3], const float co[3], const float view[3]); void shade_volume_outside(ShadeInput *shi, ShadeResult *shr); void shade_volume_inside(ShadeInput *shi, ShadeResult *shr); diff --git a/source/blender/render/intern/include/voxeldata.h b/source/blender/render/intern/include/voxeldata.h index 2353b24f310..68e924c1f2e 100644 --- a/source/blender/render/intern/include/voxeldata.h +++ b/source/blender/render/intern/include/voxeldata.h @@ -46,6 +46,6 @@ typedef struct VoxelDataHeader void cache_voxeldata(Tex *tex, int scene_frame); void make_voxeldata(struct Render *re); void free_voxeldata(struct Render *re); -int voxeldatatex(struct Tex *tex, float *texvec, struct TexResult *texres); +int voxeldatatex(struct Tex *tex, const float texvec[3], struct TexResult *texres); #endif /* VOXELDATA_H */ diff --git a/source/blender/render/intern/include/zbuf.h b/source/blender/render/intern/include/zbuf.h index 4c87520d4d1..0d129081d62 100644 --- a/source/blender/render/intern/include/zbuf.h +++ b/source/blender/render/intern/include/zbuf.h @@ -51,9 +51,9 @@ void fillrect(int *rect, int x, int y, int val); * Converts a world coordinate into a homogenous coordinate in view * coordinates. */ -void projectvert(float *v1, float winmat[][4], float *adr); -void projectverto(float *v1, float winmat[][4], float *adr); -int testclip(float *v); +void projectvert(const float v1[3], float winmat[][4], float adr[4]); +void projectverto(const float v1[3], float winmat[][4], float adr[4]); +int testclip(const float v[3]); void zbuffer_shadow(struct Render *re, float winmat[][4], struct LampRen *lar, int *rectz, int size, float jitx, float jity); void zbuffer_abuf_shadow(struct Render *re, struct LampRen *lar, float winmat[][4], struct APixstr *APixbuf, struct APixstrand *apixbuf, struct ListBase *apsmbase, int size, int samples, float (*jit)[2]); |