Advertisement
Guest User

j'vaispasassezvite!

a guest
Mar 1st, 2015
212
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C 0.42 KB | None | 0 0
  1. PBM_IMAGE *create_empty_PNM_IMAGE()
  2. {
  3.     int x;
  4.     int y;
  5.     PNM_IMAGE* image_PNM=malloc(sizeof(PNM_IMAGE));
  6.  
  7.     //allocation de structure:
  8.  
  9.     if (image_PNM==NULL)
  10.     {
  11.         free(image_PNM);
  12.         return NULL;
  13.     }
  14.  
  15.     //initialisation de valeur temporaire:
  16.  
  17.     image_PNM->resolB_x=1;
  18.     image_PNM->resolB_y=1;
  19.     image_PNM->color_LVL=1;
  20.     image_PNM->mgk_NBR=5;
  21.     return image_PNM;
  22. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement