国产探花免费观看_亚洲丰满少妇自慰呻吟_97日韩有码在线_资源在线日韩欧美_一区二区精品毛片,辰东完美世界有声小说,欢乐颂第一季,yy玄幻小说排行榜完本

首頁 > 系統(tǒng) > Ubuntu > 正文

ubuntu不能設(shè)置高分辨率問題的解決方法

2020-10-18 20:52:33
字體:
供稿:網(wǎng)友

在ubuntu12.10上安裝gnome切換到經(jīng)典模式后,分別率最高只有1024*768,以為是沒有安裝顯卡驅(qū)動(dòng)導(dǎo)致的,上網(wǎng)搜索了N多方法,安裝了各種nvidia驅(qū)動(dòng),依然沒有搞定。
反而把分辨率降低到只能設(shè)置為最高854*480,導(dǎo)致窗口按鈕都看不到。后來想啟動(dòng)時(shí)選擇默認(rèn)模式,不用gnome經(jīng)典模式,回到默認(rèn)模式不就可以了,結(jié)果還是不行。
然后又把gnome刪除,刪除時(shí)直接使用sudo apt-get remove gnome*, 把所有g(shù)nome相關(guān)的文件都刪除了,就直接導(dǎo)致啟動(dòng)不了。
最后沒辦法,又重新安裝了ubuntu12.10,安裝時(shí)選擇第一項(xiàng)默認(rèn)的保留已有文檔和軟件繼續(xù)安裝,結(jié)果安裝后雖然可以驅(qū)動(dòng)了,但還是最高只能是1024*768的分辨率。
后來又去ubutnu軟件中心安裝了nvidia當(dāng)前驅(qū)動(dòng),還是不行。由于重裝時(shí)沒有選擇安裝更新,所以又去“軟件更新器”安裝了更新,更新后重啟還是沒有作用。
再后來想到升級(jí)到13.04,經(jīng)過一個(gè)多小時(shí)漫長的等待,升級(jí)后結(jié)果還是不行。分辨率10.24*768依然不變。
此時(shí)搜索“ubuntu 硬件 顯示 未知”使,發(fā)現(xiàn)了以下文章,按照操作居然成功了,把分辨率設(shè)置為了1400*900,雖然“系統(tǒng)設(shè)置/顯示”里面還是顯示未知,但分辨率的確提高了。

(轉(zhuǎn))ubuntu分辨率設(shè)置

以下是本篇文章的內(nèi)容:

--------------------------------------------------------------->>>
我的一臺(tái)11寸上網(wǎng)本,裝的ubuntu。最近外接了一個(gè)19寸顯示器。分辨率最多只能是1024x768。顯示器設(shè)置里顯示“未知”顯示器。
 用下面的命令可以看到顯卡的信息:
 $ lspci | grep VGA
 00:02.0 VGA compatible controller: Intel Corporation Mobile 945GME Express Integrated Graphics Controller (rev 03)
 
 我一直以為是顯卡驅(qū)動(dòng)沒裝好,于是下載了intel顯卡linux驅(qū)動(dòng)的源碼,并花了幾天時(shí)間來編譯(期間安裝了N多它所依賴的包),最終還是沒能裝成功,還把Xorg搞掛了。無奈還重裝了系統(tǒng)。其實(shí)intel集成顯卡的驅(qū)動(dòng)已經(jīng)裝好了,而且用命令sudo apt-get install xserver-xorg-video-intel也可以安裝。
 之后還在網(wǎng)上看到修改/etc/X11/xorg.conf之類的解決方案。我直接頭大了。
 最后還是找到了解決方案:xrandr命令。
 首先,直接運(yùn)行xrandr查看下分辨率的情況:
 $ xrandr
 Screen 0: minimum 320 x 200, current 1280 x 1024, maximum 4096 x 4096
 LVDS1 connected (normal left inverted right x axis y axis)
    1024x600       60.0 +
    800x600        60.3     56.2
    640x480        59.9
 VGA1 connected 1280x1024+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
    1024x768       60.0 *
    800x600        60.3     56.2
    848x480        60.0
    640x480        59.9
 標(biāo)星號(hào)的那行就是我正在使用的分辨率。
 下面用cvt命令生成一個(gè)modeline,為后續(xù)添加分辨率作準(zhǔn)備:
 $ cvt 1440 900
 # 1440x900 59.89 Hz (CVT 1.30MA) hsync: 55.93 kHz; pclk: 106.50 MHz
 Modeline "1440x900_60.00"  106.50  1440 1528 1672 1904  900 903 909 934 -hsync +vsync
 再運(yùn)行xrandr --newmode來創(chuàng)建一個(gè)分辨率模式,使用“Modeline”后的內(nèi)容(--rmmode刪除這個(gè)模式):
 $ xrandr --newmode "1440x900_60.00"  106.50  1440 1528 1672 1904  900 903 909 934 -hsync +vsync
 接著用xrandr --addmode把這個(gè)模式添加到顯示器上(--delmode把這個(gè)模式從該顯示器上移除):
 $ xrandr --addmode VGA1 "1440x900_60.00"
 最后是應(yīng)用這個(gè)模式:
 $ xrandr --output VGA1 --mode "1440x900_60.00"
 到此,我的屏幕看上去就清爽多了。
 用xrandr查看一下:
 $ xrandr
 Screen 0: minimum 320 x 200, current 1440 x 900, maximum 4096 x 4096
 LVDS1 connected (normal left inverted right x axis y axis)
    1024x600       60.0 +
    800x600        60.3     56.2
    640x480        59.9
 VGA1 connected 1440x900+0+0 (normal left inverted right x axis y axis) 0mm x 0mm
    1024x768       60.0
    800x600        60.3     56.2
    848x480        60.0
    640x480        59.9
    1440x900_60.00   59.9*
 設(shè)置完后我的屏幕向左偏出了約5個(gè)像素,直接在顯示器(硬件)上調(diào)就可以了。
 參考:https://wiki.ubuntu.com/X/Config/Resolution
