Procedures

ProcedureLocationProcedure TypeDescription
allocate_colors lut Subroutine
allocate_pixels pnm Subroutine

Allocates memory for the pixels of the PNM image.

aspect_ratio pnm Subroutine

Calculates the aspect ratio of the image. Required for print_info method.

average_colors pnm Subroutine

Calculates the average color values of the image. Required for print_info method.

brighten pnm Subroutine

Brightens or darkens the image. Only supported for PGM and PPM images.

check example26 Subroutine
check_pixel_range pnm Subroutine

Checks if the pixel values are within the valid range.

cmyk_to_rgb forcolor Subroutine
convert forcolor Subroutine
copy_color forcolor Subroutine
crop pnm Subroutine

Crops the image to a specified region.

deallocate_lut lut Subroutine
deallocate_pnm pnm Subroutine

Deallocates memory for the PNM image.

decimal_to_rgb forcolor Subroutine
export lut Subroutine
export_pnm pnm Subroutine

Writes the PNM image to a file.

find_nearest forcolor Subroutine
flip_horizontal pnm Subroutine

Flips the image horizontally.

flip_vertical pnm Subroutine

Flips the image vertically.

get forcolor Subroutine
get_b forcolor Function
get_cmyk forcolor Subroutine
get_colors lut Function
get_decimal forcolor Subroutine
get_dim_colors lut Function
get_format pnm Function

Gets the encoding of the PNM image.

get_g forcolor Function
get_hex forcolor Subroutine
get_hsl forcolor Subroutine
get_hsv forcolor Subroutine
get_name forcolor Subroutine
get_num_colors lut Function
get_r forcolor Function
get_rgb forcolor Subroutine
get_xyz forcolor Subroutine
greyscale pnm Subroutine

Converts a color image to greyscale. Only supported for PPM images.

hex_to_rgb forcolor Subroutine
hsl_to_rgb forcolor Subroutine
hsv_to_rgb forcolor Subroutine
import lut Subroutine
import_pnm pnm Subroutine

Reads a PNM image from a file.

initialize_colors forcolor Subroutine
mandelbrot demo_ppm Function
negative pnm Subroutine

Inverts the colors of the image.

pixel_size pnm Subroutine

Calculates imgae size in KB and MB. Required for print_info method.

print forcolor Subroutine
print_available_colors forcolor Subroutine
print_cmyk forcolor Subroutine
print_decimal forcolor Subroutine
print_hex forcolor Subroutine
print_hsl forcolor Subroutine
print_hsv forcolor Subroutine
print_info pnm Subroutine

Displays information about the image e.g. dimensions, aspect ratio, etc.

print_name forcolor Subroutine
print_rgb forcolor Subroutine
print_xyz forcolor Subroutine
read_header pnm Subroutine

Reads the header of the PNM image from a file. Required before reading the pixels from the file.

remove_channels pnm Subroutine

Removes one or more RGB channels from the image. Only supported for PPM images.

resize pnm Subroutine

Resizes the image to specified dimensions.

rgb_to_cmyk forcolor Subroutine
rgb_to_decimal forcolor Subroutine
rgb_to_hex forcolor Subroutine
rgb_to_hsl forcolor Subroutine
rgb_to_hsv forcolor Subroutine
rgb_to_xyz forcolor Subroutine
rotate pnm Subroutine

Rotates the image by a specified angle. Supported angles are 90, 180, 270, -90, -180, -270.

save forcolor Subroutine
save_available_colors forcolor Subroutine
set forcolor Subroutine
set lut Subroutine
set_by_name forcolor Subroutine
set_cmyk forcolor Subroutine
set_colors lut Subroutine
set_comment pnm Subroutine

Sets a comment for the PNM image.

set_decimal forcolor Subroutine
set_dim_colors lut Subroutine
set_file_format pnm Subroutine

Sets the file format of the PNM image. Supported values are pbm, pgm, and ppm.

set_format pnm Subroutine

Sets the encoding of the PNM image. Supported values are ascii or plain and binary or raw.

set_header pnm Subroutine

Sets the header of the PNM image. The header includes the magic number, width, height, comment, and max_color.

set_height pnm Subroutine

Sets the height of the PNM image.

set_hex forcolor Subroutine
set_hsl forcolor Subroutine
set_hsv forcolor Subroutine
set_magicnumber pnm Subroutine

Sets the magic number of the PNM image. Supported values are P1, P2, P3, P4, P5, and P6.

set_max_color pnm Subroutine

Sets the maximum color value of the PNM image. Only required for PGM and PPM images

