diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-04-10 18:11:45 +0400 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2012-04-10 18:11:45 +0400 |
commit | 5eca59cf0d05fd8063eb83ad80b2caf9c5eacedc (patch) | |
tree | ebd47eec797e9dd6e93217054a37b0ce6541ddb6 /source/blender/modifiers/intern/MOD_util.c | |
parent | 8adc27688597baf212adcab841b42e3e07bcb0bc (diff) |
Fix #30882: using an image sequence in the displace modifier did not update
properly in animation rendering.
Diffstat (limited to 'source/blender/modifiers/intern/MOD_util.c')
-rw-r--r-- | source/blender/modifiers/intern/MOD_util.c | 16 |
1 files changed, 14 insertions, 2 deletions
diff --git a/source/blender/modifiers/intern/MOD_util.c b/source/blender/modifiers/intern/MOD_util.c index 17ff4dd1842..e134ff9dcca 100644 --- a/source/blender/modifiers/intern/MOD_util.c +++ b/source/blender/modifiers/intern/MOD_util.c @@ -32,11 +32,13 @@ #include <string.h> +#include "DNA_curve_types.h" +#include "DNA_image_types.h" #include "DNA_lattice_types.h" +#include "DNA_meshdata_types.h" #include "DNA_modifier_types.h" #include "DNA_object_types.h" -#include "DNA_curve_types.h" -#include "DNA_meshdata_types.h" +#include "DNA_scene_types.h" #include "BLI_utildefines.h" #include "BLI_math_vector.h" @@ -44,6 +46,7 @@ #include "BKE_cdderivedmesh.h" #include "BKE_deform.h" +#include "BKE_image.h" #include "BKE_lattice.h" #include "BKE_mesh.h" #include "BKE_displist.h" @@ -57,6 +60,15 @@ #include "RE_shader_ext.h" +void modifier_init_texture(Scene *scene, Tex *tex) +{ + if (!tex) + return; + + if (tex->ima && ELEM(tex->ima->source, IMA_SRC_MOVIE, IMA_SRC_SEQUENCE)) + BKE_image_user_calc_frame(&tex->iuser, scene->r.cfra, 0); +} + void get_texture_value(Tex *texture, float *tex_co, TexResult *texres) { int result_type; |