Colour conversion apparatus

Abstract: A colour conversion apparatus (2) is disclosed maps image data from a input colour space (RGB) to an output colour space (CMYK). A transfer function between the colour spaces is known relevant to the appropriate display medium (e.g. printer (8)) and this is divided into intervals (22,23,24 - Fig.7,8) for interpolating between the colour spaces. The intervals vary in length depending on the behaviour of the transfer function with the intervals being shorter where the transfer function is not well behaved (i.e. rapid change in slope). Interpolation is performed over each interval based on a mapping a volume of input pixel data (8 points of RGB) to a corresponding volume of a component of output pixel data (e.g. 8 points of C, i.e.: C000, C001, C010 etc.) Interpolation is performed between those points to derive an output pixel colour component value. The process is repeated for each primary colour component of the output colour space to produce composite output pixels. Near-white and near-black colour correction is also disclosed.

Description: Field of the Invention The present invention relates to the display of colour images on a display device and in particular, the display of colour images by a colour printing device. Background of the Invention The publication GB-A-2 050 751 discloses a colour scanner in which three uncorrected colour components (CMY) are applied to a three dimensional look-up table where are stored corresponding colour-corrected signal values for the three colours. This scanner is concerned with correction of signals within the same colour space and does not contemplate the conversion of an input image in one colour space to an output image in another colour space, Background art concerning colour conversion from one colour space to another colour space will now be described with reference to the following drawings in which: Fig. 1 illustrates an ideal colour relationship; and Fig. 2 illustrates a more realistic colour relationship which occurs in practice. Images are normally displayed by a CRT type display using an additive format such as the Red, Green, Blue (RGB) format. In this format, separate colour information is provided for each of the Red, Green and Blue primary colours and when displayed together, they form any desired colour to be displayed. However, when it is desired to print out a colour representation of the image displayed by a colour display, a subtractive colour format is generally used. One such subtractive format is the Cyan, Magenta, Yellow and Black (CMYK) format. Such a subtractive format is commonly used in colour printing devices and in particular is used in the Canon CLC500 colour laser copier/printer manufactured by Canon Inc. Referring now to Fig. 1 there is shown an ideal colour relationship. In theory the relationship between additive colours and subtractive colours is simple, as Cyan, Magenta and Yellow are simply the complementary colours to Red, Green and Blue respectively. They can be expressed by: C = 1 - R; M = 1 - G; and Y= 1 - B. Black (K) is a function of all three additive primaries as follows: K = rR + gG + bB, where r, g, and b are coefficients determined by relative human perception of red, green and blue. Referring now to Fig. 2 there is shown a more realistic colour relationship which occurs in practice. In practice the above equations are inadequate and the amount of cyan for example is a complex non-linear equation that depends on the amount of red, green, and blue. Non-linear transfer functions in the printing mechanism require a non-linear transfer function during conversion between the two colour formats. Fig. 1 shows the ideal curve for (say) cyan, whereas the curve shown in Fig. 2 is that required by the printer. One method for performing colour conversion in accordance with the arrangement shown in Fig. 2 would be to use a number of programmable read only memories (PROM's) to perform a lookup of each possible input point and a preprogrammed function similar to that shown in Fig. 2. However this solution has a number of disadvantages. Namely: (i) it may require a large amount of board space due to the number of support chips required by the PROMs; (ii) it requires a large amount of power where high speed PROMs are used; and (iii) it requires a large amount of storage space, with one value stored for each possible primary colour value with say 8 bits for each colour of red, green and blue and each mapping producing 8 bits of output, the total storage space would be 2 8 x 2 8 x 2 8 , being over 16 Mbytes for each colour pass. Another method is to use matrix multiplication to calculate a linear approximation to the required value, however, this also has a number of disadvantages, such as: (i) the resulting quality of linear blends between colours is too low for computer generated graphics; and (ii) any errors introduced by the colour conversion process are quite noticeable in areas of gradual blend between colours. This is particularly bad in luma ramps from black to white, where false colours appear. "Banding" effects are exaggerated by any printer that fails to use the full level information provided by the primary colour input level values. Such printers are in common use. The publication WO-A-92/06557 discloses a method for converting an input image in an input colour space to an output image in an output colour space, wherein at least one primary colour of said input colour space is divided into a plurality of intervals having endpoints and wherein the output colour space has output colour values corresponding to the endpoints, said method comprising the steps of: determining, for each input pixel in the input image, the output colour values corresponding to the endpoints closest to the input pixel; and interpolating between said output colour values corresponding to the endpoints closest to the input pixel to derive an output colour pixel in the output colour space. The publication WO-A-92/06537 also discloses a colour conversion apparatus for implementing such a method. The colour conversion apparatus described in this publication is not suitable for use with common printers as the pixel output rate, i.e. colour conversion, is too slow. SUMMARY OF THE INVENTION It is an object of the present invention to substantially overcome, or ameliorate at least one of the aforementioned difficulties with the prior art. In accordance with one aspect of the present invention, there is provided a method for converting an input image in an input colour space to an output image in an output colour space as set out in claim 1. In accordance with another aspect of the present invention, there is provided colour conversion apparatus for converting an input image in an input colour space to an output image in an output colour space as set out in claim 12. Brief Description of the Drawings A preferred embodiment of the present invention will now be described with reference to the accompanying drawings in which: Fig. 3 illustrates a colour processing system incorporating the preferred embodiment of the present invention; Fig. 4 illustrates the basic structure of a colour conversion apparatus of the preferred embodiment; Fig. 5 illustrates the normal colour conversion process of Fig. 2; Fig, 6 illustrates an enlarged portion of Fig. 5 Fig. 7 illustrates the colour conversion process of the red interval RAM of Fig. 4 Fig. 8 illustrates an enlarged portion of Fig. 7 Fig. 9 illustrates the process of finding a sample colour point within a 3-dimensional colour space; Fig. 10 illustrates an example of interpolation of a point within a cube; Fig. 11 illustrates an example illustrating the process of address remapping carried out by the colour conversion RAM; Fig. 12 illustrates further example showing redundancy removal; Fig. 13 illustrates a further example showing redundancy removal; Fig. 14 illustrates the colour conversion RAM; Fig. 15 illustrates the interpolation processor; Fig. 16 illustrates the internal structure of an interpolation processing element; Fig. 17 illustrates the near white correction unit; Fig. 18 illustrates an example of 2x2 dithering; Fig. 19 illustrates the near black correction unit; and Fig. 20 illustrates text detection using vertical edge scanning. Detailed Description of the Preferred Embodiment Referring now to Fig. 3, a colour conversion apparatus 2 of the preferred embodiment is designed to form part of a colour image processing system 1 similar to that set out in Australian Patent Application No. 81782/91 of 16 August 1991 (published under AU-A-8178291). However, applications of the present embodiment are not limited thereto. Fig. 3 shows a simplified block diagram of the colour image processing system 1 used in a typical application, and configured to operate on a standard computer system. The colour conversion apparatus 2 interacts with two main subsystems: The first is a processor subsystem 60, which includes in particular a processor memory 61. Colour conversion tables required for each colour pass are established in the processor memory 61. The colour image processing system 1 loads the colour conversion table required for each colour pass (C, M, Y or K) at the beginning of a conversion pass. These can be loaded either via normal write cycles to the processor memory 61 or under control of a DMA master controller 64. Adjunct to the processor subsystem 60 is a compositing memory 62 and a corresponding compositing bus 63. The second is a printer subsystem 8. The C,M,Y or K value resulting from interpolating the colour conversion table by the colour conversion apparatus 2 will be output to the printer subsystem 8 by the colour conversion apparatus 2. Processor input/output (I/O) to and from the colour conversion apparatus 2 is performed by processor bus interface subsystem 3 via a processor bus 4 in synchronization with the processor clock. I/O to and from the printer subsystem 8 is synchronized with the pixel clock of the relevant printer subsystem. An example printer subsystem 8 for use with the preferred embodiment of the present invention is Canon's CLC500 colour printer. Referring now to Fig. 4 there is shown the basic structure of a colour conversion apparatus of the preferred embodiment. The modules in colour conversion apparatus 2 form a processing pipeline which accept a stream of RGB pixel data from the compositing bus 63 and pass it along the processing pipeline to generate the appropriate colour conversion data for output to the printer interface. Interface of the colour conversion apparatus 2 to the processor bus 4 is controlled by the processor bus interface subsystem 3. The processor bus interface subsystem 3 interfaces the processor bus 4 to an internal register bus 5 for register read and write cycles, and processor DMA accesses to internal RAM within the colour conversion apparatus 2. Configuration and control of colour conversion apparatus 2 is achieved by reading and writing internal configuration and control registers 6 of the colour conversion apparatus 2 which generates control information 7 from those registers for the colour conversion apparatus 2. Each of the internal memories are dual ported (not necessarily physically but functionally by means of the processor mode bit in the configuration and control registers 6), with a port assigned to the execution pipeline of the colour conversion apparatus 2 and a port assigned to the register bus 5. The port assigned to the register bus 5 is used for the loading of each internal memory before each colour pass of the printer subsystem 8. Three distinct operations are performed by colour conversion apparatus 2, those being colour conversion, near-white correction performed by a near white correction unit 35, and text detect edge enhancement performed by a near black correction unit 36. The resulting output data 9 is the RGB to CMYK colour conversion required by the relevant printing device. The output data 9 can be returned back to the compositing memory 62 by an arrangement of bi-directional buffers 10. A non-uniform colour space conversion interval RAM 11 is advantageously provided to improve the colour conversion process. The non-uniform colour space conversion interval RAM 11 comprises separate interval RAM's 12, 13, 14 which are loaded for each colour pass and each provide a one to one transformation mapping for each of the Red, Green and Blue channels of input. Referring now to Fig. 4 to Fig. 7, the operation of the red interval RAM 12 will now be described, with the green interval RAM 13 and blue interval RAM 14 operating in a corresponding manner. As will be further described below, so as to reduce the amount of storage required by the colour conversion apparatus 2, methods of interpolation are used to derive the final output colour. A basic explanation of the interpolation process will be described in relation to one colour, the interpolation being carried out, for example, between two derived cyan values derived from the graph of Fig. 2. Referring to Fig. 5 and Fig. 6, an example of a first method of interpolation of values. In this method, it is desired to determine the cyan component of a red input data point 18. In order to do this, the scale of red values is broken up into a number of predefined substantially equal intervals and the closest two of these intervals is used for the interpolation process. Hence a lower red reference point 19 and an upper red reference point 20 are determined, their corresponding first cyan value 22 and second cyan value 23 are determined and these two points are used as interpolation points in order to determine a final interpolated value 24. However, as can be seen from Fig. 6, there can be substantial inaccuracies in certain intervals between the final interpolated value 24 and the required cyan value 25. Thereby outputing incorrect results, especially where the red to cyan curve is not well behaved. This means that the interpolation process can have a high degree of accuracy in some intervals and a substantially lower degree of accuracy in other intervals. In Fig. 7 and Fig. 8, a more ideal form of interpolation between cyan values 21 whereby the interpolation points are judiciously placed so as to minimize the error between the final interpolated value 24 and the required cyan value 25. The placement of interpolation points can be determined by the nature of the particular conversion curve, with a high number of points placed around points around areas of the curve that are not well behaved. In this case, the interpolation intervals are substantially shorter where the rate of change of the gradient of the curve is greatest (i.e. not well behaved). In particular, the length of the output colour space intervals between the interpolation points is shorter at and about locations where the transfer function undergoes a relatively rapid change in slope. Further, the length of the output colour space intervals is adjusted so that the magnitude of the change in slope of the transfer function between adjacent ones of the output colour space intervals is less than a predetermined value. A red interval RAM 12 is responsible for rescaling or remapping the set of input points of Fig. 5 to Fig. 7. This has the effect of shortening the distance between interpolation points in each badly behaved area of colour conversion curve 28 and lengthening the distance between interpolation points in each well behaved area of the colour conversion curve 29. A well behaved portion of the curve being one that has a substantially linear relationship between input red values and output cyan values. In colour conversion apparatus 2 of the preferred embodiment, the red axis is divided into 15 intervals, giving 16 interval endpoints, and the non-uniform colour space conversion interval RAM 11 accepts 24-bit RGB pixel information in the form of 8-bits for each of the red input 30, green input 31 and blue input 32. Each interval RAM 12, 13, 14 performs the abovementioned interval determination and outputs a 4 bit key corresponding to the division of each input colour into one of 16 intervals. The 4-bit key is derived from an analysis of the behaviour of the transfer curve for the particular the printer subsystem 8, and is pre-loaded into the non-uniform colour space conversion interval RAM 11. These 4 bit interval key values are concatenated together to form a 12-bit address for accessing a colour conversion RAM 33. The 12-bit address is used by the colour conversion RAM 33 to determine the eight vertices of a cube in RGB space which encloses the input pixel. The non-uniform colour space conversion interval RAM 11 can be viewed as a triple array of 8-bit data with the red index changing most frequently, followed by the green index and then the blue index (For example, for simulation in the C programming language, this would be declared as char Color_Table[blue][green][red], where red, green and blue are in the range 0 to 15). The red interval RAM 12 contains 256 4-bit interval values at addresses 0x1000 to 0x10FF. The green interval RAM 13 contains 256 4-bit interval values at addresses 0x1100 to 0x11FF. The blue interval RAM 14 contains 256 4-bit interval values at addresses 0x1200 to 0x12FF. Data is ordered from lowest interval to highest interval. Referring now to Fig. 9, there is shown the method of determining the relevant toner amount used in the next step of the conversion process carried out by the colour conversion RAM 33. The colour conversion RAM 33 is loaded with the appropriate output colour space primary colour lookup table by the processor bus interface subsystem 3 via the register bus 5 before each colour pass of the printer (CMYK) to contain 4096 colour conversion values at addresses 0x0000 to 0x0FFF. The 12-bit address from the non-uniform colour space conversion interval RAM 11 is used to select eight of the 4096 values as the vertices of the cube. This process is used by the preferred embodiment to minimize the storage requirements. For example, assuming that each primary colour has 256 (8-bits) possible levels of input, a lookup table for every combination of R, G, and B would require 16 Mbytes (256 x 256 x 256) of addresses for each of the CMY and K pass. A large lookup table can be simulated by interpolating between eight points forming a cube around the R,G,B position derived from the non-uniform colour space conversion interval RAM 11. Using the three lots of four bits output from each interval RAM 12, 13, 14 and interpolating between the endpoints of the enclosing cube, only 4 kilobytes (16 x 16 x 16) of cube lookup address space is required within the colour conversion RAM 33. Fig. 9 shows an example of how the colour conversion RAM 33 and interpolation processor 16 are used to find a toner value which is a function of R, G and B. First the lookup table finds the "cube" of eight (RGB) points which surround the exact point (either CMY or K) required. In this example the values output from the interval RAMs 12, 13, 14 are (in hexadecimal) 5, 3, and 1, these values are shown in Fig. 9 to select the appropriate enclosing cube. Fig. 10 shows the selected cube. In our example the corner C(0,0,0) represents the value of the toner intensity for (say) cyan when the interval RAM output values for R, G and B are 5, 3 and 1 respectively. Similarly, the corner C100 represents the value of the toner intensity for cyan when the values for R, G and B of the interval RAM's 12, 13, 14 are 6, 3 and 1 (respectively). At the pixel output rate for common colour printers, the colour conversion data would have to be updated approximately every 75 nanoseconds (ns). In order to obtain the eight vertices, eight reads from a single RAM lookup table would be required. This is not practicable within the required time constraint. The colour conversion RAM 33 is implemented as eight RAMs one for each vertex of the enclosing cube. To save storing duplicate data values in the vertex RAMs, a hardware address remapping scheme is implemented. Referring now to Fig. 11 there is shown an example illustrating the process of address remapping carried out by the colour conversion RAM. This example illustrates the case of one-dimensional (1-D) interpolation of a function that has been sampled at sixteen points with two different RAMs being used to store the endpoints of an interpolation interval. The even end points of the interpolation intervals are assigned to the first RAM and the odd grid points to the second RAM. Given a four-bit address (A3-A0) which will select one of the fifteen interpolation intervals, only three address bits are necessary to select one of eight endpoints stored in each RAM. The addresses for the RAM containing the 'even' endpoints will be the three most significant bits of the four bit address (A3A2A1). The addresses for the RAM containing the 'odd' endpoints will be the three most significant bits, with the least significant bit added to this three bit address (i.e. A3A2A1+A0). Referring to the example in Fig. 11 which it can be shown that the first even_RAM will contain the values corresponding to points {0,2,4,6,8,10,12,14} and the odd_RAM contains the values corresponding to the points {1,3,5,7,9,11,13,15}. Sequencing through the interpolation intervals, it can be shown that the corresponding RAM addresses will be {0,0},{1,0},{1,1},{2,1},... etc. So for the interpolation processor 16 which requires its input as a sequence of (left, right) endpoints, it is only needed to perform a swap on the data outputs whenever the least significant bit (LSB) of the interpolation interval address is set, to have the data in the required format. Fig. 12 shows, that by using the above mentioned process in three dimensions only every second cube (in each direction) is required to store all points in the RGB space, thereby avoiding duplicated storage of individual points. Fig. 13 shows the three dimensional process of Fig. 12 with only the red direction shown for clarity. Only values for cube0 37 and cube2 38 are stored in the colour conversion RAM 33. If the point of interest falls in cube0, the "normal" interpolation direction is from RGB0 to R'BG0. If, however, the point A lies in cube 1, the RGB corner value is taken from cube2 and the R'GB corner value is taken from cube0. In this case, the interpolation direction along the red axis is reversed to effectively "swap" the two corner values. This can be done by complementing the red LSBs used in looking up the fractional RAM 15 which form part of the first stage of interpolators and will be described more fully below. Each of the eight corners are stored in separate RAMs. Each RAM is addressed differently in order to access the correct cube. The colour conversion RAM outputs 52 are fed to the interpolation processor 16. Referring now to Fig. 14 there is shown the colour conversion RAM, which must output a sequence of {left, right} endpoints. Taking the example of a red input value 39 from the red interval RAM 12 that corresponds to a "red even" cube (cf Fig. 13), for "red even" RAMs 41, 43, 45, 47, three MSB address values from the red interval RAM 12 are used directly to look up the relevant vertex values. In order to determine the address value for the "red odd" value RAMs 40, 42, 44, 46 the lowest bit 48 is taken and added by adder 50 to the upper 3 bits 49 to give the odd RAM address 51. Returning now to Fig. 4, a fractional RAM 15 is provided which is reloaded by the processor bus interface subsystem 3 for each colour printer pass. The fractional RAM 15 is loaded with values corresponding to the fraction of the interval that each colour value lies on the red axis of Fig. 7. For example, if the red input data point 18 lies one third between the lower red reference point 19 and the upper red reference point 20 then the fractional RAM 15 will output an 8 bit value corresponding to this position. The fractional RAM 15 outputs 8 bits for each colour, represented by (u1,u2,u3), to the interpolation processor 16. Each component of the RGB pixel data passes through the fractional RAM 15 which provides a 8-bit interpolation fraction amount. The co-ordinate triplet is passed onto the interpolation processor 16 for further processing In Fig. 15 an example of interpolation of a point within a cube is shown in which seven interpolators are used to find the final value. The first four interpolate along the R axis (using the R interpolation fraction) to find the colour conversion values at points A1, A2, A3 and A4 (Fig. 10). The next two interpolate along the G axis between A1 and A2 to find B1 and between A3 and A4 to find B2. The final interpolator interpolates along the B axis to find the point C which forms the final interpolated value 24 Hence, for a point (u1,u2,u3) for which it is desired to know the interpolated function value C(u1,u2,u3), the following series of linear interpolations is carried out: A1 = C(u1,0,0)=(1-u1)*C000+u1*C100 A2=C(u1,0,1)=(1-u1)*C001+u1*C101 A3=C(u1,1,0)=(1-u1)*C010+u1*C110 A4=C(u1,1,1)=(1-u1)*C011+u1*C111 B1=C(u1,u2,0)=(1-u2)*A1+u2*A3 B2=C(u1,u2,1)=(1-u2)*A2+u2*A4 C=C(u1,u2,u3)=(1-u3)*B1+u3*B2 where the coordinates within the interpolation cell are normalized to range from 0 to 1. The result of the tri-linear interpolation computation gives the relevant cyan, magenta, yellow or black components. This data is used as the input for near-white correction, the next operation of the colour conversion apparatus 2. It must be appreciated that, when output colour space interpolation intervals are determined, it is possible for corresponding intervals to be of different lengths, and accordingly the eight vertices do not define a cube, but rather an arbitrary volume. However each of the volumes are contiguous and fill the entire colour space. Also the re-mapping from one colour space to the other does not necessarily involve re-mapping to a similarly shaped volume. Throughout this specification "cubes" are used for convenience of description and for ease of visualisation of the embodiments. Fig. 15 shows the structure of the interpolation processor 16 of Fig. 4. The interpolation processor 16 takes the colour conversion RAM outputs 52 C000 to C111 for points located at the eight vertices of a data point's enclosing cube and the interval swap signals 53 swap_R, swap_G and swap_B. As mentioned previously, the interval swap signals 53 are derived from the least significant bit of respective colour outputs from the non-uniform colour space conversion interval RAM 11 for each colour. Using the three interpolation fractions generated by the fractional RAM 15, the interpolator processor 15 implements the multidimensional interpolation equations outlined above via a series of interpolation processing elements 34 to calculate the required colour conversion values as given in Equation 11. Referring now to Fig. 16 there is shown the internal structure of each interpolation processing element 34. Each interpolation processing element 34 implements a one-dimensional interpolation equation: f(xi)=f(x0)+((f(x1)-f(x0))*(xi-x0)/(x1-x0)) As mentioned previously it is sometimes necessary to swap the interval inputs around. This is implemented by swap unit 54 under the control of a swap signal 55. For the first pass of the interpolation-tree, the end-points of the interpolation f(x1), f(x0) are the vertices of the enclosing cube determined by the colour conversion RAM outputs 52. The fractional terms (xi-x0)/(x1-x0) supplied by the fractional RAM 15 represent an 8-bit fractional amount (i.e. normalised between 0 and 1) to interpolate to reach the f(xi) value. Referring now to Fig. 17, there is shown the structure of the near white correction unit 35. The upper 4 bits of colour conversion data 70 output of the interpolation processor 16 are used for input to a zero detection unit 71 which is used to detect possible near white values and outputs a multiplexer selection signal 72 which is used by multiplexer 74 to select the lower four bits of output. The near white correction unit 35 uses the process of dithering for values in the range of intensities from 0 to 0x0F to increase the perceived dynamic range on the printed output. In the process of dithering an image, the decision to intensify a particular output location is made dependent on the desired intensity S(x,y) at that particular point and on a predetermined dither matrix value D(i,j). To display the required point at O(x,y), it is necessary to generate i = x modulo n j = y modulo n Then, if S(x,y)> D(i,j), the point at O(x,y) is intensified, otherwise it is not. Referring now to Fig. 18, there is shown an example of the dithering process using a 2 x 2 dither matrix values 75. The input matrix values 76 containing S(x,y), and dither matrix values 75 having locations D(i,j), are used in conjunction with the above intensification rule to produce output matrix values 77 O(x,y) with 0 corresponding to those points that are not intensified, and 1 corresponding to those points that are intensified. Hence, input position S(0,0) with a value of 0, will be compared with D(0,0) which has a value 0 also, and the comparison determination is not satisfied, so the point 0(0,0) will not be intensified. Input element S(2,3) with a value of 3, will be matched with dither matrix element D(0,1) since 2 modulo 2=0 and 3 modulo 2=1. D(0,1) has a value 2, so the output element 0(2,3) is intensified and so on. The above example is a sample operation of a dither matrix of size 2x2 elements, for an on or off output. In the preferred embodiment of the present invention, a dither matrix of size 16 x 16 is used. The near white correction unit 35 takes the output from the interpolation processor 16 and dithers points with an intensity that is less than or equal to a near white threshold, 0x0F. If the upper 4 bits of colour conversion data 70 correspond to a value greater than the near white threshold, the zero detection unit 71 outputs a multiplexor selection signal 72 such causes the multiplexor 74 to pass the input data unhindered. Otherwise, the zero detection unit 71 output causes the output to be the value provided by the comparison unit 78. The lower 4 bits of input data 73 from the interpolation processor 16 is input to a comparison unit 78 which tests if this data is greater than the dither matrix value fetched from a dither matrix RAM 79. If it exceeds the dither threshold then the near white threshold value is output from a register within the comparison unit 78. The value output from dither matrix RAM 79 is determined by input index values that are themselves constructed from a 4 bit pixel counter 80 and a 4 bit line counter 81. These counters are maintained to track a pixel's position in the dither matrix. The 4 bit line counter 81 can be reset at a frame start by a FSYNC signal 82 and counts LSYNC signal 83 pulses. The 4 bit pixel counter 80 can be reset at the line start by the LSYNC signal 83 and will count PIXCLK 84 pulses. The near white correction unit 35 provides a near white output 85 having it's four most significant bits obtained from the upper 4 bits of colour conversion data 70 output from the interpolation processor 16, and it's four least significant bits obtained from an output of the multiplexor 74. The near black correction unit 36 aims to sharpen up the edges of text by detecting the transition from black to white or vice versa. When an edge is detected, instead of printing a black made up of, for example, the Cyan, Magenta, Yellow and Black that it would normally comprise, a substantial portion of a single black colour is printed. This has the effect of hiding colour registration errors and removing excess toner around fine black text. The single colour black is actually a four colour black but with a substantial amount of "under colour removal" (UCR). When a black edge is detected the output is limited to printing a register value within the near black correction unit 36. This register is loaded with a value representing 100% output for the black pass, and say 20% for the other passes. Hence there will be 80% UCR which has been found to produce better results than 100% UCR which tends to produce results that appear too 'thin' when fine lines of text are printed. Referring now to Fig. 19, the structure of the near black correction unit 36 is shown. The RGB input pixels 88 from the compositing bus 63 are input to a latch and delay unit 87, to be delayed so they are synchronized with colour conversion data obtained from the near white output 85 previously derived from the interpolation processor 16. The near black correction unit 36 detects the case of a black input pixel. If the input pixel is not black then a multiplexor 90 passes the colour conversion data of the near white output 85 (i.e. from the previous pipeline stage) unchanged from its input to its output. If the current input pixel is black, a near black control unit 92 tests the pixel's immediate neighbours for whiteness. If either of the neighbours are white then the near black control unit 92 considers that it has detected an edge and activates the multiplexer 90 via multiplexer control signal 93 which then selects the contents of a deep black register 91 rather than the near white output 85. In order to provide some tolerance to noise in the input signal white values are considered to be in the range of R,G,B values being 0xFF-0xFE and black values are set in the range 0x00-0x01. This allows for least significant bit errors during compositing operations prior to colour conversion. The near black correction unit 36 processor scans a line for the case of a black to white or white to black transition. This enables the detection of horizontal edges. If a system requires the detection of vertical edges then it will be necessary to scan from line to line. Two status signals, a white detect signal 94 and a black detect signal 95 are provided for use for the optional detection of edges in a vertical scanning direction. Referring now to Fig. 20, there is shown an embodiment of a vertical edge detection system, which is ancillary to the colour conversion apparatus 2. One line of colour conversion data comprising the output data 9 is stored in a data line store 96, being the line that is to be colour corrected for text edges. A first line of status information is stored in a first status information store 97, and a second line of status information is stored in a second status information store 98, the store 98 corresponding to the line being written to thedata line store 96, and the store 97 to the line previously in the data line store 96. The third line of status information is current status information 99 and comes directly from the colour conversion apparatus 2 (see Fig. 17). An edge determination logic unit 100 performs the same function as that performed in the near black correction unit 36 in that an edge determination logic unit output signal 101 is high when the output of the second status information store 98 indicates a black pixel, and either the output of the first status information store 97 or the current status information 99 indicates a white pixel. When such a condition occurs a multiplexor 103 outputs the value stored in another deep black register 102 otherwise the colour data from the data line store 96 is output. The deep black register 102 is reloaded via an RBUS input 104, derived from the register bus 5, at each colour data pass of the printer device. The foregoing describes only a number of embodiments of the present invention, modifications, obvious to those skilled in the art, can be made thereto without departing from the scope of the present invention.

Claims: A method for converting an input image in an input colour space to an output image in an output colour space, wherein said input colour space is formed of at least one primary colour, the range of values of the or each primary colour being divided into a series of contiguous intervals each having two endpoints, said method comprising the steps of: storing (33), for each point in said input colour space defined by one or more endpoints at respective ones of the or each primary colour, an output colour value of a corresponding point in said output colour space; determining (11), for an input pixel in the input image and for the or each said primary colour, the interval at the respective primary colour that contains the respective colour component value of said input pixel; determining (33), for said input pixel, the output colour values of the points in said output colour space that correspond to the endpoints of the interval or intervals determined for said input pixel; interpolating (15, 16) between the thus determined output colour values to derive an output colour pixel value in said output colour space that corresponds to the colour value of said input pixel; the method being characterized by: said step of storing comprising storing the output colour values in separate groups, such that for at least one primary colour, the output colour values corresponding to adjacent endpoints at the primary colour are arranged in different groups stored in respective separate groups of storage means (40, 42, 44, 46; 41, 43, 45, 47), enabling that the output colour values corresponding to even-numbered endpoints at the primary colour are stored separate from the colour values corresponding to odd-numbered endpoints at the primary colour; and simultaneously retrieving stored output colour values (C000, C100, ..., C111) corresponding to the endpoints that define the interval or intervals determined for the input pixel, wherein at said retrieval of the stored output colour values from the storage means, for said at least one primary colour, different addressing offset values are used for accessing respective different groups of storage means. A method as claimed in claim 1, characterized in that the output colour values corresponding to adjacent endpoints of a primary colour are stored in respective different storage means. A method as claimed in claim 1 or claim 2, wherein each primary colour of the input colour space is divided into a plurality of said intervals having endpoints so as to form a plurality of volumes in the input colour space, with each volume having vertices each defined by endpoints one at each primary colour, characterized in that said storage step comprises; storing, for each volume, said output colour values corresponding to the vertices of said volume in respective storage means. A method as claimed in any preceding claim, characterized in that the interpolating step (16) further includes determining a distance measure of said input pixel from at least one of said endpoints of said determined interval or intervals by means of a lookup table (15). A method as claimed in any preceding claim, characterized in that a relationship between the two colour spaces is defined by a transfer function and the input colour intervals at a primary colour vary in length depending on the behaviour of the transfer function. A method as claimed in claim 5, characterized in that the length of the input colour intervals is shorter at and about locations where the transfer function undergoes a relatively rapid change in slope. A method as claimed in claim 6, characterized in that the length of the input colour intervals is adjusted so that the magnitude of the change in slope of the transfer function between adjacent ones of the input colour intervals is less than a predetermined value. A method as claimed in any preceding claim, characterized in that the output colour space is configured for display by means of a printing system (8) and the input colour intervals are predetermined based on a transfer characteristic of the printing system. A method as claimed in any preceding claim, characterized in that the method comprises the further step of detecting amongst said output pixels those output pixels having a value near white and altering the same to extend the perceived dynamic range of all said output pixels. A method as claimed in claim 9, characterized in that said altering involves dithering those output pixels having a value near white over a range of pixel values. A method as claimed in any preceding claim, characterized in that, the method comprises the further step of detecting amongst said output pixels those pixels having a value near black and forcing the value of selected ones of said those pixels to black. Apparatus for converting an input image in an input colour space to an output image in an output colour space, wherein said input colour space is formed of at least one primary colour, the range of values of the or each primary colour being divided into a series of contiguous intervals each having two endpoints, said apparatus comprising: means (33) for storing, for each point in said input colour space defined by one or more endpoints at respective ones of the or each primary colour, an output colour value of a corresponding point in said output colour space; means (11) for determining, for an input pixel in the input image and for the or each primary colour, the interval at the respective primary colour that contains the respective colour component value of said input pixel; means (33) for determining, for said input pixel, the output colour values of the points in said output colour space that correspond to the endpoints of the interval or intervals determined for said input pixel; and means (15, 16) for interpolating between the thus determined output colour values to derive an output colour pixel value in said output colour space that corresponds to the colour value of said input pixel; the apparatus being characterized by: said means for storing effecting the storing of the output colour values in separate groups, such that for at least one primary colour, the output colour values corresponding to adjacent endpoints at the primary colour are arranged in different groups stored in respective separate groups of storage means (40, 42, 44, 46; 41, 43, 45, 47), enabling that the output colour values corresponding to even-numbered endpoints at the primary colour are stored separate from the colour values corresponding to odd-numbered endpoints at the primary colour; and means for simultaneously retrieving stored output colour values (C000, C100, ..., C111) corresponding to the endpoints that define the interval or intervals determined for the input pixel, wherein at said retrieval of the stored output colour values from the storage means, for the or each primary colour, different addressing offset values are used for accessing respective different groups of storage means. Apparatus as claimed in claim 12, characterized in that the output colour values corresponding to adjacent endpoints at a primary colour are stored in respective different storage means. Apparatus as claimed in claim 12 or claim 13, wherein each primary colour of the input colour space is divided into a plurality of said intervals having endpoints so as to form a plurality of volumes in the input colour space, with each volume having vertices each defined by endpoints one at each primary colour, characterized in that said storage means comprises: a plurality of memory means for respectively storing, for each volume, said output colour values corresponding to the vertices of said volume in respective ones of said memory means. Colour conversion apparatus as claimed in claim 12 characterized in that said interpolation means (16) comprises a lookup table for determining a distance measure of said input pixel from at least one of said endpoints of said determined interval or intervals. Colour conversion apparatus as claimed in any one of claims 13 to 15 characterized in that a relationship between the two colour spaces is defined by a transfer function and the input colour intervals at a primary colour vary in length depending on the behaviour of the transfer function. Colour conversion apparatus as claimed in claim 16 characterized in that the length of the input colour intervals is shorter at and about locations where the transfer function undergoes a relatively rapid change in slope. Colour conversion apparatus as claimed in claim 17 characterized in that the length of the input colour intervals is adjusted so that the magnitude of the change in slope of the transfer function between adjacent ones of the input colour intervals is less than a predetermined value. Colour conversion apparatus as claimed in any one of claims 12 to 18 characterized in that the output colour space is configured for display by means of a printing system (8) and the input colour intervals are predetermined based on a transfer characteristic of the printing system.

Inventors: METCALFE JAMES ROBERT, METCALFE, JAMES ROBERT
Applicants: CANON INFORMATION SYST RES, CANON KK, CANON INFORMATION SYSTEMS RESEARCH AUSTRALIA PTY LTD., CANON KABUSHIKI KAISHA
Application year: 1994
Main classification: H04N1
IPC codes: G06T1, G09G5, H04N1, G06T5