CL_PixelBuffer::convert - ClanLib Game SDK

Home | All Classes | Grouped Classes | Index | Search

# CL_PixelBuffer::convert

Convert pixel buffer to the pixel format of the target buffer, storing the result in the target buffer.

    	void convert(
    		CL_PixelBuffer target);

    	void convert(
    		void* buffer, const CL_PixelFormat& format, int dest_pitch, const CL_Rect& dest_rect, const CL_Rect& src_rect=CL_Rect(0, 0, 0, 0));

Parameters:

target
  Target pixel buffer.
buffer
  Buffer getting stored pixels in the specified format and pitch.
format
  Pixel format of target buffer.
dest_pitch
  Bytes per line of target buffer.
dest_rect
  Destination rectangle for conversion.
src_rect
  Source rectangle for conversion.

See also:

CL_Rect | CL_PixelFormat | CL_PixelBuffer

Questions or comments, write to the ClanLib mailing list.