A method for batch generating vector fonts from handwriting and written text

By converting handwriting into electronic information text and unified conversion into vector graphics, the problem of manpower and time consumption in the process of converting handwriting into vector fonts is solved, and a real writing experience and efficient automation of vectorization process is realized.

CN112084745BActive Publication Date: 2025-02-07BEIJING MOUKE TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202010962854.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2020-09-14
Publication Date
2025-02-07
Estimated Expiration
2040-09-14

AI Technical Summary

Technical Problem

In the prior art, the process of converting handwriting into vector fonts requires a lot of manpower and time, and the writing experience is not realistic.

Method used

By providing a method of batch generating vector fonts by handwriting, it includes converting the written text into electronic information text, obtaining a single font dot matrix diagram, and uniformly converting it into a vector diagram. This method uses calibration marks and identification markers for calibration and segmentation to realize automated text segmentation, vectorization and formation of vector files.

Benefits of technology

It realizes the writer's real writing experience, and efficiently and automatically completes the steps of inputting the writing content into the electronic device and completing the text segmentation, vectorization and forming vector files, reducing manpower and time consumption.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN112084745B_ABST
    Figure CN112084745B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for batch generating vector fonts from handwriting and written text, belonging to the field of terminal technology, including: providing a written text; converting the written text into an electronic information text; obtaining a single font dot matrix through the electronic information text; and uniformly converting the single font dot matrix into a vector map. This technical solution can not only realize the writer's real writing experience, but also efficiently and automatically complete the steps of inputting the written content into an electronic device and completing the steps of text segmentation, vectorization, and forming a vector file.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of terminal technology, and more specifically, relates to a method for batch generating vector fonts from handwriting and written text. Background Art

[0002] With the rapid development of mobile terminal technology, the functions of mobile terminals such as mobile phones and tablet computers have been continuously improved, and have gradually become one of the commonly used tools in people's daily life and work.

[0003] Currently, there are two input methods for converting handwriting into vector fonts:

[0004] 1. The writer directly inputs his handwriting into the computer through a tablet computer or computer handwriting tablet to generate fonts. The writer's writing experience and habits when inputting on a tablet computer or computer handwriting tablet are very different from those when writing directly on paper media, which makes it impossible for the writer to display his normal writing level, resulting in unsatisfactory font effects when input into the computer.

[0005] 2. After writing the text, the writer needs to manually scan the text content written on the paper medium and input it into the computer. Finally, the input image needs to be cut, vectorized, adjusted and other operations on the computer to finally generate the font. In this way, a lot of human participation is required in the process of scanning the text written on the paper medium into the computer. The text image input into the computer also needs to be corrected, cut, vectorized and other manual steps, which is relatively time-consuming. Summary of the invention

[0006] The purpose of the present invention is to provide a method for batch generating vector fonts from handwritten handwriting and written text, at least to solve the technical problem that the writer needs to spend a lot of manpower and time in the process of batch converting handwritten handwriting text into vector fonts.

[0007] In order to achieve the above object, the present invention provides a method for batch generating vector fonts from handwritten traces, comprising:

[0008] Providing a written text;

[0009] Converting the written text into electronic information text;

[0010] Acquire a single font dot matrix image through the electronic information text;

[0011] The individual font bitmap images are uniformly converted into vector images.

[0012] Furthermore, the written text is divided into single pages to generate single-page electronic information text.

[0013] Further, obtaining a single font dot matrix image through the electronic information text includes:

[0014] Calibrate the single page of electronic information text to generate a standard electronic information text;

[0015] The standard electronic information text is segmented to obtain a single font dot matrix image.

[0016] Furthermore, the single font dot matrix image is uniformly converted into a vector image, including:

[0017] Image shifting, uniformly shifting the font dot matrix image;

[0018] Binarization of black and white, setting the gray value of the font dot matrix image to 0 or 100;

[0019] Adjust parameters to uniformly convert the font bitmap into a vector map.

[0020] Furthermore, calibrating the single page of electronic information text includes:

[0021] Position calibration is performed by setting calibration marks on the written text.

[0022] Further, the calibration mark includes:

[0023] The calibration graphics and identification marks are used to segment the standard electronic information text through the identification marks to obtain a single font dot matrix image.

[0024] Furthermore, the identification mark records the text characters, page number and other contents of the single page of electronic information text.

[0025] Furthermore, a text grid is provided on the written text, and a prompt mark is provided above the text grid, and the prompt mark corresponds one-to-one with the text to be written into the text grid.

[0026] The present invention also provides a handwritten handwriting batch-generated vector font written text, which is used in any of the above methods, including: a calibration mark is provided on the written text.

[0027] Further, the calibration mark includes:

[0028] Calibration graphics and identification markers.

[0029] Beneficial effects of the present invention:

