xcalib error - unsupported ramp size

8,464

Solution 1

This is actually a bug as reported upstream in debian and various other places. It seems newer version of X caused this. A user reported a workaround for intel drivers and it worked for me.

First of all, do make sure that the appropriate drivers are actually installed: $ sudo apt install xorg xserver-xorg-video-intel

You need to create a xorg .conf file to force usage of intel drivers. Create a file /etc/X11/xorg.conf.d/20-intel.conf and put these lines there.

Section "Device"
  Identifier "Intel Graphics"
  Driver "intel"
EndSection

On Ubuntu 18.04 and newer, the file /etc/X11/xorg.conf should contain Driver "intel" under the Section "Device". The Identifier may be called differently.

Now reboot or restart X (sudo systemctl restart display-manager).

Solution 2

On Ubuntu 16.04 and earlier

The other answer has worked for me quite well.

On Ubuntu 18.04

I came across this thread stating that the xcalib in the Ubuntu repository is too old - built in 2008. There have been updates to the xcalib repository. So, you can clone the git repository from there, and build and install.

Firstly, you need to have git, make and cmake:

sudo apt install git cmake make

You will also require the following libraries:

sudo apt install libx11-dev libxrandr-dev libxxf86vm-dev

And the main steps:

git clone https://github.com/OpenICC/xcalib.git
cd xcalib
cmake CMakeLists.txt
sudo make install

You can uninstall by running:

sudo make uninstall 

One (those new to Linux) can search for these by

apt-cache search [some-keyword]

Besides,

My Experience

For me (on XPS 9570) (and at least one more), the other solution didn't work on Ubuntu 18.04 - it simply didn't work, besides the fact that it disables brightness keys. I have relied on that solution for inverting screen colours for quite some time - it did work on (X)Ubuntu 16.04, Debian Stretch.

Now, thanks to google - I have been googling since more 3 days - to me, it seems google keeps searching for your query when you're offline, so that it can give you more relevant results when you search for it again.

Share:
8,464

Related videos on Youtube

tomasantunes
Author by

tomasantunes

Updated on September 18, 2022

Comments

  • tomasantunes
    tomasantunes over 1 year

    I'm trying to change the contrast with xcalib with the command xcalib -co 70 but I get the following error:

    Error - unsupported ramp size 0
    
    • Admin
      Admin almost 7 years
      According to the xcalib README the last parameter must be an ICC profile, or -a or -alter as described in this previous Q&A How to adjust contrast with xcalib
    • Admin
      Admin almost 7 years
      I tried, same error.
    • Admin
      Admin over 6 years
      @TomásAntunes Have you tried the mentioned solution?
  • erjoalgo
    erjoalgo about 6 years
    how can I avoid the reboot?
  • Anwar
    Anwar about 6 years
    You can try restarting X
  • Geppettvs D'Constanzo
    Geppettvs D'Constanzo almost 6 years
    Thank you. Solved my problem but somehow I didn't find the xorg.conf.d folder inside /etc/X11, I am using Ubuntu 18.04 so I made the directory, placed the file inside that and added the same code to a new file in /etc/X11/Xsession.d/20-intel.conf
  • Daniel
    Daniel over 5 years
    This doesn't work in Dell XPS13 Developer Edition: I cannot login after doing this
  • sunxd
    sunxd over 5 years
    @GeppettvsD'Constanzo what is your system? I have ubuntu 18.04 and thinkpad t460s with intel skylake, does not work for me after creating the file
  • Geppettvs D'Constanzo
    Geppettvs D'Constanzo over 5 years
    Ubuntu 18.04 in a stock Lenovo T400 Thinkpad. The solution worked pretty fine but somehow dual boot with Windows wiped out the boot loader so I have only Windows on that machine. Will fix later. My kid use the laptop for university homework. Impossible to gain access now.
  • Serge Stroobandt
    Serge Stroobandt over 5 years
    As demonstrated in SNA Acceleration vs. UXA Acceleration, the default and newer SNA acceleration method is twice as fast if it works.
  • Danny
    Danny over 4 years
    Thank you, I was trying to use xcalib, failed to so it, and your answer was the solution for me!