Jump to content



Photo

Birthday Help


  • Please log in to reply
14 replies to this topic

#1 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 16 May 2012 - 08:12 AM

Hi ;)

My girlfriends b-day is coming up in just a few days and decided to make a unique card for her.


So I have the card almost exactly how I wanted it however, I ran into one problem...I have a membership on americangreetings.com and decided to add one of their videos to my card to finish it off.

Adding the swf video is no problem but the problem with the video is that it changes its size of the flash video.

What happens is when I add the video I set the size of 550 x 400 and it resizes to 1000 x 1000 or so after awhile into the video and I am having a hard time adjusting the window I made to change with it.

AutoIt         
Func _Video()     HotKeySet("{ESC}", "_Exit")     $Width = @DesktopWidth     $Height = @DesktopHeight     $Obj = ObjCreate("ShockwaveFlash.ShockwaveFlash")     $GUI2 = GUICreate("", $Width, $Height, Default, Default, $WS_POPUP)     $ActiveX = GUICtrlCreateObj($Obj, 0, 0, 550, 400) With $obj   ;  .bgcolor = "#222211"     .Movie = @ScriptDir & "ResourcesVideo.swf"; it should be loaded here, directly from compiled exe - no temporary files     .scalemode = 0     .allowScriptAccess = "Always" ;.Quality = 1     ;.ScaleMode = 1     ;.Loop = True    ; .wmode = "transparent" EndWith ;GUISetState(@SW_SHOW, $GUI) GUISetState (@SW_SHOW, $GUI2) While 1     If GUIGetMsg() = -3 Then         $obj = 0         GUIDelete()         Exit     EndIf WEnd EndFunc


Little example, dont mind the messy code please...4 AM lol

This is the actual link to the video

http://www.americangreetings.com/ecards/...e-music-by-taylor-swift-ecard/ (You'll see what happens if you watch long enough...)

[Edited]

I thought that .allowScriptAccess = "Always" would help but nothing

Edited by SkellySoul, 16 May 2012 - 08:14 AM.






#2 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 16 May 2012 - 07:44 PM

Bump...Thanks

#3 searchresult

searchresult

    Adventurer

  • Active Members
  • PipPip
  • 116 posts

Posted 16 May 2012 - 07:57 PM

width: 1050px; height: 1025px; is the actual size of the video when it starts to play. 550 x 400 is just still image before it starts to play...

#4 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 16 May 2012 - 09:33 PM

width: 1050px; height: 1025px; is the actual size of the video when it starts to play. 550 x 400 is just still image before it starts to play...


Oh okay, but the thing is I even tried that Width and Height because I know that it increases to that Width and Height but I still am not able to see everything in the video.

#5 JohnOne

JohnOne

    John

  • Active Members
  • PipPipPipPipPipPip
  • 8,857 posts

Posted 16 May 2012 - 11:42 PM

Can't you do something like

With $obj
.Width = 500;(whatever)
.Height = 400;(.)
AutoIt Absolute Beginners Require a serial
Run('hh mk:@MSITStore:'&StringReplace(@AutoItExe,'.exe','.chm')&'::/html/tutorials/helloworld/helloworld.htm','',@SW_MAXIMIZE)

#6 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 17 May 2012 - 12:24 AM

Can't you do something like

With $obj
.Width = 500;(whatever)
.Height = 400;(.)


I actually tried that but for some reason I get an error.

.Width = 550 .Width = 550 ^ ERROR


#7 searchresult

searchresult

    Adventurer

  • Active Members
  • PipPip
  • 116 posts

Posted 17 May 2012 - 06:28 AM

Did you try this?

$GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP) $ActiveX = GUICtrlCreateObj($Obj, 0, 0, 1050, 1025)


#8 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 17 May 2012 - 11:33 PM

Did you try this?

$GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP) $ActiveX = GUICtrlCreateObj($Obj, 0, 0, 1050, 1025)

Yep I tried that, I even tried @Desktop Width + Height


For some reason it just doesnt want to show everything in the video...I can get it working in a program called "Sothink SWF Decompiler"


I didnt plan on uploading it but here is the actual video

http://www.mediafire.com/?7r10j61daa2o14h

#9 searchresult

searchresult

    Adventurer

  • Active Members
  • PipPip
  • 116 posts

Posted 18 May 2012 - 09:51 AM

Try this... I have small monitor at work so can't see width well... I know height is good...

