PDF.js displays blurry plots in PDF documents, e.g.

http://arxiv.org/pdf/1202.5344v1.pdf

When viewed in Chrome or Adobe Acrobat all the plots show sharp-edged squares. When viewed in Preview or PDF.js, all the squares show as blurry pixelated blobs.

} else {
      
      scale = Util.singularValueDecompose2dScale(owner.baseTransform);
      if (this._matrix) {
        const matrixScale = Util.singularValueDecompose2dScale(this._matrix);
        scale = [scale[0] * matrixScale[0], scale[1] * matrixScale[1]];
      }
    }
    
    
    const temporaryPatternCanvas = this._createMeshCanvas(
      scale,
      shadingFill ? null : this._background,
      owner.cachedCanvases
    );
    if (!shadingFill) {
      ctx.setTransform.apply(ctx, owner.baseTransform);
      if (this._matrix) {
        ctx.transform.apply(ctx, this._matrix);
      }
    }
    ctx.translate(
      temporaryPatternCanvas.offsetX,
      temporaryPatternCanvas.offsetY
    );
    ctx.scale(temporaryPatternCanvas.scaleX, temporaryPatternCanvas.scaleY);
    return ctx.createPattern(temporaryPatternCanvas.canvas, "no-repeat");
  }
}
class DummyShadingPattern extends BaseShadingPattern {