CN111596873A - Method and device for processing file to be printed and method and device for controlling file printing - Google Patents

Method and device for processing file to be printed and method and device for controlling file printing Download PDF

Info

Publication number
CN111596873A
CN111596873A CN202010472869.1A CN202010472869A CN111596873A CN 111596873 A CN111596873 A CN 111596873A CN 202010472869 A CN202010472869 A CN 202010472869A CN 111596873 A CN111596873 A CN 111596873A
Authority
CN
China
Prior art keywords
file
printed
print
image object
printing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202010472869.1A
Other languages
Chinese (zh)
Other versions
CN111596873B (en
Inventor
孔德珠
彭继兵
王恒
冯林江
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Zhuhai Pantum Electronics Co Ltd
Original Assignee
Zhuhai Pantum Electronics Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Zhuhai Pantum Electronics Co Ltd filed Critical Zhuhai Pantum Electronics Co Ltd
Priority to CN202010472869.1A priority Critical patent/CN111596873B/en
Publication of CN111596873A publication Critical patent/CN111596873A/en
Application granted granted Critical
Publication of CN111596873B publication Critical patent/CN111596873B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1237Print job management
    • G06F3/1242Image or content composition onto a page
    • G06F3/1243Variable data printing, e.g. document forms, templates, labels, coupons, advertisements, logos, watermarks, transactional printing, fixed content versioning
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1202Dedicated interfaces to print systems specifically adapted to achieve a particular effect
    • G06F3/1203Improving or facilitating administration, e.g. print management
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1202Dedicated interfaces to print systems specifically adapted to achieve a particular effect
    • G06F3/1203Improving or facilitating administration, e.g. print management
    • G06F3/1208Improving or facilitating administration, e.g. print management resulting in improved quality of the output result, e.g. print layout, colours, workflows, print preview
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1237Print job management
    • G06F3/1244Job translation or job parsing, e.g. page banding
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/12Digital output to print unit, e.g. line printer, chain printer
    • G06F3/1201Dedicated interfaces to print systems
    • G06F3/1223Dedicated interfaces to print systems specifically adapted to use a particular technique
    • G06F3/1237Print job management
    • G06F3/1244Job translation or job parsing, e.g. page banding
    • G06F3/1247Job translation or job parsing, e.g. page banding by conversion to printer ready format

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Accessory Devices And Overall Control Thereof (AREA)

Abstract

The invention relates to a method and a device for processing a file to be printed, a method and a device for controlling file printing, a readable storage medium and electronic equipment. The file printing control method includes: acquiring a file to be printed; identifying an image object in the file to be printed; judging whether the image object has a preset attribute or not; if the image object has the preset attribute, optimizing at least the image object part of the file to be printed to obtain a processed printed file; converting the processed print file into a first print file; and sending the first printing file to printing equipment to control the printing equipment to print.

Description

Method and device for processing file to be printed and method and device for controlling file printing
Technical Field
The invention relates to the technical field of image formation, in particular to a method and a device for processing a file to be printed, a method and a device for controlling file printing, a readable storage medium and electronic equipment.
Background
A printing apparatus typically prints print data supplied from an electronic apparatus such as a computer or the like on a recording medium. Such a printing apparatus may include: a copying machine, a printer, a facsimile machine, or a multifunction peripheral (MFP) that integrates the functions of the copying machine, the printer, the facsimile machine into a single system, and the like.
When such a printing apparatus performs printing, the following steps are generally required to perform the completion of printing: such as operating the electronic device, launching various applications for generating the print data, converting the print data into a language that the printing device is capable of interpreting, and transmitting the translated print data to the printing device.
As can be seen from the above, in order to obtain desired printing in response to a print command input by a user, it is necessary to process-convert original print data into translated print data and transmit the translated print data to a printing apparatus. However, when the original print data document contains a picture object with special attributes (e.g. a masked picture object), the print data with high complexity and poor portrait effect is generated by direct processing, and if the print data is directly sent to the printing device, the processing time of the printing device may be long and the printing effect may be poor.
Disclosure of Invention
In view of the above, in order to at least partially improve the above problems, the present invention provides a method and an apparatus for processing a to-be-printed document, a method and an apparatus for controlling document printing, a readable storage medium, and an electronic device.
In order to achieve the above object, the following scheme is adopted in the embodiments of the present invention.
In a first aspect, an embodiment of the present invention provides a method for processing a to-be-printed file, including:
acquiring a file to be printed;
identifying an image object in the file to be printed;
judging whether the image object has a preset attribute or not; and
and if the image object has the preset attribute, optimizing at least the image object part of the file to be printed to obtain a processed printed file.
In a second aspect, an embodiment of the present invention provides a file printing control method, including:
acquiring a file to be printed;
identifying an image object in the file to be printed;
judging whether the image object has a preset attribute or not;
if the image object has the preset attribute, optimizing at least the image object part of the file to be printed to obtain a processed printed file;
converting the processed print file into a first print file; and
and sending the first printing file to a printing device to control the printing device to print.
In a third aspect, an embodiment of the present invention provides a to-be-printed document processing apparatus, including:
the acquisition module is used for acquiring a file to be printed;
the identification module is used for identifying the image object in the file to be printed;
the judging module is used for judging whether the image object has a preset attribute or not; and
and the file processing module is used for optimizing at least the image object part of the file to be printed when the image object has the preset attribute so as to obtain a processed printed file.
In a fourth aspect, an embodiment of the present invention provides a document printing control apparatus, including:
the acquisition module is used for acquiring a file to be printed;
the identification module is used for identifying the image object in the file to be printed;
the judging module is used for judging whether the image object has a preset attribute or not;
the file processing module is used for optimizing at least the image object part of the file to be printed when the image object has the preset attribute so as to obtain a processed printed file;
the conversion module is used for converting the processed print file into a first print file and converting the file to be printed into a second print file when the image object does not have the preset attribute; and
and the sending module is used for sending the first print file to a printing device to control the printing device to print, and is also used for sending the second print file to the printing device to control the printing device to print.
In a fifth aspect, an embodiment of the present invention provides a readable storage medium, which stores a computer program, and the computer program is used for implementing the method according to any one of the first to second aspects when executed by a processor.
In a sixth aspect, an embodiment of the present invention provides an electronic device, which includes a memory and a processor, where the memory stores a computer program, and the processor executes the method described in any one of the first to second aspects of the computer program in the memory.
In the file processing method and apparatus to be printed, the file printing control method and apparatus, the readable storage medium and the electronic device provided by the embodiments of the present invention, by identifying and determining whether an image object in the file to be printed has a preset attribute, when the image object has the preset attribute, at least the image object portion of the file to be printed is optimized, so as to avoid generating print data with high complexity and poor portrait effect due to the existence of the preset attribute, and the generated print data has low complexity and good portrait effect, thereby improving the printing speed, and improving the problem that the preset attribute affects the image quality of the printed file, so that the printed file image is smooth and pure.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained according to the drawings without inventive efforts.
Fig. 1 is a flowchart of a document printing control method of an embodiment of the present invention.
Fig. 2 is a flowchart of a document printing control method according to an embodiment of the present invention.
Fig. 3(a) is a schematic diagram of a document to be printed of an image object containing preset attributes.
Fig. 3(B) is a schematic view of an image object of the document to be printed shown in fig. 3 (a).
FIG. 4 is a flow chart of a method for processing a document to be printed according to one embodiment of the invention.
Fig. 5 is a flowchart of a processing method of a document to be printed according to another embodiment of the present invention.
Fig. 6 is a block diagram of a document printing control apparatus according to an embodiment of the present invention.
Fig. 7 is a block diagram of a document processing apparatus to be printed according to an embodiment of the present invention.
Fig. 8 is a block diagram of a document processing apparatus to be printed according to another embodiment of the present invention.
FIG. 9 is a chart of experimental data records for the document printing control method and apparatus of the present invention.
FIG. 10 is a block diagram of an electronic device in accordance with an embodiment of the invention.
Detailed Description
The terms "first," "second," and "third," etc. in the description and claims of the present invention and the above-described drawings are used for distinguishing between different objects and not for describing a particular order. Furthermore, the terms "comprises" and any variations thereof, are intended to cover non-exclusive inclusions. For example, a process, method, system, article, or apparatus that comprises a list of steps or modules is not limited to the listed steps or modules but may alternatively include other steps or modules not listed or inherent to such process, method, article, or apparatus.
Referring to fig. 1 and fig. 2, fig. 1 is a flowchart of a document printing control method according to an embodiment of the present invention, and fig. 2 is a simplified flowchart of the document printing control method according to an embodiment of the present invention. By the file printing control method, the file to be printed or the initial file of the file to be printed is processed, so that a printer file is generated and sent to the printing equipment to control the printing equipment to print. The file printing control method can be operated on electronic equipment, and the electronic equipment comprises a computer, a personal computer, a notebook computer, a tablet computer, a network server, a mobile phone, a personal digital assistant, an intelligent wearable device, a printing auxiliary device connected between a client and the printing device and the like. The printing apparatus may include, but is not limited to: a copying machine, a printer, a facsimile machine, or a multifunction peripheral (MFP) that integrates the functions of the copying machine, the printer, the facsimile machine into a single system, and the like.
Specifically, the file printing control method includes the following steps S11-S15.
In step S11, a document to be printed is acquired. Specifically, the step S11 may be executed in an electronic device, and in an embodiment, an application program of the electronic device acquires an initial file and converts the initial file into the file to be printed in a preset format, so that the application program (e.g., a print driver) of the electronic device may acquire the file to be printed in the preset format. Therefore, the step S11 may include: acquiring an initial file; and converting the initial file into the file to be printed in a preset format.
The initial file may have different formats, such as WORD, EXCEL, PPT, PDF (Portable Document Format), and the like, and the preset Format of the file to be printed includes PDF but is not limited to PDF. Of course, it is understood that, in some embodiments, some applications (such as the office software WPS) of the electronic device may also directly generate the file to be printed in the preset format, and correspondingly, in step S11, an application (such as the print driver, but not limited thereto) of the electronic device may directly receive and acquire the file to be printed in the preset format without performing format conversion.
In addition, in some embodiments, the electronic device may also receive a file to be printed sent by an external device or a network server, or receive an initial file (e.g., an initial file in a format such as WORD) sent by an external device (e.g., an external other electronic device) or a network server, and convert the initial file into a preset format (e.g., through WPS office software) to obtain the file to be printed in the preset format (e.g., the file to be printed in a PDF format). In addition, in some embodiments, the electronic device may also generate the initial file, the initial file is provided to an external device or a network server and converted into the file to be printed in a preset format (for example, the file to be printed in the PDF format), and the file to be printed in the preset format is returned to the electronic device, so that the electronic device obtains the file to be printed.
Step S12, identifying an image object in the file to be printed. The file to be printed may include image objects, text objects, and the like, and specifically, in step S12, the image objects in the file to be printed may be identified by analyzing the file to be printed. Further, when the file to be printed is in a PDF format, the image objects in the file to be printed may be identified by an internal PDF identification analysis module or by calling another application program capable of implementing PDF identification analysis, and the PDF identification analysis module or PDF identification analysis application program may identify all the image objects in the file to be printed.
Step S13, determining whether the image object has a preset attribute. The preset attribute may be a mask, that is, in step S13, it is determined whether the image object of the document to be printed is an image object with a mask, and it is understood that the image object with a mask generally includes a main image and a mask. The mask may have different transparencies ranging from 0% to 100% and may be disposed on the main image to shield the main image to different degrees. As shown in fig. 3(a), fig. 3(a) is a schematic diagram of a to-be-printed file including an image object with preset attributes, where the to-be-printed file may include an image object and a text object, and first, through step S12, the whole to-be-printed file is analyzed to identify the image object of the to-be-printed file, as shown in fig. 3(B), fig. 3(B) is a schematic diagram of the image object of the to-be-printed file; further through the step S13, it is determined whether the image object has the preset attribute, specifically, as shown in fig. 3(B), it may be determined by querying to know a mask type in the picture details of the image object, and if the mask type in the picture details is an external mask, it is determined that the image object has the preset attribute of the mask, and then step S14 may be further performed.
Step S14, if the image object has the preset attribute, performing optimization processing on at least the image object portion of the file to be printed to obtain a processed print file.
In one embodiment, in step S14, the whole of the file to be printed may be optimized to obtain the processed printed file. In another embodiment, in step S14, the image object portion of the file to be printed may be optimized, and the processed image object is used to replace the original image object to obtain the processed printed file.
Specifically, in step S14, the optimizing process may include at least one of removing transparency and reducing compression rate, that is, the step of performing the optimizing process on at least the image object portion of the document to be printed may include: at least one of removing transparency of at least the image object portion of the document to be printed and reducing compression rate of at least the image object portion of the document to be printed. The transparency removal is used for enhancing the image quality and improving the printing speed; the reduced compression ratio is used to save decompression time. Further, the optimization process may further include a step of performing image preprocessing optimization of at least the image object portion before performing at least one of the steps of removing transparency and reducing compression rate.
Further, when the step of removing the transparency is performed, it may be determined whether the image object portion has only the bottom layer image or has no covering relationship, and if the determination result is yes, the step of removing the transparency may be performed to remove the transparency of the image object portion. That is, the step of performing optimization processing on at least the image object portion of the document to be printed may include: and judging whether the image object part only has the bottom layer image or has no covering relation, and if so, executing a step of removing the transparency of at least the image object part of the file to be printed.
Further, the step of removing the transparency of at least the image object portion of the document to be printed may specifically include at least one of the following three ways (for example, using one of them, using any two of them in an overlapping manner, or using all three in an overlapping manner):
(1) removing transparency from at least the image object portion by calling a file format conversion module (e.g., GhostScript);
(2) removing transparency from at least the image object portion by a PDF processing module;
(3) performing screenshot processing on at least the image object part to obtain a screenshot image, and covering at least the image object part with the screenshot image so as to remove transparency of at least the image object part;
still further, in the above manner (3), before the step of removing the transparency of at least the image object portion of the document to be printed, the following determination step may be further performed: judging whether a file format conversion module (such as GhostScript) or a PDF processing module can be called to remove the transparency of at least the image object part, if the judgment result is negative, then executing the step of the mode (3): and performing screenshot processing on at least the image object part to obtain a screenshot image, and covering at least the image object part with the screenshot image so as to remove the transparency of at least the image object part. It is understood that, among others, the file format conversion module GhostScript is a file format conversion module that is self-contained by an operating system of a general electronic device. The format of the processed print file includes, but is not limited to, the PostScript format with extension PS.
Step S15, converting the processed print file into a first print file. The first print file is to be sent to a printing device to control the printing device to print. It will be appreciated that the first printed document may have a language in which the printing device is able to directly receive and execute a print job in dependence on the first printed document, i.e. the first printed document may be recognized and directly printed by the printing device. Specifically, the extension of the first print file may be a PRN, but is not limited to the above.
And step S16, sending the first print file to a printing device to control the printing device to print. Further, it is understood that, in the file printing control method, the determination result in step S13 may be: the image object does not have a preset attribute, e.g., the image object does not have a mask, and thus, the file printing control method may further include steps S17 and S18.
Step S17, if the image object does not have the preset attribute, converting the file to be printed into a second print file. The second print file is used for being sent to the printing device to control the printing device to print. It will be appreciated that the second print file may have a language in which the printing device can directly receive and execute a print job in dependence on the second print file, i.e. the second print file may be recognised by the printing device and printed directly. Specifically, the second print file may be in the same format as the first print file, such as with an extension PRN, but is not limited to the format described above.
And step S18, sending the second print file to a printing device to control the printing device to print. The step S18 may also be executed by a print driver of the electronic device, but is not limited thereto. It can be understood that the first print file and the second print file may both be sent to the same printing device, and of course, may also be sent to different printing devices, and may be set by the user according to the requirements of the user.
It should be understood that, the steps S11-S18 may be executed by the print driver of the electronic device, but not limited thereto, and may also be executed by an application program such as an office of the electronic device, the print driver, and/or other internal and external applications, which are not exhaustive.
As can be seen from the above, in the file printing control method according to the embodiment of the present invention, the first print file or the second print file is finally generated and sent to the printing device by acquiring and processing the file to be printed or the initial file of the file to be printed, so as to control the printing device to print, thereby completing the control of file printing.
However, the embodiment of the present invention also provides a processing method of a file to be printed, which may include some steps (such as steps S11-S14, or steps S11-S15, or steps S11-15 and S17) in the file printing control method of the above embodiment, so that the file to be printed or an initial file of the file to be printed is processed to generate the processed print file, or the first print file, or the second print file. By the method for processing the file to be printed, the processed print file, the first print file or the second print file can be generated, wherein the processed print file can be further provided to other electronic equipment or a network server to be further converted into the first print file; the first printed file can also be sent to other electronic equipment or a network server, and the like, and according to actual needs, the other electronic equipment or the network server can send the first printed file to printing equipment so as to control the printing equipment to print; the second print file can be sent to other electronic devices or a network server, and the other electronic devices or the network server can send the first print file to a printing device according to actual needs so as to control the printing device to print. It can be understood that the first print file and the second print file may both be sent to the same printing device, and of course, may also be sent to different printing devices, and may be set by the user according to the requirements of the user.
The file processing method to be printed in the embodiment of the present invention can also be operated on electronic devices, where the electronic devices include, but are not limited to, computers, personal computers, notebook computers, tablet computers, network servers, mobile phones, personal digital assistants, intelligent wearable devices, printing auxiliary devices connected between clients and printing devices, and the like. The printing apparatus may include: a copying machine, a printer, a facsimile machine, or a multifunction peripheral (MFP) that integrates the functions of the copying machine, the printer, the facsimile machine into a single system, and the like.
As shown in FIG. 4, in one embodiment, the file to be printed processing method includes steps S11-S14 and S15'.
In step S11, a document to be printed is acquired.
Step S12, identifying an image object in the file to be printed.
Step S13, determining whether the image object has a preset attribute.
Step S14, if the image object has the preset attribute, performing optimization processing on at least the image object portion of the file to be printed to obtain a processed print file.
Step S15', if the image object does not have the preset attribute, outputting the file to be printed, or outputting an instruction that the file to be printed does not have the preset attribute, or outputting an instruction that the file to be printed does not need to be processed.
The steps S11-S14 have been described in detail in the above embodiment of the file printing control method, and will not be described herein again.
It is to be understood that, in the step S15', if the image object does not have the preset attribute, the file to be printed may be directly output without processing the file to be printed, or an instruction that the file to be printed does not have the preset attribute is output, or an instruction that the file to be printed does not need to be processed is output, and the file to be printed may be used to be converted into a printer file (such as a second print file) that can be understood and executed by the printing device.
In addition, it is understood that the file to be printed processing method according to the embodiment shown in fig. 4 may be built in a print driver of an electronic device, and as shown in the embodiment shown in fig. 1, the file printing control method may be executed by the print driver of the electronic device, and includes most or all of the steps of the embodiment shown in fig. 4, and therefore, the above description is given in detail with respect to the embodiment shown in fig. 1, and is not repeated here.
Further, the document to be printed processing method of the embodiment shown in fig. 4 can also be executed by a document to be printed processing device (such as an application program for processing the document to be printed) of the electronic equipment, for example, the to-be-printed document processing apparatus may receive a to-be-printed document or an initial document generated by an application program (e.g., a WPS application program), and generating and outputting the print file processed in step S14 to another application program (e.g., a scan driver), returning the file to be printed or an instruction that the file to be printed does not need to be processed to another application program (e.g., a scan driver), and converting the processed print file or the file to be printed into the first print file or the second print file by another application program (e.g., a scan driver), and sending the first print file or the second print file to the printing device to control the printing device to print.
Further, the document to be printed processing method of the embodiment shown in fig. 4 can also be run in the electronic device, executed by the document to be printed processing device (such as an application program for document to be printed processing) of the electronic device, and the electronic device can also communicate with the electronic devices of other clients, such as receiving the files to be printed or initial files sent by the electronic devices of other clients, and generating and outputting the print file processed in the step S14 to the electronic devices of other clients, returning the file to be printed or the instruction that the file to be printed does not need to be processed to the electronic devices of other clients, and converting the processed print file or the file to be printed into the first print file or the second print file by the electronic devices of other clients, and sending the first print file or the second print file to the printing device to control the printing device to print.
As shown in FIG. 5, in one embodiment, the file to be printed processing method includes steps S11-S15 and S17.
In step S11, a document to be printed is acquired.
Step S12, identifying an image object in the file to be printed.
Step S13, determining whether the image object has a preset attribute. In the step 13, if the determination result is yes, step S14 is executed; if the determination result is negative, step S17 is executed.
Step S14, if the image object has the preset attribute, performing optimization processing on at least the image object portion of the file to be printed to obtain a processed print file.
Step S15, converting the processed print file into a first print file.
Step S17, if the image object does not have the preset attribute, converting the file to be printed into a second print file.
In addition, it is understood that the file to be printed processing method according to the embodiment shown in fig. 5 may be built in a print driver of an electronic device, and as shown in the embodiment shown in fig. 1, the file printing control method may be executed by the print driver of the electronic device, and includes most or all of the steps of the embodiment shown in fig. 5, and therefore, the above description is given in detail with respect to the embodiment shown in fig. 1, and is not repeated here.
Further, the method for processing the document to be printed according to the embodiment shown in fig. 5 may also be performed by a document processing apparatus to be printed (e.g., an application program for processing the document to be printed) of the electronic device, for example, the document processing apparatus to be printed may receive the document to be printed or an initial document generated by an application program (e.g., a WPS application program), and generate and output the first print file in step S15 or the second print file in step S17 to another application program (e.g., a scan driver), and the another application program (e.g., a scan driver) may send the first print file or the second print file to the printing device to control the printing device to print.
Furthermore, the method for processing the file to be printed according to the embodiment shown in fig. 5 can also be run in an electronic device, and is executed by a file to be printed processing apparatus (e.g. an application program for processing the file to be printed) of the electronic device, and the electronic device can also communicate with electronic devices of other clients, for example, receive the file to be printed or an initial file sent by the electronic devices of other clients, and generate and output the first print file in step S15 or the second print file in step S17 to the electronic devices of other clients, and the electronic devices of other clients send the first print file or the second print file to the printing device to control the printing device to print.
Referring to fig. 6, fig. 6 is a block diagram of a document printing control apparatus 50 according to an embodiment of the present invention. The document printing control apparatus 50 may be configured to execute the document printing control method of the above-described embodiment, which may include an initial document to execute the document printing control method of the above-described embodiment. Specifically, the document printing control apparatus 50 may include an acquisition module 51, an identification module 52, a judgment module 53, a document processing module 54, a conversion module 55, and a transmission module 56.
The obtaining module 51 is used for obtaining a file to be printed. The identification module 52 is used for identifying the image object in the file to be printed. The determining module 53 is configured to determine whether the image object has a preset attribute. The file processing module 54 is configured to perform optimization processing on at least the image object portion of the file to be printed when the image object has the preset attribute, so as to obtain a processed print file.
The conversion module 55 is configured to convert the processed print file into a first print file, where the first print file is used to be sent to a printing device to control the printing device to print; the conversion module 55 is further configured to convert the file to be printed into a second print file when the image object does not have the preset attribute, where the second print file is used to be sent to the printing device to control the printing device to print.
The sending module 56 is further configured to send the first print file to a printing device to control the printing device to print; the sending module 56 is further configured to send the second print file to the printing device to control the printing device to print.
As can be seen from the foregoing, in practice, the obtaining module 51 is configured to perform the step S11, the identifying module 52 is configured to perform the step S12, the identifying module 53 is configured to perform the step S13, the determining module 53 is configured to perform the step S13, the file processing module 54 is configured to perform the step S14, the converting module 55 is configured to perform the steps S15 and S17, and the sending module 56 is configured to perform the steps S16 and S18. The details of the above steps S11-S18 have been described in detail in the above embodiments of the file printing control method, and will not be described herein again.
Further, it is understood that, in an embodiment, the obtaining module 51 may include an obtaining unit and a converting unit, wherein the obtaining unit is configured to obtain an initial file, and the converting unit is configured to convert the initial file into a file to be printed in a preset format. The file processing module 54 may perform the optimization processing on the file to be printed to obtain the processed print file in the raster image format, and specifically, the file processing module 54 includes a file format conversion module GhostScript that performs the optimization processing or calls the file format conversion module GhostScript to perform the optimization processing.
Referring to fig. 7, fig. 7 is a block diagram of a to-be-printed document processing apparatus 60 according to an embodiment of the present invention. The document to be printed processing apparatus 60 may be configured to execute the document to be printed processing method of the above-described embodiment (as shown in fig. 4), which may include an initial document executing the document to be printed processing method of the above-described embodiment. Specifically, the device 60 for processing the document to be printed may include an obtaining module 51, an identifying module 52, a judging module 53 and a document processing module 54.
The obtaining module 51 is used for obtaining a file to be printed. The identification module 52 is used for identifying the image object in the file to be printed. The determining module 53 is configured to determine whether the image object has a preset attribute. The file processing module 54 is configured to perform optimization processing on at least the image object portion of the file to be printed when the image object has the preset attribute, so as to obtain a processed print file.
As can be seen from the foregoing, in practice, the obtaining module 51 is configured to perform the step S11, the identifying module 52 is configured to perform the step S12, the identifying module 53 is configured to perform the step S13, the determining module 53 is configured to perform the step S13, and the file processing module 54 is configured to perform the step S14. The details of the above steps S11-S14 have been described in detail in the above embodiments of the file printing control method, and will not be described herein again.
Further, it is understood that, in an embodiment, the obtaining module 51 may include an obtaining unit and a converting unit, wherein the obtaining unit is configured to obtain an initial file, and the converting unit is configured to convert the initial file into a file to be printed in a preset format. The file processing module 54 may perform the optimization processing on the file to be printed to obtain the processed printed file, and specifically, the file processing module 54 includes a file format conversion module GhostScript that performs the optimization processing or calls the file format conversion module GhostScript to perform the optimization processing.
Referring to fig. 8, fig. 8 is a block diagram of a document processing apparatus 70 to be printed according to an embodiment of the present invention. The document to be printed processing apparatus 70 may be configured to execute the document to be printed processing method of the above-described embodiment (as shown in fig. 5), and may include an initial document for executing the document to be printed processing method of the above-described embodiment. Specifically, the device 70 for processing a document to be printed may include an obtaining module 51, an identifying module 52, a determining module 53, a document processing module 54, and a converting module 55.
The obtaining module 51 is used for obtaining a file to be printed. The identification module 52 is used for identifying the image object in the file to be printed. The determining module 53 is configured to determine whether the image object has a preset attribute. The file processing module 54 is configured to perform optimization processing on at least the image object portion of the file to be printed when the image object has the preset attribute, so as to obtain a processed print file.
The conversion module 55 is configured to convert the processed print file into a first print file, where the first print file is used to be sent to a printing device to control the printing device to print; the conversion module 55 is further configured to convert the file to be printed into a second print file when the image object does not have the preset attribute, where the second print file is used to be sent to the printing device to control the printing device to print.
As can be seen from the foregoing, in practice, the obtaining module 51 is configured to perform the step S11, the identifying module 52 is configured to perform the step S12, the identifying module 53 is configured to perform the step S13, the determining module 53 is configured to perform the step S13, the file processing module 54 is configured to perform the step S14, and the converting module 55 is configured to perform the steps S15 and S17. The details of the steps S11-S15 and S17 have been described in detail in the embodiments of the document printing control method, and will not be described herein again.
Further, it is understood that, in an embodiment, the obtaining module 51 may include an obtaining unit and a converting unit, wherein the obtaining unit is configured to obtain an initial file, and the converting unit is configured to convert the initial file into a file to be printed in a preset format. The file processing module 54 may perform the optimization processing on the file to be printed to obtain the processed printed file, and specifically, the file processing module 54 includes a file format conversion module GhostScript that performs the optimization processing or calls the file format conversion module GhostScript to perform the optimization processing.
In the file printing control method and device and the file to be printed processing method and device provided by the embodiment of the invention, whether the image object in the file to be printed has the preset attribute is identified and judged, when the image object has the preset attribute, at least the image object part of the file to be printed is optimized, so that the printing data with high complexity and poor portrait effect caused by the existence of the preset attribute is avoided, the generated printing data has low complexity and good portrait effect, the printing speed can be increased, the problem that the quality of the printed file image is influenced by the preset attribute can be improved, and the printed file image is smooth and pure.
In addition, through experimental comparison, as shown in fig. 9, if the image object of the file to be printed has a preset attribute of a mask, if the file to be printed is directly converted into a printer file and sent to a printing device for printing, due to the influence of the mask, each pixel point of the mask and each pixel point of the main image after the mask need to be respectively converted to obtain the printer file, the time from the generation of the file to be printed by an application program (such as WPS) to the completion of the file printing by the printing device is 68 seconds, and particularly, the size of the printer file directly converted from the file to be printed is 48.1MB, which results in a slow printing speed; however, for the same file to be printed with the preset attribute of the mask, if the image object has been optimized by the processing of the file printing control apparatus of the above embodiment, and then the image object after the optimization is converted into the printer file, that is, the file printing control method is performed, the file to be printed is converted into the first print file, and then the first print file is sent to the printing apparatus to be printed, the time from when the application program (such as WPS) generates the file to be printed to when the printing apparatus finishes printing the file is 13 seconds, and particularly, the size of the printer file directly converted from the file to be printed is 6.7MB, so that the printing speed is increased by 523%.
Referring to fig. 10, fig. 10 is a block diagram of an electronic device 90 according to an embodiment of the invention. The electronic device 90 may comprise a processor 91, a memory 92 and computer programs; wherein
A memory 92 for storing the computer program, which may also be a flash memory (flash). The computer programs are, for example, application programs, functional modules, etc. that implement the various method embodiments described above (as shown in fig. 1-5).
A processor 91 for executing the computer program stored in the memory to implement the steps of the above-described method embodiments (as shown in fig. 1-5). Reference may be made in particular to the description relating to the preceding method embodiment.
Alternatively, the memory 92 may be separate or integrated with the processor 91.
When the memory 92 is a device independent of the processor 91, the electronic device 90 may further include:
a bus 93 for connecting the memory 92 and the processor 91.
The invention also provides a readable storage medium, in which a computer program is stored, which computer program, when being executed by a processor, is adapted to carry out the method of the above-mentioned method embodiments (as shown in fig. 1-4).
The readable storage medium may be a computer storage medium or a communication medium. Communication media includes any medium that facilitates transfer of a computer program from one place to another. Computer storage media may be any available media that can be accessed by a general purpose or special purpose computer. For example, a readable storage medium is coupled to the processor such that the processor can read information from, and write information to, the readable storage medium. Of course, the readable storage medium may also be an integral part of the processor. The processor and the readable storage medium may reside in an Application Specific Integrated Circuits (ASIC). Additionally, the ASIC may reside in user equipment. Of course, the processor and the readable storage medium may also reside as discrete components in a communication device.
The present invention also provides a program product comprising execution instructions stored in a readable storage medium. The executable instructions may be read from a readable storage medium by at least one processor of the device, and execution of the executable instructions by the at least one processor causes the device to implement the methods of the various method embodiments described above (as shown in fig. 1-5).
In the above embodiments of the electronic device, it should be understood that the Processor may be a Central Processing Unit (CPU), other general-purpose processors, a Digital Signal Processor (DSP), an Application Specific Integrated Circuit (ASIC), etc. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like. The steps of a method disclosed in connection with the present invention may be embodied directly in a hardware processor, or in a combination of the hardware and software modules within the processor.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solution of the present invention, and not to limit the same; while the invention has been described in detail and with reference to the foregoing embodiments, it will be understood by those skilled in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some or all of the technical features may be equivalently replaced; and the modifications or the substitutions do not make the essence of the corresponding technical solutions depart from the scope of the technical solutions of the embodiments of the present invention.

Claims (12)

1. A method for processing a file to be printed is characterized in that: the method comprises the following steps:
acquiring a file to be printed;
identifying an image object in the file to be printed;
judging whether the image object has a preset attribute or not; and
and if the image object has the preset attribute, optimizing at least the image object part of the file to be printed to obtain a processed printed file.
2. The method of claim 1, wherein: the preset attribute comprises a mask; the acquiring of the file to be printed includes: and acquiring an initial file, and converting the initial file into the file to be printed in a preset format.
3. The method of claim 1, wherein: the optimization processing comprises at least one of removing transparency and reducing compressibility; the transparency removal is realized by at least one of calling a file format conversion module GhostScript, using a PDF processing module, and performing screenshot processing on at least the image object part to obtain a screenshot image and covering the screenshot image on at least the image object part.
4. A file printing control method is characterized in that: the file printing control method according to any one of claims 1 to 3, the step of converting the processed print file into a first print file; sending the first printing file to printing equipment to control the printing equipment to print; if the image object does not have the preset attribute, converting the file to be printed into a second printing file, and sending the second printing file to the printing equipment to control the printing equipment to print.
5. The method of claim 4, wherein: the format of the file to be printed comprises a PDF format; the format of the processed print file comprises a PostScript format with an extension name of PS; the first print file and the second print file have the same format and can be identified and directly printed by the printing equipment.
6. A to-be-printed document processing apparatus characterized by: the device comprises:
the acquisition module is used for acquiring a file to be printed;
the identification module is used for identifying the image object in the file to be printed;
the judging module is used for judging whether the image object has a preset attribute or not; and
and the file processing module is used for optimizing at least the image object part of the file to be printed when the image object has the preset attribute so as to obtain a processed printed file.
7. The apparatus of claim 6, wherein: the preset attribute comprises a mask; the acquisition module comprises an acquisition unit and a conversion unit, wherein the acquisition unit is used for acquiring an initial file, and the conversion unit is used for converting the initial file into a file to be printed in a preset format.
8. The apparatus of claim 6, wherein: the optimization processing comprises at least one of removing transparency and reducing compressibility; the file processing module is realized by at least one of removing transparency of at least the image object part by calling a file format conversion module GhostScript, removing transparency of at least the image object part by using a PDF processing module, and performing screenshot processing on at least the image object part to obtain a screenshot image and covering at least the image object part with the screenshot image so as to remove transparency of at least the image object part.
9. A document printing control apparatus characterized by: the file printing control device comprises the file to be printed processing device, the conversion module and the sending module according to claims 6-8, wherein the conversion module is used for converting the processed print file into a first print file, the sending module is further used for sending the first print file to a printing device to control the printing device to print, the conversion module is further used for converting the file to be printed into a second print file when the image object does not have the preset attribute, and the sending module is further used for sending the second print file to the printing device to control the printing device to print.
10. The apparatus of claim 9, wherein: the format of the file to be printed comprises a PDF format; the format of the processed print file comprises a PostScript format with an extension name of PS; the first print file and the second print file have the same format and can be identified and directly printed by the printing equipment.
11. A readable storage medium, in which a computer program is stored which, when being executed by a processor, is adapted to carry out the method of any one of claims 1 to 4.
12. An electronic device, comprising: memory storing a computer program, a processor executing the computer program in the memory to perform the method of any of claims 1 to 4.
CN202010472869.1A 2020-05-29 2020-05-29 File processing method and device to be printed, file printing control method and device Active CN111596873B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010472869.1A CN111596873B (en) 2020-05-29 2020-05-29 File processing method and device to be printed, file printing control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010472869.1A CN111596873B (en) 2020-05-29 2020-05-29 File processing method and device to be printed, file printing control method and device

Publications (2)

Publication Number Publication Date
CN111596873A true CN111596873A (en) 2020-08-28
CN111596873B CN111596873B (en) 2024-02-23

Family

ID=72191559

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010472869.1A Active CN111596873B (en) 2020-05-29 2020-05-29 File processing method and device to be printed, file printing control method and device

Country Status (1)

Country Link
CN (1) CN111596873B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112162711A (en) * 2020-09-01 2021-01-01 珠海格力电器股份有限公司 Image file conversion method and device, electronic equipment and computer readable medium
CN112732206A (en) * 2021-01-07 2021-04-30 珠海奔图电子有限公司 Print control method, print driving apparatus, and computer-readable storage medium
CN114721613A (en) * 2022-06-08 2022-07-08 和众印网南京信息科技有限公司 Remote control method and system for printing machine

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB1186639A (en) * 1967-06-28 1970-04-02 Printing Dev Int Knock-Out Masking Techniques
US20010053299A1 (en) * 2000-06-05 2001-12-20 Fuji Xerox Co., Ltd. Recording medium outputting method, database server, recording medium outputting apparatus, and recording medium outputting system
JP2009230340A (en) * 2008-03-21 2009-10-08 Fuji Xerox Co Ltd Printing control device, program and system
JP2017107269A (en) * 2015-12-07 2017-06-15 株式会社リコー Information processing device, information distribution system, information distribution method and program
CN109101203A (en) * 2018-07-16 2018-12-28 森大(深圳)技术有限公司 For the image processing method of type drum, device, equipment and storage medium
CN109597592A (en) * 2018-12-03 2019-04-09 珠海趣印科技有限公司 A kind of App text intelligence Enhancement Method

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB1186639A (en) * 1967-06-28 1970-04-02 Printing Dev Int Knock-Out Masking Techniques
US20010053299A1 (en) * 2000-06-05 2001-12-20 Fuji Xerox Co., Ltd. Recording medium outputting method, database server, recording medium outputting apparatus, and recording medium outputting system
JP2009230340A (en) * 2008-03-21 2009-10-08 Fuji Xerox Co Ltd Printing control device, program and system
JP2017107269A (en) * 2015-12-07 2017-06-15 株式会社リコー Information processing device, information distribution system, information distribution method and program
CN109101203A (en) * 2018-07-16 2018-12-28 森大(深圳)技术有限公司 For the image processing method of type drum, device, equipment and storage medium
CN109597592A (en) * 2018-12-03 2019-04-09 珠海趣印科技有限公司 A kind of App text intelligence Enhancement Method

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112162711A (en) * 2020-09-01 2021-01-01 珠海格力电器股份有限公司 Image file conversion method and device, electronic equipment and computer readable medium
CN112732206A (en) * 2021-01-07 2021-04-30 珠海奔图电子有限公司 Print control method, print driving apparatus, and computer-readable storage medium
WO2022148150A1 (en) * 2021-01-07 2022-07-14 珠海奔图电子有限公司 Print control method, print driving apparatus, and computer readable storage medium
CN114721613A (en) * 2022-06-08 2022-07-08 和众印网南京信息科技有限公司 Remote control method and system for printing machine
CN114721613B (en) * 2022-06-08 2022-08-16 和众印网南京信息科技有限公司 Remote control method and system for printing machine

Also Published As

Publication number Publication date
CN111596873B (en) 2024-02-23

Similar Documents

Publication Publication Date Title
CN111596873B (en) File processing method and device to be printed, file printing control method and device
US10291794B2 (en) Implementation of distributed processing using device, information processing apparatus, information processing system, and information processing method to reduce network lag
US20130219261A1 (en) Apparatus, information processing system, and information processing method
CN112732206A (en) Print control method, print driving apparatus, and computer-readable storage medium
US20150077773A1 (en) Image forming method, non-transitory computer readable storage medium stored with program for image forming system, and image forming system
US20070223025A1 (en) Printing Apparatus and Method, Computer-Readable Medium, and Computer Data Signal
US8319988B2 (en) Job auditing systems and methods for direct imaging of documents
US20230388427A1 (en) Image processing system, image processing apparatus, and image processing method
US8194269B2 (en) Image forming method and system using XHTML-print data
JP2009032186A (en) Image processor, control method thereof, program therefor, and storage medium
US20130185318A1 (en) Data providing apparatus, electronic apparatus, data processing system, and method of data processing
US9413841B2 (en) Image processing system, image processing method, and medium
JP2006172284A (en) Image processor, image processing method, computer program
US10592179B2 (en) Information processing apparatus, information processing system and information processing method for executing document reading processing
CN114356256A (en) Image processing method, equipment terminal and storage medium
JP2000284926A (en) Print processing system and its method
CN107797776B (en) Method and system for processing linearized and non-linearized PDF files
US11494135B2 (en) Information processing apparatus, control method for information processing apparatus, and storage medium
JP2006235935A (en) Printing system
EP4075256B1 (en) Method, apparatus, and system for controlling voice print
US10275194B2 (en) Electronic device for file conversion
US20020089690A1 (en) Delivering a file to a server for printing
US20230231956A1 (en) Information processing apparatus, non-transitory computer readable medium, and information processing method
JP2008124902A (en) Image processor and image processing program
CN115690813A (en) Watermark information processing method, watermark information processing device, image forming apparatus, and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant