@@ -109,7 +109,7 @@ class DrawSingleTileCallback : public gfxDrawingCallback
109109
110110 virtual bool operator ()(gfxContext* aContext,
111111 const gfxRect& aFillRect,
112- const Filter& aFilter ,
112+ const SamplingFilter aSamplingFilter ,
113113 const gfxMatrix& aTransform)
114114 {
115115 MOZ_ASSERT (aTransform.IsIdentity (),
@@ -120,7 +120,7 @@ class DrawSingleTileCallback : public gfxDrawingCallback
120120 // arguments that guarantee we never tile.
121121 mDrawResult =
122122 mImage ->DrawSingleTile (aContext, mSize , ImageRegion::Create (aFillRect),
123- mWhichFrame , aFilter , mSVGContext , mFlags );
123+ mWhichFrame , aSamplingFilter , mSVGContext , mFlags );
124124
125125 return true ;
126126 }
@@ -308,7 +308,7 @@ ClippedImage::GetFrameInternal(const nsIntSize& aSize,
308308 gfxUtils::DrawPixelSnapped (ctx, drawable, aSize,
309309 ImageRegion::Create (aSize),
310310 SurfaceFormat::B8G8R8A8 ,
311- Filter ::LINEAR ,
311+ SamplingFilter ::LINEAR ,
312312 imgIContainer::FLAG_CLAMP );
313313
314314 // Cache the resulting surface.
@@ -367,13 +367,13 @@ ClippedImage::Draw(gfxContext* aContext,
367367 const nsIntSize& aSize,
368368 const ImageRegion& aRegion,
369369 uint32_t aWhichFrame,
370- Filter aFilter ,
370+ SamplingFilter aSamplingFilter ,
371371 const Maybe<SVGImageContext>& aSVGContext,
372372 uint32_t aFlags)
373373{
374374 if (!ShouldClip ()) {
375375 return InnerImage ()->Draw (aContext, aSize, aRegion, aWhichFrame,
376- aFilter , aSVGContext, aFlags);
376+ aSamplingFilter , aSVGContext, aFlags);
377377 }
378378
379379 // Check for tiling. If we need to tile then we need to create a
@@ -396,13 +396,13 @@ ClippedImage::Draw(gfxContext* aContext,
396396
397397 // Draw.
398398 gfxUtils::DrawPixelSnapped (aContext, drawable, aSize, aRegion,
399- SurfaceFormat::B8G8R8A8 , aFilter );
399+ SurfaceFormat::B8G8R8A8 , aSamplingFilter );
400400
401401 return result;
402402 }
403403
404404 return DrawSingleTile (aContext, aSize, aRegion, aWhichFrame,
405- aFilter , aSVGContext, aFlags);
405+ aSamplingFilter , aSVGContext, aFlags);
406406}
407407
408408static SVGImageContext
@@ -428,7 +428,7 @@ ClippedImage::DrawSingleTile(gfxContext* aContext,
428428 const nsIntSize& aSize,
429429 const ImageRegion& aRegion,
430430 uint32_t aWhichFrame,
431- Filter aFilter ,
431+ SamplingFilter aSamplingFilter ,
432432 const Maybe<SVGImageContext>& aSVGContext,
433433 uint32_t aFlags)
434434{
@@ -469,7 +469,7 @@ ClippedImage::DrawSingleTile(gfxContext* aContext,
469469 aContext->Multiply (gfxMatrix::Translation (-clip.x , -clip.y ));
470470
471471 return InnerImage ()->Draw (aContext, size, region,
472- aWhichFrame, aFilter ,
472+ aWhichFrame, aSamplingFilter ,
473473 aSVGContext.map (UnclipViewport,
474474 make_pair (innerSize, mClip .Size ())),
475475 aFlags);
@@ -495,11 +495,12 @@ ClippedImage::GetOrientation()
495495nsIntSize
496496ClippedImage::OptimalImageSizeForDest (const gfxSize& aDest,
497497 uint32_t aWhichFrame,
498- Filter aFilter, uint32_t aFlags)
498+ SamplingFilter aSamplingFilter,
499+ uint32_t aFlags)
499500{
500501 if (!ShouldClip ()) {
501- return InnerImage ()->OptimalImageSizeForDest (aDest, aWhichFrame, aFilter,
502- aFlags);
502+ return InnerImage ()->OptimalImageSizeForDest (aDest, aWhichFrame,
503+ aSamplingFilter, aFlags);
503504 }
504505
505506 int32_t imgWidth, imgHeight;
@@ -527,7 +528,7 @@ ClippedImage::OptimalImageSizeForDest(const gfxSize& aDest,
527528 gfxSize desiredSize (imgWidth * scale.width , imgHeight * scale.height );
528529 nsIntSize innerDesiredSize =
529530 InnerImage ()->OptimalImageSizeForDest (desiredSize, aWhichFrame,
530- aFilter , aFlags);
531+ aSamplingFilter , aFlags);
531532
532533 // To get our final result, we take the inner image's desired size and
533534 // determine how large the clipped region would be at that scale. (Again, we
@@ -539,8 +540,8 @@ ClippedImage::OptimalImageSizeForDest(const gfxSize& aDest,
539540
540541 MOZ_ASSERT (false ,
541542 " If ShouldClip() led us to draw then we should never get here" );
542- return InnerImage ()->OptimalImageSizeForDest (aDest, aWhichFrame, aFilter,
543- aFlags);
543+ return InnerImage ()->OptimalImageSizeForDest (aDest, aWhichFrame,
544+ aSamplingFilter, aFlags);
544545}
545546
546547NS_IMETHODIMP_ (nsIntRect)
0 commit comments