11 Replies Latest reply on Dec 21, 2006 9:11 AM by Newsgroup_User

    QT movie refuses to leave stage...

    Level 7
      I have a QT movie that plays on stage with this lingo:

      on timeout
      go to "start"
      end

      property spriteNum

      on exitFrame me
      myMember = sprite(11).member
      myDuration = member(myMember).duration
      myMovietime = sprite(11).movieTime
      if myDuration > myMovietime then
      go to the frame
      else
      go to "start"
      end if
      end


      As long as I run it from within DW9 environment, it works fine. The
      movie plays when done, exits to the "start" marker as it should.
      However, as soon as I try to play the .dir outside of DW9 (from my exe),
      the movie plays, but at the end of the movie, the QT window remains
      (hangs)on stage.

      This is a kiosk app...

      Any ideas on this?

      Thanks.

      Dave
        • 1. Re: QT movie refuses to leave stage...
          Level 7
          You could move the video off the screen by changing it's locH value when
          it's done. That's what I've had to do in several cases, because the
          last frame of the video always stays resident on the screen.
          • 2. Re: QT movie refuses to leave stage...
            Level 7
            On Wed, 13 Dec 2006 18:30:37 GMT, Dave Anderson posted in
            macromedia.director.lingo:

            > else
            > go to "start"
            the stageColor = the stageColor --<<< Add this line
            > end if




            --
            Mark A. Boyd
            Keep-On-Learnin' :)
            • 3. Re: QT movie refuses to leave stage...
              Level 7
              Sorry Mark, but that didn't seem to do it either. Any other ideas?

              Dave

              Mark A. Boyd wrote:
              > On Wed, 13 Dec 2006 18:30:37 GMT, Dave Anderson posted in
              > macromedia.director.lingo:
              >
              >> else
              >> go to "start"
              > the stageColor = the stageColor --<<< Add this line
              >> end if
              >
              >
              >
              >
              • 4. Re: QT movie refuses to leave stage...
                Level 7
                On Mon, 18 Dec 2006 12:50:23 GMT, Dave Anderson posted in
                macromedia.director.lingo:

                > Sorry Mark, but that didn't seem to do it either. Any other ideas?
                >

                That typically works for me. Did you try the other suggestions?

                Another method is to have a transparent shape sprite on your "start" frame.
                The sprite can fill the stage or it can be the same rect as the QT sprite.
                This new sprite should force Director to redraw those pixels.


                --
                Mark A. Boyd
                Keep-On-Learnin' :)
                • 5. Re: QT movie refuses to leave stage...
                  Level 7
                  Sounds interesting. I'll give that a whirl. I didn't try the loc thing,
                  not sure if I'd know how.

                  What's weird is that it works fine when tested within DX, but not as a
                  projector... Hmmmm.

                  I'll report back.

                  Mark A. Boyd wrote:
                  > On Mon, 18 Dec 2006 12:50:23 GMT, Dave Anderson posted in
                  > macromedia.director.lingo:
                  >
                  >> Sorry Mark, but that didn't seem to do it either. Any other ideas?
                  >>
                  >
                  > That typically works for me. Did you try the other suggestions?
                  >
                  > Another method is to have a transparent shape sprite on your "start" frame.
                  > The sprite can fill the stage or it can be the same rect as the QT sprite.
                  > This new sprite should force Director to redraw those pixels.
                  >
                  >
                  • 6. Re: QT movie refuses to leave stage...
                    Level 7
                    on timeout
                    go to "start"
                    end


                    property spriteNum

                    on exitFrame me
                    myMember = sprite(11).member
                    myDuration = member(myMember).duration
                    myMovietime = sprite(11).movieTime
                    if myDuration < myMovietime then
                    go to the frame
                    else
                    go to "start"
                    the stageColor = the stageColor
                    end if
                    end


                    I've tried: "myDuration < myMovietime", "myDuration = myMovietime", and
                    "myDuration > myMovietime"

                    In each instance, the same issue with QT not exiting the stage (the last
                    frame of the video stays visible in fact). I also tried the transparent
                    sprite in the start frame -- no luck.

                    Maybe this means that my exitFrame script is not right?

                    Dave


                    Mark A. Boyd wrote:
                    > On Mon, 18 Dec 2006 12:50:23 GMT, Dave Anderson posted in
                    > macromedia.director.lingo:
                    >
                    >> Sorry Mark, but that didn't seem to do it either. Any other ideas?
                    >>
                    >
                    > That typically works for me. Did you try the other suggestions?
                    >
                    > Another method is to have a transparent shape sprite on your "start" frame.
                    > The sprite can fill the stage or it can be the same rect as the QT sprite.
                    > This new sprite should force Director to redraw those pixels.
                    >
                    >
                    • 7. Re: QT movie refuses to leave stage...
                      Level 7
                      On Mon, 18 Dec 2006 19:24:16 GMT, Dave Anderson posted in
                      macromedia.director.lingo:

                      > property spriteNum
                      >
                      > on exitFrame me
                      > myMember = sprite(11).member
                      > myDuration = member(myMember).duration
                      > myMovietime = sprite(11).movieTime
                      > if myDuration < myMovietime then
                      > go to the frame
                      > else
                      > go to "start"
                      > the stageColor = the stageColor
                      > end if
                      > end
                      >
                      > I've tried: "myDuration < myMovietime", "myDuration = myMovietime", and
                      > "myDuration > myMovietime"
                      >
                      > In each instance, the same issue with QT not exiting the stage (the last
                      > frame of the video stays visible in fact). I also tried the transparent
                      > sprite in the start frame -- no luck.
                      >
                      > Maybe this means that my exitFrame script is not right?
                      >
                      > Dave

                      Seems OK to me. Are you certain that it's actually going to "start"?

                      A couple of notes that may not help, but worth trying.

                      You may need to provide a little slop tolerance

                      if (myDuration - 60) <= myMovieTime then

                      And there's no need to set the duration in every frame loop. Add a property
                      variable and set it once in a beginSprite event

                      property myDuration
                      on beginSprite me
                      myDuration = sprite(11).member.duration
                      -- myDuration = sprite(11).member.duration - 60 --<< if slop factor needed.
                      end

                      on exitFrame me
                      if sprite(11).movieTime <= myDuration then
                      go the frame
                      else
                      sprite(11).locV = - 1000
                      go to "start"
                      the stageColor = the stageColor
                      end if
                      end



                      --
                      Mark A. Boyd
                      Keep-On-Learnin' :)
                      • 8. Re: QT movie refuses to leave stage...
                        kalibahlutwo
                        How about just going to another frame that plays the QT on timeout? Then when you leave that frame, the movie will be gone.
                        • 9. Re: QT movie refuses to leave stage...
                          Level 7
                          Mark A. Boyd wrote:
                          > Seems OK to me. Are you certain that it's actually going to "start"?
                          >
                          > A couple of notes that may not help, but worth trying.
                          >
                          > You may need to provide a little slop tolerance
                          >
                          > if (myDuration - 60) <= myMovieTime then
                          >
                          > And there's no need to set the duration in every frame loop. Add a property
                          > variable and set it once in a beginSprite event
                          >
                          > property myDuration
                          > on beginSprite me
                          > myDuration = sprite(11).member.duration
                          > -- myDuration = sprite(11).member.duration - 60 --<< if slop factor needed.
                          > end
                          >
                          > on exitFrame me
                          > if sprite(11).movieTime <= myDuration then
                          > go the frame
                          > else
                          > sprite(11).locV = - 1000
                          > go to "start"
                          > the stageColor = the stageColor
                          > end if
                          > end
                          >

                          I think that I'm concluding that the movie is not going back to "start"
                          at the end. I tried your suggestion with no luck either. What I do know
                          is that after the QT piece has played, remaining on the screen, I can
                          click the "Stop" sprite and immediately the QT window goes away
                          indicating that the movie went back to "start".

                          ("Stop" sprite's script)
                          on mousedown me
                          go to "start"
                          end

                          So the question is why isn't the movie going back to the start marker
                          when the QT is finished?? In fact, it appears that when the movie
                          reaches a timeout, it doesn't reset back to start...

                          on startMovie
                          set the timeoutLength = 330*60
                          cursor 200
                          end

                          on mouseup me
                          set the timeoutLength = 330*60
                          end

                          on mousedown me
                          set the timeoutLength = 330*60
                          end

                          on exitFrame
                          set the timeoutLength = 330*60
                          end

                          • 10. Re: QT movie refuses to leave stage...
                            Level 7
                            Since the movie isn't going back to 'start', is there a way to force it
                            to do that based on the length of the QT? The QT clip is 5:26. So maybe
                            something with manually setting

                            myMovietime = sprite(11).movieTime - 315*60

                            Would that work?

                            property myDuration
                            on beginSprite me
                            myDuration = sprite(11).member.duration - 60
                            end

                            on exitFrame me
                            if sprite(11).movieTime = 315*60 then
                            go the frame
                            else
                            sprite(11).locV = - 1000
                            go to "start"
                            the stageColor = the stageColor
                            end if
                            end

                            Mark A. Boyd wrote:
                            > On Mon, 18 Dec 2006 19:24:16 GMT, Dave Anderson posted in
                            > macromedia.director.lingo:
                            >
                            >> property spriteNum
                            >>
                            >> on exitFrame me
                            >> myMember = sprite(11).member
                            >> myDuration = member(myMember).duration
                            >> myMovietime = sprite(11).movieTime
                            >> if myDuration < myMovietime then
                            >> go to the frame
                            >> else
                            >> go to "start"
                            >> the stageColor = the stageColor
                            >> end if
                            >> end
                            >>
                            >> I've tried: "myDuration < myMovietime", "myDuration = myMovietime", and
                            >> "myDuration > myMovietime"
                            >>
                            >> In each instance, the same issue with QT not exiting the stage (the last
                            >> frame of the video stays visible in fact). I also tried the transparent
                            >> sprite in the start frame -- no luck.
                            >>
                            >> Maybe this means that my exitFrame script is not right?
                            >>
                            >> Dave
                            >
                            > Seems OK to me. Are you certain that it's actually going to "start"?
                            >
                            > A couple of notes that may not help, but worth trying.
                            >
                            > You may need to provide a little slop tolerance
                            >
                            > if (myDuration - 60) <= myMovieTime then
                            >
                            > And there's no need to set the duration in every frame loop. Add a property
                            > variable and set it once in a beginSprite event
                            >
                            > property myDuration
                            > on beginSprite me
                            > myDuration = sprite(11).member.duration
                            > -- myDuration = sprite(11).member.duration - 60 --<< if slop factor needed.
                            > end
                            >
                            > on exitFrame me
                            > if sprite(11).movieTime <= myDuration then
                            > go the frame
                            > else
                            > sprite(11).locV = - 1000
                            > go to "start"
                            > the stageColor = the stageColor
                            > end if
                            > end
                            >
                            >
                            >
                            • 11. Re: QT movie refuses to leave stage...
                              Level 7
                              On Thu, 21 Dec 2006 12:57:44 GMT, Dave Anderson posted in
                              macromedia.director.lingo:

                              > Since the movie isn't going back to 'start', is there a way to force it
                              > to do that based on the length of the QT? The QT clip is 5:26. So maybe
                              > something with manually setting

                              I haven't caught anything fundamentally wrong with the scripts (can't get to
                              Director from this machine).

                              Is the script in a behavior script placed in the script channel of the
                              Score? If it's a movie script, then the property variables won't work this
                              way.

                              Before banging your head too much, I would try placing a breakpoint or some
                              strategic "put" commands in the script. Also, test in a bare-bones Director
                              file.

                              > on exitFrame me
                              > if sprite(11).movieTime = 315*60 then
                              > go the frame

                              Chances are extremely thin that a movieTime will exactly equal a given value
                              in an exitFrame event. It is best to use <= in this case.



                              --
                              Mark A. Boyd
                              Keep-On-Learnin' :)