diff options
Diffstat (limited to 'source/blender/blenkernel')
-rw-r--r-- | source/blender/blenkernel/BKE_plugin_types.h | 68 | ||||
-rw-r--r-- | source/blender/blenkernel/BKE_sequencer.h | 3 | ||||
-rw-r--r-- | source/blender/blenkernel/BKE_texture.h | 5 | ||||
-rw-r--r-- | source/blender/blenkernel/CMakeLists.txt | 1 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/material.c | 2 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/seqeffects.c | 297 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/sequencer.c | 10 | ||||
-rw-r--r-- | source/blender/blenkernel/intern/texture.c | 166 |
8 files changed, 4 insertions, 548 deletions
diff --git a/source/blender/blenkernel/BKE_plugin_types.h b/source/blender/blenkernel/BKE_plugin_types.h deleted file mode 100644 index f3c5db02427..00000000000 --- a/source/blender/blenkernel/BKE_plugin_types.h +++ /dev/null @@ -1,68 +0,0 @@ -/* - * ***** BEGIN GPL LICENSE BLOCK ***** - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public License - * as published by the Free Software Foundation; either version 2 - * of the License, or (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software Foundation, - * Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. - * - * The Original Code is Copyright (C) 2001-2002 by NaN Holding BV. - * All rights reserved. - * - * The Original Code is: all of this file. - * - * Contributor(s): none yet. - * - * ***** END GPL LICENSE BLOCK ***** - */ -#ifndef __BKE_PLUGIN_TYPES_H__ -#define __BKE_PLUGIN_TYPES_H__ - -/** \file BKE_plugin_types.h - * \ingroup bke - * \author nzc - */ - -struct ImBuf; - -typedef int (*TexDoitold)(int stype, void *cast, float *texvec, float *dxt, float *dyt); -typedef int (*TexDoit)(int stype, void *cast, float *texvec, float *dxt, float *dyt, float *result); -typedef void (*SeqDoit)(void *, float, float, int, int, - struct ImBuf *, struct ImBuf *, - struct ImBuf *, struct ImBuf *); - -typedef struct VarStruct { - int type; - char name[16]; - float def, min, max; - char tip[80]; -} VarStruct; - -typedef struct _PluginInfo { - char *name; - char *snames; - - int stypes; - int nvars; - VarStruct *varstr; - float *result; - float *cfra; - - void (*init)(void); - void (*callback)(int); - void (*tex_doit)(void *); - SeqDoit seq_doit; - void (*instance_init)(void *); -} PluginInfo; - -#endif - diff --git a/source/blender/blenkernel/BKE_sequencer.h b/source/blender/blenkernel/BKE_sequencer.h index f06e0e2f71a..d6c1a26fdba 100644 --- a/source/blender/blenkernel/BKE_sequencer.h +++ b/source/blender/blenkernel/BKE_sequencer.h @@ -113,9 +113,8 @@ enum { struct SeqEffectHandle { /* constructors & destructor */ - /* init & init_plugin are _only_ called on first creation */ + /* init is _only_ called on first creation */ void (*init)(struct Sequence *seq); - void (*init_plugin)(struct Sequence *seq, const char *fname); /* number of input strips needed * (called directly after construction) */ diff --git a/source/blender/blenkernel/BKE_texture.h b/source/blender/blenkernel/BKE_texture.h index 339b78ae2d1..78fdd26c9e0 100644 --- a/source/blender/blenkernel/BKE_texture.h +++ b/source/blender/blenkernel/BKE_texture.h @@ -48,7 +48,6 @@ struct Material; struct MTex; struct OceanTex; struct ParticleSettings; -struct PluginTex; struct PointDensity; struct Tex; struct TexMapping; @@ -60,10 +59,6 @@ struct World; void BKE_texture_free(struct Tex *t); -int test_dlerr(const char *name, const char *symbol); -void open_plugin_tex(struct PluginTex *pit); -struct PluginTex *add_plugin_tex(char *str); -void free_plugin_tex(struct PluginTex *pit); void init_colorband(struct ColorBand *coba, int rangetype); struct ColorBand *add_colorband(int rangetype); diff --git a/source/blender/blenkernel/CMakeLists.txt b/source/blender/blenkernel/CMakeLists.txt index a791d6f269f..d207a08c6cb 100644 --- a/source/blender/blenkernel/CMakeLists.txt +++ b/source/blender/blenkernel/CMakeLists.txt @@ -201,7 +201,6 @@ set(SRC BKE_packedFile.h BKE_paint.h BKE_particle.h - BKE_plugin_types.h BKE_pointcache.h BKE_property.h BKE_report.h diff --git a/source/blender/blenkernel/intern/material.c b/source/blender/blenkernel/intern/material.c index 55ae7e4d11a..adf268d4d02 100644 --- a/source/blender/blenkernel/intern/material.c +++ b/source/blender/blenkernel/intern/material.c @@ -903,7 +903,7 @@ static void do_init_render_material(Material *ma, int r_mode, float *amb) ma->mapto |= mtex->mapto; /* always get derivatives for these textures */ - if (ELEM3(mtex->tex->type, TEX_IMAGE, TEX_PLUGIN, TEX_ENVMAP)) ma->texco |= TEXCO_OSA; + if (ELEM(mtex->tex->type, TEX_IMAGE, TEX_ENVMAP)) ma->texco |= TEXCO_OSA; else if (mtex->texflag & (MTEX_COMPAT_BUMP | MTEX_3TAP_BUMP | MTEX_5TAP_BUMP | MTEX_BICUBIC_BUMP)) ma->texco |= TEXCO_OSA; if (ma->texco & (TEXCO_ORCO | TEXCO_REFL | TEXCO_NORM | TEXCO_STRAND | TEXCO_STRESS)) needuv = 1; diff --git a/source/blender/blenkernel/intern/seqeffects.c b/source/blender/blenkernel/intern/seqeffects.c index 252ddb78887..cea041eb294 100644 --- a/source/blender/blenkernel/intern/seqeffects.c +++ b/source/blender/blenkernel/intern/seqeffects.c @@ -47,7 +47,6 @@ #include "BKE_fcurve.h" #include "BKE_main.h" -#include "BKE_plugin_types.h" #include "BKE_sequencer.h" #include "BKE_texture.h" #include "BKE_utildefines.h" @@ -60,11 +59,6 @@ /* **** XXX **** */ static void error(const char *UNUSED(error), ...) {} -#define INT 96 -#define FLO 128 - -/* **** XXX **** */ - /* Glow effect */ enum { GlowR = 0, @@ -122,281 +116,6 @@ static ImBuf *prepare_effect_imbufs( } /* ********************************************************************** - * PLUGINS - * ********************************************************************** */ - -static void open_plugin_seq(PluginSeq *pis, const char *seqname) -{ - int (*version)(void); - void * (*alloc_private)(void); - char *cp; - - /* to be sure: (is tested for) */ - pis->doit = NULL; - pis->pname = NULL; - pis->varstr = NULL; - pis->cfra = NULL; - pis->version = 0; - pis->instance_private_data = NULL; - - /* clear the error list */ - BLI_dynlib_get_error_as_string(NULL); - - /* if (pis->handle) BLI_dynlib_close(pis->handle); */ - /* pis->handle = 0; */ - - /* open the needed object */ - pis->handle = BLI_dynlib_open(pis->name); - if (test_dlerr(pis->name, pis->name)) return; - - if (pis->handle != NULL) { - /* find the address of the version function */ - version = (int (*)(void))BLI_dynlib_find_symbol(pis->handle, "plugin_seq_getversion"); - if (test_dlerr(pis->name, "plugin_seq_getversion")) return; - - if (version != NULL) { - pis->version = version(); - if (pis->version >= 2 && pis->version <= 6) { - int (*info_func)(PluginInfo *); - PluginInfo *info = (PluginInfo *) MEM_mallocN(sizeof(PluginInfo), "plugin_info"); - - info_func = (int (*)(PluginInfo *))BLI_dynlib_find_symbol(pis->handle, "plugin_getinfo"); - - if (info_func == NULL) error("No info func"); - else { - info_func(info); - - pis->pname = info->name; - pis->vars = info->nvars; - pis->cfra = info->cfra; - - pis->varstr = info->varstr; - - pis->doit = (void (*)(void))info->seq_doit; - if (info->init) - info->init(); - } - MEM_freeN(info); - - cp = BLI_dynlib_find_symbol(pis->handle, "seqname"); - if (cp) BLI_strncpy(cp, seqname, SEQ_NAME_MAXSTR); - } - else { - printf("Plugin returned unrecognized version number\n"); - return; - } - } - alloc_private = (void * (*)(void))BLI_dynlib_find_symbol( - pis->handle, "plugin_seq_alloc_private_data"); - if (alloc_private) { - pis->instance_private_data = alloc_private(); - } - - pis->current_private_data = (void **) - BLI_dynlib_find_symbol(pis->handle, "plugin_private_data"); - } -} - -static PluginSeq *add_plugin_seq(const char *str, const char *seqname) -{ - PluginSeq *pis; - VarStruct *varstr; - int a; - - pis = MEM_callocN(sizeof(PluginSeq), "PluginSeq"); - - BLI_strncpy(pis->name, str, FILE_MAX); - open_plugin_seq(pis, seqname); - - if (pis->doit == NULL) { - if (pis->handle == NULL) error("no plugin: %s", str); - else error("in plugin: %s", str); - MEM_freeN(pis); - return NULL; - } - - /* default values */ - varstr = pis->varstr; - for (a = 0; a < pis->vars; a++, varstr++) { - if ( (varstr->type & FLO) == FLO) - pis->data[a] = varstr->def; - else if ( (varstr->type & INT) == INT) - *((int *)(pis->data + a)) = (int) varstr->def; - } - - return pis; -} - -static void free_plugin_seq(PluginSeq *pis) -{ - if (pis == NULL) return; - - /* no BLI_dynlib_close: same plugin can be opened multiple times with 1 handle */ - - if (pis->instance_private_data) { - void (*free_private)(void *); - - free_private = (void (*)(void *))BLI_dynlib_find_symbol( - pis->handle, "plugin_seq_free_private_data"); - if (free_private) { - free_private(pis->instance_private_data); - } - } - - MEM_freeN(pis); -} - -static void init_plugin(Sequence *seq, const char *fname) -{ - seq->plugin = (PluginSeq *)add_plugin_seq(fname, seq->name + 2); -} - -/* - * FIXME: should query plugin! Could be generator, that needs zero inputs... - */ -static int num_inputs_plugin(void) -{ - return 1; -} - -static void load_plugin(Sequence *seq) -{ - if (seq) { - open_plugin_seq(seq->plugin, seq->name + 2); - } -} - -static void copy_plugin(Sequence *dst, Sequence *src) -{ - if (src->plugin) { - dst->plugin = MEM_dupallocN(src->plugin); - open_plugin_seq(dst->plugin, dst->name + 2); - } -} - -static ImBuf *IMB_cast_away_list(ImBuf *i) -{ - if (!i) { - return NULL; - } - return (ImBuf *) (((void **) i) + 2); -} - -static ImBuf *do_plugin_effect( - SeqRenderData context, Sequence *seq, float cfra, - float facf0, float facf1, - struct ImBuf *ibuf1, struct ImBuf *ibuf2, - struct ImBuf *ibuf3) -{ - char *cp; - int float_rendering; - int use_temp_bufs = FALSE; /* Are needed since blur.c (and maybe some other - * old plugins) do very bad stuff - * with imbuf-internals */ - - struct ImBuf *out = prepare_effect_imbufs(context, ibuf1, ibuf2, ibuf3); - int x = context.rectx; - int y = context.recty; - - if (seq->plugin && seq->plugin->doit) { - - if (seq->plugin->cfra) - *(seq->plugin->cfra) = cfra; - - cp = BLI_dynlib_find_symbol( - seq->plugin->handle, "seqname"); - - /* XXX: it's crappy to limit copying buffer by it's lemgth, - * but assuming plugin stuff is using correct buffer size - * it should be fine */ - if (cp) strncpy(cp, seq->name + 2, sizeof(seq->name) - 2); - - if (seq->plugin->current_private_data) { - *seq->plugin->current_private_data = seq->plugin->instance_private_data; - } - - float_rendering = (out->rect_float != NULL); - - if (seq->plugin->version <= 3 && float_rendering) { - use_temp_bufs = TRUE; - - if (ibuf1) { - ibuf1 = IMB_dupImBuf(ibuf1); - IMB_rect_from_float(ibuf1); - imb_freerectfloatImBuf(ibuf1); - ibuf1->flags &= ~IB_rectfloat; - } - if (ibuf2) { - ibuf2 = IMB_dupImBuf(ibuf2); - IMB_rect_from_float(ibuf2); - imb_freerectfloatImBuf(ibuf2); - ibuf2->flags &= ~IB_rectfloat; - } - if (ibuf3) { - ibuf3 = IMB_dupImBuf(ibuf3); - IMB_rect_from_float(ibuf3); - imb_freerectfloatImBuf(ibuf3); - ibuf3->flags &= ~IB_rectfloat; - } - if (!out->rect) imb_addrectImBuf(out); - imb_freerectfloatImBuf(out); - out->flags &= ~IB_rectfloat; - } - - if (seq->plugin->version <= 2) { - if (ibuf1) IMB_convert_rgba_to_abgr(ibuf1); - if (ibuf2) IMB_convert_rgba_to_abgr(ibuf2); - if (ibuf3) IMB_convert_rgba_to_abgr(ibuf3); - } - - if (seq->plugin->version <= 4) { - ((SeqDoit)seq->plugin->doit)( - seq->plugin->data, facf0, facf1, x, y, - IMB_cast_away_list(ibuf1), - IMB_cast_away_list(ibuf2), - IMB_cast_away_list(out), - IMB_cast_away_list(ibuf3)); - } - else { - ((SeqDoit)seq->plugin->doit)( - seq->plugin->data, facf0, facf1, x, y, - ibuf1, ibuf2, out, ibuf3); - } - - if (seq->plugin->version <= 2) { - if (!use_temp_bufs) { - if (ibuf1) IMB_convert_rgba_to_abgr(ibuf1); - if (ibuf2) IMB_convert_rgba_to_abgr(ibuf2); - if (ibuf3) IMB_convert_rgba_to_abgr(ibuf3); - } - IMB_convert_rgba_to_abgr(out); - } - if (seq->plugin->version <= 3 && float_rendering) { - IMB_float_from_rect_simple(out); - } - - if (use_temp_bufs) { - if (ibuf1) IMB_freeImBuf(ibuf1); - if (ibuf2) IMB_freeImBuf(ibuf2); - if (ibuf3) IMB_freeImBuf(ibuf3); - } - } - return out; -} - -static int do_plugin_early_out(struct Sequence *UNUSED(seq), - float UNUSED(facf0), float UNUSED(facf1)) -{ - return 0; -} - -static void free_plugin(struct Sequence *seq) -{ - free_plugin_seq(seq->plugin); - seq->plugin = NULL; -} - -/* ********************************************************************** * ALPHA OVER * ********************************************************************** */ @@ -3158,11 +2877,6 @@ static void load_noop(struct Sequence *UNUSED(seq)) } -static void init_plugin_noop(struct Sequence *UNUSED(seq), const char *UNUSED(fname)) -{ - -} - static void free_noop(struct Sequence *UNUSED(seq)) { @@ -3264,7 +2978,6 @@ static struct SeqEffectHandle get_sequence_effect_impl(int seq_type) int sequence_type = seq_type; rval.init = init_noop; - rval.init_plugin = init_plugin_noop; rval.num_inputs = num_inputs_default; rval.load = load_noop; rval.free = free_noop; @@ -3352,16 +3065,6 @@ static struct SeqEffectHandle get_sequence_effect_impl(int seq_type) rval.copy = copy_solid_color; rval.execute = do_solid_color; break; - case SEQ_PLUGIN: - rval.init_plugin = init_plugin; - rval.num_inputs = num_inputs_plugin; - rval.load = load_plugin; - rval.free = free_plugin; - rval.copy = copy_plugin; - rval.execute = do_plugin_effect; - rval.early_out = do_plugin_early_out; - rval.get_default_fac = get_default_fac_fade; - break; case SEQ_MULTICAM: rval.num_inputs = num_inputs_multicam; rval.early_out = early_out_multicam; diff --git a/source/blender/blenkernel/intern/sequencer.c b/source/blender/blenkernel/intern/sequencer.c index 63cabf80eae..5318c5514ca 100644 --- a/source/blender/blenkernel/intern/sequencer.c +++ b/source/blender/blenkernel/intern/sequencer.c @@ -929,16 +929,6 @@ const char *give_seqname(Sequence *seq) if (seq->type < SEQ_EFFECT) { return seq->strip->dir; } - else if (seq->type == SEQ_PLUGIN) { - if (!(seq->flag & SEQ_EFFECT_NOT_LOADED) && - seq->plugin && seq->plugin->doit) - { - return seq->plugin->pname; - } - else { - return "Plugin"; - } - } else { return "Effect"; } diff --git a/source/blender/blenkernel/intern/texture.c b/source/blender/blenkernel/intern/texture.c index 2ec42b47e5c..7081a642b8a 100644 --- a/source/blender/blenkernel/intern/texture.c +++ b/source/blender/blenkernel/intern/texture.c @@ -56,7 +56,6 @@ #include "IMB_imbuf.h" -#include "BKE_plugin_types.h" #include "BKE_utildefines.h" #include "BKE_global.h" #include "BKE_main.h" @@ -72,137 +71,6 @@ #include "BKE_animsys.h" #include "BKE_colortools.h" - -/* ------------------------------------------------------------------------- */ - -/* All support for plugin textures: */ -int test_dlerr(const char *name, const char *symbol) -{ - char *err; - - err = BLI_dynlib_get_error_as_string(NULL); - if (err) { - printf("var1: %s, var2: %s, var3: %s\n", name, symbol, err); - return 1; - } - - return 0; -} - -/* ------------------------------------------------------------------------- */ - -void open_plugin_tex(PluginTex *pit) -{ - int (*version)(void); - - /* init all the happy variables */ - pit->doit = NULL; - pit->pname = NULL; - pit->stnames = NULL; - pit->varstr = NULL; - pit->result = NULL; - pit->cfra = NULL; - pit->version = 0; - pit->instance_init = NULL; - - /* clear the error list */ - BLI_dynlib_get_error_as_string(NULL); - - /* no BLI_dynlib_close! multiple opened plugins... */ - /* if (pit->handle) BLI_dynlib_close(pit->handle); */ - /* pit->handle= 0; */ - - /* open the needed object */ - pit->handle = BLI_dynlib_open(pit->name); - if (test_dlerr(pit->name, pit->name)) return; - - if (pit->handle != NULL) { - /* find the address of the version function */ - version = (int (*)(void))BLI_dynlib_find_symbol(pit->handle, "plugin_tex_getversion"); - if (test_dlerr(pit->name, "plugin_tex_getversion")) return; - - if (version != NULL) { - pit->version = version(); - if (pit->version >= 2 && pit->version <= 6) { - int (*info_func)(PluginInfo *); - PluginInfo *info = (PluginInfo *) MEM_mallocN(sizeof(PluginInfo), "plugin_info"); - - info_func = (int (*)(PluginInfo *))BLI_dynlib_find_symbol(pit->handle, "plugin_getinfo"); - if (!test_dlerr(pit->name, "plugin_getinfo")) { - info->instance_init = NULL; - - info_func(info); - - pit->doit = (int (*)(void))info->tex_doit; - pit->callback = (void (*)(unsigned short))info->callback; - pit->stypes = info->stypes; - pit->vars = info->nvars; - pit->pname = info->name; - pit->stnames = info->snames; - pit->varstr = info->varstr; - pit->result = info->result; - pit->cfra = info->cfra; - pit->instance_init = info->instance_init; - if (info->init) info->init(); - } - MEM_freeN(info); - } - else { - printf("Plugin returned unrecognized version number\n"); - return; - } - } - } -} - -/* ------------------------------------------------------------------------- */ - -/* very badlevel define to bypass linking with BIF_interface.h */ -#define INT 96 -#define FLO 128 - -PluginTex *add_plugin_tex(char *str) -{ - PluginTex *pit; - VarStruct *varstr; - int a; - - pit = MEM_callocN(sizeof(PluginTex), "plugintex"); - - BLI_strncpy(pit->name, str, sizeof(pit->name)); - open_plugin_tex(pit); - - if (pit->doit == NULL) { - if (pit->handle == NULL) {; } //XXX error("no plugin: %s", str); - else {; } //XXX error("in plugin: %s", str); - MEM_freeN(pit); - return NULL; - } - - varstr = pit->varstr; - for (a = 0; a < pit->vars; a++, varstr++) { - if ( (varstr->type & FLO) == FLO) - pit->data[a] = varstr->def; - else if ( (varstr->type & INT) == INT) - *((int *)(pit->data + a)) = (int) varstr->def; - } - - if (pit->instance_init) - pit->instance_init((void *) pit->data); - - return pit; -} - -/* ------------------------------------------------------------------------- */ - -void free_plugin_tex(PluginTex *pit) -{ - if (pit == NULL) return; - - /* no BLI_dynlib_close: same plugin can be opened multiple times, 1 handle */ - MEM_freeN(pit); -} - /* ****************** Mapping ******************* */ TexMapping *add_tex_mapping(void) @@ -550,8 +418,6 @@ int colorband_element_remove(struct ColorBand *coba, int index) void BKE_texture_free(Tex *tex) { - free_plugin_tex(tex->plugin); - if (tex->coba) MEM_freeN(tex->coba); if (tex->env) BKE_free_envmap(tex->env); if (tex->pd) BKE_free_pointdensity(tex->pd); @@ -573,10 +439,6 @@ void BKE_texture_free(Tex *tex) void default_tex(Tex *tex) { - PluginTex *pit; - VarStruct *varstr; - int a; - tex->type = TEX_CLOUDS; tex->stype = 0; tex->flag = TEX_CHECKER_ODD; @@ -644,15 +506,6 @@ void default_tex(Tex *tex) tex->ot->output = TEX_OCN_DISPLACEMENT; tex->ot->object = NULL; } - pit = tex->plugin; - if (pit) { - varstr = pit->varstr; - if (varstr) { - for (a = 0; a < pit->vars; a++, varstr++) { - pit->data[a] = varstr->def; - } - } - } tex->iuser.fie_ima = 2; tex->iuser.ok = 1; @@ -833,11 +686,6 @@ Tex *BKE_texture_copy(Tex *tex) if (texn->type == TEX_IMAGE) id_us_plus((ID *)texn->ima); else texn->ima = NULL; - if (texn->plugin) { - texn->plugin = MEM_dupallocN(texn->plugin); - open_plugin_tex(texn->plugin); - } - if (texn->coba) texn->coba = MEM_dupallocN(texn->coba); if (texn->env) texn->env = BKE_copy_envmap(texn->env); if (texn->pd) texn->pd = BKE_copy_pointdensity(texn->pd); @@ -865,11 +713,6 @@ Tex *localize_texture(Tex *tex) /* image texture: BKE_texture_free also doesn't decrease */ - if (texn->plugin) { - texn->plugin = MEM_dupallocN(texn->plugin); - open_plugin_tex(texn->plugin); - } - if (texn->coba) texn->coba = MEM_dupallocN(texn->coba); if (texn->env) { texn->env = BKE_copy_envmap(texn->env); @@ -1058,7 +901,7 @@ void autotexname(Tex *tex) { Main *bmain = G.main; char texstr[20][15] = {"None", "Clouds", "Wood", "Marble", "Magic", "Blend", - "Stucci", "Noise", "Image", "Plugin", "EnvMap", "Musgrave", + "Stucci", "Noise", "Image", "EnvMap", "Musgrave", "Voronoi", "DistNoise", "Point Density", "Voxel Data", "Ocean", "", "", ""}; Image *ima; char di[FILE_MAXDIR], fi[FILE_MAXFILE]; @@ -1079,7 +922,6 @@ void autotexname(Tex *tex) } else new_id(&bmain->tex, (ID *)tex, texstr[tex->type]); } - else if (tex->type == TEX_PLUGIN && tex->plugin) new_id(&bmain->tex, (ID *)tex, tex->plugin->pname); else new_id(&bmain->tex, (ID *)tex, texstr[tex->type]); } } @@ -1565,11 +1407,7 @@ void BKE_free_oceantex(struct OceanTex *ot) /* ------------------------------------------------------------------------- */ int BKE_texture_dependsOnTime(const struct Tex *texture) { - if (texture->plugin) { - // assume all plugins depend on time - return 1; - } - else if (texture->ima && + if (texture->ima && ELEM(texture->ima->source, IMA_SRC_SEQUENCE, IMA_SRC_MOVIE)) { return 1; |