Jump to content

Flash-matic


trancexx
 Share

Recommended Posts

was asked the other day.

That first post hides a great idea an code. Unfortunately it's not AutoIt.

It's something that was never done in this language and almost impossible to be done before AutoItObject, you need AutoItObject. Remember that, you need AutoItObject. Hahaha... :)

After some googling two links crystallized, stackoverflow's and Delphy Flash thing. Read both to compare it to AutoIt's version. My conclusion is that AutoIt is as good as any language when it comes to object manipulation. Even easier to work with.

Shockwave object was used before in AutoIt scripts, there isn't much to say about that.

The main issue that was resolved here is how to load swf from memory, variable. If someone would inspect Flash typelib with some available tool (hey, :) , how interesting), he/she could see that IShockwaveFlash is IDispatch based interface with few available methods for loading files. But there is none to load either memory or stream. So, Idispatch can load only files from disk (yours or somebody elses), nothing more.

On the other hand linked articles suggest that IUnknown can load stream. This is where conventional AutoIt is lost and where AutoItObject takes control.

Described in steps, it would be:

  • Create Shockwave object
  • Expand it to IUnknown level
  • Create Stream object on (out of) SWF data
  • Ask Shockwave object for PersistStreamInit object
  • Call InitNew method of PersistStreamInit object to initialize it
  • Use Load method to load Stream of SWF data
  • Create Shockwave object control in Autoit GUI

Interesting thing is that you don't need to have Flash installed on system where this could be run. All your app would need in that case is Flash dll. Accessible Flash10m.ocx for example. Another interesting thing is that you can embed files in both scripts (as in this example) and executables as resources and run it from there.

I have added little input control, you'll figure out what's it for. By using AutoItObject you get Ward's base64 decoder for free. I used that to shrink the size of the embedded file.

Script (don't miss):

SWF.au3

Everybody loves Duck Sauce, is this amazing or is this amazing?

♡♡♡

.

eMyvnE

Link to comment
Share on other sites

Control below button and input?

FireFox, does it work if you remove upper control completely and comment out $oShockwaveFlash1 entirely? And what's the version of your AutoIt?

edit:

@JohnOne, both SWFs are from memory.

Edited by trancexx

♡♡♡

.

eMyvnE

Link to comment
Share on other sites

Your Flash-matic is good AutoIt solution of unpossible task.

BTW I've done more than three trials to resolve "MapWindow GIS ActiveX" problem and failed.

Read about it on Home page of project

The OCX (it's free!) with dependencies can be download from here

Is it really impossible to create MapWindowGIS-matic for AutoIt users?

Thanx

:)

The point of world view

Link to comment
Share on other sites

Control below button and input?

FireFox, does it work if you remove upper control completely and comment out $oShockwaveFlash1 entirely? And what's the version of your AutoIt?

Nop it does not. I have autoit v3.3.6.1

Br, FireFox.

Link to comment
Share on other sites

@trancexx

Can you give me the function to stop the video and the streaming?

Br, FireFox.

This may sound strange but there is no such function, at least not the way you think.

Those are SWFs. Autoit is using ShockwaveFlash object to run SWF. SWF is what's streaming and depending on the developer of the SWF it can receive commands thru SetVariable method.

Probably someone with better understanding of the thematic could explain better. I'm very limited with knowledge in this area.

Edited by trancexx

♡♡♡

.

eMyvnE

Link to comment
Share on other sites

Excellent job :)

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...