Mercurial > hg > Members > kono > tree_dandy2
view object.c @ 30:00ef8386edd6
scale_matrix does not work
author | Shinji KONO <kono@ie.u-ryukyu.ac.jp> |
---|---|
date | Sat, 25 Dec 2010 21:04:59 +0900 |
parents | 6754fbb63ac7 |
children |
line wrap: on
line source
#include <stdio.h> #include <stdlib.h> #include <string.h> #include <libxml/parser.h> #include "object.h" void init_object(OBJECT *obj) { obj->name = NULL; obj->surfaces = NULL; } void free_object(OBJECT *obj) { SURFACE *cur,*next; if (obj == NULL) { printf("obj is NULL\n"); return; } for(cur=obj->surfaces;cur;cur=next) { next = cur->next; free(cur); } free(obj); }