• Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint
Share this Page URL

Lesson 20. Synchronizing with Digital Vi... > Adding a Background by Moving Channe...

Adding a Background by Moving Channels

A background graphic for the movie will tie all the elements together. Remember, though, that Director displays each channel on top of the previous one, so if you want a graphic to be displayed as a background, underneath all the other elements, you will need to place it in channel 1. In this Director movie, though, channels 1 through 4 are already full. One way to reorder the channels is to use the Arrange command on the Modify menu.

Click channel 1 on the left side of the score to select all the cells in this channel. Then hold down the Shift key and click channel 4 to select all the filled cells in the score.

Figure .

You can now move the selection down a channel. You can also drag the selection, if you prefer.

Choose Modify > Arrange > Move Forward.

The entire selection moves forward one channel, freeing channel 1 for the background image you will add next.

Figure .

Click channel 1, frame 1. Then click cast member 1 (Background) and choose Modify > Cast to Time.

The Cast to Time command centers a cast member on the stage. This is quick way to place a full-screen background so that it exactly covers the stage. This cast member provides a more interesting space background than the plain black background you've been working with up until now.

Figure .


To extend a sprite that is only one frame, hold down Alt (Windows) or Option (Macintosh) while you drag.

Extend the duration of the bitmap sprite in channel 1 through frame 88.

Your score should now look like this:

Figure .

Rewind and play the movie.

The script in frame 10 no longer works, and the text doesn't animate onto the stage. Why? The channel that contained the digital video (channel 1) now contains the background graphic. Your movie script doesn't work any more because the gQTChannel global variable is initialized to 1, but the digital video movie is now in channel 2. You need to reinitialize the global variable to a new number.

Open the movie script (cast member 7).

Change the value assigned to the gQTChannel variable in the startMovie handler as shown here in bold:

global gQTChannel                     --Declare gQTChannel as a global variable.
                                      --It contains the channel number of the digital video.

on startMovie                         --When the movie starts,
  gQTChannel = 2
							--set the value of gQTChannel to 2.


Close the window and play the movie.

With one simple change, the movie plays correctly. The script can now find the channel that contains the digital video. If you had used the value 1 in the scripts, you would have had to find all the locations where you used 1 and in each case change the value to 2. Now you can see the value of variables.



Not a subscriber?

Start A Free Trial

  • Creative Edge
  • Create BookmarkCreate Bookmark
  • Create Note or TagCreate Note or Tag
  • PrintPrint