summaryrefslogtreecommitdiff
path: root/src/lib/evas/canvas/evas_canvas3d_texture.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/evas/canvas/evas_canvas3d_texture.c')
-rw-r--r--src/lib/evas/canvas/evas_canvas3d_texture.c42
1 files changed, 21 insertions, 21 deletions
diff --git a/src/lib/evas/canvas/evas_canvas3d_texture.c b/src/lib/evas/canvas/evas_canvas3d_texture.c
index e01762d..664de1c 100644
--- a/src/lib/evas/canvas/evas_canvas3d_texture.c
+++ b/src/lib/evas/canvas/evas_canvas3d_texture.c
@@ -54,7 +54,7 @@ _texture_proxy_subrender(Evas_Canvas3D_Texture *obj)
54{ 54{
55 /* Code taken from _proxy_subrender() in file evas_object_image.c */ 55 /* Code taken from _proxy_subrender() in file evas_object_image.c */
56 Eo *evas = NULL; 56 Eo *evas = NULL;
57 eo_do(obj, evas = evas_common_evas_get()); 57 evas = evas_common_evas_get(obj);
58 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 58 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
59 Evas_Canvas3D_Texture_Data *pd = eo_data_scope_get(obj, MY_CLASS); 59 Evas_Canvas3D_Texture_Data *pd = eo_data_scope_get(obj, MY_CLASS);
60 Evas_Object_Protected_Data *source; 60 Evas_Object_Protected_Data *source;
@@ -165,7 +165,7 @@ _texture_fini(Evas_Canvas3D_Texture *obj)
165 void *data = NULL; 165 void *data = NULL;
166 Evas_Canvas3D_Material_Data *material = NULL; 166 Evas_Canvas3D_Material_Data *material = NULL;
167 167
168 eo_do(obj, evas = evas_common_evas_get()); 168 evas = evas_common_evas_get(obj);
169 Evas_Canvas3D_Texture_Data *pd = eo_data_scope_get(obj, MY_CLASS); 169 Evas_Canvas3D_Texture_Data *pd = eo_data_scope_get(obj, MY_CLASS);
170 170
171 if (pd->engine_data) 171 if (pd->engine_data)
@@ -206,7 +206,7 @@ _texture_material_change_notify(const Eina_Hash *hash EINA_UNUSED, const void *k
206 void *data EINA_UNUSED, void *fdata) 206 void *data EINA_UNUSED, void *fdata)
207{ 207{
208 Evas_Canvas3D_Material *m = *(Evas_Canvas3D_Material **)key; 208 Evas_Canvas3D_Material *m = *(Evas_Canvas3D_Material **)key;
209 eo_do(m, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_MATERIAL_TEXTURE, (Evas_Canvas3D_Object *)fdata)); 209 evas_canvas3d_object_change(m, EVAS_CANVAS3D_STATE_MATERIAL_TEXTURE, (Evas_Canvas3D_Object *)fdata);
210 return EINA_TRUE; 210 return EINA_TRUE;
211} 211}
212 212
@@ -224,7 +224,7 @@ _evas_canvas3d_texture_evas_canvas3d_object_update_notify(Eo *obj, Evas_Canvas3D
224 if (pd->source) 224 if (pd->source)
225 { 225 {
226 Eo *evas = NULL; 226 Eo *evas = NULL;
227 eo_do(obj, evas = evas_common_evas_get()); 227 evas = evas_common_evas_get(obj);
228 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 228 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
229 Evas_Object_Protected_Data *src = eo_data_scope_get(pd->source, EVAS_OBJECT_CLASS); 229 Evas_Object_Protected_Data *src = eo_data_scope_get(pd->source, EVAS_OBJECT_CLASS);
230 230
@@ -321,10 +321,10 @@ evas_canvas3d_texture_add(Evas *e)
321EOLIAN static Eo * 321EOLIAN static Eo *
322_evas_canvas3d_texture_eo_base_constructor(Eo *obj, Evas_Canvas3D_Texture_Data *pd EINA_UNUSED) 322_evas_canvas3d_texture_eo_base_constructor(Eo *obj, Evas_Canvas3D_Texture_Data *pd EINA_UNUSED)
323{ 323{
324 obj = eo_do_super_ret(obj, MY_CLASS, obj, eo_constructor()); 324 obj = eo_constructor(eo_super(obj, MY_CLASS));
325 pd->atlas_enable = EINA_TRUE; 325 pd->atlas_enable = EINA_TRUE;
326 326
327 eo_do(obj, evas_canvas3d_object_type_set(EVAS_CANVAS3D_OBJECT_TYPE_TEXTURE)); 327 evas_canvas3d_object_type_set(obj, EVAS_CANVAS3D_OBJECT_TYPE_TEXTURE);
328 328
329 return obj; 329 return obj;
330} 330}
@@ -333,7 +333,7 @@ EOLIAN static void
333_evas_canvas3d_texture_eo_base_destructor(Eo *obj, Evas_Canvas3D_Texture_Data *pd EINA_UNUSED) 333_evas_canvas3d_texture_eo_base_destructor(Eo *obj, Evas_Canvas3D_Texture_Data *pd EINA_UNUSED)
334{ 334{
335 _texture_fini(obj); 335 _texture_fini(obj);
336 eo_do_super(obj, MY_CLASS, eo_destructor()); 336 eo_destructor(eo_super(obj, MY_CLASS));
337} 337}
338 338
339EOLIAN static void 339EOLIAN static void
@@ -343,7 +343,7 @@ _evas_canvas3d_texture_data_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd,
343{ 343{
344 Eo *evas = NULL; 344 Eo *evas = NULL;
345 void *image = NULL; 345 void *image = NULL;
346 eo_do(obj, evas = evas_common_evas_get()); 346 evas = evas_common_evas_get(obj);
347 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 347 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
348 348
349 if (!pd->engine_data && e->engine.func->texture_new) 349 if (!pd->engine_data && e->engine.func->texture_new)
@@ -366,7 +366,7 @@ _evas_canvas3d_texture_data_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd,
366 pd->engine_data, 366 pd->engine_data,
367 image); 367 image);
368 e->engine.func->image_free(e->engine.data.output, image); 368 e->engine.func->image_free(e->engine.data.output, image);
369 eo_do(obj, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL)); 369 evas_canvas3d_object_change(obj, EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL);
370} 370}
371 371
372EOLIAN static void 372EOLIAN static void
@@ -378,7 +378,7 @@ _evas_canvas3d_texture_file_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, const c
378 Eo *evas = NULL; 378 Eo *evas = NULL;
379 void *image; 379 void *image;
380 380
381 eo_do(obj, evas = evas_common_evas_get()); 381 evas = evas_common_evas_get(obj);
382 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 382 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
383 383
384 if (!pd->engine_data && e->engine.func->texture_new) 384 if (!pd->engine_data && e->engine.func->texture_new)
@@ -399,14 +399,14 @@ _evas_canvas3d_texture_file_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, const c
399 image); 399 image);
400 400
401 e->engine.func->image_free(e->engine.data.output, image); 401 e->engine.func->image_free(e->engine.data.output, image);
402 eo_do(obj, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL)); 402 evas_canvas3d_object_change(obj, EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL);
403} 403}
404 404
405EAPI void 405EAPI void
406_evas_canvas3d_texture_source_set(Eo *obj , Evas_Canvas3D_Texture_Data *pd, Evas_Object *source) 406_evas_canvas3d_texture_source_set(Eo *obj , Evas_Canvas3D_Texture_Data *pd, Evas_Object *source)
407{ 407{
408 Eo *evas = NULL; 408 Eo *evas = NULL;
409 eo_do(obj, evas = evas_common_evas_get()); 409 evas = evas_common_evas_get(obj);
410 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 410 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
411 Evas_Object_Protected_Data *src; 411 Evas_Object_Protected_Data *src;
412 412
@@ -441,7 +441,7 @@ _evas_canvas3d_texture_source_set(Eo *obj , Evas_Canvas3D_Texture_Data *pd, Evas
441 pd->engine_data = e->engine.func->texture_new(e->engine.data.output, pd->atlas_enable); 441 pd->engine_data = e->engine.func->texture_new(e->engine.data.output, pd->atlas_enable);
442 442
443 _texture_proxy_set(obj, source, src); 443 _texture_proxy_set(obj, source, src);
444 eo_do(obj, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL)); 444 evas_canvas3d_object_change(obj, EVAS_CANVAS3D_STATE_TEXTURE_DATA, NULL);
445} 445}
446 446
447EOLIAN static void 447EOLIAN static void
@@ -483,7 +483,7 @@ _evas_canvas3d_texture_color_format_get(const Eo *obj EINA_UNUSED, Evas_Canvas3D
483{ 483{
484 Evas_Colorspace format = -1; 484 Evas_Colorspace format = -1;
485 Eo *evas = NULL; 485 Eo *evas = NULL;
486 eo_do(obj, evas = evas_common_evas_get()); 486 evas = evas_common_evas_get(obj);
487 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 487 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
488 488
489 if (e->engine.func->image_colorspace_get && 489 if (e->engine.func->image_colorspace_get &&
@@ -502,7 +502,7 @@ EOLIAN static void
502_evas_canvas3d_texture_size_get(const Eo *obj, Evas_Canvas3D_Texture_Data *pd, int *w, int *h) 502_evas_canvas3d_texture_size_get(const Eo *obj, Evas_Canvas3D_Texture_Data *pd, int *w, int *h)
503{ 503{
504 Eo *evas = NULL; 504 Eo *evas = NULL;
505 eo_do(obj, evas = evas_common_evas_get()); 505 evas = evas_common_evas_get(obj);
506 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 506 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
507 if (e->engine.func->texture_size_get) 507 if (e->engine.func->texture_size_get)
508 { 508 {
@@ -515,21 +515,21 @@ EOLIAN static void
515_evas_canvas3d_texture_wrap_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Wrap_Mode s, Evas_Canvas3D_Wrap_Mode t) 515_evas_canvas3d_texture_wrap_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Wrap_Mode s, Evas_Canvas3D_Wrap_Mode t)
516{ 516{
517 Eo *evas = NULL; 517 Eo *evas = NULL;
518 eo_do(obj, evas = evas_common_evas_get()); 518 evas = evas_common_evas_get(obj);
519 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 519 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
520 if (e->engine.func->texture_wrap_set) 520 if (e->engine.func->texture_wrap_set)
521 { 521 {
522 e->engine.func->texture_wrap_set(e->engine.data.output, 522 e->engine.func->texture_wrap_set(e->engine.data.output,
523 pd->engine_data, s, t); 523 pd->engine_data, s, t);
524 } 524 }
525 eo_do(obj, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_TEXTURE_WRAP, NULL)); 525 evas_canvas3d_object_change(obj, EVAS_CANVAS3D_STATE_TEXTURE_WRAP, NULL);
526} 526}
527 527
528EOLIAN static void 528EOLIAN static void
529_evas_canvas3d_texture_wrap_get(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Wrap_Mode *s, Evas_Canvas3D_Wrap_Mode *t) 529_evas_canvas3d_texture_wrap_get(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Wrap_Mode *s, Evas_Canvas3D_Wrap_Mode *t)
530{ 530{
531 Eo *evas = NULL; 531 Eo *evas = NULL;
532 eo_do(obj, evas = evas_common_evas_get()); 532 evas = evas_common_evas_get(obj);
533 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 533 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
534 if (e->engine.func->texture_wrap_set) 534 if (e->engine.func->texture_wrap_set)
535 { 535 {
@@ -542,21 +542,21 @@ EOLIAN static void
542_evas_canvas3d_texture_filter_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Texture_Filter min, Evas_Canvas3D_Texture_Filter mag) 542_evas_canvas3d_texture_filter_set(Eo *obj, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Texture_Filter min, Evas_Canvas3D_Texture_Filter mag)
543{ 543{
544 Eo *evas = NULL; 544 Eo *evas = NULL;
545 eo_do(obj, evas = evas_common_evas_get()); 545 evas = evas_common_evas_get(obj);
546 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 546 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
547 if (e->engine.func->texture_filter_set) 547 if (e->engine.func->texture_filter_set)
548 { 548 {
549 e->engine.func->texture_filter_set(e->engine.data.output, 549 e->engine.func->texture_filter_set(e->engine.data.output,
550 pd->engine_data, min, mag); 550 pd->engine_data, min, mag);
551 } 551 }
552 eo_do(obj, evas_canvas3d_object_change(EVAS_CANVAS3D_STATE_TEXTURE_FILTER, NULL)); 552 evas_canvas3d_object_change(obj, EVAS_CANVAS3D_STATE_TEXTURE_FILTER, NULL);
553} 553}
554 554
555EOLIAN static void 555EOLIAN static void
556_evas_canvas3d_texture_filter_get(const Eo *obj EINA_UNUSED, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Texture_Filter *min, Evas_Canvas3D_Texture_Filter *mag) 556_evas_canvas3d_texture_filter_get(const Eo *obj EINA_UNUSED, Evas_Canvas3D_Texture_Data *pd, Evas_Canvas3D_Texture_Filter *min, Evas_Canvas3D_Texture_Filter *mag)
557{ 557{
558 Eo *evas = NULL; 558 Eo *evas = NULL;
559 eo_do(obj, evas = evas_common_evas_get()); 559 evas = evas_common_evas_get(obj);
560 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS); 560 Evas_Public_Data *e = eo_data_scope_get(evas, EVAS_CANVAS_CLASS);
561 if (e->engine.func->texture_filter_get) 561 if (e->engine.func->texture_filter_get)
562 { 562 {