Table of Contents

 
GetImageBitDepth
 

Purpose

Queries the surface of the given image or the main surface

 

Protoype

Uint8 CImageMngr::GetImageBitDepth (string str_img_id)
 

Parameters

img_id the ID of the image to query
 

Description

This function is used to get the bit depth (8, 16, 32) of a surface. For str_img_id you can either pass in the ID of an image object to get the bit depth of, or you can use PRIMARY to get the bit depth of the primary surface.

 

Use

CImageMngr image;
Uint8 bdepth = image.GetImageBitDepth("my_image");
 

Prev: GetAlpha