GetScreenDepth
BitDepth = GetScreenDepth()
 
Parameters: NONE
Returns:

    BitDepth = The depth (in bits) of the current graphics mode
 

      GetScreenDepth() returns the current bit depth (number of colours) of the screen.


Bit Depths Supported (number of colours)

      16 =65536 Possible colours.
      24 = 16.8 Million colours (warning a lot of newer video cards longer support this mode)
      32 = 16.8 Million colours



FACTS:


      * none.





Mini Tutorial:


      Display the current width/height/depth and type of the screen currently in use.

  
  Print "The Screens Current Settings are."
  Print "Current Display Width:"+Str$(GetScreenWidth())
  Print "Current Display Height:"+Str$(GetScreenHeight())
  Print "Current Display Depth:"+Str$(GetScreenDepth())
  Print "Current Display Type:"+Str$(GetScreenType())
  
; Display the Screen and waitkey for key press before ending.
  Sync
  WaitKey
  



Since PlayBasics default screen mode settings are 800,600,16,1 the above code will output.

  
  Current Display Width:800
  Current Display Height:600
  Current Display Depth:16
  Current Display Type:1
  


Note: Since it's running windowed mode, it might not have a screen depth of 16.



 
Related Info: GetScreenHeight | GetScreenType | GetScreenWidth | OpenScreen :
 


(c) Copyright 2002 - 2024 - Kevin Picone - PlayBASIC.com