Plain Text         
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> _Video() Func _Video()     HotKeySet("{ESC}", "_Exit")     $Width = @DesktopWidth     $Height = @DesktopHeight     $vHeight = 1050     $vWidth = 1025     $Obj = ObjCreate("ShockwaveFlash.ShockwaveFlash")     $GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP)     GUISetBkColor(0xFFFFFF)     $ActiveX = GUICtrlCreateObj($Obj, $Width / 2 - $vWidth / 2, $Height / 2 - $vHeight / 2, $vWidth, $vHeight)     With $Obj         .Movie = @ScriptDir & "Video.swf"; it should be loaded here, directly from compiled exe - no temporary files         .Movie.stage.stageWidth = 1050         .Movie.stage.stageHeight = 1025         .allowScriptAccess = "always"         .scalemode = False         .wmode = "transparent"         .flashvars = "bframe=1&amp;ihost=http://ak.imgag.com/imgag&amp;brandldrPath=/swf/loaders/&amp;cardNum=/product/full/ap/3286601/graphic1&amp;ahost=http://www.americangreetings.com&amp;phost=http://www.americangreetings.com&amp;asv=3&amp;brandldr=wsag_as3&amp;mode=init&amp;mtype=0&amp;productNumber=3286601&amp;shellWebPath=/swf&amp;fps=fps24&amp;controlbar=/swf/control_bars/controlBar_nutshell&amp;pdType=WS&amp;flvWidth=550&amp;flvHeight=400&amp;largeX=550&amp;laregY=400&amp;showControlBar=1&amp;postroll=/swf/dynamic_plugins/AGJoinOverlayPlugin&amp;overlaywait=2000&amp;NameFirstFrom=sender&amp;NameFirstTo=recipient&amp;"     EndWith     GUISetState(@SW_SHOW, $GUI2)     While 1         If GUIGetMsg() = -3 Then             $Obj = 0             GUIDelete()             Exit         EndIf     WEnd EndFunc   ;==>_Video Func _Exit()     Exit EndFunc   ;==>_Exit

Edited by searchresult, 18 May 2012 - 10:54 AM.


#10 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 18 May 2012 - 07:57 PM

Try this... I have small monitor at work so can't see width well... I know height is good...

Plain Text         
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> _Video() Func _Video()     HotKeySet("{ESC}", "_Exit")     $Width = @DesktopWidth     $Height = @DesktopHeight     $vHeight = 1050     $vWidth = 1025     $Obj = ObjCreate("ShockwaveFlash.ShockwaveFlash")     $GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP)     GUISetBkColor(0xFFFFFF)     $ActiveX = GUICtrlCreateObj($Obj, $Width / 2 - $vWidth / 2, $Height / 2 - $vHeight / 2, $vWidth, $vHeight)     With $Obj         .Movie = @ScriptDir & "Video.swf"; it should be loaded here, directly from compiled exe - no temporary files         .Movie.stage.stageWidth = 1050         .Movie.stage.stageHeight = 1025         .allowScriptAccess = "always"         .scalemode = False         .wmode = "transparent"         .flashvars = "bframe=1&amp;ihost=http://ak.imgag.com/imgag&amp;brandldrPath=/swf/loaders/&amp;cardNum=/product/full/ap/3286601/graphic1&amp;ahost=http://www.americangreetings.com&amp;phost=http://www.americangreetings.com&amp;asv=3&amp;brandldr=wsag_as3&amp;mode=init&amp;mtype=0&amp;productNumber=3286601&amp;shellWebPath=/swf&amp;fps=fps24&amp;controlbar=/swf/control_bars/controlBar_nutshell&amp;pdType=WS&amp;flvWidth=550&amp;flvHeight=400&amp;largeX=550&amp;laregY=400&amp;showControlBar=1&amp;postroll=/swf/dynamic_plugins/AGJoinOverlayPlugin&amp;overlaywait=2000&amp;NameFirstFrom=sender&amp;NameFirstTo=recipient&amp;"     EndWith     GUISetState(@SW_SHOW, $GUI2)     While 1         If GUIGetMsg() = -3 Then             $Obj = 0             GUIDelete()             Exit         EndIf     WEnd EndFunc   ;==>_Video Func _Exit()     Exit EndFunc   ;==>_Exit

Thanks for continuing to help me, I really appreciate it...unfortunately the width doesnt want to work when the video resizes....the height seems fine.

I was also wondering what .flashvar does.

Edited by SkellySoul, 18 May 2012 - 07:57 PM.


#11 searchresult

searchresult

    Adventurer

  • Active Members
  • PipPip
  • 116 posts

Posted 18 May 2012 - 08:14 PM

Problem is that the overlay is set to 2000px width. there should be solution to this but... well if i find something out, will post it...

#12 searchresult

searchresult

    Adventurer

  • Active Members
  • PipPip
  • 116 posts

Posted 18 May 2012 - 09:07 PM

Now it is working as you wanted...

