Methods of compression and expansion of dot pattern

Abstract: In a method of compression of a dot pattern wherein a dot pattern, which is arranged in such a manner that two or more printing dots do not continue in a main scanning direction, is compressed and stored in a memory, while data read out from the memory is subjected to an expansion processing to obtain an original dot pattern, so that a printing is performed, dummy printing dots (102, 104) are inserted into rows of the printing dots arranged in the main scanning direction in such a manner that columns of the printing dots arranged in a subscanning direction perpendicular to the main scanning direction are repeatedly disposed. The dot pattern is compressed based on the columns (2nd to 17th columns in FIG. 1A) of the printing dots and associated information (CI in FIG. 1A) indicating repetition of the disposition, and then stored in the memory. Further in accordance with the method as stated above, a dot pattern (FIG. 6) including dummy printing dots (102, 104) is prepared (RAM 3 in FIG. 2; FIGS. 5A and 5B) based on the columns of the printing dots, which are read out from the memory, arranged in the subscanning direction, and associated information (CI in FIG. 6) indicating repetition of the disposition of the columns of the printing dots in the main scanning direction. Part of the printing dots is deleted (3, 10, 11, 12 in FIG. 7) if so arranged that two or more printing dots including the dummy printing dots continue in the main scanning direction, so that the dot pattern is restored in such a manner that two or more printing dots do not continue in the main scanning direction.

