This discussion has been locked.
You can no longer post new replies to this discussion. If you have a question you can start a new discussion

Incorrect drawing image with wayland on Mali400

Symptom

I found there have some display problem when enable fade in or out. (if i disable fade animation, problem occurs when surface destroyed only)

The display error area is on the right-up corner.

Original image Error image

 

I already know that Mali 4xx series have the h/w limitation. The limitation is, the floating point is implemented in 16-bit in fragment shader of Mali 4xx. So there could be issues when precision requirement is high.

But I think it is strange that the triangle pattern appears just like the above because of the high precision.

How to reproduce

1) To reproduce this error more easier, I modify some part of weston code. you can check below patch.

Fullscreen
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
diff --git a/clients/image.c b/clients/image.c
index 4126305..7955d24 100644
--- a/clients/image.c
+++ b/clients/image.c
@@ -380,6 +380,7 @@ image_create(struct display *display, const char *filename,
}
image->window = window_create(display);
+ //window_set_fullscreen(image->window, 1);
image->widget = window_frame_create(image->window, image);
window_set_title(image->window, title);
image->display = display;
@@ -400,7 +401,7 @@ image_create(struct display *display, const char *filename,
widget_set_button_handler(image->widget, button_handler);
widget_set_axis_handler(image->widget, axis_handler);
window_set_key_handler(image->window, key_handler);
- widget_schedule_resize(image->widget, 500, 400);
+ widget_schedule_resize(image->widget, 1024, 600);
return image;
}
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

 

2) You have to enable fade animation in your weston.ini file.

weston.ini

panel-location=none
locking=true
animation=fade

...

My debugging note
  • Ubuntu (weston 1.11.1) Does it work in a desktop environment? => Yes, it is normal.
  • Drawing problems occurred under the condition of "1 pixel wide black and white vertical line"
  • The currently tested wayland version is 1.9.0, is it the same in version 1.12.0? => Regardless of version.

If i disable the weston_matrix_init() function in weston_view_animation_create() function, error seems like disappeared.

So I suspected that there would be a problem with weston's animation algorithm. But as a result of searching at wayland bugreport, no user has ever reported an error related this issue.

Questions
  1. What i really want to know is, 'Why does the GPU draw a triangle on the top right corner?'
  2. Is there another way to avoid precision error?
  3. I think i can avoid precision error if i know the exact root cause. It's a difficult process, but somebody help me?

 

0