This project is read-only.
1

Closed

IBitmapPicture: Difference GetBytesInRow/GetOffsetY

description

Clarify the difference between methods GetBytesInRow and GetOffsetY. Please note that
 
int Picture::GetOffsetY() const
{
return GetBytesInRow();
}
 
Add corresponding comment to the header.

comments

wladik wrote Dec 28, 2010 at 8:04 AM

Added comments to the methods: GetOffsetX, GetOffsetY, GetBytesInRow

Vladimir35 wrote Dec 28, 2010 at 8:46 PM

Can the following happen?
GetOffsetY() != GetBytesInRow()
Under which conditions?

wladik wrote Dec 29, 2010 at 6:50 AM

The method GetBytesInRow() returns value in bytes
The method GetOffsetY() returns value in color components. For 24-bit RGB, the color component is also one byte, and both methods return the same number.
If in the future there will be need to support for example 48-bit RGB format, then these two methods would be different because the color component occupies two bytes. (GUID_WICPixelFormat48bppRGB)

wrote Dec 30, 2010 at 11:57 AM

wrote Feb 14, 2013 at 2:39 AM

wrote May 16, 2013 at 7:56 AM