Description: BACKGROUND OF THE INVENTION Field of the Invention The present invention relates to methods of compression and expansion of a dot pattern consisting of a number of dots arranged in a matrix configuration. Description of the Prior Art A so-called dot printer such as a wire or stylus type of dot printer or the like is provided with a character generator or memory for storing therein a dot pattern with which a character is represented by a number of dots arranged in a matrix configuration, which is of the length or column of 17 dots x breadth or row of 17 dots, and includes in total 289 dots, for example. The dot pattern on this memory is represented in such a manner that a dot to be printed is given by "1" and a dot not to be printed is given by "0", and the dot pattern is stored on a dividing basis on each column. When a printing of a character is performed, a dot pattern is read out from the memory in units of columns to drive printing wires provided on a printing head, so that a desired printing is carried out. A printing head of the dot printer is generally so arranged that a plurality of printing wires are disposed in a longitudinal direction, for instance, there is an arrangement in which nine printing wires are disposed in a longitudinal direction. In a case where a so-called NLQ character represented by 17 dots x 17 dots is printed using such a printing head, the printing head is scanned twice in a main scanning direction or a lateral direction every printing of one character (one line corresponding). More in detail length 17 dots are divided into two blocks so as to perform printing of odd rows in a first scanning and printing of even rows in a second scanning. According to NLQ character, the maximum number of dots on each column of a dot pattern represented by 17 dots x 17 dots for characters, symbols and so on is limited within 13 dots, and regarding, for instance, English small letter "j", its lowest dots are lowered 4 dots, that is, the lowest dots are located at row 17th dot position and be treated as a so-called descender letter. Mixing of such a descender letter makes it possible to provide a good balance of a printing result. It is necessary for the memory to store various dot patterns corresponding to many characters, and thus it is needed to prepare a large capacity of memory, if the amount of data of the individual dot pattern is much. Consequently, there is employed such a method that a dot pattern is subjected to a compression processing to store a memory, and when a printing is performed, the dot pattern is subjected to an expansion processing to obtain an original dot pattern. FIG. 3 shows a dot pattern of an ordinary descender letter. The figure is directed to a descender letter of English small letter "j" represented by a dot pattern of length 17 dots x breadth 17 dots. In the figure, there are arranged printing dots in such a manner that two or more printing dots do not continue in a main scanning direction or a lateral direction, in other words, there is no such an occasion that two or more continuous printing dots, represented in the figure by dark circles, are arranged in an individual row. Hereinafter, it is so defined that in the dot pattern, dots constructing the individual row are referred to as a row dot pattern and dots constructing the individual column are referred to as a column dot pattern. The reason why the dot patterns are arranged in such a manner that two or more printing dots do not continue in a main scanning direction is that a high speed printing is realized. The detailed reason will be described hereinafter. When a printing length of wire, or stylus, of a printing head of the wire dot printer is driven, the printing wire protrudes from a home position to print a dot on a printing sheet at a predetermined position and returns to the home position. This operation is repeated. When the same printing wire is continuously driven, the driving is performed waiting that the printing wire returns to the home position. The reason why this is so done is that if a new driving is carried out while the printing wire has not yet returned to the home position, it is impossible to supply a sufficient driving force to the printing wire. That is, there is provided no constant pressing force of the printing wire for pressing a printing sheet. This causes unevenness in density of the printing dots and so on. In order to avoid such a situation, the driving of the printing wire is to be performed in a constant condition. In a case where a printing is performed, on the other hand, there may exist printing wires which are not driven in printing of a certain column. Such printing wires are ready to immediately operate for printing of the adjacent column. Consequently, there is no necessity for waiting for return of the printing wire driven in printing of a certain column to the home position. In other words, it is permitted, while the printing wire driven in a certain column is going to return to the home position, to carry out the printing of the adjacent column. Such a driving of the printing wire may be realized by means of arranging the printing dots in such a manner that two or more printing dots do not continue in a main scanning direction. Thus, there is provided the dot pattern as shown in FIG. 3. It is now assumed, for example, that the printing at column 11th, row 16th has been completed. Thus, next, the printing at column 12th will be performed. In this case, if it is assumed that there is a dot at column 12th, row 16th, for example, it is impossible to perform the printing without waiting for return of the printing wire driven in printing of column 11th to the home position. However, it is possible to immediately perform the printing of a dot at column 12th, row 14th, since there is no printing dot at column 11th, row 14th. There are proposed various compression methods of compression of a dot pattern. There is known a method as disclosed in, for example, Japanese Patent Laid-Open Gazette 62-30052/1987, in which information indicating variation of individual column dot patterns is stored, and only column dot pattern, which is different from that of the adjacent column, is stored in a memory, thereby reducing the amount of data per character. If such a compression method is applied to the dot pattern as shown in FIG. 3, it would be impossible to expect a sufficient compression and thus to reduce the amount of data. That is, no compression is performed on columns in each of which there exists a printing dot and compression is performed on only 14th - 17th columns in each of which there exists no printing dot. In effect, there are only 4 columns which are subjected to compression of the column dot data. The reason why this is so is that the dot patterns are arranged in such a manner that two or more printing dots do not continue in a main scanning direction and the column dot patterns in adjacent columns are always different from each other. As stated above, it is impossible to expect effects of the compression on the dot patterns which are arranged in such a manner that two or more printing dots do not continue in a main scanning direction. SUMMARY OF THE INVENTION It is therefore an object of the present invention to provide methods of compression and expansion of a dot pattern which make it possible to expect a sufficient effect on even the dot patterns which are arranged in such a manner that two or more printing dots do not continue in a main scanning direction. According to the present invention there is provided a method of compression of a dot pattern according to claim 1. Further according to the present invention there is provided a method of expansion of a dot pattern according to claim 4. BRIEF DESCRIPTION OF THE DRAWINGS The objects and features of the present invention will become more apparent from the consideration of the following detailed description taken in conjunction with the accompanying drawings in which: FIGS. 1A and 1B are diagrams used for the explanation of a compression method according to the present invention; FIG. 2 is a block diagram of a printing apparatus, by way of example, to which methods of compression and expansion of a dot pattern according to the present invention are applicable ; FIG. 3 shows an example of a dot pattern of an ordinary descender letter; FIGS. 4A and 4B are diagrams used for the explanation of the memory storage according to the present invention; FIGS. 5A and 5B are flow charts related to a method of expansion according to the present invention ; FIG. 6 is a diagram used for the explanation of expansion according to the present invention; and FIG. 7 is a block diagram related to a method of expansion according to the present invention. DESCRIPTION OF THE PREFERRED EMBODIMENTS FIG. 2 is a block diagram of a printing apparatus, by way of example, to which methods of compression and expansion of a dot pattern according to the present invention are applicable. As shown in the figure, ROM 2, RAM 3 and I/O driver 4 are connected through a bus line BUS to a processor (CPU) 1. Connected to I/O driver 4 are an interface 5 for controlling communication with an external apparatus, a printing head 6, a line feed motor 7 for feeding a printing sheet, and a spacing motor 8 for use in scanning of the printing head 6. In the printing apparatus as stated above, CPU 1 controls the respective units based on programs and data stored in ROM 2 so as to perform a desired printing triangle FIGS. 1A and 1B are diagrams used for the explanation of a compression method according to the present invention. Referring to FIG. 1A, there will be explained hereinafter a case of insertion of dummy printing dots. As a dot pattern, English small letter "j" is referred to by way of example, which has been explained above in conjunction with FIG. 3. First, taking notice of each of the rows, if there exist in the same row printing dots, represented by dark or solid circles 100, in both an immediately preceding column and an immediately succeeding column with respect to the noticed column, a dummy printing dot, denoted by a white or blank circle 102, is inserted into or added to a position between those printing dots, or the noticed column, which is referred to as the first insertion processing. Next, in a case where there exist in the same row printing dot or dark circle 100 in an immediately preceding column with respect to the noticed column, but no printing dot, denoted by a white circle 102 in an immediately succeeding column with respect to the noticed column, a dummy printing dot, which is represented by a doubled circle 104, is inserted or added, for the time being, into a position located immediately after the existing printing dot, or the noticed column. And thereafter, comparisons between the columns into each of which the dummy printing dot or doubled circle 104 is inserted and the columns each of which is located immediately before the existing dummy printing dot are sequentially carried out in units of columns from 1st column to 17th column. As a result, if there is obtained a coincidence between the associated columns in a dot pattern, the dummy printing dot, marked with a doubled circle 104, which has been inserted for the time being, is determined, that is, be retained as the dummy printing dot as it is. On the other hand, if there is obtained no coincidence between the associated columns in a dot pattern, the dummy printing dot 104, which has been inserted for the time being, is withdrawn, that is, there is provided such a status that no dummy printing dot exists, which is called the second insertion processing. Such a status is shown with diamonds in FIG. 1A. The second insertion processing will be explained more in detail hereinafter, by way of example, referring to the dot patterns of 2nd column to 4th column. First, the dummy printing dots are inserted, for the time being, into 3rd column, 15th row and 4th column, 16th row. Next, Comparison of 2nd column and 3rd column is performed. In this case, there is obtained no coincidence between 2nd column, 16th row and 3rd column, 16th row, and thus the dummy printing dot, which has been inserted, for the time being into, 3rd column, 15th row, is withdrawn (shown by the diamonds 106 in FIG. 1A). Consecutively, comparison of 3rd column and 4th column is performed. In this case, there is obtained coincidence between 3rd column, 16th row and 4th column, 16th row in a dot pattern, that is, the printing dot or dark circle 100 and the dummy printing dot or doubled circle 104, are coincident with each other in the location. Consequently, the dummy printing dot 104 which has been inserted, for the time being, into 4rd, column 16th row, is retained. It is noted that while the second insertion processing is performed after the first insertion processing, a status of a dot pattern in a case where the second insertion processing is performed is a status before the first insertion processing is performed, that is, such a status that there is no dummy printing dot or white circle 102 on the dot pattern. In other words, in the first insertion processing, a position, into which the dummy printing dot or white circle 102 is to be inserted is simply grasped, and after completion of the second insertion processing, the dummy printing dot, designated by a white circle 102 is actually inserted into the position grasped in the first insertion processing. Upon completion of those processing, taking notice of individual columns, compression information CI is prepared. First, 1st column is unconditionally stored in a memory and be out of an object of compression, and thus the preparation processing for compression information CI is carried out initially from 2nd column. In this preparation, column of interest is compared with the immediately proceeding column in the dot pattern. As a result, if there is obtained no coincidence therebetween, the content of compression information CI is given by "0", and if there is obtained coincidence therebetween, the content of compression information CI is given by "1". The compression information or data CI comprises 16 bits to provide indication as to whether compression of the individual column of 2nd to 17th columns has been performed. The compression information CI indicates the number of repeated occurrences in which the printing dot is repeatedly disposed in a main or primary scanning direction. For example, five consecutive contents "1" indicates that the printing dot (the same dot pattern of column) is disposed repeatedly six times, and two consecutive contents "1" indicates that the printing dot (the same dot pattern of column) is disposed repeatedly three times. The preparation of compression information CI will be explained more in detail hereinafter. As shown in FIG. 1A, there are obtained coincidence in the dot pattern between 3rd and 4th columns, 5th to 10th columns, 13th and 14th columns, and 15th to 17th columns. Consequently, regarding the respective leading columns of the coincident groups of columns, that is, 3rd column, 5th column, 13th column and 15th column, since the dot patterns of their columns are stored in a memory, the corresponding contents of compression information CI are given by "0", respectively. In other words, 2nd bit, 4th bit, 12 bit and 14bit of compression information CI are set to the content "0", respectively. On the other hand, regarding 4th column, 6th to 10th columns 14th column and 16th to 17th columns the corresponding contents of compression information CI are given by "1", respectively. In other words, 3nd bit, 5th bit to 9th bit, 13 bit, 15 bit and 16 bit of compression information CI are set to the content "1", respectively. Regarding columns on which the same dot pattern does not continue, that is. 2nd column, 11th column and 12th column, the corresponding contents of compression information CI are given by "0", respectively. In other words, 1st bit 10th bit and 11 bit of compression information CI are set to the content "0", respectively. Next, compression of the dot pattern will be explained, referring to FIG. 1B. In the figure, a longitudinal direction designates a row number and a lateral direction designates a column number, wherein the numerals between the parentheses in the lateral direction designates a column number in FIG. 1A. FIG. 1B shows a status in which individual columns are compressed based on the above explained compression information CI. There are retained 1st column and only columns on which the corresponding contents of compression information CI are given by "0", respectively. In other words, compressed or suppressed are columns on which the corresponding contents of compression information CI are given by "1", respectively. Consequently, as shown in FIG. 1B there is prepared a dot pattern of length: 17 dots x breadth: 8 dots, that is, 17 rows x 8 columns. To more specifically describe it, first, the 1st column is unconditionally stored in a memory and be retained. Next, taking notice of 1st bit of compression information CI corresponding to 2nd column, the corresponding content is given by "0" and 2nd column, FIG. 1B, is retained without compression. Similarly, taking notice of 2nd bit of compression information CI corresponding to 3nd column, the corresponding content is given by "0" and 3rd column, FIG. 1B, is retained without compression. Further, taking notice of 3rd bit of compression information CI corresponding to 4th column, the corresponding content is given by "1", that, is 4th column is coincident with 3rd column in the dot pattern and it is compressed. Hereinafter, on a similar basis, taking notice of 4th bit to 16th bit of compression information CI corresponding to 5th column to 17 column, respectively, performed is such a processing that the column of interest is retained to be stored in the memory or it is compressed. FIGS. 4A and 4B are diagrams used for the explanation of the memory storage according to the present invention. In the figures, a longitudinal direction designates the bit number of 8 bits, and a lateral direction designates the address number, wherein the number between parentheses "( )" in the longitudinal direction designates the row number in case of expansion being performed, and the number between parentheses "( )" in the lateral direction designates the column number in FIG. 1A, or the column which is stored in the memory without compression. The number in parentheses "( )" in the longitudinal direction shifts in the row number depending on a presence or absence of a shift designation bit, or the situation as to whether or not the shift designation bit has been reset. In FIG. 4A, it is separated into two cases in one of which 1st row to 13th row are shown, and in another of which 5th row to 17th row are shown. In FIG. 4B, it is separated into two cases in one of which 2nd row to 14th row are shown, and in another of which 6th row to 16th row are shown. In a case where 6th row to 16th row are shown, 7th bit is not used, on other words, there is no such an occasion that data related to the printing dot is stored. FIGS. 4A and 4B show a status in which a dot pattern is actually stored. In the storage of the dot pattern, to provide a simple driving of the printing head, there is given such a processing that 17 rows are divided into two groups one of which consists of odd-numbered rows another of even-numbered rows. In the processing, it may be employed such a manner that the individual odd-numbered rows and the individual even-numbered rows are represented with 8 bits, respectively, as disclosed in Japanese Patent-Laid Open Gazette 78758/1985, for example. According to such a manner, one bit of 8 bits is used for a shift designation bit, and the remaining 7 bits are used for representation of a dot pattern. For example, in case of a dot pattern corresponding to the odd-numbered rows shown on FIG. 4A, if the shift designation bit is reset (content 0), printing dots marked by the dark circles 100 on 1st row, 3rd row, ... 13th row are represented, on the other hand, if the shift designation bit is set (content 1) printing dots, designated by the dark triangles 108, on 5th row, 7th row ... 17th row are represented. That is, in a case where the shift designation bit is set, a dot pattern of 7 bits is shifted by 2 bits. Also regarding a dot pattern of the even-numbered rows shown in FIG. 4B, it is similarly applicable. To more specifically explain, by way of example, such a case that a printing head provided with 9 printing wires is driven, data of 7th bit of the dot pattern of 7 bits is utilized for driving of 7th printing wire, if the shift designation bit has been reset. On the other hand, if the shift designation bit has been set, data of 7th bit of the dot pattern of 7 bits is utilized for driving of 9th printing wire. Thus, suitable selection of the content of the shift designation bit makes it possible to readily perform driving of 9 printing wires or stylus. Further, it is possible to perform storage of the dot pattern into the memory in units of bytes which permit data to be readily treated. Individual columns of information, each consisting of 8 bits, are stored in units of bytes in addresses [1] to [8], on odd-numbered rows, and in addresses [1] + k to [8] + k, on even-numbered rows, where k is a constant. In the figures, those addresses are represented by numbers encircled. For instance in a case where a group of dot patterns ofodd-numbered rows and a group of dot patterns ofeven-numbered rows are consecutively stored, if the dotpatterns of odd-numbered rows are stored in addresses 1000 to 1999, then k equals 1000. Thus, storage of the dot patterns of even-numbered rows is initiated from address 2000. Compression information CI is preserved in a table, referring to which in order to obtain a position on a memory in which a dot pattern corresponding to a desired character is stored, in a pair relation with a memory address provided on each character. A method of compression of the present invention is effected in accordance with the procedure as explained above. Next, a method of expansion of the present invention will be explained hereinafter. In a processing for expansion, from limitation on driving of a printing head, first, carried out are an expansion of dot patterns on the odd-numbered rows as explained in FIG. 4A and the printing, and thereafter an expansion of dot patterns on the even-numbered rows and the printing are carried out. Explained hereinafter would be, by way of example such a case that the expansion of dot patterns on the odd-numbered rows is performed, referring to FIGS. 5A and 5B, 6 and 7. FIGS. 5A and 5B are flow charts related to a method of expansion according to the present invention. FIG. 6 is a diagram used for the explanation of expansion according to the present invention. Described hereinafter would be, by way of example, such a case that data each consisting of 8 bits, 8 rows, which are explained with reference to FIG. 4A, are sequentially read out and expanded. In explanation of FIGS. 5A and 5B, it is assumed that various counters and flags are provided in RAM 3 of FIG. 2. First, it is determined as to whether a dot pattern to be printed (expanded) is a dot pattern on the odd-numbered row (step 1). If a result is "yes", the procedure goes to step 2 in which an address counter ADRCT (1) is set with address [1], FIG. 4A. The address [1] is an address of a memory, or a first address of a memory area in which a dot pattern of a desired character to be read out is stored. In step 3, a compression information register CIREG stores compression information CI, an address counter ADRCT (2) stores a predetermined address, or a first address of a memory area on RAM 3 in which an expanded dot pattern is stored, and column counter CLMCT is set with "17". The column counter CLMCT determines as to whether a character of expansion processing has been completed, and is set with "17", since a final column of a character corresponding is here 17th column. Next, in step 4, referring to the address counter ADRCT (1), a byte of data are read out from a memory to perform a separation of a dot pattern (7 bits) and a shift designation bit (1 bit), and upon adding 9th bit of the content "0" to the lower bit of the dot pattern, the dot pattern is stored in a data register DTREG, while the content of the shift designation bit is set to a flag FLG (1). In step 5, the content of the address counter ADRCT (1) is increased. In step 6, it is determined as to whether the content of the the flag FLG (1) is "1". If a result is "yes", the procedure goes to step 7 in which the content of the data register DTREG is shifted by 2 bits in a lower bit direction. And referring to the address counter ADRCT (2). the content of the data register DTREG is written in RAM 3 (step 8). In step 9, the content of the address counter ADRCT (2) is renewed ( number "2" is added because storage is performed bridging 2 addresses). In step 10, the content of the column counter CLMCT is decreased, and in step 11 it is determined as to whether the content of the column counter CLMCT is "0". If a result is "yes", the processing involved in the dot patterns on the odd-numbered rows is terminated. Meanwhile, if the result is "no", the procedure goes to step 12 in which the content of the compression information register CIREG is shifted by one bit and then be set to a flag FLG (2). In step 13, it is determined as to whether the content of the flag FLG (2) is "1". If a result is "yes", the procedure goes back to step 8 to perform preparation of a row of the same dot pattern. On the other hand, if the result is "no", the procedure goes back to step 4 to perform reading out of new data. If the result of step 1 is "no", the procedure goes to step 14 in which an address counter ADRCT (1) is set with address [1] + k (FIG. 4B), and then goes to step 3. Such a processing as stated above is continued until the content of the column counter CLMCT becomes "0", so that the dot pattern as shown in FIG. 6 is prepared. While the individual column consists of 16 dots, the actual dots to be supplied to the printing head are upper 9 dots. That is, uppermost dot is utilized for driving of 1st printing wire to perform a printing of 1st, row the next dot is utilized for driving of 2nd printing wire or stylus to perform a printing of 3rd row. Thus, 9th dot is utilized for driving of 9th printing wire to perform a printing of 17th row. In the dot pattern shown in FIG. 6, there are mixed the printing dots marked with dark circles 100 and the dummy printing dots designated by white or blank circles 102. Thus, it is necessary to perform a processing in which the dummy printing dots or white circles 102 are deleted. Now, referring to FIG. 7, there will be explained such a processing for deletion of the dummy printing dots. FIG. 7 is a block diagram related to a method of expansion according to the present invention. In the figure, there are shown storage device 10, NOT gate or inverter 11 and AND gate 12, as well as RAM 3 and I/O driver 4 as explained with reference to FIG. 2. The storage device 10, NOT gate 11 and AND gate 12 may be realized by an internal register of CPU 1, or execution of a program sequence stored in ROM 2 by CPU 1 itself. An output of the storage device 10 is connected to the NOT gate 11, and an output of the NOT gate 11 is connected to an input A of the AND gate 12. An output of the AND gate 12 is connected to inputs of RAM 3 and the storage device 10. An output of the RAM 3 is connected to an input B of the AND gate 12 and the I/O driver 4. Now it is assumed that all of the signals, which are transmitted through the respective ones of the circuits and the devices of the structure as mentioned above, are given in units of 9 bits. Consequently, the storage device 10 is provided with a storage capacity of 9 bits basis, and the NOT gate 11 and the AND gate 12 perform logical operations of NAND/NOR and AND, respectively. Under an initial condition, all the contents of the storage device 10 have been set to "0". Under this condition, first, data of the upper 9 dots on 1st column shown in FIG. 6 is read out from RAM 3 and be entered to the input B of AND gate 12. On the other hand, data of 9 bits of all the contents "1" inverted in NOT gate 11 is entered to the input A of AND gate 12, and thus the same data as entered to the input B is delivered from the output of AND gate 12. The data from the output of AND gate 12 is stored in the storage device 10 as well as an area on RAM 3 from which the previous 9 bits of data was read out. In the similar manner, when data of the upper 9 dots on 2nd column shown in FIG. 6 is read out from RAM 3 data of the content "1" on 8th dot is delivered from the output of AND gate 12. The data from the output of AND gate 12 is stored in the storage device 10 as well as RAM 3. Next, when data of the upper 9 dots on 3rd column shown in FIG. 6 is read out from RAM 3, data of the contents "0" of 9 dots is entered to the input B of AND gate 12. On the other hand, data of the content "0" on 8th dot is entered to the input A of AND gate 12, and thus the data of the contents"0" of 9 bits is delivered from the output of AND gate 12. The data from the output of AND gate 12 is stored in the storage device 10 as well as RAM 3. The fourth column shown in FIG. 6 is also subjected to the similar processing to that as stated on 3rd column, and thus the data of the contents "0" of 9 bits is delivered from the output of AND gate 12. The data from the output of AND gate 12 is stored in the storage device 10 as well as RAM 3. When data on 5th column shown in FIG. 6 is read out from RAM 3, data of the contents "1" on 3rd and 9th dots is delivered from the output of AND gate 12. And when data on 6th column shown in FIG. 6 is read out from RAM 3, data of the contents "1" on 3rd and 9th dots is entered to the input B of AND gate 12. On the other hand, data of the contents "0" on 3rd and 9th dot is delivered from the output of NOT gate 11 and be entered to the input A of AND gate 12, and thus the data of the contents "0" of 9 bits is delivered from the output of AND gate 12. Thus, the dummy printing dot, marked a blank circle 102, on 6th column has been deleted. Hereafter similarly, the dummy printing dots or white circles 102 on 8th, 10th, 12th and 14th columns are deleted. When the processing as stated above is completed up to 17th column, the expansion processing is completely terminated, and thereafter the dot pattern is transferred from RAM 3 to I/O driver 4, so that a predetermined printing is performed. In a case where for example, 215 sets of dot patterns designated by ASCII codes, or 215 characters, are stored in a memory by applying any methods of compression and expansion of the dot patterns, if applying, for example, such a conventional compression method that one character or set is compressed to data of 17 columns of 16 bits (i.e. 272 bits) upon simply providing a shift designation bit, then a storage capacity needs 7310 (215 x 272) bytes. On the other hand, if applying the methods of compression and expansion of a dot pattern according to the present invention as stated above it is possible to compress 1082 columns in total of 215 sets of dot patterns. If this is expressed by the amount of data, it may be given by the equivalence "1082 x 16 bits = 3604 bytes" (including the shift designation bit). Additional amount of data as information for indicating memory addresses to indicate the storage locations for the compression information CI and 215 sets of dot patterns needs 4 bytes for each set (one character) of dot pattern, and thus in total 860 (215 x 4) bytes. Therefore, a compression ratio in case of application of the present invention is given by the following equation: Thus, it is sufficient for the present invention to prepare about 63% of storage capacity of a memory comparing with a conventional one. According to the methods of compression and expansion of a dot pattern according to the present invention as stated above, there is provided such a situation that dummy printing dots, are added to form the consecutive printing dots even in the dot patterns which are arranged in such a manner that two or more printing dots do not continue in a main scanning direction, and thus it is possible to easily improve effect of the compression. Further, also in the expansion, it is possible to easily delete the dummy printing dots.

