forked from enlightenment/efl
evas/render: fix proxy clipping when source_clip is disabled
Summary: when source_clip is disabled, the clipper used should be the one used by the proxy object. previously this would never be the case, meaning that disabling source_clip had no effect @fix Depends on D8879 Reviewers: Hermet Reviewed By: Hermet Subscribers: cedric, #reviewers, #committers Tags: #efl Differential Revision: https://phab.enlightenment.org/D8880
This commit is contained in:
parent
e851aa6e52
commit
bca846d846
|
@ -1649,11 +1649,12 @@ _proxy_context_clip(Evas_Public_Data *evas, void *ctx, Evas_Proxy_Render_Data *p
|
||||||
if (!proxy_render_data) return EINA_TRUE;
|
if (!proxy_render_data) return EINA_TRUE;
|
||||||
if (proxy_render_data->source_clip)
|
if (proxy_render_data->source_clip)
|
||||||
{
|
{
|
||||||
|
Evas_Object_Protected_Data *src_obj = proxy_render_data->src_obj;
|
||||||
/* trust cache.clip since we clip like the source */
|
/* trust cache.clip since we clip like the source */
|
||||||
ENFN->context_clip_clip(ENC, ctx,
|
ENFN->context_clip_clip(ENC, ctx,
|
||||||
obj->cur->cache.clip.x + off_x,
|
src_obj->cur->cache.clip.x + off_x,
|
||||||
obj->cur->cache.clip.y + off_y,
|
src_obj->cur->cache.clip.y + off_y,
|
||||||
obj->cur->cache.clip.w, obj->cur->cache.clip.h);
|
src_obj->cur->cache.clip.w, src_obj->cur->cache.clip.h);
|
||||||
ENFN->context_clip_get(ENC, ctx, NULL, NULL, &cw, &ch);
|
ENFN->context_clip_get(ENC, ctx, NULL, NULL, &cw, &ch);
|
||||||
return ((cw > 0) && (ch > 0));
|
return ((cw > 0) && (ch > 0));
|
||||||
}
|
}
|
||||||
|
@ -2128,9 +2129,9 @@ evas_render_mapped(Evas_Public_Data *evas, Evas_Object *eo_obj,
|
||||||
if (obj->cur->clipper && (mapped > 1) &&
|
if (obj->cur->clipper && (mapped > 1) &&
|
||||||
_evas_render_object_is_mask(obj->cur->clipper))
|
_evas_render_object_is_mask(obj->cur->clipper))
|
||||||
_evas_render_mapped_mask(evas, obj, obj->cur->clipper, proxy_render_data, output, ctx, off_x, off_y, level, do_async);
|
_evas_render_mapped_mask(evas, obj, obj->cur->clipper, proxy_render_data, output, ctx, off_x, off_y, level, do_async);
|
||||||
else if (!proxy_src_clip)
|
else if (!proxy_src_clip && proxy_render_data)
|
||||||
{
|
{
|
||||||
if (!_proxy_context_clip(evas, ctx, proxy_render_data, obj, off_x, off_y))
|
if (!_proxy_context_clip(evas, ctx, proxy_render_data, proxy_render_data->proxy_obj, off_x, off_y))
|
||||||
goto on_empty_clip;
|
goto on_empty_clip;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -2181,9 +2182,9 @@ evas_render_mapped(Evas_Public_Data *evas, Evas_Object *eo_obj,
|
||||||
proxy_render_data,
|
proxy_render_data,
|
||||||
off_x, off_y);
|
off_x, off_y);
|
||||||
}
|
}
|
||||||
else
|
else if (proxy_render_data)
|
||||||
{
|
{
|
||||||
if (!_proxy_context_clip(evas, ctx, proxy_render_data, obj, off_x, off_y))
|
if (!_proxy_context_clip(evas, ctx, proxy_render_data, proxy_render_data->proxy_obj, off_x, off_y))
|
||||||
goto on_empty_clip;
|
goto on_empty_clip;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -2239,9 +2240,9 @@ evas_render_mapped(Evas_Public_Data *evas, Evas_Object *eo_obj,
|
||||||
|
|
||||||
ENFN->context_clip_clip(ENC, ctx, ecx, ecy, ecw, ech);
|
ENFN->context_clip_clip(ENC, ctx, ecx, ecy, ecw, ech);
|
||||||
}
|
}
|
||||||
else
|
else if (proxy_render_data)
|
||||||
{
|
{
|
||||||
if (!_proxy_context_clip(evas, ctx, proxy_render_data, obj, off_x, off_y))
|
if (!_proxy_context_clip(evas, ctx, proxy_render_data, proxy_render_data->proxy_obj, off_x, off_y))
|
||||||
goto on_empty_clip;
|
goto on_empty_clip;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue