| 221 | |
| 222 | |
| 223 | void DoWriteSavePic(FileWriter* file, uint8_t* scr, int width, int height, bool upsidedown) |
| 224 | { |
| 225 | int pixelsize = 3; |
| 226 | |
| 227 | int pitch = width * pixelsize; |
| 228 | if (upsidedown) |
| 229 | { |
| 230 | scr += ((height - 1) * width * pixelsize); |
| 231 | pitch *= -1; |
| 232 | } |
| 233 | |
| 234 | M_CreatePNG(file, scr, nullptr, SS_RGB, width, height, pitch, vid_gamma); |
| 235 | } |
| 236 | |
| 237 | //=========================================================================== |
| 238 | // |
no test coverage detected