Issue with setting calibration matrix on imx6 platform.

Peter Hutterer peter.hutterer at who-t.net
Mon May 11 22:52:44 UTC 2020


On Mon, May 11, 2020 at 09:17:16AM +0530, poornachandrasekhar.alamanda at india.horner-apg.com wrote:
> Hi,
> 
>  
> 
> We are trying to set calibration matrix on imx6 platfrom.
> 
> We are able to set the touch calibration matrix using udev (static) on imx6
> platform.
> 
>  
> 
> Our requirement is to set the calibration matrix dynamically during the run
> time from the application.
> 
> Libinput provides api's for setting the calibration matrix, so using them. I
> tried setting, but the touch changes does not get reflected.

think of libinput like a "grep" process. the normal instance runs within
your compositor. your code below is equivalent to starting a new grep on
the same file but with different options - this does not affect the
instance already running in the compositors.

If you want to change calibration at runtime, you need to talk to the
compositor to get it to apply those options to the real libinput
instance.

Cheers,
  Peter


> I am using following api
> 
> 1. libinput_path_create_context()
> 
> 2. libinput_path_add_device()
> 
> 3. libinput_device_config_calibration_has_matrix()
> 
> 4. libinput_device_config_calibration_get_matrix()
> 
> 5. libinput_device_config_calibration_set_matrix()
> 
>  
> 
> I have attached the c file used for touch calibration for your reference,
> 
> where TouchCalibrationMatrix() is performing all operations.
> 
>  
> 
> After setting the new calibration and reading back the calibration, I can
> see that calibration matrix is set, but it is not getting reflected in the
> touch.
> 
>  
> 
> Can you please let me know where I am going wrong.
> 
>  
> 
> Thanks & Regards,
> 
> Poorna Chandra Sekhar Alamanda.


More information about the wayland-devel mailing list