/* if successful, returns respective image_type_params pointer if success if input type_id is not supported by any of image_type_support returns NULL  */
struct image_type_params* mkimage_get_type(int type)
/* if successful, returns respective image_type_params pointer if success if input type_id is not supported by any of image_type_support returns NULL  */
struct image_type_params* mkimage_get_type(int type)
{
	struct image_type_params *curr;
	for (curr = mkimage_tparams; curr != NULL; curr = curr->next) {
		if (curr->check_image_type) {
			if (!curr->check_image_type (type))
				return curr;
		}
	}
	return NULL;
}