- duplicating a scene now duplicates all strips (not just selected ones)
- python change, dont import 'bpy' by default, initially I thaught this would make scripting easier but it ends up being annoying when you want to register a script or if you want to import it. (more trouble then its worth to save 1 line, also not very pythonic).
This commit is contained in:
@@ -234,6 +234,7 @@ typedef struct SeqLoadInfo {
|
||||
#define SEQ_DUPE_UNIQUE_NAME 1<<0
|
||||
#define SEQ_DUPE_CONTEXT 1<<1
|
||||
#define SEQ_DUPE_ANIM 1<<2
|
||||
#define SEQ_DUPE_ALL 1<<3 /* otherwise only selected are copied */
|
||||
|
||||
/* use as an api function */
|
||||
typedef struct Sequence *(*SeqLoadFunc)(struct bContext *, ListBase *, struct SeqLoadInfo *);
|
||||
|
||||
@@ -220,7 +220,7 @@ Scene *copy_scene(Main *bmain, Scene *sce, int type)
|
||||
if(sce->ed) {
|
||||
scen->ed= MEM_callocN( sizeof(Editing), "addseq");
|
||||
scen->ed->seqbasep= &scen->ed->seqbase;
|
||||
seqbase_dupli_recursive(sce, &scen->ed->seqbase, &sce->ed->seqbase, 0);
|
||||
seqbase_dupli_recursive(sce, &scen->ed->seqbase, &sce->ed->seqbase, SEQ_DUPE_ALL);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -4299,7 +4299,7 @@ void seqbase_dupli_recursive(Scene *scene, ListBase *nseqbase, ListBase *seqbase
|
||||
|
||||
for(seq= seqbase->first; seq; seq= seq->next) {
|
||||
seq->tmp= NULL;
|
||||
if(seq->flag & SELECT) {
|
||||
if((seq->flag & SELECT) || (dupe_flag & SEQ_DUPE_ALL)) {
|
||||
seqn = seq_dupli(scene, seq, dupe_flag);
|
||||
if (seqn) { /*should never fail */
|
||||
if(dupe_flag & SEQ_DUPE_CONTEXT) {
|
||||
|
||||
@@ -166,11 +166,6 @@ static PyObject *CreateGlobalDictionary( bContext *C, const char *filename )
|
||||
Py_DECREF(item);
|
||||
}
|
||||
|
||||
/* add bpy to global namespace */
|
||||
mod= PyImport_ImportModuleLevel("bpy", NULL, NULL, NULL, 0);
|
||||
PyDict_SetItemString( dict, "bpy", mod );
|
||||
Py_DECREF(mod);
|
||||
|
||||
return dict;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user