Plain Text         
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> _Video() Func _Video()     HotKeySet("{ESC}", "_Exit")     $Width = @DesktopWidth     $Height = @DesktopHeight     $vHeight = 1025     $vWidth = 1200     $Obj = ObjCreate("ShockwaveFlash.ShockwaveFlash")     $GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP)     GUISetBkColor(0xFFFFFF)     GUICtrlCreateObj($Obj, $Width / 2 - $vWidth / 2, $Height / 2 - $vHeight / 2, $vWidth, $vHeight)     With $Obj         .Movie = @ScriptDir & "Video.swf"; it should be loaded here, directly from compiled exe - no temporary files         .scale = "noscale"     EndWith     GUISetState(@SW_SHOW, $GUI2)     While 1         If GUIGetMsg() = -3 Then             $Obj = 0             GUIDelete()             Exit         EndIf     WEnd EndFunc   ;==>_Video Func _Exit()     Exit EndFunc   ;==>_Exit


You can center as you wish but don't touch dimension ($vHeight and $vWidth) ;)

Edited by searchresult, 18 May 2012 - 09:08 PM.


#13 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 19 May 2012 - 02:58 AM

Now it is working as you wanted...

Plain Text         
#include <GUIConstantsEx.au3> #include <WindowsConstants.au3> _Video() Func _Video()     HotKeySet("{ESC}", "_Exit")     $Width = @DesktopWidth     $Height = @DesktopHeight     $vHeight = 1025     $vWidth = 1200     $Obj = ObjCreate("ShockwaveFlash.ShockwaveFlash")     $GUI2 = GUICreate("", $Width, $Height, 0, 0, $WS_POPUP)     GUISetBkColor(0xFFFFFF)     GUICtrlCreateObj($Obj, $Width / 2 - $vWidth / 2, $Height / 2 - $vHeight / 2, $vWidth, $vHeight)     With $Obj         .Movie = @ScriptDir & "Video.swf"; it should be loaded here, directly from compiled exe - no temporary files         .scale = "noscale"     EndWith     GUISetState(@SW_SHOW, $GUI2)     While 1         If GUIGetMsg() = -3 Then             $Obj = 0             GUIDelete()             Exit         EndIf     WEnd EndFunc   ;==>_Video Func _Exit()     Exit EndFunc   ;==>_Exit


You can center as you wish but don't touch dimension ($vHeight and $vWidth) ;)

That is exactly what I was looking for excellent...you have no idea how happy I am now that it is working...made my day :)

Thank you...may be if you don't mind can you explain what was causing the problem.

#14 guinness

guinness

    guinness

  • MVPs
  • 10,351 posts

Posted 19 May 2012 - 05:46 AM

See above.

Example List: _AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_DesktopDimensions()_DisplayPassword()_Fibonacci()_FileCompare()_FileCompareContents()_FileNameByHandle()_FilePrefix/SRE()_FindInFile()_GetBackgroundColor()/_SetBackgroundColor()_GetConrolID()_GetCtrlClass()_GetDirectoryFormat()_GetDriveMediaType()_GetFilename()/_GetFilenameExt()_GetHardwareID()_GetIP()_GetIP_Country()_GetOSLanguage()_GetSavedSource_GetStringSize()_GetSystemPaths()_GetURLImage()_GIFImage()_GoogleWeather()_GUICtrlCreateGroup()_GUICtrlListBox_CreateArray()_GUICtrlListView_CreateArray()_GUICtrlListView_SaveCSV()_GUICtrlListView_SaveHTML()_GUICtrlListView_SaveTxt()_GUICtrlListView_SaveXML()_GUICtrlMenu_Recent()_GUICtrlMenu_SetItemImage()_GUICtrlTreeView_CreateArray()_GUIDisable()_GUIImageList_SetIconFromHandle()_GUISetIcon()_Icon_Clear()/_Icon_Set()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsUPX()_IsValidType()_IsWebColor()_Language()_Log()_MicrosoftInternetConnectivity()_MSDNDataType()_PathFull/GetRelative/Split()_PathSplitEx()_PrintFromArray()_ProgressSetMarquee()_ReDim()_RockPaperScissors()/_RockPaperScissorsLizardSpock()_ScrollingCredits_SelfDelete()_SelfRename()_SelfUpdate()_SendTo()_ShellAll()_ShellFile()_ShellFolder()_SingletonHWID()_SingletonPID()_Startup()_StringIsValid()_StringReplaceWholeWord()_StringStripChar()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()AutoIt SearchAutoIt3 PortableAutoItWinGetTitle()/AutoItWinSetTitle()CodingFileInstallrGeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIGetBkColor()LockFile()PasteBinSciTE JumpSignature CreatorWM_COPYDATAMore Examples...Updated: 11/04/2013


#15 SkellySoul

SkellySoul

    Universalist

  • Active Members
  • PipPipPipPipPipPip
  • 320 posts

Posted 19 May 2012 - 08:43 AM

See above.


I don't know what exactly an overlay means...it could mean many different things.




0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users