1 /*****************************************************************************\
2 dj350.cpp : Implimentation for the DJ350 class
4 Copyright (c) 1996 - 2001, Hewlett-Packard Co.
7 Redistribution and use in source and binary forms, with or without
8 modification, are permitted provided that the following conditions
10 1. Redistributions of source code must retain the above copyright
11 notice, this list of conditions and the following disclaimer.
12 2. Redistributions in binary form must reproduce the above copyright
13 notice, this list of conditions and the following disclaimer in the
14 documentation and/or other materials provided with the distribution.
15 3. Neither the name of Hewlett-Packard nor the names of its
16 contributors may be used to endorse or promote products derived
17 from this software without specific prior written permission.
19 THIS SOFTWARE IS PROVIDED BY THE AUTHOR "AS IS" AND ANY EXPRESS OR IMPLIED
20 WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
21 MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN
22 NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23 SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED
24 TO, PATENT INFRINGEMENT; PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS
25 OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
26 ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27 (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
28 THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29 \*****************************************************************************/
38 #include "printerproxy.h"
42 extern uint32_t ulMapDJ600_CCM_CMY[ 9 * 9 * 9 ];
43 extern uint32_t ulMapDJ600_CCM_K[ 9 * 9 * 9 ];
45 DJ350::DJ350(SystemServices* pSS, int numfonts, BOOL proto)
48 CMYMap = ulMapDJ600_CCM_CMY;
49 // pMode[SPECIALMODE_INDEX] = new Mode350KPhoto (ulMapDJ600_CCM_K);
50 // pMode[SPECIALMODE_INDEX] = new Mode350CPhoto (CMYMap);
52 #ifdef APDK_EXTENDED_MEDIASIZE
58 DBG1("DJ350 created\n");
62 Mode350KPhoto::Mode350KPhoto (uint32_t *map)
65 theQuality = qualityPresentation;
71 CompatiblePens[0] = BLACK_PEN;
72 // medium = mediaGlossy;
74 // strcpy (ModeName, "BlackBest");
77 Mode350CPhoto::Mode350CPhoto (uint32_t *map)
80 theQuality = qualityPresentation;
83 CompatiblePens[0] = COLOR_PEN; // only thing allowed
85 medium = mediaSpecial;
87 // strcpy(ModeName, "ColorPhoto");
91 Header350::Header350 (Printer *p, PrintContext* pc) : Header (p, pc)
94 DRIVER_ERROR Header350::Send ()
100 if (dyeCount == 3 || ResolutionY[0] == 600) // color pen
102 err = ConfigureRasterData ();
107 err = Simple (); // set color mode and resolution
112 if (ResolutionY[0] == 600)
115 sprintf(uom,"%c%c%c%d%c",ESC,'&','u',thePrintMode->ResolutionY[K],'D');
116 err=thePrinter->Send((const BYTE*)uom, 7 );
121 err = Graphics(); // start raster graphics and set compression mode
126 Header* DJ350::SelectHeader (PrintContext *pc)
128 return new Header350 (this, pc);