mirror of
https://github.com/zen-browser/pdf.js.git
synced 2025-07-09 09:45:42 +02:00
Merge pull request #3520 from brendandahl/single-cs
Create only one instance of each device colorspace.
This commit is contained in:
commit
99db7a8dbc
4 changed files with 28 additions and 26 deletions
10
src/util.js
10
src/util.js
|
@ -14,7 +14,7 @@
|
|||
* See the License for the specific language governing permissions and
|
||||
* limitations under the License.
|
||||
*/
|
||||
/* globals Cmd, DeviceCmykCS, Dict, globalScope, INFOS, MozBlobBuilder, Name,
|
||||
/* globals Cmd, ColorSpace, Dict, globalScope, INFOS, MozBlobBuilder, Name,
|
||||
PDFJS, Ref, WARNINGS, verbosity */
|
||||
|
||||
'use strict';
|
||||
|
@ -281,12 +281,8 @@ var Util = PDFJS.Util = (function UtilClosure() {
|
|||
};
|
||||
|
||||
Util.makeCssCmyk = function Util_makeCssCmyk(cmyk) {
|
||||
var cs = new DeviceCmykCS();
|
||||
Util.makeCssCmyk = function makeCssCmyk(cmyk) {
|
||||
var rgb = cs.getRgb(cmyk, 0);
|
||||
return Util.makeCssRgb(rgb);
|
||||
};
|
||||
return Util.makeCssCmyk(cmyk);
|
||||
var rgb = ColorSpace.singletons.cmyk.getRgb(cmyk, 0);
|
||||
return Util.makeCssRgb(rgb);
|
||||
};
|
||||
|
||||
// Concatenates two transformation matrices together and returns the result.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue