Notices
Computer & Technology Related Post here for help and discussion of computing and related technology. Internet, TVs, phones, consoles, computers, tablets and any other gadgets.

some basic dual screen screen savers i wrote...

Thread Tools
 
Search this Thread
 
Old 04 August 2006, 11:33 AM
  #1  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default some basic dual screen screen savers i wrote...

http://www.z3romass.com/usr/pdrop.scr
3d spiral shapes dropping down the screen

http://www.z3romass.com/usr/MTMarquee.scr
marquee screen saver - free text, ip address, running processes, vertical or horizontal scrolling

your welcome to the code if you want to change anything.
they're fine on one screen too.

cd

edit: new matrix

http://www.z3romass.com/usr/MatrixIV.scr

Last edited by ChefDude; 04 August 2006 at 05:30 PM.
Old 04 August 2006, 11:34 AM
  #2  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

if anyone has 3 screens, do these still work? i enumerated all the monitors and mapped the virtual screen space, so it should
Old 04 August 2006, 02:06 PM
  #3  
David_Wallis
Scooby Regular
 
David_Wallis's Avatar
 
Join Date: Nov 2001
Location: Leeds - It was 562.4bhp@28psi on Optimax, How much closer to 600 with race fuel and a bigger turbo?
Posts: 15,239
Likes: 0
Received 1 Like on 1 Post
Default

What are they written in?

David
Old 04 August 2006, 02:30 PM
  #4  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

vanilla vb

