Setting Wallpaper

BlitzMax Forums/BlitzMax Beginners Area/Setting Wallpaper

Blitzer101(Posted 2006) [#1]
Hi,

Does anyone know if it's possible to set the Windows wallpaper from a BlitzMAX application? Naturally if it is a few pointers in the right direction would be helpful. :)

Thanks in advance. :)


assari(Posted 2006) [#2]
I thought this would work but didn't.
Const SPI_SETDESKWALLPAPER:Int = $14
Const SPIF_UPDATEINIFILE:Int = $1
Const SPIF_SENDWININICHANGE:Int = $2

Extern "win32"
	Function SystemParametersInfoA:Int(uAction:Int,uParam:Int,lpvParam$z,fuWinIni:Int)
End Extern

Print SystemParametersInfoA(SPI_SETDESKWALLPAPER, 0, "C:\WINDOWS\Web\Wallpaper\Azul.jpg", SPIF_UPDATEINIFILE|SPIF_SENDWININICHANGE)

End

Maybe you will have better luck


ImaginaryHuman(Posted 2006) [#3]
Would be nice to be able to get the background texture itself and use it for rendering to.

On the Mac the desktop's backbground is a texture and there are a few apps that tap into it and actually render to it so that there is a full-screen screensaver running as the backdrop to the desktop. It would be cool to be able to do that.


Blitzer101(Posted 2006) [#4]
assari,

Thanks - will try and make head or tail of what you done there is supposed to do and then see if I can fathom it out at some point. Have to admit I don't have a clue ATM though! LOL. :)