Claims: A method of compression of a dot pattern, wherein a dot pattern which is arranged in such a manner that two or more printing dots do not continue in a main scanning direction, is compressed and stored in a memory, while data read out from said memory is subjected to an expansion processing to obtain an original dot pattern, so that a printing is performed, CHARACTERIZED IN THAT dummy printing dots (102, 104) are inserted into rows of the printing dots arranged in the main scanning direction in such a manner that column of dummy printing dots are generated early corresponding to the respective preceeding column of printing dots, and the dot pattern is compressed based on the columns (2nd to 17th columns in FIG. 1A) of the printing dots and the dummy printing dots repeating said printing dots in the following column and associated information (CI in FIG. 1A) indicating said repetition is stored in said memory. A method of compression of a dot pattern according to claim 1, CHARACTERIZED IN THAT while the dot pattern (FIG. 1A) consists of 17 dots in column x 17 dots in row arranged in a matrix configuration to represent characters the dot pattern (FIG. 1B) is given by 8 dots in column x 17 dots in row arranged in a matrix configuration when compressed. A method of compression of a dot pattern according to claim 2, CHARACTERIZED IN THAT 17 rows are divided into two groups one of which consists of odd-numbered rows (FIG. 4A), another of even-numbered rows (FIG. 4B). A method of expansion of a dot pattern compressed according to claim 1 wherein, data read out from said memory is subjected to an expansion processing to obtain an original dot pattern, so that a printing is performed. CHARACTERIZED IN THAT a dot pattern (FIG. 6) including dummy printing dots (102) is prepared (RAM 3 in FIG. 2, FIGS. 5A and 5B) based on the columns of the printing dots, which are read out from said memory means, arranged in a subscanning direction substantially perpendicular to the main scanning direction, and associated information (CI in FIG. 6) indicating repetition of the disposition of the columns of the printing dots in the main scanning direction, and part of the printing dots is deleted (3, 10, 11, 12 in FIG. 7) if so arranged that two or more printing dots including the dummy printing dots continue in the main scanning direction, so that the dot pattern is restored in such a manner that two or more printing dots do not continue in the main scanning direction. A method of expansion of a dot pattern according to claim 5, CHARACTERIZED IN THAT said part of the printing dots includes the dummy printing dots, and deletion of the dummy printing dots is performed by logical operation in units of 9 bits.

Inventors: ITO TOSHIKAZU C O OKI ELECTRIC, ITO, TOSHIKAZU, C/O OKI ELECTRIC INDUSTRY CO.,LTD.
Applicants: OKI ELECTRIC IND CO LTD, OKI ELECTRIC INDUSTRY CO., LTD.
Application year: 1991
Main classification: G06K15
IPC codes: B41J2, H04N1, G06K15