Fix off-by-one bug in Pixmap::WritePng.
parent
6846010416
commit
6d5d88f01e
|
@ -186,7 +186,7 @@ bool Pixmap::WritePng(FILE *f, bool flip) {
|
||||||
if(flip) {
|
if(flip) {
|
||||||
rows.push_back(&data[stride * y]);
|
rows.push_back(&data[stride * y]);
|
||||||
} else {
|
} else {
|
||||||
rows.push_back(&data[stride * (height - y)]);
|
rows.push_back(&data[stride * (height - y - 1)]);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue