3 Replies Latest reply on Apr 23, 2007 4:54 PM by Applied CD

    Mpeg Advanced Xtra: Pause/Play toolbar button not working when resized

    Applied CD Level 1
      Hi all,

      I’ve got an Mpeg Advanced Xtra (v1.5.2) sprite playing MPG 1 video with an attached behavior that will let me scale the sprite to full screen when called. The toolbar option is checked so the progress bar and pause/play button shows. On XP everything works as expected. On Mac OS X if the sprite is resized while the video is paused the pause/play button on the toolbar becomes inactive. The button graphic will toggle between pause and play but the movie won’t start playing again. Restoring the sprite size does not clear the problem. Jumping to a frame without the video sprite and returning will restore the button’s functionality until you try to resize the paused sprite again. Here’s the strange part: Resizing the sprite while the video is playing works fine … also, if there’s more than one video on the stage, resizing one video sprite will trigger the problem if any video sprites are paused … and the problem effects all video sprites on stage, not just the one that got scaled. I’ve monitored sprite().movieRate in the message window and it gets stuck on 0 despite what the pause/play button is showing. I can manually reset movieRate to 1 and get the button activity back. I know this is kind of specific, but has anyone seen something like this?

      Thanks,

      - Bob Gallo
      - Applied CD Technologies

      PS: I've attached my scaling code, although it works fine on XP so I'm not sure this is where the problem is.

        • 1. Re: Mpeg Advanced Xtra: Pause/Play toolbar button not   working when   resized
          Level 7
          What do Tabuleiro have to say? You did post a support question there, right?
          • 2. Re: Mpeg Advanced Xtra: Pause/Play toolbar button not   working when   resized
            Applied CD Level 1
            Yeah, I’m guilty of a little cross-posting. They haven’t responded yet but to be fair I’ve asked questions of them in the past and they’ve been good about responding. However, while I’m waiting I might mention that I created a test movie that simplifies the problem a whole lot. Forget about the resizing and all that code, it has nothing to do with the problem. The issue can be simply stated as follows:

            On Mac OS X only, if lingo is used to pause the movie by setting sprite(X).movieRate = 0 then only lingo can resume the movie by setting sprite(X).movieRate = 1. If lingo sets the movieRate to 1, then the toolbar button toggles the movieRate between 0 and 1 as expected. If lingo sets the movieRate to 0, then the toolbar toggles the movieRate between 0 and 0.0000 and nothing happens.

            The button/lingo interaction works properly on XP, lingo can be used to pause the video and the toolbar button can be used to turn it back on.
            • 3. Re: Mpeg Advanced Xtra: Pause/Play toolbar button not   working when   resized
              Applied CD Level 1
              I’ll post up if I get official word from Tabuleiro but for now I’ve got a kludge that seems to work:

              sprite(X).mediaBusy toggles properly for any combination of toolbar button and lingo but it’s read only. Because of the “bug” (yes, presumptive on my part) you can end up with sprite(X).movieRate = 0 and sprite(X).mediaBusy = TRUE at the same time. Since my playhead is always moving I just added the following corrective line to the behavior attached to the video sprite:

              on exitFrame me
              if (sprite(me.spriteNum).mediaBusy and (sprite(me.spriteNum).movieRate = 0)) then sprite(me.spriteNum).movieRate = 1
              -- some other junk here
              end