[gs-cvs] rev 7534 - in trunk/gs: doc src
leonardo at ghostscript.com
leonardo at ghostscript.com
Fri Dec 29 12:59:40 PST 2006
Author: leonardo
Date: 2006-12-29 12:59:39 -0800 (Fri, 29 Dec 2006)
New Revision: 7534
Modified:
trunk/gs/doc/pscet_status.txt
trunk/gs/src/gsdps1.c
Log:
Fix : The CPSI compatibility for 'clippath' starting point.
pscet_status.txt : A better classification for strokepath problems.
DETAILS :
Debugged with :
CET 13-22.ps page 6, the item much13;
CET 11-11.PS page 6, the item much13
See comment in code.
EXPECTED DIFFERENCES :
None.
Modified: trunk/gs/doc/pscet_status.txt
===================================================================
--- trunk/gs/doc/pscet_status.txt 2006-12-28 13:08:56 UTC (rev 7533)
+++ trunk/gs/doc/pscet_status.txt 2006-12-29 20:59:39 UTC (rev 7534)
@@ -2800,11 +2800,11 @@
13-01-6 OK Minor differences visually reviewed by HAS
-13-01-7 OK Minor differences visually reviewed by HAS
+13-01-7 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-02-1 OK Minor differences visually reviewed by RJJ
-13-02-10 OK Minor differences visually reviewed by HAS
+13-02-10 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-02-2 OK Minor differences visually reviewed by RJJ
@@ -2904,13 +2904,13 @@
13-10-8 OK Minor differences visually reviewed by HAS. Color corrected by rev 7172.
-13-10-9 OK Minor differences visually reviewed by HAS
+13-10-9 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-11-1 OK
13-12-1 OK
-13-12-10 OK Minor differences visually reviewed by HAS
+13-12-10 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-12-2 OK
@@ -2992,7 +2992,7 @@
a number of operatord. IMHO this can be AOK
assign Raph
-13-16-9 DIFF clippath, usrtokepath. assign: Raph.
+13-16-9 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-17-1 OK Corrected by 7152 and 7162. ADC
@@ -3008,29 +3008,13 @@
13-17-7 OK Minor differences in positions and character shapes - ADC
-13-17-8 DIFF GS has an extra black square a bottom left (above black bar
- that says 'Standard test 6.7'). CPSI shows no squre.
- Distiiler/Acrobat 7.0 shows two squares. Minor difference
- in the position of two small squres in item 30 of the first
- column. (The difference is small enough that I cannot tell
- which one is closer to the output for Distiller/Acrobat.)
- Differences in positions of the second square in items 19
- and 20 in the column labeled 'CASH'. Difference in position
- of both square in item 25 in she same column.a GS shows a
- square in item 13 in the column labeled 'MUCH'. - ADC
- assign Alex (initial analysis).
+13-17-8 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-18-1 OK
13-18-10 OK Minor differences in positions and character shapes - ADC
-13-18-11 DIFF Minor difference in the position of two small square outlines
- in item 30 of the first column. (The difference is small enough
- that I cannot tell which one is closer to the output for
- Distiller/Acrobat.) Differences in positions of the second square
- in items 19 and 20 in the column labeled 'CASH'. Difference in
- position of both square in item 25 in she same column.a GS shows
- a square in item 13 in the column labeled 'MUCH'. - ADC
+13-18-11 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-18-2 OK
@@ -3060,11 +3044,7 @@
13-19-6 OK Minor differences in positions and character shapes - ADC
-13-19-7 DIFF GS has an extra black square a bottom left (above black bar
- that says 'Stnadard test 6.7'). CPSI shows no squre.
- Distiiler/Acrobat 7.0 shows two squares. Major difference
- in position of squares in item 25 of the column labeled 'CASH'
- Minor differences in positions of some other squares. - ADC
+13-19-7 DIFF Same as 13-20-6 - strokepath - Assigned to Ray.
13-20-1 OK Minor differences in positions and character shapes - ADC
@@ -3077,22 +3057,13 @@
13-20-5 OK Corrected by 7152 and 7162. ADC
-13-20-6 DIFF cash25 : The placement of "Script" depends on
+13-20-6 DIFF cash25 : The placement of "GENOA" depends on
the 'strokepath' ending point.
CPSI generates more contours for 'strokepath',
so Ghostscript ending point can't be same
while it does lesser contours,
because the starting point was fixed for other CET tests.
assign: Ray.
- .
- much13 : 'Script' falls to the lower left corner.
- With CPSI it falls outside the clipping path.
- The reason is the 'clippath' strating point :
- CPSI starts a rectangle with the upper left corner,
- Ghostscript does with the lower right corner.
- However Ghostscript's algirithm is pretty complicated
- with uniting contacring rectangles.
- Assign: Ray.
13-21-1 DIFF CPSI indicates [F] for ( SharedFontDirectory xcheck). GS
indicates [T]. - ADC
@@ -3111,7 +3082,6 @@
13-22-5 OK Color corrected by rev 7172.
13-22-6 DIFF cash25 : strokepath - Same as 13-20-6 cahs25. assign: Ray.
- much13 : clippath - Same as 13-20-6 much13. Assign: Ray.
13-23-1 DIFF Extra line under /ordfeminine and /ordmasculine characters. - ADC
Might be a font issue: some fonts use underbars, others don't.
Modified: trunk/gs/src/gsdps1.c
===================================================================
--- trunk/gs/src/gsdps1.c 2006-12-28 13:08:56 UTC (rev 7533)
+++ trunk/gs/src/gsdps1.c 2006-12-29 20:59:39 UTC (rev 7534)
@@ -94,7 +94,7 @@
/* Append a list of rectangles to a path. */
int
-gs_rectappend(gs_state * pgs, const gs_rect * pr, uint count)
+gs_rectappend_compat(gs_state * pgs, const gs_rect * pr, uint count, bool clip)
{
extern bool CPSI_mode;
@@ -103,27 +103,59 @@
int code;
if (CPSI_mode) {
- if (px > qx) {
- px = qx; qx = pr->p.x;
+ /* We believe that the result must be independent
+ on the device initial matrix.
+ Particularly for the correct dashing
+ the starting point and the contour direction
+ must be same with any device initial matrix.
+ Only way to provide it is to choose the starting point
+ and the direction in the user space. */
+ if (clip) {
+ /* CPSI starts a clippath with the upper right corner. */
+ /* Debugged with CET 11-11.PS page 6 item much13.*/
+ if ((code = gs_moveto(pgs, qx, qy)) < 0 ||
+ (code = gs_lineto(pgs, qx, py)) < 0 ||
+ (code = gs_lineto(pgs, px, py)) < 0 ||
+ (code = gs_lineto(pgs, px, qy)) < 0 ||
+ (code = gs_closepath(pgs)) < 0
+ )
+ return code;
+ } else {
+ /* Debugged with CET 12-12.PS page 10 item more20.*/
+ if (px > qx) {
+ px = qx; qx = pr->p.x;
+ }
+ if (py > qy) {
+ py = qy; qy = pr->p.y;
+ }
+ if ((code = gs_moveto(pgs, px, py)) < 0 ||
+ (code = gs_lineto(pgs, qx, py)) < 0 ||
+ (code = gs_lineto(pgs, qx, qy)) < 0 ||
+ (code = gs_lineto(pgs, px, qy)) < 0 ||
+ (code = gs_closepath(pgs)) < 0
+ )
+ return code;
}
- if (py > qy) {
- py = qy; qy = pr->p.y;
- }
} else {
/* Ensure counter-clockwise drawing. */
if ((qx >= px) != (qy >= py))
qx = px, px = pr->q.x; /* swap x values */
+ if ((code = gs_moveto(pgs, px, py)) < 0 ||
+ (code = gs_lineto(pgs, qx, py)) < 0 ||
+ (code = gs_lineto(pgs, qx, qy)) < 0 ||
+ (code = gs_lineto(pgs, px, qy)) < 0 ||
+ (code = gs_closepath(pgs)) < 0
+ )
+ return code;
}
- if ((code = gs_moveto(pgs, px, py)) < 0 ||
- (code = gs_lineto(pgs, qx, py)) < 0 ||
- (code = gs_lineto(pgs, qx, qy)) < 0 ||
- (code = gs_lineto(pgs, px, qy)) < 0 ||
- (code = gs_closepath(pgs)) < 0
- )
- return code;
}
return 0;
}
+int
+gs_rectappend(gs_state * pgs, const gs_rect * pr, uint count)
+{
+ return gs_rectappend_compat(pgs, pr, count, false);
+}
/* Clip to a list of rectangles. */
int
@@ -135,7 +167,7 @@
gx_path_init_local(&save, pgs->memory);
gx_path_assign_preserve(&save, pgs->path);
gs_newpath(pgs);
- if ((code = gs_rectappend(pgs, pr, count)) < 0 ||
+ if ((code = gs_rectappend_compat(pgs, pr, count, true)) < 0 ||
(code = gs_clip(pgs)) < 0
) {
gx_path_assign_free(pgs->path, &save);
More information about the gs-cvs
mailing list