mirror of
https://github.com/apache/nuttx.git
synced 2026-05-23 06:39:01 +08:00
Fix previous commit: In calculating the length of a run, the width has to be updated AFTER the start X position has been modified.
This commit is contained in:
@@ -201,8 +201,6 @@ static void lcdfb_update(FAR struct lcdfb_dev_s *priv,
|
||||
endx = priv->xres-1;
|
||||
}
|
||||
|
||||
width = endx - startx + 1;
|
||||
|
||||
starty = rect->pt1.y;
|
||||
if (starty < 0)
|
||||
{
|
||||
@@ -225,6 +223,8 @@ static void lcdfb_update(FAR struct lcdfb_dev_s *priv,
|
||||
startx &= ~(pixperbyte - 1);
|
||||
}
|
||||
|
||||
width = endx - startx + 1;
|
||||
|
||||
/* Get the starting position in the framebuffer */
|
||||
|
||||
run = priv->fbmem + starty * priv->stride;
|
||||
|
||||
Reference in New Issue
Block a user