Image forming method and device, and storage medium
By obtaining and processing the printer's job parameters and generating target pages, the problem of limited types of existing printers in all-in-one printing functions is solved, user-defined all-in-one printing is realized, and paper utilization is improved.
Patent Information
- Application Number
- CN202411686974.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-22
- Publication Date
- 2025-04-15
- Estimated Expiration
- 2044-11-22
AI Technical Summary
Existing printers only support limited types in all-in-one printing functions, such as two-in-one, four-in-one, eight-in-one and sixteen-in-one, which cannot meet users' needs for other multiple all-in-one types.
By obtaining the original job parameters of the original page and the target job parameters of the target page, the layout information of the sub-images in the original page and the sub-images in the target page is determined, and the target page is generated and printed.
It realizes the conversion of the original all-in-one manuscript into a user-defined all-in-one manuscript, which meets the user's imaging needs for a variety of all-in-one types, and automatically selects the best layout solution to maximize the utilization of paper area.
Smart Images

Figure CN119821013A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of image forming technology, and in particular to an image forming method, device and storage medium. Background Art
[0002] Currently, many printers support the multi-in-one printing function, that is, automatically scaling multiple pages into one page and printing them on one sheet of paper. However, multi-in-one printing usually only supports 2-in-1, 4-in-1, 8-in-1, and 16-in-1 types, and cannot meet users' imaging needs for other types of multi-in-one, or, for each existing type of multi-in-one, cannot meet users' imaging needs for other different arrangements of the multiple sub-pages contained therein. Summary of the invention
[0003] In view of this, the present application provides an image forming method, device and storage medium for converting existing all-in-one type originals and regenerating them into user-defined all-in-one type manuscripts, thereby meeting the user's imaging needs for various all-in-one types.
[0004] In a first aspect, an embodiment of the present application provides an image forming method, comprising: obtaining original job parameters of an original page and target job parameters of a target page to be generated, wherein the original job parameters include at least original all-in-one type information, and the target job parameters include at least target all-in-one type information different from the original all-in-one type information; determining, based on the original job parameters, each original sub-image contained in the original page; determining, based on the target all-in-one type information, target layout information of each target sub-image in the target page to be generated; determining, based on the target layout information and each original sub-image, each target sub-image of the target page to be generated; and generating the target page using the each target sub-image and printing it.
[0005] In a possible implementation, the original job parameters also include a scanning source and an original arrangement direction of each original sub-image in the original page, and determining each original sub-image contained in the original page based on the original job parameters includes: scanning the original page to obtain a scanned image; determining the original layout information of the original page based on the scanning source, the original all-in-one type information and the original arrangement direction; and determining each original sub-image from the scanned image based on the original layout information.
[0006] In a possible implementation, target layout information of each target sub-image in the target page to be generated is determined according to the target all-in-one type information, including: according to the target all-in-one type information and in accordance with an arrangement logic strategy, a number of candidate layout information of each target sub-image in the target page to be generated is determined; and candidate layout information that meets preset conditions is selected from the several candidate layout information as the target layout information.
[0007] In a possible implementation, based on the target all-in-one type information and in accordance with an arrangement logic strategy, several candidate layout information of each target sub-image in the target page to be generated is determined, including: based on the target all-in-one type information, determining the number of each target sub-image in the direction of the first target edge in the target page to be generated; based on the number of each target sub-image in the direction of the first target edge and the aspect ratio of the original sub-image, determining several groups of candidate sizes of each target sub-image; based on the number of each target sub-image in the direction of the first target edge and the several groups of candidate sizes, determining several candidate layout information of each target sub-image.
[0008] In a possible implementation, each group of candidate sizes includes a first candidate side length and a second candidate side length; according to the number of target sub-images in the direction of the first target side and the groups of candidate sizes, several candidate layout information of the target sub-images are determined, including: detecting whether the first candidate side length and the second candidate side length of each group of candidate sizes of the target sub-images match the side length of the target page to be generated; in the case that the first candidate side length or the second candidate side length does not match the side length of the target page to be generated, correcting the candidate size, and determining the candidate layout information of the target sub-image according to the corrected groups of candidate sizes and the number of target sub-images in the direction of the first target side; in the case that the first candidate side length and the second candidate side length match the side length of the target page to be generated, directly determining the candidate layout information of the target sub-image according to the candidate size and the number of target sub-images in the direction of the first target side.
[0009] In a possible implementation, the first candidate side length or the second candidate side length does not match the side length of the target page to be generated, including: the first candidate side length is greater than the side length of the target page to be generated, or the second candidate side length is greater than the side length of the target page to be generated.
[0010] In a possible implementation, based on the target all-in-one type information and in accordance with an arrangement logic strategy, several candidate layout information of each target sub-image in the target page to be generated is determined, including: based on the target all-in-one type information, determining a method for equally dividing the target page to be generated; based on the method for equally dividing the target page to be generated, determining several candidate layout information of each target sub-image in the target page to be generated.
[0011] In a possible implementation, candidate layout information that meets preset conditions is selected from the plurality of candidate layout information as the target layout information, including: among the plurality of candidate layout information, the candidate layout information with the largest area of each target sub-image is determined as the target layout information.
[0012] In a possible implementation, the target layout information includes position information, the position information includes position information of corresponding target points in each target sub-image, and the target points include at least two boundary points on a diagonal line in the target sub-image.
[0013] In a possible implementation, the target sub-images of the target page to be generated are determined based on the target layout information and the original sub-images, including: preprocessing the original sub-images according to the target layout information to obtain the target sub-images of the target page to be generated, and the preprocessing includes scaling and / or rotation.
[0014] In a second aspect, an embodiment of the present application provides an image forming device, comprising a memory for storing computer program instructions and a processor for executing program instructions, wherein when the computer program instructions are executed by the processor, the device is triggered to execute the method described in the first aspect above.
[0015] In a third aspect, an embodiment of the present application provides a computer-readable storage medium, wherein the computer-readable storage medium includes a stored program, wherein when the program is running, the device where the computer-readable storage medium is located is controlled to execute the method described in the first aspect.
[0016] The present application provides an image forming method, device and storage medium, which have at least the following technical effects: In the above technical solution, the image forming device can convert the original all-in-one type of manuscript into other all-in-one types of manuscripts by copying the original manuscript, and can support user-defined all-in-one types, thereby meeting the user's imaging needs for various all-in-one types of manuscripts. In addition, the above solution can automatically select the best typesetting solution under the currently set all-in-one type to maximize the use of paper area. BRIEF DESCRIPTION OF THE DRAWINGS
[0017] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0018] Figure 1 A schematic diagram of a scenario of an image forming method provided in an embodiment of the present application; Figure 2 A schematic diagram of a process of an image forming method provided in an embodiment of the present application; Figure 3 A schematic diagram of an interface of an image forming method provided in an embodiment of the present application; Figure 4 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Figure 5 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Figure 6 Another schematic diagram of an interface of the image forming method provided in an embodiment of the present application; Figure 7 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Figure 8 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Fig. 9 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Fig.10 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Fig.11 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Fig.12 A schematic diagram of another scenario of the image forming method provided in an embodiment of the present application; Fig.13 Another schematic diagram of a process of forming an image according to an embodiment of the present application; Fig.14 A schematic diagram of the structure of another image forming device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0019] In order to better understand the technical solution of the present application, the embodiments of the present application are described in detail below with reference to the accompanying drawings.
[0020] It should be clear that the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.
[0021] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, and are not intended to limit the present application. The singular forms "a", "said" and "the" used in the embodiments of the present application and the appended claims are also intended to include plural forms, unless the context clearly indicates other meanings.
[0022] It should be understood that the term "and / or" used in this article is only a description of the association relationship of associated objects, indicating that there can be three relationships. For example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone. In addition, the character " / " in this article generally indicates that the associated objects before and after are in an "or" relationship.
[0023] In the field of image formation, many image forming devices already have an all-in-one imaging function, which can be used to automatically scale the contents of multiple pages and layout them into one page for printing. This function can save paper and meet the imaging needs of users in some special scenarios. In common technical solutions, the all-in-one types that image forming devices can support only include two-in-one type, four-in-one type, eight-in-one type and sixteen-in-one type. Understandably, refer to Figure 1 As shown in 1a, the two-in-one type is to layout the content of two pages into one page, refer to Figure 1 As shown in 1b, the four-in-one type is to typeset the contents of four pages into one page. Figure 1 As shown in 1c, the eight-in-one type is to typeset the contents of eight pages into one page. Figure 1 As shown in 1d, the sixteen-in-one type is to typeset the contents of sixteen pages into one page.
[0024] However, in actual application scenarios, users also hope to perform other all-in-one types of imaging, such as three-in-one type, five-in-one type, six-in-one type, etc., or split and reorganize the existing all-in-one type into user-defined all-in-one types. The existing technical solutions cannot meet the above-mentioned imaging needs of users.
[0025] This application is filed to address the above issues.
[0026] This application can be used to regenerate an all-in-one type of original into another all-in-one type of manuscript specified by the user, thereby meeting the user's imaging needs for a variety of different all-in-one types.
[0027] The technical solution provided in this application can be used for any image forming device, including but not limited to printers, copiers, fax machines, scanners, and multifunction machines that integrate printing, copying, faxing, scanning and other functions.
[0028] The technical solutions provided in this application are described in detail in the following examples.
[0029] Figure 2 The following is a flow chart of an image forming method provided in an embodiment of the present application. Figure 2 As shown, the storage process of print data may include: 101. Obtain original job parameters of the original page and target job parameters of the target page to be generated.
[0030] In the embodiment of the present application, the original page is any one or more pages in the all-in-one type manuscript that the user has printed, and the target page is another all-in-one type page that the user wants to generate. In the embodiment of the present application, for easy distinction, the all-in-one type information of the original page can be expressed as the original all-in-one type information, and the all-in-one type information of the target page can be expressed as the target all-in-one type information, and the original all-in-one type information is different from the target all-in-one type information. The image forming device can be used to convert the all-in-one type of the original page when the user has printed the original page of the all-in-one type, convert the original page into a target page of another all-in-one type, and print it.
[0031] Before implementing the all-in-one type conversion, the image forming device needs to first obtain the original job parameters of the original page and the target job parameters of the target page to be generated. Specifically, the panel of the image forming device may display the following: Figure 3 The target setting interface 30 shown in FIG. Figure 3 As shown, the target setting interface 30 is an all-in-one redefinition interface, which may include setting options for original job parameters of an original page and setting options for target job parameters of a target page to be generated.
[0032] Among them, the setting options for the original job parameters of the original page may include: scanning source 311, original imaging direction 312, original paper type 313, original all-in-one type 314, and original arrangement direction 315. In the embodiment of the present application, the "original" refers to the above-mentioned "original page". Specifically, the scanning source includes the manuscript table FB and the automatic document feeder (Automatic Document Feeder, ADF). When the scanning source is the manuscript table, the user places the documents to be scanned on the manuscript table page by page for scanning. When the scanning source is the ADF, the user places all the documents to be scanned into the ADF at one time, and the ADF automatically feeds them into the image forming device page by page for scanning, without the user manually placing them one by one. The original imaging direction refers to the direction in which the page content of the original is displayed on the page, such as Figure 4 As shown, for example Figure 4 The original image direction of a is upward. Figure 4 The original image direction of b is downward, Figure 4 The original image direction of c is left. Figure 4 d is in the right direction. The original paper type refers to the size of the original paper to be scanned, such as A4 paper type, A3 paper type, etc. The original arrangement direction refers to the arrangement direction of the original sub-images contained in the pages of the original, such as Figure 5 As shown, for example, it may include horizontal arrangement and vertical arrangement.
[0033] The setting options for the target job parameters of the target page to be generated may include: target paper type 321, target all-in-one type 322 and target arrangement direction 323. Among them, the target paper type refers to the paper type of the target page that the user wants to obtain. The target page is also the page that the user wants to obtain after scanning, reorganizing and copying the original page, that is, the "copy". The target arrangement direction refers to the arrangement direction of the target sub-images contained in the target page that the user wants to obtain. The target all-in-one type refers to the all-in-one type of the target page that the user wants to obtain. The value of the target all-in-one type can be obtained according to the user's input operation. Specifically, in response to the Figure 3 The trigger operation of the target all-in-one type 322 button in the interface shown in the figure can display the image forming device as shown in the figure. Figure 6 In the all-in-one redefinition interface shown in FIG. 1 , an input keyboard of a target all-in-one type 322 may be displayed in the all-in-one type redefinition interface, and a user may enter a customized all-in-one value in the input keyboard. For example, when the user desires to implement a three-in-one type of imaging, the user may enter a value of 3. In response to a triggering operation of a confirmation button in the input keyboard, the image forming apparatus may determine the target all-in-one type.
[0034] 102, obtaining a scanned image of the original page.
[0035] When the original job parameters of the original page and the target job parameters of the target page to be generated are set, the user can control the image forming device to start the copy / print operation of the original page, and convert the original page into a target all-in-one type target page through the copy / print operation. Figure 3 The "Start Copying" button 331 in the target setting interface is shown. Further, in response to the triggering operation of the "Start Copying" button 331, the image forming device may first perform a scanning operation on the original page, thereby obtaining a scanned image of the original page.
[0036] 103. Acquire each original sub-image included in the original page from the scanned image according to the original job parameters.
[0037] According to the above, the original job parameters include the scan source and the original arrangement direction of each original sub-image in the original page. After obtaining the scanned image of the original page, first, the original layout information of the original page can be determined according to the scan source, the original all-in-one type information and the original arrangement direction. Among them, the original sub-image refers to the image of the sub-page merged into the original page. The number of original sub-images in the original page is related to the original all-in-one type information of the original page. For example, assuming that the original all-in-one type information of the original page is four-in-one, then the number of original sub-images in the original page is 4. The original layout information may include position information and size information.
[0038] Specifically, the image forming device may first determine the page orientation of the scanned image according to the original image forming direction and the scanning source. In the embodiment of the present application, due to different hardware implementations, when the original page has different scanning sources, the page orientation of the scanned image obtained is different. Figure 7 As shown in the figure, when the scanning source is the platen FB, Figure 7 As shown in a, when the original imaging direction is upward, the page orientation of the scanned image is left; Figure 7 As shown in b, when the original imaging direction is downward, the page orientation of the scanned image is right; Figure 7 As shown in c, when the original imaging direction is left, the page orientation of the scanned image is upward; Figure 7 d, when the original image direction is right, the page orientation of the scanned image is downward. Figure 7 As shown in FIG. 4 , when the original image is in the upward direction, the page orientation of the scanned image is rightward; Figure 7 As shown in FIG. 5 , when the original image is in the downward direction, the page orientation of the scanned image is leftward; Figure 7 As shown in FIG. 6 , when the original image is in the left direction, the page orientation of the scanned image is upward; Figure 7As shown in h, when the imaging direction of the original is right, the page orientation of the obtained scanned image is downward. Furthermore, the image forming device can determine the original page layout information of the original page according to the page orientation of the scanned image, the original all-in-one type information of the original page, the original paper type, and the original arrangement direction. Specifically, in an embodiment of the present application, the size information of each original sub-image in the scanned image can be determined according to the original paper type and the original all-in-one type information, and then the position information of each original sub-image in the scanned image can be determined according to the page orientation of the scanned image and the original arrangement direction. The position information can be represented in the form of coordinates, for example, for any original sub-image, the coordinates of the original sub-image can be represented by the coordinates of at least two boundary points on the diagonal line of the original sub-image. For example, the upper left corner coordinates and the lower right corner coordinates.
[0039] refer to Figure 8 As shown in 8a, the original multi-in-one type of the original page is a four-in-one type, the original paper type is A4 paper type, the original arrangement direction is horizontal, and the page orientation of the scanned image is upward. According to the side length of the A4 paper type, it can be determined that when the A4 paper type is divided into 4 sub-areas, the side length of each sub-area is the size information of each original sub-image in the scanned image. It can be understood that the width of each original sub-image is The short side length of A4 paper 1 / 2 of the original sub-image. The long side length of A4 paper In the case where the coordinates of the original sub-image are represented by the coordinates of the upper left corner boundary point and the lower right corner boundary point of the original sub-image, such as Figure 8 As shown in 8a, the position of the original sub-image 1 can be represented by the coordinates of point A and point B, the position of the original sub-image 2 can be represented by the coordinates of point C and point D, the position of the original sub-image 3 can be represented by the coordinates of point E and point F, and the position of the original sub-image 4 can be represented by the coordinates of point B and point G. Then, according to the arrangement direction of each original sub-image, the position information of the original sub-images 1, 2, 3, and 4 can be determined respectively: In another example, Figure 8 As shown in FIG8b, when the arrangement direction of each original sub-image is changed to vertical, the position information of the original sub-images 1, 2, 3, and 4 will be changed to: Furthermore, the image forming device may obtain each original sub-image from the scanned image according to the original layout information of each original sub-image in the scanned image. In a specific implementation, illustratively, the image forming device may obtain the data of the original sub-image from the corresponding storage area according to the storage area of each original sub-image in the scanned image.
[0040] 104. Determine target layout information of each target sub-image in the target page to be generated according to the target job parameters.
[0041] In the embodiment of the present application, when the target multi-in-one type of the target page defined by the user is other multi-in-one types that can be directly generated by the image forming device, such as two-in-one, four-in-one, eight-in-one or sixteen-in-one, the specific method for determining the target layout information of each target sub-image in the target page can refer to the aforementioned method for determining the original layout information of the original sub-image in the original page. For example, when the target multi-in-one type of the target page defined by the user is an eight-in-one type, it can be determined based on the side length of the target paper type that the target paper type is divided into eight sub-areas, and the side length of each sub-area is the size information of each target sub-image in the target page. Then, the position information of each target sub-image in the target page can be determined based on the target arrangement direction set by the user. In this way, the target layout information of each target sub-image in the target page can be obtained.
[0042] When the user-defined target page's all-in-one type is other types, such as three-in-one type, five-in-one type, etc., the specific method for determining the target layout information of each target sub-image in the target page can refer to the following description. It can be understood that the three-in-one type and the five-in-one type are only used as an example, and the following method description can also be applied to other odd-numbered all-in-one types or other even-numbered all-in-one types.
[0043] In the embodiment of the present application, according to the target all-in-one type information and the arrangement logic strategy, several candidate layout information of each target sub-image in the target page to be generated can be determined. Then, the candidate layout information that meets the preset conditions can be selected from the several candidate layout information as the target layout information.
[0044] In a possible implementation, the target layout information of each target sub-image in the target page to be generated can be determined based on the first arrangement logic. Specifically, the first arrangement logic is to arrange each target sub-image evenly along one of the edges of the target page. Specifically, based on the first arrangement logic, multiple candidate layout information of the target sub-image in the target page to be generated can be obtained first, and then, based on each candidate layout information, the area of the target sub-image can be calculated respectively, and the one of the candidate layouts that makes the target sub-image area the largest is determined as the target layout information of the target sub-image.
[0045] The specific method for determining the candidate layout information of the target sub-image based on the first arrangement logic is described below.
[0046] Specifically, first, the number of target sub-images in the direction of the first target edge in the target page to be generated can be determined according to the target all-in-one type information set by the user. The first target edge can be determined according to the target arrangement direction of each target sub-image in the target page set by the user. The first target edge can be a wide edge or a long edge. When the target arrangement direction is horizontal, the first target edge can be a short edge, and when the target arrangement direction is vertical, the first target edge can be a long edge. Then, according to the number of target sub-images in the direction of the first target edge and the aspect ratio of the original sub-image, several groups of candidate sizes of each target sub-image can be determined. Furthermore, according to the number of target sub-images in the direction of the first target edge and several groups of candidate sizes of each target sub-image, several candidate layout information of each target sub-image can be determined.
[0047] The following is a method for determining several groups of candidate sizes for each target sub-image. Specifically, the first candidate side length of each target sub-image can be determined based on the side length of the first target side. The side length of the first target side can be determined based on the target paper type set by the user. Specifically, if the target all-in-one type is N-in-one, then the number of target sub-images in the direction of the first target side of the target page to be generated is determined to be N. Then, the side length of the first target side is divided into N equal parts to determine the first candidate side length of each target sub-image. Then, the second candidate side length of each target sub-image can be determined based on the first candidate side length and the aspect ratio of the original sub-image. When the first candidate side length is the width length, the second candidate side length is the height length, or when the first candidate side length is the height length, the second candidate side length is the width length.
[0048] For example, when the target arrangement direction of each target sub-image set by the user is horizontal, the target all-in-one type is three-in-one type, and the target paper size is A4 paper size, two candidate layout modes can be obtained as follows: Fig. 9 as well as Fig.10 As shown. Fig. 9Take the candidate layout mode 01 shown as an example, where the first candidate side length L1 of each target sub-image is the width length, and the second candidate side length L2 is the height length. The first candidate side length is 1 / 3 of the width length of the target paper size (A4) of L1, and the ratio of the first candidate side length L1 to the second candidate side length L2 is equal to the aspect ratio of the original sub-image. Therefore, the second candidate side length can be calculated according to the formula: Calculated, among which, is the width of the original sub-image, is the height of the original sub-image.
[0049] for Fig.10 Another candidate layout 02 is shown, Fig. 9 The candidate layout 01 shown is the opposite. The first candidate side length L1 of each target sub-image is the height, and the second candidate side length L2 is the width. The first candidate side length is 1 / 3 of the width of the target paper size (A4). The ratio of the second candidate side length L2 to the first candidate side length L1 is equal to the aspect ratio of the original sub-image. Therefore, the second candidate side length can be calculated according to the formula: Calculated. Among them, is the width of the original sub-image, is the height of the original sub-image.
[0050] Furthermore, in some implementation scenarios, the aspect ratio of the original sub-image may be inconsistent with the aspect ratio of the target paper type. In this case, when determining the candidate side lengths of each target sub-image according to the above method, one of the candidate side lengths may be greater than the side length of the target paper type. Fig.11 As shown, assuming that the target all-in-one type is three-in-one, then the first target edge ( Fig.11 The length of the target paper type (the long side of the original sub-image) is divided into three equal parts to determine the first candidate side length L1 of each target sub-image. Then, after determining the second candidate side length L2 of each target sub-image according to the aspect ratio of the original sub-image, it is found that the value of the second candidate side length L2 calculated in this way is greater than the wide side of the target paper type.
[0051] For the above-mentioned implementation scenario, in the embodiment of the present application, after determining several groups of candidate sizes of each target sub-image, it is possible to first detect whether the first candidate side length and the second candidate side length of the candidate size of each target sub-image match the side length of the target page to be generated. In the case that the first candidate side length or the second candidate side length does not match the side length of the target page to be generated, the candidate size can be corrected, and then the candidate layout information of each target sub-image can be determined according to the corrected groups of candidate sizes and the number of each target sub-image in the direction where the first target side is located. Among them, the first candidate side length or the second candidate side length does not match the side length of the target page to be generated, including that the first candidate side length is greater than the side length of the target page to be generated, or that the second candidate side length is greater than the side length of the target page to be generated. In the case that the first candidate side length and the second candidate side length match the side length of the target page to be generated, the candidate layout information of each target sub-image can be directly determined according to the candidate size and the number of each target sub-image in the direction where the first target side is located.
[0052] In another specific implementation, considering that the first candidate side length is determined based on the first target side of the target page that is bisected by the target all-in-one type, the first candidate side length will always be smaller than the side length of the target page to be generated. Therefore, it is only necessary to determine whether the second candidate side length matches the side length of the target page to be generated. Specifically, after determining the second candidate side length of the target sub-image, it is possible to determine whether the second candidate side length is greater than the length of the second target side, wherein the second target side is an edge in the target page that is perpendicular to the first target side, and the length of the second target side can be determined based on the target paper type set by the user. If the second candidate side length is greater than the length of the second target side, the candidate size of the target sub-image can be corrected so that the corrected second candidate side length is equal to the second target side length, and the corrected first candidate side length can be determined based on the corrected second candidate side length and the aspect ratio of the original sub-image. As shown in the example below: Fig.11 For example, the corrected second candidate side length Equal to the width of A4 paper, the corrected first candidate side length If the second candidate side length is not greater than the second target side length, it indicates that the target sub-image does not exceed the target page, and no processing is performed.
[0053] Through the above method, multiple candidate layout information of each target sub-image can be obtained, including size information and position information. The size information can be represented by the candidate size, and the position information can be represented by the coordinates of the target point. The target point can be, for example, a boundary point on the diagonal line of the target sub-image. Fig. 9 Taking the candidate layout mode 01 shown in the figure as an example, after the candidate side lengths of each target sub-image are determined, the position information of each target sub-image is respectively: In another possible implementation, the target layout information of each target sub-image in the target page to be generated may be determined according to the second arrangement logic. Specifically, the second arrangement logic is to arrange each target sub-image evenly in the entire target page.
[0054] Specifically, first, the method of dividing the area of the target page can be determined according to the target all-in-one type information set by the user. In the case where the target all-in-one type is an N-in-one type, where N is a positive integer, if N>2 and N<=4, then it can be determined that the area of the target page of the target paper type is divided into 4 parts; if N>4 and N<=8, then it can be determined that the area of the target page of the target paper type is divided into 8 parts; if N=9, then it can be determined that the area of the target page of the target paper type is divided into 9 parts; if N>9 and N<=16, then it can be determined that the area of the target page of the target paper type is divided into 16 parts. Furthermore, the target layout information of each target sub-image in the target page to be generated can be determined according to the method of dividing the area of the target page and the target arrangement direction of the target sub-image set by the user.
[0055] For ease of understanding, take the target paper type as A4, the target multi-in-one type as five-in-one type, and the target sub-image target arrangement direction as horizontal as an example. At this time, since N is 5, the area of the target page can be divided into 8 equal parts to obtain 8 sub-areas. Then, according to the target arrangement direction (horizontal) set by the user, starting from the first sub-area, each target sub-image can be arranged horizontally until the 5 target sub-images are arranged. In this way, the target layout information of each target sub-image in the target page to be generated can be obtained as follows: Fig.12 The representation method of the position information and size information of each target sub-image can refer to the above description.
[0056] In another possible implementation, the two aforementioned implementations may be combined, and multiple candidate layout information of each target sub-image in the target page to be generated may be determined in accordance with the first arrangement logic and the second arrangement logic. Then, one of the multiple candidate layout information may be selected to maximize the area of the target sub-image as the target layout information of each target sub-image in the target page to be generated.
[0057] Specifically, refer to Fig.13 First, according to the user Figure 3 The setting operation in the interface shown acquires the original job parameters of the original page and the target job parameters of the target page, and then, the original layout information of each original sub-image of the original page can be determined according to the original job parameters.
[0058] Then, based on the first arrangement logic, multiple candidate layout information of the target sub-image can be determined. Specifically, first, according to the target all-in-one type of the target page, the target page can be divided into equal parts according to the width (equivalent to the aforementioned first target side), and the width after the equal division is used as the width of the target sub-image (i.e., the first candidate side length), and then the height of the target sub-image (i.e., the second candidate side length) is calculated according to the aspect ratio of the original sub-image, so that the area 1 of the target sub-image can be calculated. Second, the width after the equal division can be used as the height of the target sub-image (i.e., the first candidate side length), and then the width of the target sub-image (i.e., the second candidate side length) is calculated according to the aspect ratio of the original sub-image, so that the area 2 of the target sub-image can be calculated. Third, according to the target all-in-one type of the target page, the target page can be divided into equal parts according to the height (equivalent to the aforementioned first target side), and the height after the equal division is used as the height of the target sub-image (i.e., the first candidate side length), and then the width of the target sub-image (i.e., the second candidate side length) is calculated according to the aspect ratio of the original sub-image, so that the area 3 of the target sub-image can be calculated. Fourth, the height after equal division can be used as the width of the target sub-image (i.e., the first candidate side length), and then the height of the target sub-image (i.e., the second candidate side length) can be calculated according to the aspect ratio of the original sub-image. In this way, the area 4 of the target sub-image can be calculated.
[0059] Furthermore, based on the second arrangement logic, the candidate layout information of the target sub-image can be determined. Specifically, the target page can be divided equally according to the number of target all-in-one types, and the area of the target sub-image can be calculated according to the determined division method 5.
[0060] Furthermore, the target sub-images' areas 1 to 5 can be compared to determine the largest area max, and the candidate layout information when the target sub-image has the largest area can be determined as the target layout information. Then, the original image can be scaled and rotated according to the target layout information to obtain each target sub-image. Then, according to the arrangement of the target sub-images in the target page (horizontally or vertically), the coordinates of each target sub-image are determined and arranged in sequence until the arrangement is completed.
[0061] Alternatively, in another possible implementation, the image forming device may pre-store a mapping relationship table between multiple different job parameters and layout information of each sub-image in the page. Then, after obtaining the target job parameters input by the user, the mapping relationship table may be queried to directly determine the target layout information of each target sub-image corresponding to the target job parameters. With this implementation, the image forming device does not need to calculate and compare different layout methods in each implementation process, saving processing resources and improving algorithm efficiency.
[0062] 105 , pre-processing each original sub-image according to the target layout information to obtain each target sub-image.
[0063] In the embodiment of the present application, the original sub-images obtained in the original page can be scaled and rotated according to the position information and size information of each target sub-image, so as to obtain each target sub-image. The scaling process can be processed by the control module of the chip in the image forming device, for example. The chip can calculate the scaling ratio and send it to the control module for scaling. The rotation process can be processed by the image processing module of the chip in the image forming device, for example. The chip can calculate the rotation angle and send it to the image processing module for rotation.
[0064] 106. Generate a target page using each target sub-image and print it.
[0065] In the embodiment of the present application, each target sub-image obtained can be arranged on the target paper type according to the determined target layout information, so as to generate a target page and print it.
[0066] In the above technical solution, the image forming device can convert the original all-in-one type of manuscript into other all-in-one types of manuscripts by copying the original manuscript, and can support user-defined all-in-one types, thereby meeting the user's imaging needs for various all-in-one types of manuscripts. In addition, the above solution can automatically select the best typesetting solution under the currently set all-in-one type to maximize the use of paper area.
[0067] Corresponding to the above-mentioned embodiment, the present application also provides an image forming device. Fig.14 The schematic diagram of the structure of an image forming device provided in an embodiment of the present application is as follows: the image forming device 400 may include: a processor 401, a memory 402, and a communication unit 403. These components communicate via one or more buses. It can be understood by those skilled in the art that the structure of the image forming device shown in the figure does not constitute a limitation on the embodiment of the present application, and it may be a bus structure or a star structure, and may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently.
[0068] The communication unit 403 is used to establish a communication channel so that the image forming device can communicate with other devices, receive user data sent by other devices or send user data to other devices.
[0069] The processor 401 is the control center of the image forming device. It uses various interfaces and lines to connect various parts of the entire image forming device. It runs or executes software programs, instructions, and / or modules stored in the memory 402, and calls data stored in the memory to perform various functions of the image forming device and / or process data. The processor can be composed of an integrated circuit (IC), for example, it can be composed of a single packaged IC, or it can be composed of multiple packaged ICs with the same or different functions. For example, the processor 401 can only include a central processing unit (CPU). In the embodiment of the present application, the CPU can be a single computing core or multiple computing cores.
[0070] The memory 402 is used to store the execution instructions of the processor 401. The memory 402 can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic memory, flash memory, magnetic disk or optical disk.
[0071] When the execution instructions in the memory 402 are executed by the processor 401 , the image forming device 400 is enabled to execute part or all of the steps in various embodiments of the present application.
[0072] In a specific implementation, the present application further provides a computer storage medium, wherein the computer storage medium may store a program, and when the program is executed, the program may include some or all of the steps in each embodiment of the image forming method provided in the present application. The storage medium may be a disk, an optical disk, a read-only memory (ROM) or a random access memory (RAM), etc.
[0073] In a specific implementation, the present application also provides a computer program product, wherein the computer program product includes executable instructions, and when the executable instructions are executed on a computer, the computer executes part or all of the steps in each embodiment of the image forming method provided in the present application.
[0074] Those skilled in the art can clearly understand that the technology in the embodiments of the present application can be implemented by means of software plus a necessary general hardware platform. Based on this understanding, the technical solution in the embodiments of the present application is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which can be stored in a storage medium such as ROM / RAM, a disk, an optical disk, etc., including a number of instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application or some parts of the embodiments.
[0075] In the description of this specification, the description with reference to the terms "one embodiment", "some embodiments", "example", "specific example", or "some examples" etc. means that the specific features, structures, materials or characteristics described in conjunction with the embodiment or example are included in at least one embodiment or example of the present application. In this specification, the schematic representations of the above terms do not necessarily refer to the same embodiment or example. Moreover, the specific features, structures, materials or characteristics described may be combined in any one or more embodiments or examples in a suitable manner. In addition, those skilled in the art may combine and combine the different embodiments or examples described in this specification and the features of the different embodiments or examples, without contradiction.
[0076] In addition, the terms "first" and "second" are used for descriptive purposes only and should not be understood as indicating or implying relative importance or implicitly indicating the number of the indicated technical features. Therefore, the features defined as "first" and "second" may explicitly or implicitly include at least one of the features. In the description of this application, the meaning of "plurality" is at least two, such as two, three, etc., unless otherwise clearly and specifically defined.
[0077] Any process or method description in a flowchart or otherwise described herein may be understood to represent a module, fragment or portion of code comprising one or more executable instructions for implementing the steps of a custom logical function or process, and the scope of the preferred embodiments of the present application includes alternative implementations in which functions may not be performed in the order shown or discussed, including performing functions in a substantially simultaneous manner or in the reverse order depending on the functions involved, which should be understood by technicians in the technical field to which the embodiments of the present application belong.
[0078] The word "if" as used herein may be interpreted as "at the time of" or "when" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrases "if it is determined" or "if (stated condition or event) is detected" may be interpreted as "when it is determined" or "in response to determining" or "when detecting (stated condition or event)" or "in response to detecting (stated condition or event)", depending on the context.
[0079] In the several embodiments provided in the present application, it should be understood that the disclosed systems, devices and methods can be implemented in other ways. For example, the device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation. For example, multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0080] In addition, each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit. The above-mentioned integrated unit may be implemented in the form of hardware or in the form of hardware plus software functional units.
[0081] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
[0082] In this specification, the same or similar parts between the various embodiments can be referred to each other. In particular, for the device embodiment and the terminal embodiment, since they are basically similar to the method embodiment, the description is relatively simple, and the relevant parts can be referred to the description in the method embodiment.
Claims
1. An image forming method, characterized in that: include: Acquire original job parameters of an original page and target job parameters of a target page to be generated, wherein the original job parameters at least include original all-in-one type information, and the target job parameters at least include target all-in-one type information different from the original all-in-one type information; Determining each original sub-image included in the original page according to the original job parameters; Determining target layout information of each target sub-image in the target page to be generated according to the target all-in-one type information; Determining each target sub-image of the target page to be generated according to the target page layout information and the each original sub-image; The target page is generated by using the target sub-images and printed.
2. The method according to claim 1, characterized in that The original operation parameters also include a scanning source and an original arrangement direction of each original sub-image in the original page. Determining each original sub-image included in the original page according to the original operation parameters includes: Scanning the original page to obtain a scanned image; Determining original layout information of the original page according to the scan source, the original all-in-one type information, and the original arrangement direction; According to the original layout information, each original sub-image is determined from the scanned image.
3. The method according to claim 1, characterized in that: Determining target layout information of each target sub-image in the target page to be generated according to the target all-in-one type information includes: According to the target all-in-one type information and in accordance with the arrangement logic strategy, determining a plurality of candidate layout information of each target sub-image in the target page to be generated; The candidate layout information that meets the preset conditions is selected from the plurality of candidate layout information as the target layout information.
4. The method according to claim 3, characterized in that According to the target all-in-one type information and in accordance with the arrangement logic strategy, a plurality of candidate layout information of each target sub-image in the target page to be generated is determined, including: Determining, according to the target all-in-one type information, the number of each target sub-image in the direction where the first target edge is located in the target page to be generated; Determining a plurality of groups of candidate sizes of the target sub-images according to the number of the target sub-images in the direction where the first target edge is located and the aspect ratio of the original sub-image; According to the number of each target sub-image in the direction where the first target edge is located and the plurality of groups of candidate sizes, a plurality of candidate layout information of each target sub-image is determined.
5. The method according to claim 4, characterized in that Each group of candidate sizes includes a first candidate side length and a second candidate side length; according to the number of target sub-images in the direction of the first target side and the groups of candidate sizes, determining a plurality of candidate layout information of each target sub-image, including: Detecting whether the first candidate side lengths and the second candidate side lengths of each group of candidate sizes of each target sub-image match the side lengths of the target page to be generated; In the case that the first candidate side length or the second candidate side length does not match the side length of the target page to be generated, the candidate sizes are corrected, and according to the corrected groups of candidate sizes and the number of target sub-images in the direction of the first target side, candidate layout information of each target sub-image is determined; When the first candidate side length and the second candidate side length match the side length of the target page to be generated, the candidate layout information of each target sub-image is determined directly based on the candidate size and the number of each target sub-image in the direction of the first target side.
6. The method according to claim 5, characterized in that The first candidate side length or the second candidate side length does not match the side length of the target page to be generated, including: The first candidate side length is greater than the side length of the target page to be generated, or the second candidate side length is greater than the side length of the target page to be generated.
7. The method according to claim 3, characterized in that According to the target all-in-one type information and in accordance with the arrangement logic strategy, a plurality of candidate layout information of each target sub-image in the target page to be generated is determined, including: Determining, according to the target all-in-one type information, a method for equally dividing the target page to be generated; According to the method of equally dividing the target page to be generated, a plurality of candidate layout information of each target sub-image in the target page to be generated is determined.
8. The method according to claim 3, characterized in that Selecting candidate layout information that meets preset conditions from the plurality of candidate layout information as the target layout information includes: Among the plurality of candidate layout information, the candidate layout information with the largest area of each target sub-image is determined as the target layout information.
9. The method according to claim 1, characterized in that: The target layout information includes position information, and the position information includes position information of corresponding target points in each target sub-image, and the target points include at least two boundary points on a diagonal line in the target sub-image.
10. The method according to claim 1, characterized in that Determining each target sub-image of the target page to be generated according to the target page layout information and each original sub-image includes: The original sub-images are pre-processed according to the target page layout information to obtain target sub-images of the target page to be generated, wherein the pre-processing includes scaling and / or rotation.
11. An image forming device, characterized in that: include: A memory for storing computer program instructions and a processor for executing the program instructions, wherein when the computer program instructions are executed by the processor, the device is caused to perform the method according to any one of claims 1 to 10.
12. A computer-readable storage medium, characterized in that: The computer-readable storage medium includes a stored program, wherein when the program is executed, the device where the computer-readable storage medium is located is controlled to execute the method according to any one of claims 1 to 10.
Citation Information
Patent Citations
Image Processing Apparatus, Non-Transitory Computer-Readable Storage Medium Storing Imposition Control Program, And Imposition Control Method
CN107463346A
Image formation apparatus
JP2016219890A
Allocation program, allocation device and allocation method
US20100315659A1