Johnny talk Johnny way


Linux Framebuffer … Action!
2009, 四月 10, 星期五, 1:39 上午
分類: Linux Device | 標籤: , ,

Frame buffer是一個顯示記憶空間,從試驗中可以直接在指定的位置填入RGB數值,就可以改變螢幕畫面上的一個點;簡單一些,可以下cat命令,把Frame buffer的內容Dump出來,這樣等於是把畫面剪貼下來一樣,若再把畫面Dump回Frame buffer,剛剛的畫面又會回去,很直覺的操作,中間不需要透過複雜的轉換,後面我們就來認識他吧!

一般套裝Linux,Kernel似乎預設就有開啟Frame buffer,所以只要在Loader的參數加上vga mdoe就可以在Console開啟Frame buffer,不過開啟後Frame buffer的解析度跟Color bit就已經決定,不可動態更改。

在loader的選單中加入VESA mode

title Linux
root(hd0,0)
kernel .......................................... vga=792
initrd ...

可以參考的模式如下表

Bits 640×480 800×600 1024×768 1280×1024 1600×1200
8 769 771 773 775 796
16 785 788 791 794 798
32 786 789 792 795 799

開機後,看到企鵝就代表成功啟動Frame buffer囉!


發表迴響 目前為此
發表迴響



發表迴響

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / 變更 )

Twitter picture

You are commenting using your Twitter account. Log Out / 變更 )

Facebook照片

You are commenting using your Facebook account. Log Out / 變更 )

連結到 %s



Follow

Get every new post delivered to your Inbox.