weston-info: do not round refresh rates
Weston-info was accidentally rounding refresh rates to integer Hz. Fix it to print 3 decimals, as the protocol carries exactly that. Reported-by: Michel Dänzer <michel@daenzer.net> Cc: John Galt <johngaltfirstrun@gmail.com> Signed-off-by: Pekka Paalanen <pekka.paalanen@collabora.co.uk> Reviewed-by: Michel Dänzer <michel@daenzer.net> Reviewed-by: Quentin Glidic <sardemff7+git@sardemff7.net>
This commit is contained in:
@@ -226,7 +226,7 @@ print_output_info(void *data)
|
||||
wl_list_for_each(mode, &output->modes, link) {
|
||||
printf("\tmode:\n");
|
||||
|
||||
printf("\t\twidth: %d px, height: %d px, refresh: %.f Hz,\n",
|
||||
printf("\t\twidth: %d px, height: %d px, refresh: %.3f Hz,\n",
|
||||
mode->width, mode->height,
|
||||
(float) mode->refresh / 1000);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user