You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The solution tells us is 16, but why? And why is the second "geometry" offset by only 8 then? Assuming it starts at the end of the previous, shouldn't it be at 17?
Activity
ayamflow commentedon Jun 5, 2018
Had some trouble with this one too, here's what I understood:
strideis the BYTES_PER_ELEMENT * < number of elements per row >There are 4 floats between startx0 and startx1, so the stride is 4 * 4 = 16;
offsetis BYTES_PER_ELEMENT * < number of elements before the value >there are 2 elements before endx0, so the offset is 4 * 2 = 8.
Hopefully this is correct and is helpful ✌️