* Fixed a swapping bug for 16 bit colorspaces
* Added some comments * Added some checking to avoid noop shifts * Added buffer length checks * Implemented (as Stephan suggested) a version of ConvertBits() that takes offsets. This new version allows to move a region of the source into a region (possibly not at the same point) on the dest while converting colorspaces on the fly. git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16592 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -519,8 +519,9 @@ BBitmap::ImportBits(const void *data, int32 length, int32 bpr, int32 offset,
|
||||
if (bpr < 0)
|
||||
bpr = get_bytes_per_row(colorSpace, width);
|
||||
|
||||
return BPrivate::ConvertBits(data, fBasePtr, bpr, fBytesPerRow,
|
||||
colorSpace, fColorSpace, width, fBounds.IntegerHeight() + 1);
|
||||
return BPrivate::ConvertBits(data, fBasePtr, length, fSize, bpr,
|
||||
fBytesPerRow, colorSpace, fColorSpace, width,
|
||||
fBounds.IntegerHeight() + 1);
|
||||
}
|
||||
|
||||
// ImportBits
|
||||
|
||||
Reference in New Issue
Block a user