Stride should be used to calculate the size rather than width. Change-Id: I01051fdf4dd2978d56b9998d8bcd542c50458f56