Search the Community
Showing results for tags 'splashimageon'.
-
Hello, I'm trying to build some script with SplashImageOn, the idea is to show an image on top of the screen. But I don't know why it's not showing anything, I press "t" and nothing happens... #include <Date.au3> #include <GUIConstantsEx.au3> #include <WindowsConstants.au3> HotKeySet("t","test") Global $title = "Time now: " & @HOUR & ":" & @MIN Global $image = "images\karanda0015.jpg" #Region ### START Koda GUI section ### Form= $Form1 = GUICreate("Form1", 615, 437, 192, 124) GUISetState(@SW_SHOW) #EndRegion ### END Koda GUI section ### Func test() If Not FileExists($image) Then MsgBox(16,"ERROR","Unable to find " & $image) EndIf SplashImageOn($title,$image,250,200,6,5) Sleep(5000) SplashOff() EndFunc While 1 $nMsg = GUIGetMsg() Switch $nMsg Case $GUI_EVENT_CLOSE Exit EndSwitch ;Loop() WEnd
-
To save future readers a little sweat I'm editing my original post to insert the following: After trying various suggested scripting approaches, some of which introduced new problems and some which had the same problem described here, I tried my script and a few others on another computer. No white flashes, tears, glitches. So I brought it back to my main box and disabled the Intel GPU that was feeding a 3rd monitor. Down to two monitors connected to a single NVidia GPU the visual glitches disappeared. Who would'a thought?! That said, some of the replies that follow provide valuable insights into the various ways to skin this cat using AutoIt. Some suggested scripts introduced new problems so they might be instructive about approaches to avoid. Ultimately, JohnOne suggested an elegantly simple script that perfectly accomplishes my goal. --------------------- I want to display a 800x600 picture (i.e., not full-screen) without a border, close-box, title, etc. I then want to replace that picture with another one -- cleanly. Think of an old-fashioned dual-projector slide show where there's no black-out or other interruption to the image on screen. This way I can start with a background image, then add elements to it seamlessly (once called "a build", i.e., pseudo-animation). The image format doesn't matter to me. I can't use an animated GIF or video because my code is doing things in the background between images, so timing varies. I'm having bad luck using an AutoIt form to accomplish this (GUICtrlCreatePic, followed by subsequent GUICtrlSetImage's). The result is a glitch -- usually a white flash or tear in the picture -- at almost every image change. (see 10/10/13 post entitled "random visual glitch when using GUICtrlSetImage"). So I guess that's out. SplashImageOn blanks out the first image before displaying the next (like a single-projector slide show), so it's not seamless -- plus there's still a tiny border visible. $var = Default SplashImageOn("","image1.bmp",$var,$var,$var,$var,1) sleep(2000) SplashImageOn("","image2.bmp",$var,$var,$var,$var,1) sleep(2000) SplashImageOn("","image3.bmp",$var,$var,$var,$var,1) sleep(2000) Any suggestions?
- 17 replies