Claims
- 1. A character image data compression method for compressing matrix-type binary data having data elements formed in lines and in combination corresponding to a two-directional character image comprising the steps of:
- detecting the occurrence or non-occurrence of a character image segment in each data element of the matrix in each line;
- identifying a contact state in a vertical direction of said character image segment, by comparison of data in adjacent lines; and
- producing an output comprising a control code corresponding to said contact state, and variable length coded data corresponding to information of respectively different types in accordance with the type of contact state, said control code being applicable to all of said states,
- wherein the contact state in a vertical direction of said character image segment, is identified as any one of the following modes: an insertion mode (INS) in which no contact segment exists in a previous line, a simple contact different mode (DIF) in which one segment in the previous line contacts to one segment in a present line, a join mode (JOIN) in which a plurality of segments in the previous line contact to one segment in the present line, a fork mode (FORK) in which one segment in the previous line contacts to a plurality of segments in the present line, a join-fork mode (J-F) in which a plurality of segments in the previous line contact to a plurality of segments in the present line, and a deletion mode (DEL) in which no contact segment exists in the present line, and the encoded information includes a control code corresponding to the contact state, and also
- (a) information regarding a length (M) of a background portion prior to said segment and a length (N) of said segment in a case where said contact state corresponds to the insertion mode (INS),
- (b) information regarding difference amounts (S;D) at each end of respective contact segments and/or repeat number (K) of said simple contact difference mode of the succeeding lines, and/or polarity information (Ps;Pd) applying positive and negative polarities to said difference amounts (S;D) in a case where said contact state corresponds to the simple contact difference mode (DIF),
- (c) information regarding a number (Q) of segments to be joined and difference amounts (S;D) between extreme ends of a plurality of segments to be joined and ends of one joined segment, and polarity information (Ps;Pd) regarding said difference amounts (S;D) in a case where said contact state corresponds to the join mode (JOIN),
- (d) information regarding a number (Q) of forked segments and run-lengths (Mq;Nq) of formed segments in a case where said contact state corresponds to the fork mode (FORK), or
- (e) information regarding a number (Qj) of segments to be joined, the number (Qf) of the forked segments, and run-lengths (Mqf;Nqf) of said forked segments in a case where said contact state corresponds to join-fork mode (J-F), but when the contact state corresponds to the deletion mode, onlly a deletion mode control code (DEL) is produced.
- 2. An image-data compression method according to claim 1, in which, when the said contact state corresponds to the insertion mode (INS), insertion mode control codes different from one another are produced in accordance with the length N of said segment and one of two insertion mode control codes or may be produced in accordance with a case where said length N of the segment is below "63" or where said length of the segment is over "64".
- 3. An image data compression method according to claim 1, wherein a case where said discriminated result of said contact state corresponds to the simple contact difference mode (DIF), difference mode control codes different from one another are outputted in accordance with said difference amounts (S;D).
- 4. An image data compression method according to claim 3, wherein, in the case where said difference amounts (S;D) are both "0", only a difference 0 mode control code is produced together with coded data regarding repeat number (K) of said simple contact difference mode in the succeeding lines.
- 5. An image data compression method according to claim 3, wherein the case where said difference amounts (S;D) are both "1" or less, or "3" or less, a difference mode control code or (DIF-1) or (DIF-3) is produced together with coded data regarding information of repeat number (K) of said simple contact difference mode in succeeding lines and difference amounts (Sk;Dk) of respective segments in the succeeding lines corresponding to said repeat number (K) and polarity information (Ps;Pd) of said difference amounts (Sk;Dk), and only one type of said polarity information (Ps;Pd) is applied commonly to said difference amounts (Sk;Dk) of said segment in the succeeding lines.
- 6. An image data compression method according to claim 3, wherein in the case where either of said difference amounts (S;D) is "4" or more, a difference mode control code is produced together with coded data regarding information of said difference amounts (S;D) and polarity information (Ps;Pd) of said difference amounts (S;D).
- 7. An image data compression method according to claim 6, wherein control codes different from one another are produced in accordance with values of said difference amounts (S;D) and any one of "difference 4" mode control codes, and is produced in accordance with any one of cases where said difference amounts (S;D) are "7" or less, "8-15", or "16" or more.
- 8. An image data compression method according to claim 1, wherein in a case where said contact state corresponds to the simple contact difference mode satisfying a condition that said difference amounts (S;D) are both "3" or less, any one of difference mode control codes, and is selected in accordance with a condition of generation of the contact state satisfying said difference amount condition in the following line and the selected control code is produced together with said coded data coincident with said selected control code.
- 9. An image data compression method according to claim 1, in which in a case where said contact state corresponds to any one of said join mode, said fork mode, and said join-fork mode, there is coded a value obtained by substracting "2" from the number of segments to be actually joined or forked.
Priority Claims (1)
Number |
Date |
Country |
Kind |
56-211909 |
Dec 1981 |
JPX |
|
Parent Case Info
This application is a continuation, of application Ser. No. 372,151, filed Apr. 27, 1982, now abandoned.
US Referenced Citations (3)
Continuations (1)
|
Number |
Date |
Country |
Parent |
372151 |
Apr 1982 |
|