Page 1 of 1
a module/script to change a movie of 2layers simultaneously?
Posted: Sat May 27, 2006 11:26 pm
by nbd
Hi !
Is there a way to do the follwing:
I have 2 layers.
with a click in my media window I like to apply this movie to both layers.
Is that possible? How?
I am thinking of a module that links itself "between" the media window and the layer set?
Thank you all!
Posted: Sun May 28, 2006 4:15 pm
by nbd
possible thought:
one layer is accessed directly via the KeywordEvent :
the other layer is correlated to that via:
Code: Select all
modul8.setValue('ctrl_layer_media',param,2)
problem: 2.5 beta2 crashes with that code.
crash log has been sent to beta25.[/code]
Posted: Sun May 28, 2006 4:18 pm
by boris
Maybe you can use the KeywordEvent (feedback) into the script.
When one layer is changed you can change another.
Posted: Sun May 28, 2006 4:21 pm
by boris
Sorry I diden't see your answer
We will check your crash, thanks !
Posted: Sun May 28, 2006 4:36 pm
by boris
Ok
It's a python crash because you made a endless loop, is not a problem w/modul8 beta.
You need to improve a litle bit your script :
feedbackLock = 0
and in your KeywordEvent :
Code: Select all
if not feedbackLock :
feedbackLock = 1
if keyword=='ctrl_layer_media':
modul8.setValue('ctrl_layer_media',param,2)
feedbackLock = 0
And now an endless loop is not possible and it works ![/code]
Posted: Sun May 28, 2006 4:40 pm
by boris
Sorry the 'TAB' seems to be not working into the forum...
Posted: Sun May 28, 2006 4:42 pm
by nbd
A great, I understand:
the KeywordEvent is repeatedly called by itself, because it is reacting on the thing itself changes.
THX !
Posted: Sun May 28, 2006 4:53 pm
by nbd
code with TABS:
Code: Select all
if not feedbackLock:
feedbackLock = 1
if keyword=='ctrl_layer_media':
modul8.setValue('ctrl_layer_media',param,2)
feedbackLock = 0
Posted: Sun May 28, 2006 6:02 pm
by boris
Just add one "tab" , but it works also without...
Thanks for the tips about "code", I update my message...