Warning: Attempt to read property "date" on null in /usr/local/www/websvn.planix.org/blame.php on line 247

Warning: Attempt to read property "msg" on null in /usr/local/www/websvn.planix.org/blame.php on line 247
WebSVN – planix.SVN – Blame – /os/branches/feature_posix/sys/lib/ghostscript/gs_ciecs3.ps – Rev 2

Subversion Repositories planix.SVN

Rev

Go to most recent revision | Details | Last modification | View Log | RSS feed

Rev Author Line No. Line
2 - 1
%    Copyright (C) 2002 Aladdin Enterprises.  All rights reserved.
2
% 
3
% This software is provided AS-IS with no warranty, either express or
4
% implied.
5
% 
6
% This software is distributed under license and may not be copied,
7
% modified or distributed except as expressly authorized under the terms
8
% of the license contained in the file LICENSE in this distribution.
9
% 
10
% For more information about licensing, please refer to
11
% http://www.ghostscript.com/licensing/. For information on
12
% commercial licensing, go to http://www.artifex.com/licensing/ or
13
% contact Artifex Software, Inc., 101 Lucas Valley Road #110,
14
% San Rafael, CA  94903, U.S.A., +1(415)492-9861.
15
 
16
% $Id: gs_ciecs3.ps,v 1.1 2002/08/22 07:12:28 henrys Exp $
17
% Level 3 CIEBased color space method dictionaries.
18
% This assumes gs_ciecs2.ps has already been processed.
19
 
20
%
21
% The validation routines in these method dictionaries perform only
22
% partial validations; the .setcie* operators will perform the rest.
23
%
24
 
25
 
26
.currentglobal true .setglobal
27
.cspace_util begin
28
 
29
 
30
/.setciedefspace where
31
  {
32
    pop
33
    colorspacedict
34
    /CIEBasedDEF
35
      mark
36
        /cs_potential_indexed_base true
37
        /cs_potential_pattern_base true
38
        /cs_potential_alternate true
39
        /cs_potential_icc_alternate true
40
        /cs_get_ncomps //ncomps_3
41
 
42
        /cs_get_range
43
          {
44
            1 get /RangeDEF .knownget not
45
              { //dflt_range_3 }
46
            if
47
          }
48
        bind
49
 
50
        /cs_get_default_color { pop 0 0 0 } bind
51
        /cs_get_currentgray //no_currentgray
52
        /cs_get_currentrgb //no_currentrgb
53
        /cs_get_currentcmyk //no_currentcmyk
54
        /cs_validate //check_cie_cspace
55
        /cs_substitute //dup_1
56
        /cs_prepare {}
57
 
58
        /cs_install
59
          {
60
            NOCIE
61
              { pop /DeviceRGB //.cs_install exec }
62
              { 1 get .setciedefspace }
63
            ifelse
64
          }
65
        bind
66
 
67
        /cs_prepare_color //validate_3
68
        /cs_complete_setcolor //pop_1
69
      .dicttomark
70
    put
71
  }
72
if
73
 
74
 
75
/.setciedefgspace where
76
  {
77
    pop
78
    colorspacedict
79
    /CIEBasedDEFG
80
      mark
81
        /cs_potential_indexed_base true
82
        /cs_potential_pattern_base true
83
        /cs_potential_alternate true
84
        /cs_potential_icc_alternate true
85
        /cs_get_ncomps //ncomps_4
86
 
87
        /cs_get_range
88
          {
89
            1 get /RangeDEFG .knownget not
90
              { //dflt_range_4 }
91
            if
92
          }
93
        bind
94
 
95
        /cs_get_default_color { pop 0 0 0 0 } bind
96
        /cs_get_currentgray //no_currentgray
97
        /cs_get_currentrgb //no_currentrgb
98
        /cs_get_currentcmyk //no_currentcmyk
99
        /cs_validate //check_cie_cspace
100
        /cs_substitute //dup_1
101
        /cs_prepare {}
102
 
103
        % the use of the DeviceCMYK color space is questionable:
104
        % it will likely have the wrong polarity
105
        /cs_install
106
          {
107
            NOCIE
108
              { pop /DeviceCMYK //.cs_install exec }
109
              { 1 get .setciedefgspace }
110
            ifelse
111
          }
112
        bind
113
 
114
        /cs_prepare_color //validate_4
115
        /cs_complete_setcolor //pop_1
116
      .dicttomark
117
    put
118
  }
119
if
120
 
121
 
122
end     % .cspace_util
123
.setglobal