set_name forcolor Subroutine
set_num_colors lut Subroutine
set_pixel pnm Subroutine

Sets the pixel values of the PNM image.

set_pixels pnm Subroutine

Sets the pixel values of the PNM image.

set_pnm pnm Subroutine

Sets the attributes of the PNM image.

set_rgb forcolor Subroutine
set_width pnm Subroutine

Sets the width of the PNM image.

set_xyz forcolor Subroutine
swap_channels pnm Subroutine

Swaps the RGB channels of the image. Only supported for PPM images.

write_header pnm Subroutine

Writes the header of the PNM image to a file. Required before writing the pixels to the file.

xyz_to_rgb forcolor Subroutine
call~~graph~~CallGraph none~assignment(=) color%assignment(=) proc~copy_color color%copy_color none~assignment(=)->proc~copy_color proc~allocate_colors format_lut%allocate_colors proc~allocate_pixels format_pnm%allocate_pixels proc~aspect_ratio aspect_ratio proc~average_colors average_colors proc~brighten format_pnm%brighten proc~set_pixels format_pnm%set_pixels proc~brighten->proc~set_pixels proc~check check proc~check_pixel_range format_pnm%check_pixel_range proc~cmyk_to_rgb cmyk_to_rgb proc~convert color%convert proc~convert->proc~cmyk_to_rgb proc~decimal_to_rgb decimal_to_rgb proc~convert->proc~decimal_to_rgb proc~hex_to_rgb hex_to_rgb proc~convert->proc~hex_to_rgb proc~hsl_to_rgb hsl_to_rgb proc~convert->proc~hsl_to_rgb proc~hsv_to_rgb hsv_to_rgb proc~convert->proc~hsv_to_rgb proc~rgb_to_cmyk rgb_to_cmyk proc~convert->proc~rgb_to_cmyk proc~rgb_to_decimal rgb_to_decimal proc~convert->proc~rgb_to_decimal proc~rgb_to_hex rgb_to_hex proc~convert->proc~rgb_to_hex proc~rgb_to_hsl rgb_to_hsl proc~convert->proc~rgb_to_hsl proc~rgb_to_hsv rgb_to_hsv proc~convert->proc~rgb_to_hsv proc~rgb_to_xyz rgb_to_xyz proc~convert->proc~rgb_to_xyz proc~xyz_to_rgb xyz_to_rgb proc~convert->proc~xyz_to_rgb proc~crop format_pnm%crop proc~crop->proc~allocate_pixels proc~set_height format_pnm%set_height proc~crop->proc~set_height proc~crop->proc~set_pixels proc~set_width format_pnm%set_width proc~crop->proc~set_width proc~deallocate_lut format_lut%deallocate_lut proc~deallocate_pnm format_pnm%deallocate_pnm proc~export format_lut%export proc~get_num_colors format_lut%get_num_colors proc~export->proc~get_num_colors proc~export_pnm format_pnm%export_pnm proc~set_format format_pnm%set_format proc~export_pnm->proc~set_format proc~write_header write_header proc~export_pnm->proc~write_header proc~find_nearest color%find_nearest proc~get_rgb color%get_rgb proc~find_nearest->proc~get_rgb proc~initialize_colors initialize_colors proc~find_nearest->proc~initialize_colors proc~flip_horizontal format_pnm%flip_horizontal proc~flip_horizontal->proc~check_pixel_range proc~flip_horizontal->proc~set_height proc~flip_horizontal->proc~set_width proc~flip_vertical format_pnm%flip_vertical proc~flip_vertical->proc~check_pixel_range proc~flip_vertical->proc~set_height proc~flip_vertical->proc~set_width proc~get color%get proc~get_cmyk color%get_cmyk proc~get->proc~get_cmyk proc~get_decimal color%get_decimal proc~get->proc~get_decimal proc~get_hex color%get_hex proc~get->proc~get_hex proc~get_hsl color%get_hsl proc~get->proc~get_hsl proc~get_hsv color%get_hsv proc~get->proc~get_hsv proc~get_name color%get_name proc~get->proc~get_name proc~get->proc~get_rgb proc~get_xyz color%get_xyz proc~get->proc~get_xyz proc~get_b color%get_b proc~get_colors format_lut%get_colors proc~get_dim_colors format_lut%get_dim_colors proc~get_format format_pnm%get_format proc~get_g color%get_g proc~get_r color%get_r proc~greyscale format_pnm%greyscale proc~greyscale->proc~check_pixel_range proc~import format_lut%import proc~import->proc~allocate_colors proc~set_dim_colors format_lut%set_dim_colors proc~import->proc~set_dim_colors proc~set_num_colors format_lut%set_num_colors proc~import->proc~set_num_colors proc~import_pnm format_pnm%import_pnm proc~import_pnm->proc~allocate_pixels proc~import_pnm->proc~check_pixel_range proc~read_header read_header proc~import_pnm->proc~read_header proc~set_file_format format_pnm%set_file_format proc~import_pnm->proc~set_file_format proc~import_pnm->proc~set_format proc~initialize_colors->proc~convert proc~set color%set proc~initialize_colors->proc~set proc~mandelbrot mandelbrot proc~negative format_pnm%negative proc~negative->proc~set_pixels proc~pixel_size pixel_size proc~print color%print proc~print_cmyk color%print_cmyk proc~print->proc~print_cmyk proc~print_decimal color%print_decimal proc~print->proc~print_decimal proc~print_hex color%print_hex proc~print->proc~print_hex proc~print_hsl color%print_hsl proc~print->proc~print_hsl proc~print_hsv color%print_hsv proc~print->proc~print_hsv proc~print_name color%print_name proc~print->proc~print_name proc~print_rgb color%print_rgb proc~print->proc~print_rgb proc~print_xyz color%print_xyz proc~print->proc~print_xyz proc~print_available_colors color%print_available_colors proc~print_available_colors->proc~initialize_colors proc~print_info format_pnm%print_info proc~print_info->proc~aspect_ratio proc~print_info->proc~average_colors proc~print_info->proc~pixel_size proc~remove_channels format_pnm%remove_channels proc~remove_channels->proc~check_pixel_range proc~resize format_pnm%resize proc~resize->proc~allocate_pixels proc~resize->proc~set_height proc~resize->proc~set_pixels proc~resize->proc~set_width proc~rotate format_pnm%rotate proc~rotate->proc~allocate_pixels proc~rotate->proc~set_height proc~rotate->proc~set_pixels proc~rotate->proc~set_width proc~save color%save proc~save->proc~export_pnm proc~set_pnm format_pnm%set_pnm proc~save->proc~set_pnm proc~save_available_colors color%save_available_colors proc~save_available_colors->proc~initialize_colors proc~set_by_name color%set_by_name proc~set->proc~set_by_name proc~set_cmyk color%set_cmyk proc~set->proc~set_cmyk proc~set_decimal color%set_decimal proc~set->proc~set_decimal proc~set_hex color%set_hex proc~set->proc~set_hex proc~set_hsl color%set_hsl proc~set->proc~set_hsl proc~set_hsv color%set_hsv proc~set->proc~set_hsv proc~set_name color%set_name proc~set->proc~set_name proc~set_rgb color%set_rgb proc~set->proc~set_rgb proc~set_xyz color%set_xyz proc~set->proc~set_xyz proc~set_by_name->proc~initialize_colors proc~set_colors format_lut%set_colors proc~set_comment format_pnm%set_comment proc~set_header format_pnm%set_header proc~set_header->proc~set_comment proc~set_header->proc~set_height proc~set_magicnumber format_pnm%set_magicnumber proc~set_header->proc~set_magicnumber proc~set_max_color format_pnm%set_max_color proc~set_header->proc~set_max_color proc~set_header->proc~set_width proc~set_pixel set_pixel proc~set_pixels->proc~check_pixel_range proc~set_pnm->proc~allocate_pixels proc~set_pnm->proc~set_file_format proc~set_pnm->proc~set_format proc~set_pnm->proc~set_header proc~set_pnm->proc~set_pixels proc~set~2 format_lut%set proc~set~2->proc~allocate_colors proc~swap_channels format_pnm%swap_channels proc~swap_channels->proc~check_pixel_range program~demo_color demo_color program~demo_color->proc~convert program~demo_color->proc~find_nearest program~demo_color->proc~get program~demo_color->proc~print_available_colors program~demo_color->proc~save_available_colors program~demo_color->proc~set program~demo_ppm demo_ppm program~demo_ppm->proc~brighten program~demo_ppm->proc~crop program~demo_ppm->proc~deallocate_pnm program~demo_ppm->proc~export_pnm program~demo_ppm->proc~flip_horizontal program~demo_ppm->proc~flip_vertical program~demo_ppm->proc~greyscale program~demo_ppm->proc~import_pnm program~demo_ppm->proc~mandelbrot program~demo_ppm->proc~negative program~demo_ppm->proc~print_info program~demo_ppm->proc~remove_channels program~demo_ppm->proc~resize program~demo_ppm->proc~rotate program~demo_ppm->proc~set_pnm program~demo_ppm->proc~swap_channels program~example26 example26 program~example26->proc~check program~example26->proc~convert program~example26->proc~get program~example26->proc~set program~example27 example27 program~example27->proc~convert program~example27->proc~find_nearest program~example27->proc~set program~example28 example28 program~example28->proc~set program~example29 example29 program~example29->proc~print_available_colors program~example29->proc~save_available_colors program~test test program~test->proc~deallocate_pnm program~test->proc~export_pnm program~test->proc~print_info program~test->proc~set_pnm program~test1 test1 program~test1->proc~deallocate_pnm program~test1->proc~export_pnm program~test1->proc~print_info program~test1->proc~set_pnm program~test10 test10 program~test10->proc~deallocate_pnm program~test10->proc~export_pnm program~test10->proc~import_pnm program~test10->proc~print_info program~test11 test11 program~test11->proc~deallocate_pnm program~test11->proc~export_pnm program~test11->proc~import_pnm program~test11->proc~print_info program~test12 test12 program~test12->proc~deallocate_pnm program~test12->proc~export_pnm program~test12->proc~import_pnm program~test12->proc~print_info program~test13 test13 program~test13->proc~deallocate_pnm program~test13->proc~export_pnm program~test13->proc~import_pnm program~test13->proc~print_info program~test14 test14 program~test14->proc~deallocate_pnm program~test14->proc~export_pnm program~test14->proc~import_pnm program~test14->proc~print_info program~test15 test15 program~test15->proc~deallocate_lut program~test15->proc~export program~test15->proc~set~2 program~test16 test16 program~test16->proc~deallocate_lut program~test16->proc~export program~test17 test17 program~test17->proc~deallocate_pnm program~test17->proc~export_pnm program~test17->proc~negative program~test17->proc~print_info program~test17->proc~set_pnm program~test18 test18 program~test18->proc~brighten program~test18->proc~deallocate_pnm program~test18->proc~export_pnm program~test18->proc~print_info program~test18->proc~set_pnm program~test19 test19 program~test19->proc~deallocate_pnm program~test19->proc~export_pnm program~test19->proc~print_info program~test19->proc~set_pnm program~test19->proc~swap_channels program~test2 test2 program~test2->proc~deallocate_pnm program~test2->proc~export_pnm program~test2->proc~print_info program~test2->proc~set_pnm program~test20 test20 program~test20->proc~deallocate_pnm program~test20->proc~export_pnm program~test20->proc~print_info program~test20->proc~remove_channels program~test20->proc~set_pnm program~test21 test21 program~test21->proc~deallocate_pnm program~test21->proc~export_pnm program~test21->proc~greyscale program~test21->proc~print_info program~test21->proc~set_pnm program~test22 test22 program~test22->proc~deallocate_pnm program~test22->proc~export_pnm program~test22->proc~print_info program~test22->proc~rotate program~test22->proc~set_pnm program~test23 test23 program~test23->proc~deallocate_pnm program~test23->proc~export_pnm program~test23->proc~flip_horizontal program~test23->proc~flip_vertical program~test23->proc~print_info program~test23->proc~set_pnm program~test24 test24 program~test24->proc~crop program~test24->proc~deallocate_pnm program~test24->proc~export_pnm program~test24->proc~print_info program~test24->proc~set_pnm program~test25 test25 program~test25->proc~deallocate_pnm program~test25->proc~export_pnm program~test25->proc~print_info program~test25->proc~resize program~test25->proc~set_pnm program~test3 test3 program~test3->proc~deallocate_pnm program~test3->proc~export_pnm program~test3->proc~print_info program~test3->proc~set_pnm program~test4 test4 program~test4->proc~deallocate_pnm program~test4->proc~export_pnm program~test4->proc~print_info program~test4->proc~set_pnm program~test6 test6 program~test6->proc~deallocate_pnm program~test6->proc~export_pnm program~test6->proc~print_info program~test6->proc~set_pnm program~test7 test7 program~test7->proc~deallocate_pnm program~test7->proc~export_pnm program~test7->proc~import_pnm program~test7->proc~print_info program~test8 test8 program~test8->proc~deallocate_pnm program~test8->proc~export_pnm program~test8->proc~import_pnm program~test8->proc~print_info program~test9 test9 program~test9->proc~deallocate_pnm program~test9->proc~export_pnm program~test9->proc~import_pnm program~test9->proc~print_info
Help