Saturday, May 11, 2024
 Popular · Latest · Hot · Upcoming
3
rated 0 times [  3] [ 0]  / answers: 1 / hits: 2560  / 2 Years ago, sat, june 4, 2022, 2:46:13

I know the X.org server run is executed with certain value of bpp, 8bpp by default i think.



But how can I find out the actual bits per pixel using into my framebuffer while i'm on linux? is there any command that can get it?



Thanks.


More From » graphics

 Answers
7

In a terminal, run the xwininfo command, then choose a window - the Depth: result is the bits per pixel. For example:



$ xwininfo

xwininfo: Please select the window about which you
would like information by clicking the
mouse in that window.

xwininfo: Window id: 0x3e00005 "davidp@sysadmin: ~"

Absolute upper-left X: 1920
Absolute upper-left Y: 24
Relative upper-left X: 0
Relative upper-left Y: 0
Width: 1920
Height: 1056
Depth: 32
Visual: 0x74
Visual Class: TrueColor
Border width: 0
Class: InputOutput
Colormap: 0x3e00004 (not installed)
Bit Gravity State: NorthWestGravity
Window Gravity State: NorthWestGravity
Backing Store State: NotUseful
Save Under State: no
Map State: IsViewable
Override Redirect State: no
Corners: +1920+24 -0+24 -0-0 +1920-0
-geometry 212x56-0-0


You could also use xdpyinfo, which will give you more information than you probably want - including all available bit depths for your displays (without showing you which one is actually in use).


[#28070] Sunday, June 5, 2022, 2 Years  [reply] [flag answer]
Only authorized users can answer the question. Please sign in first, or register a free account.
eaderitable

Total Points: 368
Total Questions: 117
Total Answers: 111

Location: Tuvalu
Member since Sat, Feb 11, 2023
1 Year ago
;