Mercurial > hg > Game > Cerium
annotate Renderer/Engine/polygon.cc @ 1319:31455d34e502 draft
collada file reader minor changes.
author | Taiki TAIRA <e095767@ie.u-ryukyu.ac.jp> |
---|---|
date | Sun, 18 Dec 2011 09:39:14 +0900 |
parents | bb9c885c1cb5 |
children | 3f95f61faef6 |
rev | line source |
---|---|
539 | 1 #include <iostream> |
2 #include <SDL.h> | |
3 #include <SDL_opengl.h> | |
4 #include <SDL_image.h> | |
5 #include "polygon.h" | |
6 #include "xml.h" | |
1050 | 7 #include "matrix_calc.h" |
539 | 8 #include "triangle.h" |
9 #include "vertex.h" | |
10 #include "Span.h" | |
11 #include "SpanC.h" | |
12 #include "scene_graph_pack.h" | |
13 #include "error.h" | |
14 #include "viewer_types.h" | |
15 using namespace std; | |
16 | |
17 | |
1130 | 18 |
19 | |
20 Polygon::Polygon() | |
539 | 21 { |
1050 | 22 position_init(); |
539 | 23 } |
24 | |
25 void | |
26 Polygon::position_init(void) | |
27 { | |
1129 | 28 |
539 | 29 xyz[0] = 0; |
30 xyz[1] = 0; | |
31 xyz[2] = 0; | |
32 xyz[3] = 1; | |
33 c_xyz[0] = 0; | |
34 c_xyz[1] = 0; | |
35 c_xyz[2] = 0; | |
36 c_xyz[3] = 1; | |
37 angle[0] = 0; | |
38 angle[1] = 0; | |
39 angle[2] = 0; | |
40 angle[3] = 1; | |
1050 | 41 scale[0] = 1; |
42 scale[1] = 1; | |
43 scale[2] = 1; | |
539 | 44 |
861 | 45 |
539 | 46 } |
47 | |
48 void Polygon::pickup_coordinate(char *cont) | |
49 { | |
860 | 50 |
1128 | 51 // size は頂点の数, count は面の数 |
906
becd6fad3ae0
coord_pack is stuffed with infomation of create polygon at spe.
Yutaka_Kinjyo
parents:
861
diff
changeset
|
52 char *tmp_cont = cont; |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
53 int count = size / 3; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
54 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
55 for (int i = 0; i < pp_num; i++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
56 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
57 TrianglePackPtr tri = pp[i].tri; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
58 // TrianglePack の size のチェック |
1253
bb9c885c1cb5
COLLADA add read node
Yuhi TOMARI <e095740@ie.u-ryukyu.ac.jp>
parents:
1205
diff
changeset
|
59 |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
60 int tri_size = (count < MAX_SIZE_TRIANGLE) ? count : MAX_SIZE_TRIANGLE ; |
1253
bb9c885c1cb5
COLLADA add read node
Yuhi TOMARI <e095740@ie.u-ryukyu.ac.jp>
parents:
1205
diff
changeset
|
61 |
bb9c885c1cb5
COLLADA add read node
Yuhi TOMARI <e095740@ie.u-ryukyu.ac.jp>
parents:
1205
diff
changeset
|
62 //それを構造体に登録 |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
63 pp[i].info.size = tri_size; |
1253
bb9c885c1cb5
COLLADA add read node
Yuhi TOMARI <e095740@ie.u-ryukyu.ac.jp>
parents:
1205
diff
changeset
|
64 |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
65 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
66 for (int j = 0; j < tri_size; j++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
67 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
68 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver1.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
69 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver1.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
70 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver1.z)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
71 |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
72 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver2.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
73 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver2.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
74 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver2.z)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
75 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
76 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver3.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
77 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver3.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
78 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver3.z)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
79 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
80 if (tmp_cont == NULL) |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
81 { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
82 cout << "Analyzing obj data failed coordinate\n"; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
83 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
84 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
85 count -= 1; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
86 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
87 } |
1128 | 88 |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
89 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
90 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
91 if (count != 0) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
92 printf("miss pickup_coordinate size. diff size = %d\n", count); |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
93 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
94 |
539 | 95 } |
96 | |
97 void Polygon::pickup_normal(char *cont) | |
98 { | |
860 | 99 |
100 | |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
101 // size は頂点の数, count は面の数 |
1128 | 102 char *tmp_cont = cont; |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
103 int count = size / 3; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
104 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
105 for (int i = 0; i < pp_num; i++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
106 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
107 TrianglePackPtr tri = pp[i].tri; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
108 // TrianglePack の size のチェック |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
109 int tri_size = (count < MAX_SIZE_TRIANGLE) ? count : MAX_SIZE_TRIANGLE ; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
110 pp[i].info.size = tri_size; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
111 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
112 for (int j = 0; j < tri_size; j++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
113 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
114 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal1.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
115 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal1.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
116 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal1.z)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
117 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
118 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal2.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
119 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal2.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
120 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal2.z)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
121 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
122 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal3.x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
123 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal3.y)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
124 tmp_cont = pickup_float(tmp_cont, &(tri[j].normal3.z)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
125 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
126 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
127 if (tmp_cont == NULL) |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
128 { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
129 cout << "Analyzing obj data failed coordinate\n"; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
130 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
131 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
132 count -= 1; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
133 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
134 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
135 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
136 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
137 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
138 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
139 if (count != 0) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
140 printf("miss pickup_normal size. diff size = %d\n", count); |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
141 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
142 |
539 | 143 } |
144 | |
145 void Polygon::pickup_model(char *cont) | |
146 { | |
147 cont = pickup_float(cont,c_xyz); | |
148 cont = pickup_float(cont,c_xyz+1); | |
149 cont = pickup_float(cont,c_xyz+2); | |
150 | |
151 if (cont == NULL) | |
152 { | |
153 cout << "Analyzing obj data failed model\n"; | |
154 } | |
155 } | |
156 | |
157 void Polygon::pickup_texture(char *cont) | |
158 { | |
860 | 159 |
906
becd6fad3ae0
coord_pack is stuffed with infomation of create polygon at spe.
Yutaka_Kinjyo
parents:
861
diff
changeset
|
160 char *tmp_cont = cont; |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
161 int count = size / 3; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
162 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
163 for (int i = 0; i < pp_num; i++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
164 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
165 TrianglePackPtr tri = pp[i].tri; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
166 // TrianglePack の size のチェック |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
167 int tri_size = (count < MAX_SIZE_TRIANGLE) ? count : MAX_SIZE_TRIANGLE ; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
168 pp[i].info.size = tri_size; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
169 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
170 for (int j = 0; j < tri_size; j++) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
171 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
172 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver1.tex_x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
173 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver1.tex_y)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
174 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
175 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver2.tex_x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
176 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver2.tex_y)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
177 |
1127
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
178 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver3.tex_x)); |
c4287bf771a0
CreatePolygonFromSceneGraph can work on Mac OSX.
Yutaka_Kinjyo
parents:
1126
diff
changeset
|
179 tmp_cont = pickup_float(tmp_cont, &(tri[j].ver3.tex_y)); |
1126
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
180 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
181 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
182 if (tmp_cont == NULL) |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
183 { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
184 cout << "Analyzing obj data failed coordinate\n"; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
185 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
186 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
187 count -= 1; |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
188 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
189 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
190 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
191 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
192 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
193 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
194 if (count != 0) { |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
195 printf("miss pickup_texture size. diff size = %d\n", count); |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
196 } |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
197 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
198 |
6043da6e48f1
complete compile but not work yet.
yutaka@localhost.localdomain
parents:
1125
diff
changeset
|
199 |
539 | 200 } |
201 | |
202 char *get_pixel(int tx, int ty, SDL_Surface *texture_image) | |
203 { | |
204 return (char*)texture_image->pixels+(texture_image->format->BytesPerPixel*((texture_image->w)*ty+tx)); | |
205 } | |
206 | |
207 unsigned my_ntohl(unsigned u) { | |
208 // rr gg bb 00 | |
209 // rr | |
210 // bb gg rr | |
211 //unsigned u1 = ((u&0xff)<<24) + | |
212 // ((u&0xff00)<<8) + | |
213 // ((u&0xff0000)>>8) + | |
214 // ((u&0xff000000)>>24); | |
215 unsigned u1; | |
216 unsigned b = (u&0xff000000)>>24; | |
217 unsigned g = (u&0xff0000)>>16; | |
218 unsigned r = (u&0xff00)>>8; | |
219 u1 = r + (g<<8) + (b<<16); | |
220 //printf("pixel %x->%x\n",u,u1); | |
221 return u1; | |
222 } | |
223 | |
224 Uint32 Polygon::get_rgb(int tx, int ty) | |
225 { | |
226 SDL_PixelFormat *fmt; | |
227 //Uint32 temp, pixel; | |
228 Uint8 red, green, blue; | |
229 | |
1130 | 230 fmt = texture_info->texture_image->format; |
539 | 231 |
232 if (tx<0) tx = 0; | |
1130 | 233 if (texture_info->texture_image->w-1< tx) tx = texture_info->texture_image->w-1 ; |
539 | 234 if (ty<0) ty = 0; |
1130 | 235 if (texture_info->texture_image->h-1< ty) ty = texture_info->texture_image->h-1 ; |
539 | 236 |
237 | |
238 //SDL_LockSurface(texture_image); | |
1130 | 239 char *p = get_pixel(tx,ty,texture_info->texture_image); |
539 | 240 blue = (Uint8) p[0]; |
241 green = (Uint8) p[1]; | |
242 red = (Uint8) p[2]; | |
243 | |
244 //printf("tx = %d ty = %d ", tx,ty); | |
245 //printf("pixel color => R: %d, G: %d, B: %d\n", red, green, blue); | |
246 | |
247 SDL_PixelFormat *pf = NULL; | |
248 //pf = viewer->screen->format; | |
249 | |
250 //cout << SDL_MapRGB(pf, red, green, blue) << endl; | |
251 return SDL_MapRGB(pf, red, green, blue); | |
252 } | |
1205
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
253 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
254 void Polygon::font_coordinate(int baseline, int row,int width) |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
255 { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
256 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
257 //int count = size / 3; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
258 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
259 for (int i = 0; i < pp_num; i++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
260 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
261 TrianglePackPtr tri = pp[i].tri; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
262 // TrianglePack の size のチェック |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
263 int tri_size = 2; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
264 pp[i].info.size = tri_size; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
265 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
266 for (int j = 0; j < tri_size; j++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
267 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
268 tri[j].ver1.x = 0.0 ; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
269 tri[j].ver1.y = 0.0 + baseline; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
270 //tri[j].ver1.y = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
271 tri[j].ver1.z = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
272 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
273 if(j < 1) |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
274 { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
275 tri[j].ver2.x = 0.0 ; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
276 tri[j].ver2.y = row +baseline; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
277 //tri[j].ver2.y = row; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
278 tri[j].ver2.z = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
279 }else{ |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
280 tri[j].ver2.x = width ; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
281 tri[j].ver2.y = 0.0 +baseline; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
282 //tri[j].ver2.y = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
283 tri[j].ver2.z = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
284 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
285 tri[j].ver3.x = width ; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
286 tri[j].ver3.y =row +baseline; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
287 //tri[j].ver3.y =row; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
288 tri[j].ver3.z = 0.0; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
289 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
290 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
291 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
292 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
293 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
294 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
295 void Polygon::font_normal() |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
296 { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
297 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
298 //テスト用 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
299 float polygon_point[2][9] = { {0,0,1, 0,0,1, 0,0,1}, |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
300 {0,0,1, 0,0,1, 0,0,1} }; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
301 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
302 //int count = size / 3; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
303 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
304 for (int i = 0; i < pp_num; i++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
305 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
306 TrianglePackPtr tri = pp[i].tri; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
307 // TrianglePack の size のチェック |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
308 int tri_size = 2; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
309 pp[i].info.size = tri_size; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
310 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
311 for (int j = 0; j < tri_size; j++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
312 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
313 tri[j].normal1.x = polygon_point[j][0]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
314 tri[j].normal1.y = polygon_point[j][1]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
315 tri[j].normal1.z = polygon_point[j][2]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
316 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
317 tri[j].normal2.x = polygon_point[j][3]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
318 tri[j].normal2.y = polygon_point[j][4]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
319 tri[j].normal2.z = polygon_point[j][5]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
320 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
321 tri[j].normal3.x = polygon_point[j][6]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
322 tri[j].normal3.y = polygon_point[j][7]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
323 tri[j].normal3.z = polygon_point[j][8]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
324 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
325 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
326 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
327 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
328 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
329 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
330 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
331 void Polygon::font_model() |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
332 { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
333 //テスト用 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
334 float polygon_point[3] = {0,0,0}; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
335 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
336 c_xyz[0] = polygon_point[0]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
337 c_xyz[1] = polygon_point[1]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
338 c_xyz[2] = polygon_point[2]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
339 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
340 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
341 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
342 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
343 void Polygon::font_texture(float row,float width) |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
344 { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
345 float texture_point[2][7] = { {0,0, 0,1, 1,1}, |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
346 {0,0, 1,0, 1,1} }; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
347 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
348 for (int i = 0; i < pp_num; i++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
349 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
350 TrianglePackPtr tri = pp[i].tri; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
351 // TrianglePack の size のチェック |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
352 int tri_size = 2; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
353 pp[i].info.size = tri_size; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
354 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
355 for (int j = 0; j < tri_size; j++) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
356 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
357 tri[j].ver1.tex_x = texture_point[j][0]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
358 tri[j].ver1.tex_y = texture_point[j][1]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
359 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
360 tri[j].ver2.tex_x = texture_point[j][2]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
361 tri[j].ver2.tex_y = texture_point[j][3]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
362 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
363 tri[j].ver3.tex_x = texture_point[j][4]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
364 tri[j].ver3.tex_y = texture_point[j][5]; |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
365 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
366 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
367 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
368 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
369 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
370 } |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
371 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
372 /*if (count != 0) { |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
373 printf("miss pickup_texture size. diff size = %d\n", count); |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
374 }*/ |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
375 |
b8adf4e95e96
add createStringFont()
Takao YONAMINE <e095763@ie.u-ryukyu.ac.jp>
parents:
1143
diff
changeset
|
376 } |