| 165 } |
165 } |
| 166 |
166 |
| 167 // initialize texture |
167 // initialize texture |
| 168 // mesh will be created in the update func |
168 // mesh will be created in the update func |
| 169 text->texture = cxMallocDefault(sizeof(AscTexture)); |
169 text->texture = cxMallocDefault(sizeof(AscTexture)); |
| 170 asc_texture_init_rectangle(text->texture, 1); |
170 asc_texture_init(text->texture, 1, ASC_TEXTURE_RECTANGLE, |
| |
171 ASC_TEXTURE_MIN_FILTER_NEAREST, ASC_TEXTURE_MAG_FILTER_NEAREST); |
| 171 |
172 |
| 172 // basic node properties |
173 // basic node properties |
| 173 asc_scene_node_init(node, |
174 asc_scene_node_init(node, |
| 174 ASC_SCENE_NODE_FUNCS(asc_text), |
175 ASC_SCENE_NODE_FUNCS(asc_text), |
| 175 .name = args.name, |
176 .name = args.name, |