SplitmediaLabsLimited / xjs

XSplit JS Framework. Make plugins for XSplit Broadcaster, quickly and easily.
Other
39 stars 11 forks source link

Bug ActionAfterPlayback; wrong constants #323

Open BrendaH opened 3 years ago

BrendaH commented 3 years ago

I tried to use setActionAfterPlaybackwith the defined constants as documented here: https://xjsframework.github.io/api.html#/core/ActionAfterPlayback However, the results were kind of weird.

When I used getActionAfterPlaybackto check which number corresponds to the actually chosen setting in the properties window in Xsplit I found out that we have the following: 4 = TRANSPARENT 3 = HIDE 1 = REWIND 0 = NOTHING

(LOOP is not in the 'when finished' pulldown. Setting to LOOP does work, but it affects the pulldown called 'play' above the 'when finished'. However, there's no LOOP value (2) returned when using getActionAfterPlayback)

So it seems that HIDE and TRANSPARENT have been mixed up. When I want to set 'when finished' to HIDE I actually have to use the TRANSPARENT constant.... Can this be fixed?

Also it took me a while to find out that I had to pass these constants using xjs.ActionAfterPlayback.TRANSPARENT (and not just xjs.TRANSPARENT or TRANSPARENT), might be an improvement to the documentation to add this?

SML-MeSo commented 3 years ago

It seems that HIDE and TRANSPARENT have been mixed up

Rechecked this one and it seems the values for HIDE and TRANSPARENT are indeed interchanged, for fixing.

LOOP is not in the 'when finished' pulldown

As for the LOOP not being present, it was removed from the dropdown because it is essentially being overwritten by the value of the Play dropdown. Said dropdown practically is a more detailed property for setting where you can choose to loop for a certain number of times or infinitely. So yeah, you will not get a LOOP value unless it is set via xjs and not via the source properties dialog. This Play dropdown is what lead to, I think, your issue #296. I guess we would have to consider adding that capability to the XJS (looping count)

took me a while to find out... might be an improvement to the documentation to add this

Hopefully this would be handled in issue #308