Y.s Diary


 

2013年 02月 09日
DefaultDepth (OpenPandora)
+ [前置]

標準の 16ビットカラー (16bpp) を、24ビットカラー (32bpp) に変更する方法です。

  • PowerVR SGX の 24ビットカラー (32bpp) でのレンダリングは、 バグがあるかもとのコメントが
  • 24ビットカラー (32bpp) が必要なアプリケーションを動かすの ?
  • 1画素のデータが増えるからレンダリングが遅くなるのでは
  • Pandora の LCD って 24bit なの (18bit + ディザリング ?)

等は、気にしない方向で…

以下、1GHz Edition / SuperZaxxon v1.53 (Kernel 3.2.30) で確認しました。

<追記 (2013/02/11)>

FIRST BATCH / SuperZaxxon v1.53 (Kernel 3.2.30) でも確認しました。

</追記 (2013/02/11)>

+ [修正前]

16ビットカラー (16bpp) です。

$ xwininfo -root

xwininfo: Window id: 0x44 (the root window) (has no name)

  Absolute upper-left X:  0
  Absolute upper-left Y:  0
  Relative upper-left X:  0
  Relative upper-left Y:  0
  Width: 800
  Height: 480
  Depth: 16
  Visual: 0x21
  Visual Class: TrueColor
  Border width: 0
  Class: InputOutput
  Colormap: 0x20 (installed)
  Bit Gravity State: ForgetGravity
  Window Gravity State: NorthWestGravity
  Backing Store State: NotUseful
  Save Under State: no
  Map State: IsViewable
  Override Redirect State: no
  Corners:  +0+0  -0+0  -0-0  +0-0
  -geometry 800x480+0+0

$ grep -i depth /var/log/Xorg.0.log
(**) omapfb(0): Depth 16, (--) framebuffer bpp 16
$ fbset -i

mode "800x480-60"
    # D: 36.001 MHz, H: 33.242 kHz, V: 60.003 Hz
    geometry 800 480 800 1440 16
    timings 27777 214 68 34 39 1 1
    rgba 5/11,6/5,5/0,0/0
endmode

Frame buffer device information:
    Name        : omapfb
    Address     : 0x9f800000
    Size        : 3072000
    Type        : PACKED PIXELS
    Visual      : TRUECOLOR
    XPanStep    : 1
    YPanStep    : 1
    YWrapStep   : 0
    LineLength  : 1600
    Accelerator : No
+ [修正箇所]
  1. /etc/init.d/psplash の

    fbset -depth 16
    

    fbset -depth 32
    

    に変更します。

  2. /etc/init.d/slim-init の

    fbset -depth 16
    

    を削除します。

  3. /etc/X11/xorg.conf の

            DefaultDepth    16
    

            DefaultDepth    24
    

    に変更し、次の行に

            DefaultFbBpp    32
    

    を追加します。更に

                    Depth   16
    

                    Depth   24
    

    に変更します。

  4. トリプルバッファリングの為の VRAM 容量が足りなくなりますので、 autoboot.txt と boot.txt で指定されている VRAM サイズを倍にします。

  5. リブートします。

+ [修正後]

24ビットカラー (32bpp) です。

$ xwininfo -root

xwininfo: Window id: 0x44 (the root window) (has no name)

  Absolute upper-left X:  0
  Absolute upper-left Y:  0
  Relative upper-left X:  0
  Relative upper-left Y:  0
  Width: 800
  Height: 480
  Depth: 24
  Visual: 0x21
  Visual Class: TrueColor
  Border width: 0
  Class: InputOutput
  Colormap: 0x20 (installed)
  Bit Gravity State: ForgetGravity
  Window Gravity State: NorthWestGravity
  Backing Store State: NotUseful
  Save Under State: no
  Map State: IsViewable
  Override Redirect State: no
  Corners:  +0+0  -0+0  -0-0  +0-0
  -geometry 800x480+0+0

$ grep -i depth /var/log/Xorg.0.log
(**) omapfb(0): Depth 24, (**) framebuffer bpp 32
(--) Depth 24 pixmap format is 32 bpp
$ fbset -i

mode "800x480-60"
    # D: 36.001 MHz, H: 33.242 kHz, V: 60.003 Hz
    geometry 800 480 800 1440 32
    timings 27777 214 68 34 39 1 1
    rgba 8/16,8/8,8/0,8/24
endmode

Frame buffer device information:
    Name        : omapfb
    Address     : 0x9f200000
    Size        : 6144000
    Type        : PACKED PIXELS
    Visual      : TRUECOLOR
    XPanStep    : 1
    YPanStep    : 1
    YWrapStep   : 0
    LineLength  : 3200
    Accelerator : No
 

This page is written in Japanese.