Closed internetxs closed 2 years ago
Hi internetxs,
Try with:
switcher.setTransitionNextTransition(mE, nextTransition)
mE
is the mixEffect
number.nextTransition
defines the next transition.If you look at the Set methods in the docs, you'll see it says:
Args:
mE: see ATEMMixEffects
nextTransition: see ATEMTransitionStyles
... and if you search for ATEMTransitionStyles
you'll end up by finding this:
class ATEMTransitionStyles(ATEMConstantList):
"""TransitionStyle list"""
mix = ATEMConstant('mix', 0)
dip = ATEMConstant('dip', 1)
wipe = ATEMConstant('wipe', 2)
dVE = ATEMConstant('dVE', 3)
sting = ATEMConstant('sting', 4)
which doesn't really look as it makes sense.
Looking at the CTTp message in the reverse engineering docs I see I may have made a mistake in the docs... the nextTransition
parameter is not expected to be an element of ATEMTransitionStyles
.
To correctly buid a value for this field you can use this code for now:
# Define constants for nextTransition flags
NextTrans_BKGD = 1
NextTrans_KEY1 = 2
NextTrans_KEY2 = 4
NextTrans_KEY3 = 8
NextTrans_KEY4 = 16
#
# Some use cases:
#
# Set next transition on me1 to KEY1
switcher.setTransitionNextTransition("mixEffect1", NextTrans_KEY1)
# Set next transition on me1 to KEY1 + KEY2
switcher.setTransitionNextTransition("mixEffect1", NextTrans_KEY1 + NextTrans_KEY2)
# Set next transition on me1 back to BKGD
switcher.setTransitionNextTransition("mixEffect1", NextTrans_BKGD)
Seems that reading the value can be easier, these are available as boolean
:
switcher.transition[mE].nextTransition.background
switcher.transition[mE].nextTransition.key1
switcher.transition[mE].nextTransition.key2
switcher.transition[mE].nextTransition.key3
switcher.transition[mE].nextTransition.key4
switcher.transition[mE].nextTransitionNext.background
switcher.transition[mE].nextTransitionNext.key1
switcher.transition[mE].nextTransitionNext.key2
switcher.transition[mE].nextTransitionNext.key3
switcher.transition[mE].nextTransitionNext.key4
If this works please let me know and I'll fix the docs and create a more user-friendly way to set these flags.
Hi maybe wrong way to ask but i am trying to find the correct command to set the key 1 to on
Could you tell me on how to do this?
Thanks