if (mtex && mtex->pt && mtex->pt->w && mtex->pt->h)
{
// canvas coords
- mx = dc->clip.mask_x;
- my = dc->clip.mask_y;
- if (mask->scaled.origin)
- {
- mw = mask->scaled.w;
- mh = mask->scaled.h;
- mask_smooth = mask->scaled.smooth;
- }
- else
- {
- mw = mask->w;
- mh = mask->h;
- }
+ mx = gc->dc->clip.mask_x;
+ my = gc->dc->clip.mask_y;
+ mw = mask->w;
+ mh = mask->h;
+ mask_smooth = mask->scaled.smooth;
}
else mtex = NULL;
if (mtex && mtex->pt && mtex->pt->w && mtex->pt->h)
{
// canvas coords
- mx = dc->clip.mask_x;
- my = dc->clip.mask_y;
- if (mask->scaled.origin)
- {
- mw = mask->scaled.w;
- mh = mask->scaled.h;
- //scalex = mask->w / (double)mask->scaled.w;
- //scaley = mask->h / (double)mask->scaled.h;
- mask_smooth = mask->scaled.smooth;
- }
- else
- {
- mw = mask->w;
- mh = mask->h;
- }
- //if (c) RECTS_CLIP_TO_RECT(mx, my, mw, mh, cx, cy, cw, ch);
- //mx = mx - dc->clip.mask_x;
- //my = my - dc->clip.mask_y;
+ mx = gc->dc->clip.mask_x;
+ my = gc->dc->clip.mask_y;
+ mw = mask->w;
+ mh = mask->h;
+ mask_smooth = mask->scaled.smooth;
}
else mtex = NULL;
// canvas coords
mx = gc->dc->clip.mask_x;
my = gc->dc->clip.mask_y;
- if (mask->scaled.origin)
- {
- mw = mask->scaled.w;
- mh = mask->scaled.h;
- mask_smooth = mask->scaled.smooth;
- }
- else
- {
- mw = mask->w;
- mh = mask->h;
- }
+ mw = mask->w;
+ mh = mask->h;
+ mask_smooth = mask->scaled.smooth;
}
else mtex = NULL;
// canvas coords
mx = gc->dc->clip.mask_x;
my = gc->dc->clip.mask_y;
- if (mask->scaled.origin)
- {
- mw = mask->scaled.w;
- mh = mask->scaled.h;
- mask_smooth = mask->scaled.smooth;
- }
- else
- {
- mw = mask->w;
- mh = mask->h;
- }
+ mw = mask->w;
+ mh = mask->h;
+ mask_smooth = mask->scaled.smooth;
}
else mtex = NULL;
if (!src) return NULL;
gc = src->gc;
- if ((dst_w > gc->shared->info.max_texture_size) ||
- (dst_h > gc->shared->info.max_texture_size))
- return NULL;
-
if (dst && (dst->scaled.origin == src) &&
- (dst->scaled.w == dst_w) && (dst->scaled.h == dst_h))
+ (dst->w == dst_w) && (dst->h == dst_h))
return dst;
if (dst)
dst->gc = gc;
dst->cs.space = src->cs.space;
dst->alpha = alpha;
- dst->w = src->w;
- dst->h = src->h;
+ dst->w = dst_w;
+ dst->h = dst_h;
dst->tex = src->tex;
dst->tex->references++;
dst->tex_only = 1;
if (!reffed) src->references++;
dst->scaled.origin = src;
- dst->scaled.w = dst_w;
- dst->scaled.h = dst_h;
dst->scaled.smooth = smooth;
return dst;