<<<---------------------------------------------------------------

特此感謝!終于搞定了浪費(fèi)了大半天的問題。

不過,關(guān)機(jī)重新開機(jī)后此設(shè)置有時(shí)候就沒有了,又恢復(fù)到原來的分辨率了。

現(xiàn)在把設(shè)置新分辨率的命令寫到一個(gè)sh腳本中,如果分辨率恢復(fù)到原來的自動(dòng)執(zhí)行此shell文件就可以了。

代碼如下:

復(fù)制代碼
代碼如下:

#!/bin/bash</p><p># set screen resolution to 1400 * 900</p><p># Query current resolution
echo "Current resolution:"
xrandr
echo "-------------------------------------"</p><p># New one modeline for 1440 * 900
echo "New one modeline for 1440 * 900:"
cvt 1440 900
echo "-------------------------------------"</p><p># Create resolution using "xrandr --newmode" command
echo "Create resolution 1400 * 900:"
xrandr --newmode "1440x900_60.00" 106.50 1440 1528 1672 1904 900 903 909 934 -hsync +vsync
echo "-------------------------------------"</p><p># Add the resolution to monitor
echo "Add the resolution to monitor:"
xrandr --addmode VGA1 "1440x900_60.00"
echo "-------------------------------------"</p><p># Apply the resolution
echo "Apply the resolution:"
xrandr --output VGA1 --mode "1440x900_60.00"
echo "-------------------------------------"</p><p># Query current resolution again to determine the settings valid or not
echo "Current resolution after settings:"
xrandr
echo "-------------------------------------"


設(shè)置分辨率1680 * 1050的shell腳本如下:


復(fù)制代碼
代碼如下:

#!/bin/bash</p><p># set screen resolution to 1680×1050</p><p># Query current resolution
echo "Current resolution:"
xrandr
echo "-------------------------------------"</p><p># New one modeline for 1680×1050
echo "New one modeline for 1680×1050:"
cvt 1680 1050
echo "-------------------------------------"</p><p># Create resolution using "xrandr --newmode" command
echo "Create resolution 1680×1050:"
xrandr --newmode "1680x1050_60.00" 146.25 1680 1784 1960 2240 1050 1053 1059 1089 -hsync +vsync
echo "-------------------------------------"</p><p># Add the resolution to monitor
echo "Add the resolution to monitor:"
xrandr --addmode VGA1 "1680x1050_60.00"
echo "-------------------------------------"</p><p># Apply the resolution
echo "Apply the resolution:"
xrandr --output VGA1 --mode "1680x1050_60.00"
echo "-------------------------------------"</p><p># Query current resolution again to determine the settings valid or not
echo "Current resolution after settings:"
xrandr
echo "-------------------------------------"

發(fā)表評(píng)論 共有條評(píng)論
用戶名: 密碼:
驗(yàn)證碼: 匿名發(fā)表
主站蜘蛛池模板: 尚志市| 凌海市| 嘉善县| 湖北省| 平遥县| 卢氏县| 石楼县| 诸城市| 武义县| 高雄县| 辽宁省| 苍梧县| 扎囊县| 六安市| 长治县| 苗栗市| 塘沽区| 玉龙| 象州县| 常宁市| 利辛县| 普兰店市| 綦江县| 高密市| 巫山县| 简阳市| 高淳县| 南召县| 龙泉市| 长汀县| 安阳市| 六枝特区| 错那县| 延津县| 潮州市| 浙江省| 中西区| 三台县| 体育| 乐亭县| 苏尼特右旗|