| 343 | |
| 344 | |
| 345 | void Frame::addLogo(void) |
| 346 | { |
| 347 | unsigned char *rowptr, *logoptr = vgllogo, *logoptr2; |
| 348 | |
| 349 | if(!bits || hdr.width < 1 || hdr.height < 1) return; |
| 350 | |
| 351 | int height = min(VGLLOGO_HEIGHT, hdr.height - 1); |
| 352 | int width = min(VGLLOGO_WIDTH, hdr.width - 1); |
| 353 | int stride = flags & FRAME_BOTTOMUP ? -pitch : pitch; |
| 354 | if(height < 1 || width < 1) return; |
| 355 | if(flags & FRAME_BOTTOMUP) |
| 356 | rowptr = &bits[pitch * height + (hdr.width - width - 1) * pf->size]; |
| 357 | else |
| 358 | rowptr = &bits[pitch * (hdr.height - height - 1) + |
| 359 | (hdr.width - width - 1) * pf->size]; |
| 360 | DRAWLOGO() |
| 361 | |
| 362 | if(!rbits) return; |
| 363 | logoptr = vgllogo; |
| 364 | if(flags & FRAME_BOTTOMUP) |
| 365 | rowptr = &rbits[pitch * height + (hdr.width - width - 1) * pf->size]; |
| 366 | else |
| 367 | rowptr = &rbits[pitch * (hdr.height - height - 1) + |
| 368 | (hdr.width - width - 1) * pf->size]; |
| 369 | logoptr = vgllogo; |
| 370 | DRAWLOGO() |
| 371 | } |
| 372 | |
| 373 | |
| 374 | void Frame::dumpHeader(rrframeheader &h) |