[0030] By providing a written text, the written text is converted into an electronic information text; a single font dot matrix image is obtained through the electronic information text, and the single font dot matrix image is uniformly converted into a vector image. This technical solution can not only realize the writer's real writing experience, but also efficiently and automatically complete the steps of inputting the written content into the electronic device and completing the text segmentation, vectorization and forming a vector file.

[0031] Furthermore, a calibration mark is provided on the written text, which can have a good calibration effect in the subsequent process.

[0032] Other features and advantages of the present invention will be described in detail in the following detailed description. BRIEF DESCRIPTION OF THE DRAWINGS

[0033] The above and other objects, features and advantages of the present invention will become more apparent through a more detailed description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, wherein like reference numerals generally represent like components throughout the exemplary embodiments of the present invention.

[0034] Figure 1 A flow chart showing a method for batch generating vector fonts by handwriting is shown;

[0035] Figure 2 The present invention shows a structural schematic diagram of batch generation of vector font written texts by handwriting.

[0036] Figure symbols: 1. Written text; 2. Square; 3. QR code; 4. Prompt mark; 5. Text grid. DETAILED DESCRIPTION

[0037] The preferred embodiments of the present invention will be described in more detail below. Although the preferred embodiments of the present invention are described below, it should be understood that the present invention can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided to make the present invention more thorough and complete, and to fully convey the scope of the present invention to those skilled in the art.

[0038] Example 1

[0039] refer to Figure 1 The present invention provides a method for batch generating vector fonts from handwritten handwriting, comprising:

[0040] S01: Provide a written text;

[0041] S02: Convert written text into electronic information text;

[0042] S03: Obtaining a single font dot matrix image through the electronic information text;

[0043] S04: Convert individual font bitmaps into vector images.

[0044] Execute step S01: provide a written text.

[0045] The written text can be paper for printing, and the material can be coated paper, kraft paper, white cardboard, etc. The material used in this technical solution is coated paper. It should be noted that this technical solution has no requirements on the material of the written text, and anything that can be written on it can be used.

[0046] In addition, a text grid is provided on the written text, and a prompt mark is provided above the text grid, and the prompt mark corresponds one by one to the text to be written into the text grid.

[0047] Prompt marks are set on the text box so that the writer can write according to the prompt marks during the writing process.

[0048] Execute step S02: convert the written text into electronic information text.

[0049] Specifically, the technical solution is to divide the written text into single pages, and convert them into single-page electronic information text through an electronic device. The electronic information text is an image, which can be in jpg format or png format, etc. The electronic device can be a computer, and of course it can also be other electronic devices. As long as the device can convert the written text into electronic information text, there is no limitation here.

[0050] Execute step S03: obtain a single font dot matrix image through the electronic information text.

[0051] Specifically, a single font dot matrix image is obtained through the electronic information text, including:

[0052] Calibrate a single page of electronic information text to generate a standard electronic information text;

[0053] Segment the standard electronic information text to obtain individual font dot matrix images;

[0054] Calibrating a single page of electronic information text includes: performing position calibration by setting a calibration mark on the written text, the calibration mark includes a calibration graphic and an identification mark, and the calibration graphic and the identification mark are aligned up and down in this embodiment, which can improve the accuracy of the calibration. It should be noted that there is no restriction on the positional relationship between the calibration graphic and the identification mark. The main function of the calibration mark is that when the electronic information text undergoes geometric transformation, including processes such as rotation, scaling, and four-corner transformation, the shape and position of the calibration graphic and the identification mark meet the expected settings, which can improve the accuracy of the calibration. Among them, the calibration figure can be a square, rectangle or other figure that can play a calibration role, and there is no restriction here; the identification marker records the text characters, page number and other contents of the single-page electronic information text. In this embodiment, the identification marker is a QR code. By identifying the QR code, the text characters, page number and other contents of the single-page electronic information text can be known. It should be noted that the information recorded in the QR code is the content of the current page of the single-page electronic information text. Therefore, the content of each single-page electronic information text is different, and the content recorded in the QR code is also different; the standard electronic information text is segmented by the identification marker to obtain a single font dot matrix map. By segmenting the standard electronic information text by the identification marker, the font corresponding to the cut font dot matrix map can be identified.

[0055] In this embodiment, calibration marks of squares 2 and QR codes 3 are provided on the written text 1. There are two squares 2, which are located on both sides above the written text 1 and are symmetrically arranged. The QR code 3 is located directly below one of the squares 2 and on one side of the written text 1. By setting the calibration marks, the accuracy of calibration can be improved.

[0056] Execute step S04: convert the single font bitmap into a vector map.

[0057] Convert individual font bitmaps into vector graphics, including:

[0058] Image offset, uniformly offset the font dot map;

[0059] Black and white binary conversion, set the gray value of the font bitmap to 0 or 100;

[0060] Black and white binarization is to set the grayscale value of the pixels on the image to 0 or 100, that is, to make the entire image appear to be only black and white.

[0061] Adjust the parameters to uniformly convert the font bitmap into a vector map;

