Jump to content

Birthday Help


Recommended Posts

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.

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
Link to comment
Share on other sites

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.

Link to comment
Share on other sites

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

Link to comment
Share on other sites

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

#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
Link to comment
Share on other sites

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

#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
Link to comment
Share on other sites

Now it is working as you wanted...

#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
Link to comment
Share on other sites

Now it is working as you wanted...

#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.

Link to comment
Share on other sites

See above.

UDF List:

 
_AdapterConnections()_AlwaysRun()_AppMon()_AppMonEx()_ArrayFilter/_ArrayReduce_BinaryBin()_CheckMsgBox()_CmdLineRaw()_ContextMenu()_ConvertLHWebColor()/_ConvertSHWebColor()_DesktopDimensions()_DisplayPassword()_DotNet_Load()/_DotNet_Unload()_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()_GUIRegisterMsg()_GUISetIcon()_Icon_Clear()/_Icon_Set()_IdleTime()_InetGet()_InetGetGUI()_InetGetProgress()_IPDetails()_IsFileOlder()_IsGUID()_IsHex()_IsPalindrome()_IsRegKey()_IsStringRegExp()_IsSystemDrive()_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()_StringCompact()_StringIsValid()_StringRegExpMetaCharacters()_StringReplaceWholeWord()_StringStripChars()_Temperature()_TrialPeriod()_UKToUSDate()/_USToUKDate()_WinAPI_Create_CTL_CODE()_WinAPI_CreateGUID()_WMIDateStringToDate()/_DateToWMIDateString()Au3 script parsingAutoIt SearchAutoIt3 PortableAutoIt3WrapperToPragmaAutoItWinGetTitle()/AutoItWinSetTitle()CodingDirToHTML5FileInstallrFileReadLastChars()GeoIP databaseGUI - Only Close ButtonGUI ExamplesGUICtrlDeleteImage()GUICtrlGetBkColor()GUICtrlGetStyle()GUIEventsGUIGetBkColor()Int_Parse() & Int_TryParse()IsISBN()LockFile()Mapping CtrlIDsOOP in AutoItParseHeadersToSciTE()PasswordValidPasteBinPosts Per DayPreExpandProtect GlobalsQueue()Resource UpdateResourcesExSciTE JumpSettings INISHELLHOOKShunting-YardSignature CreatorStack()Stopwatch()StringAddLF()/StringStripLF()StringEOLToCRLF()VSCROLLWM_COPYDATAMore Examples...

Updated: 22/04/2018

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...