Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSergey Sharybin <sergey.vfx@gmail.com>2011-06-06 00:54:04 +0400
committerSergey Sharybin <sergey.vfx@gmail.com>2011-06-06 00:54:04 +0400
commita1c22262fef25de91dbafd7b401e349538dc3d61 (patch)
treeeeb0092df131068785f7d0e03a5f47c111fb04a9 /source/blender/imbuf/IMB_imbuf.h
parenta580b5ec80d5c0744b63f9b7e8048c0f16681a38 (diff)
Bake from multires mesh
======================= Added option to baked named "Bake From Multires" which is avaliable for normals baking and displacement baking. If this option is enabled, then no additional hi-res meshes and render structures would be created . This saves plenty of memory and meshes with millions of faces could be successfully baked in few minutes. Baking happens from highest level against viewport subdivision level, so workflow is following: - Set viewport level to level at which texture would be applied during final rendering. - Choose Displacement/Normals baking. - Enable "Bake From Multires" option. - You're ready to bake. Displacement baker had aditional option named "Low Resolution Mesh". This option is used to set if you want texture for realtime (games) usage. Internally it does the following: - If it's disabled, displacement is calculated from subdivided viewport level, so texture looks "smooth" (it's how default baked works). - If it's enabled, dispalcement is calculated against unsubdivided viewport levels. This leads to "scales". This isn;t useful for offline renders much, but very useful for creating game textures. Special thanks to Morten Mikkelsen (aka sparky) for all mathematics and other work he've done fr this patch!
Diffstat (limited to 'source/blender/imbuf/IMB_imbuf.h')
-rw-r--r--source/blender/imbuf/IMB_imbuf.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/source/blender/imbuf/IMB_imbuf.h b/source/blender/imbuf/IMB_imbuf.h
index 21249c9e8f7..1eefc58d4de 100644
--- a/source/blender/imbuf/IMB_imbuf.h
+++ b/source/blender/imbuf/IMB_imbuf.h
@@ -243,8 +243,15 @@ void IMB_free_anim(struct anim *anim);
*
* @attention Defined in filter.c
*/
+
+#define FILTER_MASK_NULL 0
+#define FILTER_MASK_MARGIN 1
+#define FILTER_MASK_USED 2
+
void IMB_filter(struct ImBuf *ibuf);
void IMB_filterN(struct ImBuf *out, struct ImBuf *in);
+void IMB_mask_filter_extend(char *mask, int width, int height);
+void IMB_mask_clear(struct ImBuf *ibuf, char *mask, int val);
void IMB_filter_extend(struct ImBuf *ibuf, char *mask);
void IMB_makemipmap(struct ImBuf *ibuf, int use_filter);
void IMB_remakemipmap(struct ImBuf *ibuf, int use_filter);