Re: [Gnome-print] deprecate : gnome_print_ps_setmatrix ()



On Sun, 16 Jul 2000, Chema Celorio wrote:

> While looking at the postscript driver I encountered
> that we have implemented the "setmatrix" operator in
> gnome-print.
> 
> This function should be removed, and while we are at
> breakeage time. I hope we can do it before the next
> release.

Maybe. It is probably useful only in PS error handler (reset matrix to
device default one).
On the other hand - in gnome-print CTM does not necessarily correspond to
user->device coordinate transformation, but instead user->abstract page
transformation. So in most cases it can be safely emulated, w.o. the risk
of generating bad artefacts (there is no analogue of PS page header
etc. in gnome-print).
In PostScript its effect can be neutralized also - just do
  /setmatrix {req_dev_trans setmatrix concat} bind def
in job header

Nevertheless I would vote for removing it - without setmatrix programs are
forced to generate cleaner print jobs.

Lauris

> 
> I do not know how much this function is beeing used.
> But I hope it isn't used very much:
> 
> Why ?
> 
> well, we should never set the matrix ourselves ( there
> is a special case but it is not a gnome-print case )
> because some poscript devices uses the CTM for calibration
> to compensate physical difference. ( for example the
> motor that moves the media rotates faster or slower
> than the speed designed to rotate)
> 
> >From the Red Book (2nd ed.):
> pag 508
> "....Except in device setup procedures, use of setmatrix
> should be very rare. Postscript languaje programs should
> ordinarily *modify* the CTM ( by use for translate, scale
> and concat ) rather than replacing it."
> 
> pag 742
> "
> ....
> [example of one use of setmatrix ]
> matrix currentmatix   /* places on the stack the current CTM */
> rx rx scale
> 0 0 1 0 360 arc
> setmatrix
> stroke
> 
> This exaple .....However, do not use this operator to perform
> such operations as flipping the coordinate axes. Instead, use
> the concat operator and concatenate to the current transformation
> matrix. Ordinarily, Postscrip programs should modify the CTM
> rather than replacing it."





[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]