here's the api list for the graphics
Private Declare Sub SetWindowPos Lib "user32" (ByVal hwnd As Long, ByVal hWndInsertAfter As Long, ByVal x As Long, ByVal y As Long, ByVal cx As Long, ByVal cy As Long, ByVal wFlags As Long)
Private Declare Function ShowCursor Lib "user32" (ByVal bShow As Long) As Long
Private Declare Function GetPixel Lib "gdi32" (ByVal hDC As Long, ByVal x As Long, ByVal y As Long) As Long
Private Declare Function SetPixel Lib "gdi32" (ByVal hDC As Long, ByVal x As Long, ByVal y As Long, ByVal crColor As Long) As Long
Private Declare Function AlphaBlend Lib "msimg32.dll" (ByVal hDC As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal hDC As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal lInt As Long, ByVal BLENDFUNCT As Long) As Long
Private Declare Sub RtlMoveMemory Lib "kernel32.dll" (Destination As Any, Source As Any, ByVal Length As Long)
Private Declare Function GetDeviceCaps Lib "gdi32" (ByVal hDC As Long, ByVal nIndex As Long) As Long
Private Declare Function BitBlt Lib "gdi32" (ByVal hDestDC As Long, ByVal x As Long, ByVal y As Long, ByVal nWidth As Long, ByVal nHeight As Long, ByVal hSrcDC As Long, ByVal xSrc As Long, ByVal ySrc As Long, ByVal dwRop As Long) As Long
Private Declare Function CreateCompatibleBitmap Lib "gdi32" (ByVal hDC As Long, ByVal nWidth As Long, ByVal nHeight As Long) As Long
Private Declare Function CreateCompatibleDC Lib "gdi32" (ByVal hDC As Long) As Long
Private Declare Function GetDC Lib "user32" (ByVal hwnd As Long) As Long
Private Declare Function DeleteDC Lib "gdi32" (ByVal hDC As Long) As Long
Private Declare Function DeleteObject Lib "gdi32" (ByVal hObject As Long) As Long
Private Declare Function CreateEllipticRgn Lib "gdi32" (ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long
Private Declare Function SetWindowRgn Lib "user32" (ByVal hwnd As Long, ByVal hRgn As Long, ByVal bRedraw As Boolean) As Long
Private Declare Function CreateFont Lib "gdi32" Alias "CreateFontA" (ByVal nHeight As Long, ByVal nWidth As Long, ByVal nEscapement As Long, ByVal nOrientation As Long, ByVal fnWeight As Long, ByVal fdwItalic As Boolean, ByVal fdwUnderline As Boolean, ByVal fdwStrikeOut As Boolean, ByVal fdwCharSet As Long, ByVal fdwOutputPrecision As Long, ByVal fdwClipPrecision As Long, ByVal fdwQuality As Long, ByVal fdwPitchAndFamily As Long, ByVal lpszFace As String) As Long
Private Declare Function SelectObject Lib "gdi32" (ByVal hDC As Long, ByVal hObject As Long) As Long
Private Declare Function TextOut Lib "gdi32" Alias "TextOutA" (ByVal hDC As Long, ByVal x As Long, ByVal y As Long, ByVal lpString As String, ByVal nCount As Long) As Long
Private Declare Function MulDiv Lib "kernel32" (ByVal nNumber As Long, ByVal nNumerator As Long, ByVal nDenominator As Long) As Long
Private Declare Function SetBkMode Lib "gdi32" (ByVal hDC As Long, ByVal nBkMode As Long) As Long
Private Declare Function GetSysColorBrush Lib "user32" (ByVal nIndex As Long) As Long
Private Declare Function FillRect Lib "user32" (ByVal hDC As Long, lpRect As RECT, ByVal hBrush As Long) As Long
Private Declare Function SetRect Lib "user32" (lpRect As RECT, ByVal X1 As Long, ByVal Y1 As Long, ByVal X2 As Long, ByVal Y2 As Long) As Long
Private Declare Function FloodFill Lib "gdi32" (ByVal hDC As Long, ByVal x As Long, ByVal y As Long, ByVal crColor As Long) As Long
Private Declare Sub Sleep Lib "kernel32" (ByVal dwMilliseconds As Long)
Private Declare Function GetTickCount& Lib "kernel32" ()
Private Declare Function SetTextColor Lib "gdi32" (ByVal hDC As Long, ByVal crColor As Long) As Long
Old 04 August 2006, 02:31 PM
  #5  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

(for the matrix one)
Old 04 August 2006, 02:32 PM
  #6  
David_Wallis
Scooby Regular
 
David_Wallis's Avatar
 
Join Date: Nov 2001
Location: Leeds - It was 562.4bhp@28psi on Optimax, How much closer to 600 with race fuel and a bigger turbo?
Posts: 15,239
Likes: 0
Received 1 Like on 1 Post
Default

Just a few api calls used then!
Old 04 August 2006, 02:59 PM
  #7  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

lunchtime projects don't usually stretch to directdraw and opengl and c++ is tediously slow to develop, so, how else do i get 50 fps at 2560x1024???


i didn't include the get monitor api calls.

the marquee one has about 15 more to enumerate the window processes too.

Trending Topics

Old 04 August 2006, 04:02 PM
  #8  
dharbige
Scooby Regular
 
dharbige's Avatar
 
Join Date: Feb 2001
Posts: 845
Likes: 0
Received 0 Likes on 0 Posts
Default

Matrix one doesn't work properly for me. Maybe due to my having my second monitor to the left of my main one, rather than on the right.

Anyway, the "Main" screen looks fine in preview, but the secondary screen just has a thin band of "matrixy" stuff on the right-hand side, but the rest of the screen still shows my workspace.

Regardless of the configured position of my second screen, if I leave my PC so it goes into the screen saver by itself, I get the following error: " Run-time error '384': A form can't be moved or sized while minimized or maximized", and a small rectangle labled "Form1" appears in the bottom-left of my main screen.
Old 04 August 2006, 04:45 PM
  #9  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

uhmm, i got that too!

windows must be having a tantrum.

i'll post when it's corrected.
Old 04 August 2006, 05:31 PM
  #10  
ChefDude
Scooby Regular
Thread Starter
 
ChefDude's Avatar
 
Join Date: Aug 2005
Posts: 4,290
Likes: 0
Received 0 Likes on 0 Posts
Default

new matrix version at the top.


works fine now
Related Topics
Thread
Thread Starter
Forum
Replies
Last Post
JimBowen
ICE
5
02 July 2023 01:54 PM
Mattybr5@MB Developments
Full Cars Breaking For Spares
28
28 December 2015 11:07 PM
shorty87
Full Cars Breaking For Spares
19
22 December 2015 11:59 AM
Mattybr5@MB Developments
Full Cars Breaking For Spares
12
18 November 2015 07:03 AM



Quick Reply: some basic dual screen screen savers i wrote...



All times are GMT +1. The time now is 06:48 AM.