Playing Flash files has been possible, since the release of the WebBrowser Library, but we could not Control the Movie being played...
I found a very interesting piece of code, wich wrapped a Flash Movie Player, and took a peak at it...
The result is my FlashPlayerWrapper...
This DESKTOP wrapper consist of 3 seperate dlls, that must all be in the same Folder...
You only need to add as a component the FlashWrapper.dll...
With the very usefull sugestions from marathon332, Here's what IS DONE:
ALPHA RELEASE 0.1
The constructor now has a new syntax:
New(FormName) were FormName is the Form To host the FlashPlayer Control
Author - Returns my Nickname...
DllVersion - Returns "0.1"
Left - sets/gets the corresponding value
Top - sets/gets the corresponding value
Width - sets/gets the corresponding value
Height - sets/gets the corresponding value
Movie - The FileName of the file to be played. * Usualy the movie plays automatically after this line.
Enabled - sets/gets the corresponding value
TotalFrames - GETS the total number of frames in the current file
MenuEnabled - sets/gets the corresponding value, this being the context menu..
MovieLoop - sets/gets the corresponding value, Had to add the prefix "Movie" because the IDE was having some issues with it..
BackColor - sets/gets the corresponding value
Mode - sets/gets the corresponding value, possible values are "Window", "Opaque" and "Transparent"
Quality - sets/gets the corresponding value. possible most common values are "Low", "Medium" and "Best"
CurrentFrame - returns the current Frame number.
Play - Starts the file.
Stop - hugh, Stops the file.
Foward - Speeds up the file playing
Back - Not sure about this one, I need a biggers swf to test...
Rewind - Same as a video player I guess..
Focus - Sets the focus to the player, if possible
GotoFrame(Frame) - Jumps to a specific frame, the playing gets stopped...
Zoom - Cool feature but a bit confusing...It does zomm the movie, but i cant make sense of the range...Play a bit with it...
Dispose - Well, disposes of the control
Since this is still an alpha releas, this IS the help file..
When I release V1.0, I will also provide the cs and chm files.
I will also try to combine this 3 parts dll into a single dll, but this may take some time to acomplish...
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)
My Posts helped you? Consider Buying me a Porto Glass!
Thanks for your Words MrGee...
This DLL is still in a very embryonary stage, and some more usefull and powerfull functions and events will be added...
I don't think a device version will be possible at this point, as flash support for the device, not WebBrowser embeded, is also very recent, but I will try it...
I would like to know from the Users with more Flash knowleage than me, what are the props, methods and events that they would like to see implemented, in order to achieve TRUE Flash movie playing control...
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)
My Posts helped you? Consider Buying me a Porto Glass!
Sub App_Start Form1.Show 'FP = FlashPlayer Object FP.New1("Form1",0,0,Form1.Width, Form1.Height) FP.Movie = AppPath &"\449961_StarBaron.swf" End Sub Sub mnuPlay_Click FP.Play End Sub
hope this gets developed further because I have a lot of flash animations that I can use.
--Steve
At least one more release will be posted, with version number, but I NEED the users to tell me what props, methods and events ARE USEFULL in swf playing...
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)
My Posts helped you? Consider Buying me a Porto Glass!
A Frame property would be good so that the animation can be controlled on the main timeline. Such as Goto Frame 1 or Stop Frame 1
Disabling the right-click menu so that you don't get all the options would be handy too since the flash would be embedded and users shouldn't have too many options there that could mess up on the presentation.
A means of passing variables to and from the flash movie would be excellent since flash has a lot of Internet data connectivity.
Making the flash transparent would be very useful for interface applications. You could then have fancy animated buttons.
Making a device version would be excellent but maybe not possible as you've indicated previously.
As of now I'm having problems controlling the height and width of the flash object. Not sure if you can overcome that or not.
That's it for now, but if I can think of any others, I'll add to the list..
A Frame property would be good so that the animation can be controlled on the main timeline. Such as Goto Frame 1 or Stop Frame 1
Disabling the right-click menu so that you don't get all the options would be handy too since the flash would be embedded and users shouldn't have too many options there that could mess up on the presentation.
A means of passing variables to and from the flash movie would be excellent since flash has a lot of Internet data connectivity.
Making the flash transparent would be very useful for interface applications. You could then have fancy animated buttons.
Making a device version would be excellent but maybe not possible as you've indicated previously.
As of now I'm having problems controlling the height and width of the flash object. Not sure if you can overcome that or not.
That's it for now, but if I can think of any others, I'll add to the list..
Keep up the good work CableGuy.
--Steve
Thanks for the sugestions, i believe most of then are "easely" implemented...
I too had some issues understanding why I couldn't set the width and height of my sample swf file, but then, moving the height and width props to AFTER the movie propertie solved it...
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)
My Posts helped you? Consider Buying me a Porto Glass!
@marathon332
Could you please upload a swf file with known Frames count, variables etc so I can run some tests...?
I will be working on this tomorrow aftermoon, and probably be releasing v0.1 ln early evening....
__________________
Paulo Gomes - Porto, Portugal - Living/Working in France
Mobile Device: Samsung Galaxy S, Android 2.3.4 CUstom ROM
Laptop: Toshiba NB100-130 (running on Win7Ultimate)
My Posts helped you? Consider Buying me a Porto Glass!