Source language: Translate to:

Why does the Flash Movie object have its own color?

Questions about using NeoBook's scripting language

Moderator: Neosoft Support

Why does the Flash Movie object have its own color?

Postby Enigman » Fri Jan 09, 2015 4:29 pm

Okay, here I am decades down the line with NeoBook and I am just now starting to play with the Flash Movie player object. Better late than never I guess.

I am updating a screen saver that is based in NB with a complex modular flash file that literally sits on top of NB. I used to use an old plug-in to drive the flash modules, but it is out of release now. So I am converting to the native NB flash player.

In order for my screen saver to work, I must define the player with a variable instead of a hard coded flash file location. If I uncheck the box for "Use background color", then the player fires up with a white background. AAACCCKKK ... no can do. However, if I check the box for "Use background color", then while the flash module is loading, the color of the player is a dark red, (values RGB 15,0,1 or Hex #0F0001). This is almost as bad as white. You wouldn't think so, but when the saver starts, first the screen is black because the page background is black and I expand the page to fill the screen, then the flash player object loads and expands to screen size while it is still red, Then the flash movie location variable is populated, then the flash module loads and the screen goes back to black again because my flash movie background is black and then the animation proceeds. The delay in populating the variable is because I must first find where the movie has been installed. Even though the red value is only 15/0F, it is still jarring when it flashes on screen.

I can tell that the deep red color is coded into the flash player object because when I am in the editor and the player is sitting there with the flash movie location variable empty then the player doesn't know where the flash movie is and the object is dark red. If I give it a hard coded flash movie location, then while in the editor the object color is black, which is the first frame of the flash movie. I would have hoped that the object's "I don't know where the movie is" color would have been full black.

Here's the 64 dollar question. Does anyone know how to override that dark red color until the movie loads? OR, Dave? Can the color be fixed?

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Why does the Flash Movie object have its own color?

Postby CN_Iceman » Sat Jan 10, 2015 12:03 am

Hi.

If the player is running on an rectangle object, you can downsize to something very small or even off the screen, start playing out of the user sight and then back to center and maximize it.
Greetings/Saludos, Jose.
www.icemansoft.es
User avatar
CN_Iceman
 
Posts: 297
Joined: Tue Mar 01, 2011 11:04 am
Location: España

Re: Why does the Flash Movie object have its own color?

Postby Enigman » Sun Jan 11, 2015 10:14 am

CN_Iceman wrote:Hi.

If the player is running on an rectangle object, you can downsize to something very small or even off the screen, start playing out of the user sight and then back to center and maximize it.

Uh ... the player is it's own object and doesn't run on a rectangle, but the idea is sound.

I did a complete rearrangement of how the player is started. I moved the player off screen by default. When the program starts I do the discovery of where the flash movie is, set the location in the player variable and start the movie, then I expand the program to fit the screen. Then the player is resized to match and brought on screen. None of that fixed the problem initially. I still got a flash of red before the movie ... until ... I made one change. Instead of using (FlashPlay "FlashBox" "") to start the movie, I switched to (FlashGotoFrame "FlashBox" "2") and added (Delay "100") after it to let it execute immediately. That made it so that by the time I expand the player and move it on screen, the player is already running at frame 2. That eliminated the red flash from being seen. It still happens, but it is off stage when it happens.

I don't really like doing it that way and it presents other problems I need to fix, but it works in a klugy way. I would still prefer that the player did not have a default red color.

Dave? Any comment on that?

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA

Re: Why does the Flash Movie object have its own color?

Postby Neosoft Support » Mon Jan 12, 2015 11:56 am

The "use background color" option refers to the color selected for the Flash object on NeoBook's style palette. When "use background color" is unchecked then the background color is derived from the Flash content itself. When "use background color" is checked, the Flash object's background color (chosen from NeoBook's palette) will be used. This may not work if the Flash file has a solid rather than transparent background.
NeoSoft Support
Neosoft Support
NeoSoft Team
 
Posts: 5602
Joined: Thu Mar 31, 2005 10:48 pm
Location: Oregon, USA

Re: Why does the Flash Movie object have its own color?

Postby Enigman » Mon Jan 12, 2015 2:21 pm

Neosoft Support wrote:The "use background color" option refers to the color selected for the Flash object on NeoBook's style palette. When "use background color" is unchecked then the background color is derived from the Flash content itself. When "use background color" is checked, the Flash object's background color (chosen from NeoBook's palette) will be used.

Thank you for chiming in, Dave. I would have thought that it worked that way, but when I first dropped the player on the editor it came in with the reddish color already and no matter how I set the "use background color" checkbox, I could not get it to react to the color selector so I assumed it did not work that way. Checking the box caused the player to start with the reddish color, but unchecking the box caused it to start white which was much worse. The flash movie has a solid black background for the first five frames and then there is a JPG background at frame 6.

Since then I have done a lot of tweaking and Rube Goldberg'ing of the code to avoid having the player on screen when it starts. But since you have mentioned this today I have tried again to get the player to respond to a color assignment and it finally did after many iterations of selecting the player with the "use background color" option enabled and trying to select colors. Finally, it took green, and then on the next try it took black. Go figure. Don't know what was happening but I have worked around it now.

However, since I have your attention, I have a much more urgent question in the main forum about "New rules for screensavers". If you could look at that I would appreciate it.

Thanks.
User avatar
Enigman
 
Posts: 314
Joined: Tue Apr 12, 2005 3:57 pm
Location: Foothill Ranch, CA


Return to NeoBook Action Commands

Who is online

Users browsing this forum: No registered users and 2 guests

cron