Changeset 1500
- Timestamp:
- Jun 10, 2009 8:33:43 AM (15 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/packages/vizservers/nanovis/RpAVTranslate.cpp
r1353 r1500 173 173 return false; 174 174 } 175 175 /* Copy the data into the picture without the padding and reversing the 176 * rows. Note that the origin of the GL image is the lower-left while for 177 * the movie it's upper-left. */ 178 size_t bytesPerRow = _width + linePad; 179 uint8_t *srcRowPtr = rgbData + ((_height - 1) * bytesPerRow); 176 180 uint8_t *destPtr = _rgbPictPtr->data[0]; 177 uint8_t *srcPtr = rgbData;178 181 for (size_t y = 0; y < _height; y++) { 179 for (size_t x = 0; x < _width; x++) { 180 destPtr[0] = srcPtr[0]; 181 destPtr[1] = srcPtr[1]; 182 destPtr[2] = srcPtr[2]; 183 srcPtr += 3; 184 destPtr +=3; 182 uint8_t *sp, *send; 183 184 for (sp = srcRowPtr, send = sp + _width; sp < send; sp++, destPtr++) { 185 *destPtr = *sp; 185 186 } 186 src Ptr += linePad;187 srcRowPtr -= bytesPerRow; 187 188 } 188 189
Note: See TracChangeset
for help on using the changeset viewer.