5 Replies Latest reply on Mar 23, 2007 12:49 PM by Newsgroup_User

    load members and program cycle

    Level 7
      Hi,

      I noticed errors when loading members on beginsprite event. Sprites
      (flash) are displayed on the stage that only exist on previous frame for
      a short time. What I want to do is to load a external background image.
      In the frame that is displayed previously I have a Flash member on the
      stage. When I jump to the desired frame the picture is loaded but the
      Flash member is still visible for a short time _over_ the loaded
      background/bitmap member but it isn't on the stage any more.

      I did load the member before jumping to that problematic frame but I
      wonder if loading an external member can be done on one frame cycle
      without these display errors. Is there a behavior event that would do
      better?

      TIA
        • 1. Re: load members and program cycle
          Level 7
          From your description, it sounds like you are trying to solve a display
          problem by applying a a Flash-like solution. I'm sure what the problem
          is though. Are you seeing the persistence of a Flash sprite on the stage
          in a frame where it doesn't exist? Or, are you trying to cover a Flash
          sprite with another? Or is it something else?

          Is this a shockwave movie or a projector? Why is this background image
          external? Does it change frequently?

          --
          Rob
          _______
          Rob Dillon
          Adobe Community Expert
          http://www.ddg-designs.com
          412-243-9119

          http://www.macromedia.com/software/trial/
          • 2. Re: load members and program cycle
            Level 7
            Rob Dillon - Adobe Community Expert wrote:
            > is though. Are you seeing the persistence of a Flash sprite on the stage
            > in a frame where it doesn't exist?

            Yes, I can see it but it isn't on a sprite channel anymore. Looks like
            it stays there some frames. And I can see the loaded background image
            behind it.

            > Is this a shockwave movie or a projector? Why is this background image
            > external? Does it change frequently?

            A projector, the picture is loaded from local HD. I have at maximum
            about 40 or 50 background images.

            I remember in the past I used the prepareframe event on a frame script.
            But I am not sure if it is a good idea for a behavior.
            • 3. Re: load members and program cycle
              Level 7
              You can scrub off a Flash or digital video sprite in a number of ways, I
              move the sprite off the visible area of the stage when I'm finished with
              it. You can also change the visible property, or the direct to stage
              property. Moving is the most reliable in my experience.

              If the new graphic will cover the old Flash sprite, you can place the
              new graphic in a higher numbered sprite channel and it should show on
              top, if the Flash sprite has it's direct to stage property turned off.

              If you have those background images imported into your Director movie as
              cast members they will display faster, and probably more smoothly.
              Unless you are replacing the original content on a constant basis,
              there's no need to use external media in a projector.

              --
              Rob
              _______
              Rob Dillon
              Adobe Community Expert
              http://www.ddg-designs.com
              412-243-9119

              http://www.macromedia.com/software/trial/
              • 4. Re: load members and program cycle
                Level 7
                Rob Dillon - Adobe Community Expert wrote:
                > If you have those background images imported into your Director movie as
                > cast members they will display faster, and probably more smoothly.
                > Unless you are replacing the original content on a constant basis,
                > there's no need to use external media in a projector.

                It is more due to database stuff. I think, importing 40-50 background
                images as png should take much memory. My problem is that my application
                will run on a mac mini and I am not sure if there will be a memory upgrade.

                The idea to put something 'offstage' is a good thing. Now I load my
                image before jumping to that frame. To keep my behavior I put the sprite
                off the stage when doing that.

                Well, it is always good to have a workaround but I was just wondering if
                there is a better or cleaner way to load external members.
                • 5. Re: load members and program cycle
                  Level 7
                  You can import everything into your movie and then use memory control to
                  load and unload members into and out of memory as you need them. Have a
                  look at the preLoadMember and unloadMember commands.

                  --
                  Rob
                  _______
                  Rob Dillon
                  Adobe Community Expert
                  http://www.ddg-designs.com
                  412-243-9119

                  http://www.macromedia.com/software/trial/