updating parser logic
git-svn-id: svn://anubis/fart/trunk@97 7f9b0f55-74a9-4bce-be96-3c2cd072584d
This commit is contained in:
parent
0fc1e468fe
commit
2f16235ed2
@ -120,10 +120,26 @@ camera_items: /* empty */
|
|||||||
| camera_item camera_items
|
| camera_item camera_items
|
||||||
;
|
;
|
||||||
|
|
||||||
camera_item: POSITION vector
|
camera_item: POSITION vector {
|
||||||
| LOOKAT vector
|
$$ = new Node();
|
||||||
| UP vector
|
$$->type = POSITION;
|
||||||
| VFOV vector
|
$$->the_Vector = $2->the_Vector;
|
||||||
|
}
|
||||||
|
| LOOKAT vector {
|
||||||
|
$$ = new Node();
|
||||||
|
$$->type = LOOKAT;
|
||||||
|
$$->the_Vector = $2->the_Vector;
|
||||||
|
}
|
||||||
|
| UP vector {
|
||||||
|
$$ = new Node();
|
||||||
|
$$->type = UP;
|
||||||
|
$$->the_Vector = $2->the_Vector;
|
||||||
|
}
|
||||||
|
| VFOV vector {
|
||||||
|
$$ = new Node();
|
||||||
|
$$->type = VFOV;
|
||||||
|
$$->the_Vector = $2->the_Vector;
|
||||||
|
}
|
||||||
;
|
;
|
||||||
|
|
||||||
intersect: INTERSECT LCURLY boolean_items RCURLY
|
intersect: INTERSECT LCURLY boolean_items RCURLY
|
||||||
@ -136,9 +152,21 @@ material_items: /* empty */
|
|||||||
| material_item material_items
|
| material_item material_items
|
||||||
;
|
;
|
||||||
|
|
||||||
material_item: COLOR vector
|
material_item: COLOR vector {
|
||||||
| REFLECTANCE number
|
$$ = new Node();
|
||||||
| SHININESS number
|
$$->type = COLOR;
|
||||||
|
$$->the_Vector = $2->the_Vector;
|
||||||
|
}
|
||||||
|
| REFLECTANCE number {
|
||||||
|
$$ = new Node();
|
||||||
|
$$->type = REFLECTANCE;
|
||||||
|
$$->the_double = $2->the_double;
|
||||||
|
}
|
||||||
|
| SHININESS number {
|
||||||
|
$$ = new Node();
|
||||||
|
$$->type = SHININESS;
|
||||||
|
$$->the_double = $2->the_double;
|
||||||
|
}
|
||||||
;
|
;
|
||||||
|
|
||||||
number: DEC_NUMBER {
|
number: DEC_NUMBER {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user