cramaboule Posted October 1, 2011 Posted October 1, 2011 Hello all, Here is an update of this topic: I did the transition based on a real time input. Thus, if you put 200ms the transition will be made in reel 200ms (+~10ms on my PC) From my first post (see link) just replace:For $a = 0 To 254 Step $speed WinSetTrans($hGDI[$d], "", $a) Sleep($delay) Next by: $ms = 200 ; set your time (ms) $step = $ms/255 $TimerInit=TimerInit() $i=1 $p = 1 $Diff=$step $TimerInit2=TimerInit() While 1 If $i > 254 Then ExitLoop If $Diff >= $step And $p And $i < 256 Then WinSetTrans($hGDI[$d], "", int($i)) $i += 1 $TimerInit=TimerInit() $p = 0 Else Do $Diff=TimerDiff($TimerInit) Until $Diff >= $step $p=1 EndIf WEnd $Diff2=TimerDiff($TimerInit2) ConsoleWrite("+ "&$Diff2 & @LF) Of course you won't need $speed and $delay.I wonder if it is working nice on your PC as well ? Cramaboule My Autoit programs: MAC Address - - Delete Temp Files - - Ping Test - - Play Video with VLC full screen dual monitors - - Set IP - - Pics Converter - - AutoUpdater - - CPU Usage - - Ending Script Nicely - - GDI+ GUI crossfades (slide transitions) - - Beamer - - Search and Search in Files - - Silent Ninite Others: Export Icons into Dll - - My website
cramaboule Posted October 2, 2011 Author Posted October 2, 2011 Arrr I wonder why sometimes I make things more complicated than it appears.... $ms = 1000 ; set your time (ms) $step = $ms/255 $TimerInit=TimerInit() $Diff=$step $TimerInit2=TimerInit() For $i = 1 To 255 WinSetTrans($hGDI[$d], "", $i) $TimerInit=TimerInit() Do $Diff=TimerDiff($TimerInit) Until $Diff >= $step Next $Diff2=TimerDiff($TimerInit2) ConsoleWrite("+ "&$Diff2 & @LF) My Autoit programs: MAC Address - - Delete Temp Files - - Ping Test - - Play Video with VLC full screen dual monitors - - Set IP - - Pics Converter - - AutoUpdater - - CPU Usage - - Ending Script Nicely - - GDI+ GUI crossfades (slide transitions) - - Beamer - - Search and Search in Files - - Silent Ninite Others: Export Icons into Dll - - My website
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now