2009-05-01, 00:14
Yeah the autoit script i made is only for nvidia. I could make the same with the catalyst panel but i dont have any ati card on any of my computers.
clemon79 Wrote:Have you tried a second Find Window after the window move?
tiben20 Wrote:Yeah the autoit script i made is only for nvidia. I could make the same with the catalyst panel but i dont have any ati card on any of my computers.
;rundll32.exe NvCpl.dll,dtcfg setview <display#> <viewtype> [<primary NV device monikerc>] [<secondary NV device moniker>]
;Example: "setview <display#> dualview AA DA"
;If <display#> = 2, then AA will be 2 and DA will be 1.
;If <display#> = 1, then AA will be 1 and DA will be 2.
;"setview <display#> dualview AA DA"
;viewtype can be any of the following: standard (or normal) • clone • hspan • vspan • dualview
;the moniker syntaxe is:
;first character
;A = Analog, D = Digital, T = TV.
;second character
;A-H or 0-7 <------- this is the index
;
;Example
;rundll32.exe NvCpl.dll,dtcfg setview 2 clone AA TA
; setting the first analog monitor connected and the first tv connected in clone mode
;the primary will be the tv connected
;if you would have the first analog monitor connected as the primary you would have to do
;rundll32.exe NvCpl.dll,dtcfg setview 1 clone AA TA
;this command is the delay before excuting each process
;this example is too set it to .5sec before each action
;rundll32.exe NvCpl.dll,dtcfg setdelay pre 500
;
;this one is to set the delay after a process
;this example is for 2 min
;rundll32.exe NvCpl.dll,dtcfg setdelay post 120000
;
;this one is for making a display the primary display
;rundll32.exe NvCpl.dll,dtcfg primary 2
;
;this one for the RESOLUTION SETTINGS OF A DISPLAY
;
;rundll32.exe NvCpl.dll,dtcfg setmode <display#> <hres> <vres> <bpp> <freq>
;this is too Sets display #2 to 1024x768x32 @75Hz
;rundll32.exe NvCpl.dll,dtcfg setmode 2 1024 768 32 75
nvcplaction("nvcpl.dll,dtcfg setview 1 standard #TA")
;gotoTv()
;$pid = run("C:\Apps\XBMC\XBMC.exe -p")
;ProcessWaitClose($PID)
;gotoNormal(0)
Exit
func gotoTv()
;Working one
;rundll32.exe nvcpl.dll,dtcfg setview 1 standard #T0
nvcplaction("nvcpl.dll,dtcfg setview 1 standard #T0")
endfunc
func gotoNormal($viewtype)
select
case $viewtype=0;primary on left monitor
nvcplaction("nvcpl.dll,dtcfg setview 1 standard #DA")
case $viewtype=1;useless for me primary on right monitor
nvcplaction("nvcpl.dll,dtcfg setview 1 standard #AA")
case $viewtype=2;dualview
nvcplaction("nvcpl.dll,dtcfg setview 1 dualview #DA #AA")
EndSelect
;single monitor
;rundll32.exe nvcpl.dll,dtcfg setview 1 standard #DA
;primary on second monitor
;rundll32.exe nvcpl.dll,dtcfg setview 1 standard #AA
;dual view
;rundll32.exe nvcpl.dll,dtcfg setview 1 dualview #DA #AA
EndFunc
func nvcplaction($nvcplcmd)
ShellExecute("rundll32.exe" ,$nvcplcmd)
sleep(500)
EndFunc
mason Wrote:AWSOME! got exactly what i needed ... and you probably too kotix. heres how it goes :
[/url]
i got a dell tft as primary on my workstation, and a samsung lcd in the livingroom connected with the second output on my gfx.
build up your tree like on the screenshot, and check the 'Set Display Preset' under 'Start' - Query your current setting and it should show the devices like that :
[url=http://g.imageshack.us/img102/eg1hh4.jpg/1/]
then switch your primary - secondary display in the settings for your gfx and query again for the 'Stop' Command.
in this case you start your pc it comes up as normal, when the HID Button event occur, it switches your displays from primary to secondary, starts XBMC (dont forget to use the -fs -p command line switches) and Enables the Stop Folder so when you press the button again, it quits XBMC restores your display settings and reenable the Start folder!
perfect ... at least for me ....