[0062] The bitmap can be converted into a vector map by adjusting the parameters. The operation can be performed in batches. By adjusting the parameters, the font bitmap can be adjusted uniformly. For example, the font bitmap can be uniformly expanded, sharpened, etc. to turn it into the required vector map, and then the vector map can be saved as a vector file.

[0063] The image is corrected based on the relative positions of the calibration mark and the QR code, and the segmentation actions for the corrected electronic information text are also fixed, so the entire calibration, segmentation and binarization process is automatic.

[0064] For example, suppose there are 100 uncalibrated electronic information texts in a folder called "origin". The following command is executed through the software: autocutter -i origin -o cutted -t100. After entering this command, the electronic information texts in the origin folder will be automatically calibrated, segmented and binarized. The results of the segmentation and binarization will be saved in the "cutted" folder. It should be noted that the software does not impose any restrictions here, and any software that can automatically complete the above operations can do it.

[0065] This technical solution can not only realize the writer's real writing experience, but also efficiently and automatically complete the steps of inputting the written content into the electronic device and completing the text segmentation, vectorization and forming vector files.

[0066] Example 2

[0067] refer to Figure 2 A method for batch-generating vector font written texts from handwritten handwriting, used in the method of embodiment 1, comprises:

[0068] A writing text 1 is provided with a plurality of character grids 5 , and a writer writes the characters to be written into the character grids 5 .

[0069] The calibration mark is used for subsequent font calibration operations; the calibration mark includes a square 2 and a QR code 3. There are two squares 2, which are located on both sides above the written text 1 and are symmetrically arranged. The QR code 3 is located directly below one of the squares 2 and on one side of the written text 1. The text characters, page number and other contents of a single-page electronic information text can be known by identifying the QR code. The information recorded in the QR code is the content of the current page of the single-page electronic information text. Therefore, the content of each single-page electronic information text is different, and the content recorded in the QR code is also different. It should be noted that there is no restriction on the positional relationship between the square 2 and the QR code 3. The main function of the calibration mark is that when the electronic information text undergoes geometric transformation, including processes such as rotation, scaling, and four-corner transformation, the shape and position of the square and the QR code meet the expected settings, which can improve the accuracy of the calibration.

[0070] The prompt mark 4 is arranged above the character grid 5 and corresponds one-to-one with the characters to be written in the character grid 5. The prompt mark 4 corresponds to the characters to be written in the character grid 5, and the writer writes according to the prompt mark.

[0071] The embodiments of the present invention have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and changes will be apparent to those skilled in the art without departing from the scope and spirit of the described embodiments.

Claims

1. A method for batch generating vector fonts from handwriting, characterized in that: include: Providing a written text; Converting the written text into electronic information text; Acquire a single font dot matrix image through the electronic information text; Convert the single font dot matrix image into a vector image; The step of obtaining a single font dot matrix image from the electronic information text comprises: segmenting each standard electronic information text based on the identification mark set on the written text to obtain a single font dot matrix image; the identification mark records the text characters and page number contained in a single page of electronic information text; the standard electronic information text is generated based on the single page of electronic information text converted from the written text; The single font bitmap is uniformly converted into a vector map, including: Image shifting, uniformly shifting the font dot matrix image; Binarization of black and white, setting the gray value of the font dot matrix image to 0 or 100; Adjust parameters to uniformly convert the font dot map into a vector map, wherein the adjustment parameters include at least one of the following: font expansion and sharpness.

2. The method for batch generating vector fonts from handwritten handwriting according to claim 1, characterized in that: The written text is divided into single pages to generate single-page electronic information text.

3. The method for batch generating vector fonts from handwritten handwriting according to claim 2, characterized in that: Obtaining a single font dot matrix image through the electronic information text includes: Calibrate the single page of electronic information text to generate a standard electronic information text; The standard electronic information text is segmented to obtain a single font dot matrix image.

4. The method for batch generating vector fonts from handwritten handwriting according to claim 3 is characterized in that: Calibrate the single page of electronic information text, including: Position calibration is performed by setting calibration marks on the written text.

5. The method for batch generating vector fonts from handwritten handwriting according to claim 4 is characterized in that: The calibration mark includes: The calibration graphics and identification marks are used to segment the standard electronic information text through the identification marks to obtain a single font dot matrix image.

6. A method for batch generating vector fonts from handwritten handwriting according to any one of claims 1 to 5, characterized in that: A text grid is provided on the written text, and a prompt mark is provided above the text grid, and the prompt mark corresponds one-to-one with the text to be written into the text grid.

7. A method for batch-generating vector font written texts from handwritten handwriting, used in the method according to any one of claims 1 to 5, characterized in that: include: The written text is provided with a calibration mark; The calibration mark includes: a calibration graphic and an identification mark.

Citation Information

Patent Citations

  • Method and system for fast making vector font library

    CN103488711A

  • A typesetting method and a typesetting system for calligraphy character images

    CN109670069A