Skip to content

Commit

Permalink
Access the bbox/background data correctly in the MeshShadingPattern
Browse files Browse the repository at this point in the history
… class (issue 18816)

This appears to have regressed in PR 13808, since it removed the `matrix`-entry from array returned by the `MeshShading.prototype.getIR` method *without* also updating the indexes in the `MeshShadingPattern` constructor.
  • Loading branch information
Snuffleupagus committed Jan 8, 2025
1 parent dfbd1d5 commit 70c2001
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/display/pattern_helper.js
Original file line number Diff line number Diff line change
Expand Up @@ -313,8 +313,8 @@ class MeshShadingPattern extends BaseShadingPattern {
this._colors = IR[3];
this._figures = IR[4];
this._bounds = IR[5];
this._bbox = IR[7];
this._background = IR[8];
this._bbox = IR[6];
this._background = IR[7];
this.matrix = null;
}

Expand Down
1 change: 1 addition & 0 deletions test/pdfs/.gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,7 @@
!issue8424.pdf
!issue8480.pdf
!bug1650302_reduced.pdf
!issue18816.pdf
!issue8570.pdf
!issue8697.pdf
!issue8702.pdf
Expand Down
Binary file added test/pdfs/issue18816.pdf
Binary file not shown.
7 changes: 7 additions & 0 deletions test/test_manifest.json
Original file line number Diff line number Diff line change
Expand Up @@ -10078,6 +10078,13 @@
"annotations": true,
"type": "eq"
},
{
"id": "issue18816",
"file": "pdfs/issue18816.pdf",
"md5": "45f863f5b227f700ffea1210e4f80403",
"rounds": 1,
"type": "eq"
},
{
"id": "issue17794",
"file": "pdfs/issue17794.pdf",
Expand Down

0 comments on commit 70c2001

Please sign in to comment.