comparison ps2util.h @ 96:0b65ca27f113

compile on Mac OS X 2
author Atuto SHIROMA <e095729@ie.u-ryukyu.ac.jp>
date Thu, 02 Jun 2011 14:56:11 +0900
parents b0249b856488
children afddacdf30dd
comparison
equal deleted inserted replaced
95:b0249b856488 96:0b65ca27f113
1 /* ps2util.h */
2
3 // 適当に数値当て:miya
4 #define JOYPAD_1 1
5
6
1 #ifndef PS2UTIL_H 7 #ifndef PS2UTIL_H
2 #define PS2UTIL_H 8 #define PS2UTIL_H
3 9
4 10
5 /* 11 /*
6 どう宣言したものか迷う orz 12 どう宣言したものか迷う orz
7 */ 13 */
8 #define ALIGN_16BYTE 64 14 #define ALIGN_16BYTE 64
9 15
10 #include "field.h" 16 //#include "field.h"
11 #include "libps2.h" 17 #include "libps2.h"
12 #include "col.h" 18 #include "col.h"
13 19
14 OBJECT *ps2util_obj_Create_fromXML(char *filename); 20 OBJECT *ps2util_obj_Create_fromXML(char *filename);
15 21
30 一応。 36 一応。
31 bool もあるかもわからん 37 bool もあるかもわからん
32 */ 38 */
33 void ps2util_obj_Set_effect(OBJECT*, int); 39 void ps2util_obj_Set_effect(OBJECT*, int);
34 40
35 void ps2_vu0_copy_vector(FVECTOR , FVECTOR); 41 void ps2_vu0_copy_vector( FVECTOR a, FVECTOR b);
36 void ps2util_obj_Renew_transMatrix(OBJECT*); 42 void ps2util_obj_Renew_transMatrix(OBJECT*);
37 43
38 TEXTURE* read_png_file(char *texname); 44 TEXTURE* read_png_file(char *texname);
39 int ps2util_tex_Set(TEXTURE*); 45 int ps2util_tex_Set(TEXTURE*);
40 void ps2util_obj_Set_texture(OBJECT*, TEXTURE*); 46 void ps2util_obj_Set_texture(OBJECT*, TEXTURE*);
41 void ps2_vu0_unit_matrix(FMATRIX); 47 void ps2_vu0_unit_matrix( FMATRIX );
42 void ps2_vu0_rot_matrix_y(FMATRIX , FMATRIX , float); 48 void ps2_vu0_rot_matrix_y( FMATRIX , FMATRIX , float);
49
50 // マトリックス m0 にベクトル v1 を右から乗算して v0 に与える
51 //void ps2_vu0_apply_matrix(ps2_vu0_fvector v0, ps2_vu0_fmatrix m0, ps2_vu0_fvector v1)
43 void ps2_vu0_apply_matrix(FVECTOR , FMATRIX , FVECTOR ); 52 void ps2_vu0_apply_matrix(FVECTOR , FMATRIX , FVECTOR );
44 53
45 void ps2_vu0_scale_vector(FVECTOR , FVECTOR , float ); 54 void ps2_vu0_scale_vector( FVECTOR , FVECTOR , float );
46 void ps2_vu0_add_vector(FVECTOR , FVECTOR , FVECTOR ); 55 void ps2_vu0_add_vector(FVECTOR , FVECTOR , FVECTOR );
47 56
48 void ps2_vu0_outer_product(FVECTOR rotaxis, FVECTOR car_vertical, FVECTOR yd); 57 void ps2_vu0_outer_product(FVECTOR rotaxis, FVECTOR car_vertical, FVECTOR yd);
49 float ps2_vu0_inner_product(FVECTOR yd, FVECTOR car_vertical); 58 float ps2_vu0_inner_product(FVECTOR yd, FVECTOR car_vertical);
50 59
51 void ps2_vu0_mul_matrix(FMATRIX pose1, FMATRIX yrot, FMATRIX pose2); 60 void ps2_vu0_mul_matrix(FMATRIX pose1, FMATRIX yrot, FMATRIX pose2);
52 void ps2_vu0_copy_matrix(FMATRIX car_body_transfer, FMATRIX pose);
53 61
54 void ps2util_tex_Exclude(TEXTURE* t); 62 //void ps2_vu0_copy_matrix(FMATRIX *car_body_transfer, FMATRIX pose);
63 void ps2_vu0_copy_matrix(FMATRIX transfer, FMATRIX pose); // 一個目の引数がポインタだとコンパイル通らなかった。なんで?
64
65
66 void ps2util_tex_Exclude( TEXTURE* t );
55 67
56 68
57 void free_texture(TEXTURE *tex); 69 void free_texture(TEXTURE *tex);
58 70
59 void ps2util_obj_Free(OBJECT* p_body); 71 void ps2util_obj_Free(OBJECT* p_body);
64 void ps2_vu0_normalize(FVECTOR colface_normal1, FVECTOR colface_normal2); 76 void ps2_vu0_normalize(FVECTOR colface_normal1, FVECTOR colface_normal2);
65 void xml_free(PolygonInfo xml); 77 void xml_free(PolygonInfo xml);
66 78
67 void ps2util_obj_Draw(OBJECT *object); 79 void ps2util_obj_Draw(OBJECT *object);
68 80
69 void gSprite_Init();
70
71 void delete_name_dictionary(const char *string); 81 void delete_name_dictionary(const char *string);
72 82
73 void ps2util_sprite_Destroy(ps2utilSprite *title_sprite); 83 void ps2util_sprite_Destroy(ps2utilSprite *title_sprite);
74 84
75 85
77 unsigned short x, unsigned short y, 87 unsigned short x, unsigned short y,
78 unsigned short sptable_tw1, unsigned short sptable_th1, 88 unsigned short sptable_tw1, unsigned short sptable_th1,
79 unsigned short sptable_tx, unsigned short sptable_ty, 89 unsigned short sptable_tx, unsigned short sptable_ty,
80 unsigned short sptable_tw2, unsigned short sptable_th2, 90 unsigned short sptable_tw2, unsigned short sptable_th2,
81 int sprite_prio_foreground); 91 int sprite_prio_foreground);
92
82 void ps2util_sprite_Request(ps2utilSprite *p); 93 void ps2util_sprite_Request(ps2utilSprite *p);
83
84 int ps2util_sprite_Create(ps2utilSprite *sp, TEXTURE *sprite_tex); 94 int ps2util_sprite_Create(ps2utilSprite *sp, TEXTURE *sprite_tex);
85 void ps2util_sprite_Unuse_alpha(ps2utilSprite *sp); 95 void ps2util_sprite_Unuse_alpha(ps2utilSprite *sp);
86 void ps2util_graphic_Init(); 96 void ps2util_graphic_Init();
87 97
98 void ps2util_sprite_Draw();
99
88 //ps2 依存関係の sprite.c より 100 //ps2 依存関係の sprite.c より
89 inline void sprite_disappear( SPRITE *sprite ); 101 inline void sprite_disappear( SPRITE *sprite );
90 102
103 void ps2util_graphic_Finish( void );
91 104
92 105 // title.cに書いてた
93 106 void ps2util_sprite_Use_alpha( ps2utilSprite *title );
94 107
95 #endif 108 #endif
109