summaryrefslogtreecommitdiff
path: root/base/gxcht.c
Commit message (Collapse)AuthorAgeFilesLines
* Update postal address in file headersChris Liddell2023-04-041-2/+2
|
* Fix compiler warnings in base/Chris Liddell2023-01-041-5/+5
| | | | | | Function prototype mismatches and missing prototypes Fix compiler warnings
* Pickle phase into colored halftones in clist.Robin Watts2021-11-241-11/+29
|
* Pass x0,y0 to device color deserialisation (read) calls.Robin Watts2021-11-241-1/+3
| | | | | | | | | | | | When we serialise colors into the clist, we want to include the "phase" of colors with them where appropriate. During reading the phase for such colors will need to be offset by the offset of the screen. If, for example, we are rendering for a band that starts at (0, 1000) then the phase will need to be offset by 1000. Therefore pass this offset to the color reading code, so we can adjust by it.
* Remove 'alpha' field from gx_device_color.Robin Watts2021-06-181-39/+0
| | | | | | | | This field is set to gx_max_color_value on creation. It is then encoded/decoded, copied around and serialised/deserialised, but can never actually be set to any other value. Strip out the code that knocks on from this.
* Add object type specific device halftones to the graphics state.Ray Johnston2021-05-031-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | PostScript 'sethalftone' has an optional parameter "ObjectType" that allows one of the three object specific types to be set: Vector, Image or Text. Also add a new PostScript operator to set the current halftone (dev_ht, set by sethalftone) as the device halftone to be used for an object type: path, image and text. For non-PostScript clients, the gs_halftone structure adds a 'objtype' element (enum) that can be set prior to calling gs_sethalftone. The gs_gstate_s dev_ht is now an array of HT_OBJTYPE_COUNT elements, indexed by the gs_HT_objtype_t enum, with HT_OBJTYPE_DEFAULT (value 0) used for prior sethalftone/setscreen/setcolorscreen operations. NOTE: adding object types beyond the default+3 entries will require modification of gx_select_dev_ht since it only uses 3 bits of the 'tag' to get the index for the dev_ht[] array. For code style, change to use != NULL instead of != 0 in most places that this commit touched (but we may want a general cleanup of this everywhere). TBD: Command line options for all PDL's will need a method to take a halftone specification -- most likely a file that may be "PS-lite" syntax and may be limited to a threshold array. Discussions are in progress.
* Remove strip_copy_rop in favour of strip_copy_rop2.Robin Watts2021-04-281-22/+2
|
* Remove obsolete tile_rectangle dev_proc.Robin Watts2021-04-201-2/+2
|
* Update copyright to 2021Chris Liddell2021-03-151-1/+1
|
* Strip trailing whitespace from .c and .h files.Robin Watts2020-09-091-3/+3
|
* Update copyright to 2020Chris Liddell2020-04-101-1/+1
|
* Macro removalMichael Vrhel2019-02-191-46/+39
| | | | | | Get rid of two macros in the halftone tile creation code. One was replaced with an inline function. The other was simple enough and used only in two spots to just use directly.
* Update source/header file copyright notice to 2019Chris Liddell2019-01-161-1/+1
|
* Update copyright notice with new head office address.Ken Sharp2018-01-301-3/+3
| | | | | | | | | Also update copyright dates. Remove gs_cmdl.ps as we no longer use it, and remove its entry from psfiles.htm. Remove xfonts.htm as this feature (xfont support) is long, long gone.
* Fix operation of 1bpc, 3 component halftones.Robin Watts2017-11-151-0/+7
| | | | | | | | | | | | | | | | | | | In the chunky world, it makes no sense to deal with 3 bit rgb as this doesn't pack neatly into a byte. You'd do it by handling 4 bit chunks. Accordingly, parts of Ghostscript are written to assume that you'd not do anything this crazy. Unfortunately, in the planar world, a 1 bpc, 3 component device does make (some) sense. Sadly, stuff like the halftone generation gets deeply confused by this. Here we fix 2 specific instances of this problem. In the halftone generation, we generate 3bit chunky halftones as 4 bit ones, and in the planar_copy_color routines, we assume that 3 bit data is actually 4 bit (as a) it probably comes from these routines, and b) if it doesn't it'd be packed as 4 bit in any sane world).
* Make gs_imager_state == gs_state.Chris Liddell2016-06-061-10/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Change how gstate initialisation is done: Previously we relied on the imager state being a subset of the gstate (thus assigning an imager state to a graphics state over wrote to the entries common to both, and didn't overwrite any already set graphics state specific entries). Making the imager and graphics states the same means that approach doesn't work, so this changes it to initialise the entries individually. Renames gsistate.c->gsgstate.c and gxistate.h->gxgstate.h Cleanup and fix the gs_state gc stuff. Uses different check for pre/post clist pdf14 device Previously, the code used "is_gstate" in the imager/graphics state object to determine if the code was being called pre or post clist (post clist would only ever have had an imager_state so is_gstate = false). With no imager state any more, that test would no longer work (and I am dubious about whether it was really safe, anyway). Other places check for the presence of a clist reader device in the pdf14 device structure - so use that here too. Adds initial (NULL) value for show_gstate pointer in gs_state. Removes the now pointless macro for the contents of the graphics state Changes function names that had "imager" to use "gstate" Removes the redundant 'is_state' flag Cleans up gs_(g)state_putdeviceparams(): Previously we had to similar routines: one took a graphics state, and used the device from the graphics state, the other took an imager state and the device as an explicit parameter. With the removal of the imager state, "merge" those two functions Replaces gs_state with gs_gstate It makes for less confusion as it really is a g(raphics)state
* Improve logability of errors.Robin Watts2016-02-181-1/+1
| | | | | Ensure that we always return_error(gs_error_blah) rather than just return gs_error_blah.
* Remove legacy lower case arch_* macrosChris Liddell2016-01-111-1/+1
| | | | | Most of the ARCH_* macros had lower case equivalents for "backwards compatibility" - it's been long enough.....
* Commit of build_consolidation branchChris Liddell2015-07-201-0/+1484
Squashed into one commit (see branch for details of the evolution of the branch). This brings gpcl6 and gxps into the Ghostscript build system, and a shared set of graphics library object files for all the interpreters. Also, brings the same configuration options to the pcl and xps products as we have for Ghostscript.