CN109559322A - Image processing method, device, storage medium and electronic equipment - Google Patents
Image processing method, device, storage medium and electronic equipment Download PDFInfo
- Publication number
- CN109559322A CN109559322A CN201811464326.4A CN201811464326A CN109559322A CN 109559322 A CN109559322 A CN 109559322A CN 201811464326 A CN201811464326 A CN 201811464326A CN 109559322 A CN109559322 A CN 109559322A
- Authority
- CN
- China
- Prior art keywords
- image
- original image
- painting canvas
- split
- subgraphs
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/11—Region-based segmentation
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/10—Segmentation; Edge detection
- G06T7/13—Edge detection
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- Image Processing (AREA)
Abstract
The embodiment of the present application provides a kind of image processing method, device, storage medium and electronic equipment, is related to technical field of image processing.Method includes: to obtain original image to be split and create interim painting canvas;Original image is divided into multiple subgraphs by the size based on interim painting canvas, and determines location information of the every subgraph in original image;Multiple subgraphs and corresponding location information are sent to receiving end, so that receiving end splices multiple subgraphs and obtains original image.Original image can be divided into multiple subgraphs and based on the interim painting canvas created in web is applied, location information of the every subgraph determined when so that receiving end is based on segmentation in original image, and multiple subgraphs can be spliced and obtain original image, and then realize by dividing and export to obtain completely and clearly original image.
Description
Technical field
This application involves technical field of image processing, are situated between in particular to a kind of image processing method, device, storage
Matter and electronic equipment.
Background technique
Show image using the web application (World Wide Web, global wide area network or WWW) on browser
Through being widely used.
The web application of browser by the displaying on a web browser of the very big image overall of some sizes or can pass through contracting
Put the local detail for showing image on a web browser.But common technology of the painting canvas technology as browser end drawing image, by
It is limited in by browser itself, it is difficult to which complete and clearly big picture image is exported by existing painting canvas.
Therefore, the web of browser is complete using upper export and clearly big picture image, is current urgently to be resolved ask
Topic.
Summary of the invention
The application is to provide a kind of image processing method, device, storage medium and electronic equipment, existing with effective solution
There is the web of browser in technology to be difficult to export complete and clearly big picture image using existing painting canvas using upper.
Embodiments herein is accomplished in that
In a first aspect, the embodiment of the present application provides a kind of image processing method, which comprises
It obtains original image to be split and creates interim painting canvas;
The original image is divided into multiple subgraphs by the size based on the interim painting canvas, and determines every subgraph
Location information in the original image;
Multiple described subgraphs and corresponding location information are sent to receiving end, so that multiple described sons of receiving end splicing
Image obtains the original image.
In this application, original image can be divided into multiple and based on the interim painting canvas created in web is applied
Subgraph.Therefore, the every subgraph determined after multiple subgraphs being sent to receiving end, when so that receiving end is based on segmentation exists
Location information in original image, and multiple subgraphs can be spliced and obtain original image, and then realize and exported by dividing
To complete and clearly original image.
With reference to first aspect, described to obtain original image to be split and create interim in some possible implementations
Painting canvas, comprising:
Remove background image from the image to be sent limited more than browser, obtains original image to be split;Based on clear
Device of looking at limitation, determines the size for the subgraph that the original image is divided into, and create the interim painting canvas of correspondingly-sized.
In this application, it is created since the interim painting canvas of creation is the limitation based on browser, so that creation
The size of interim painting canvas is big as far as possible, therefore can reduce the number of segmentation, reduces the operation realized in difficulty and cutting procedure
Amount.
With reference to first aspect, in some possible implementations, the size based on the interim painting canvas will be described
Original image is divided into multiple subgraphs, comprising:
The original image to be split is covered on the painting canvas, using the method for positional shift, to the original image
It is displaced, every subgraph is drawn out on the interim painting canvas, obtain the coding of graphics data of every subgraph;
It is described that multiple described subgraphs and corresponding location information are sent to receiving end, comprising:
The coding of graphics data of every subgraph in multiple described subgraphs and corresponding location information are sent to and are connect
Receiving end.
In this application, since displacement bias method is that the mobile relative to interim painting canvas of original image is carried out image point
Cut, thus can be more simple and convenient realization image segmentation, and can accurately also determine the position of each subgraph.
Second aspect, the embodiment of the present application provide a kind of image processing method, which comprises
Obtain multiple subgraphs and corresponding location information that transmitting terminal is sent, wherein multiple described subgraphs are described
Transmitting terminal is based on browser limitation and creates interim painting canvas, and the size based on interim painting canvas obtains original image segmentation to be split
Image;
Multiple described subgraphs are spliced, the original image to be split is obtained.
In this application, since receiving end can press corresponding location information by multiple subgraphs that will be exported and divide
Splicing, thus the original image to be split restored, therefore, by image segmentation and image mosaic realize export it is complete and
Clearly original image is to receiving end.
With reference to first aspect, in some possible implementations, multiple described subgraphs is spliced described, obtain institute
After stating original image to be split, which comprises
The original image to be split is synthesized with the background image received, obtains the figure to be sent of the transmitting terminal
Picture.
In this application, it since original image to be split is the image not comprising background image in original image, realizes
After subsequent splicing obtains this original image, user can increase background according to their own needs, so that the export of original image
It is more humanized.
The third aspect, the embodiment of the present application provide a kind of image processing apparatus, and described device includes:
Painting canvas creation module, for obtaining original image to be split and creating interim painting canvas.
The original image is divided into multiple subgraphs for the size based on the interim painting canvas by image segmentation module,
And determine location information of the every subgraph in the original image.
Image sending module, for multiple described subgraphs and corresponding location information to be sent to receiving end, so that connecing
Receiving end splices multiple described subgraphs and obtains the original image.
In conjunction with the third aspect, in some possible implementations,
The painting canvas creation module is also used to remove background image from the image to be sent limited more than browser, obtain
Obtain original image to be split;It is limited based on browser, determines the size for the subgraph that the original image is divided into, and create correspondence
The interim painting canvas of size.
In conjunction with the third aspect, in some possible implementations,
Described image divides module, is also used to for the original image to be split being covered on the painting canvas, using position
The method of offset is displaced the original image, and every subgraph is drawn out on the interim painting canvas, obtains every
The coding of graphics data of subgraph;
And described image divides module, is also used to the coding of graphics number of every subgraph in multiple described subgraphs
Accordingly and corresponding location information is sent to receiving end.
Fourth aspect, the embodiment of the present application provide a kind of image processing apparatus, and described device includes:
Image obtains module, for obtaining multiple subgraphs and corresponding location information of transmitting terminal transmission, wherein described
Multiple subgraphs are that the transmitting terminal is based on the interim painting canvas of browser limitation creation, and the size based on interim painting canvas will be to be split
Image obtained from original image segmentation.
Image mosaic module obtains the original image to be split for splicing multiple described subgraphs.
In conjunction with fourth aspect, in some possible implementations, described device further include:
Image synthesis module obtains described for synthesizing the original image to be split with the background image received
The image to be sent of transmitting terminal.
5th aspect, the embodiment of the present application provide a kind of calculating of non-volatile program code that can be performed with computer
The readable storage medium of machine, said program code make the computer execute such as first aspect and any realization side of first aspect
Image processing method described in formula or the image processing method as described in second aspect and any implementation of second aspect.
6th aspect, the embodiment of the present application provide a kind of electronic equipment, and the electronic equipment includes: processor, storage
Device, bus and communication module.The processor, the communication module and memory are connected by the bus.The memory,
For storing program.The processor, for by calling storage program in the memory with such as first aspect and
Image processing method described in any implementation of first aspect or such as second aspect and any implementation institute of second aspect
The image processing method stated.
To enable the above objects, features, and advantages of the application to be clearer and more comprehensible, preferred embodiment is cited below particularly, and cooperate
Appended attached drawing, is described in detail below.
Detailed description of the invention
Technical solution in ord to more clearly illustrate embodiments of the present application, below will be to needed in the embodiment attached
Figure is briefly described, it should be understood that the following drawings illustrates only some embodiments of the application, therefore is not construed as pair
The restriction of range for those of ordinary skill in the art without creative efforts, can also be according to this
A little attached drawings obtain other relevant attached drawings.
Fig. 1 shows a kind of structural block diagram of image processing system of the application first embodiment offer;
The structural block diagram of electronic equipment in a kind of image processing system provided Fig. 2 shows the application first embodiment;
Fig. 3 shows a kind of flow chart of image processing method of the application second embodiment offer;
Fig. 4 shows a kind of first structure block diagram of image processing apparatus of the application second embodiment offer;
Fig. 5 shows a kind of the second structural block diagram of image processing apparatus of the application 3rd embodiment offer.
Specific embodiment
Below in conjunction with attached drawing in the embodiment of the present application, technical solutions in the embodiments of the present application carries out clear, complete
Ground description, it is clear that described embodiments are only a part of embodiments of the present application, instead of all the embodiments.Usually exist
The component of the embodiment of the present application described and illustrated in attached drawing can be arranged and be designed with a variety of different configurations herein.Cause
This, is not intended to limit claimed the application's to the detailed description of the embodiments herein provided in the accompanying drawings below
Range, but it is merely representative of the selected embodiment of the application.Based on embodiments herein, those skilled in the art are not being done
Every other embodiment obtained under the premise of creative work out, shall fall in the protection scope of this application.
It should also be noted that similar label and letter indicate similar terms in following attached drawing, therefore, once a certain Xiang Yi
It is defined in a attached drawing, does not then need that it is further defined and explained in subsequent attached drawing.Term " first ", " the
Two " etc. are only used for distinguishing description, are not understood to indicate or imply relative importance.
First embodiment
Referring to Fig. 1, the embodiment of the present application provides a kind of image processing system 10, which includes:
Transmitting terminal 11 and receiving end 12.Communication connection is established in transmitting terminal 11 and receiving end 12.
Transmitting terminal 11 can be the application program operated on electronic equipment 20, and in the present embodiment, transmitting terminal 11 can be
Operate in the web application on the browser of electronic equipment 20.
Receiving end 12 can be the background program operated on electronic equipment 20, in the present embodiment, receiving end 12 and send
End 11 may operate on same electronic equipment 20, but in some cases, transmitting terminal 11 and receiving end 12 can also transport respectively
Row is on different electronic equipments 20.
As shown in Fig. 2, electronic equipment 20 can be terminal device.Wherein, terminal device can be PC
(personal computer, PC), tablet computer, smart phone, personal digital assistant (personal digital
Assistant, PDA) etc..
In the present embodiment, which may include: memory 21, communication interface 22, bus 23 and processor 24.
Wherein, processor 24, communication interface 22 and memory 21 are connected by bus 13.Processor 14 is deposited in memory 11 for executing
The executable module of storage, such as computer program.The component and structure of electronic equipment 20 shown in Fig. 2 are only exemplary, and
Unrestricted, as needed, electronic equipment 20 also can have other assemblies and structure.
Memory 21 may include high-speed random access memory (Random Access Memory RAM), it is also possible to also
Including non-labile memory (non-volatile memory), for example, at least a magnetic disk storage.In the present embodiment,
Memory 11 stores program required for executing image processing method.
Bus 23 can be isa bus, pci bus or eisa bus etc..It is total that bus can be divided into address bus, data
Line, control bus etc..Only to be indicated with a four-headed arrow in Fig. 2, it is not intended that an only bus or one convenient for indicating
The bus of seed type.
Processor 24 may be a kind of IC chip, the processing capacity with signal.During realization, above-mentioned side
Each step of method can be completed by the integrated logic circuit of the hardware in processor 14 or the instruction of software form.Above-mentioned
Processor 24 can be general processor, including central processing unit (Central Processing Unit, abbreviation CPU), network
Processor (Network Processor, abbreviation NP) etc.;It can also be digital signal processor (DSP), specific integrated circuit
(ASIC), ready-made programmable gate array (FPGA) either other programmable logic device, discrete gate or transistor logic,
Discrete hardware components.It may be implemented or execute disclosed each method, step and the logic diagram in the embodiment of the present invention.It is general
Processor can be microprocessor or the processor is also possible to any conventional processor etc..In conjunction with institute of the embodiment of the present invention
The step of disclosed method, can be embodied directly in hardware decoding processor and execute completion, or with the hardware in decoding processor
And software module combination executes completion.Software module can be located at random access memory, and flash memory, read-only memory may be programmed read-only
In the storage medium of this fields such as memory or electrically erasable programmable memory, register maturation.
Method performed by the device of stream process or definition that any embodiment of the embodiment of the present invention discloses can be applied to
In processor 24, or realized by processor 24.Processor 24 is stored in after receiving and executing instruction by the calling of bus 23
After program in memory 21, processor 24, which controls communication interface 22 by bus 23, can then execute the stream of image processing method
Journey.
Second embodiment
Referring to Fig. 3, the embodiment of the present application provides a kind of image processing method, which can be by sending
End or receiving end execute, which includes: step S100, step S200, step S300, step S400, step
S500 and step S600.
Step S100: it obtains original image to be split and creates interim painting canvas.
Step S200: the original image is divided into multiple subgraphs by the size based on the interim painting canvas, and is determined
Location information of the every subgraph in the original image.
Step S300: multiple described subgraphs and corresponding location information are sent to receiving end.
Step S400: multiple subgraphs and corresponding location information that transmitting terminal is sent are obtained.
Step S500: multiple described subgraphs are spliced, the original image to be split is obtained.
Step S600: the original image to be split is synthesized with the background image received, obtains the transmitting terminal
Image to be sent.
Each step in the application will be described in detail below.
Step S100: it obtains original image to be split and creates interim painting canvas.
Transmitting terminal can be the web application that image is shown based on the interim painting canvas technology of canvas, preset on transmitting terminal
The rule of picture step is created, so that the interim painting canvas of rule creation of the transmitting terminal based on creation picture step gone out is used as drawing
It makes, the carrier of displaying and deduced image.
Transmitting terminal can obtain image to be sent, and by showing that interface can show image to be sent, wherein send
End can be such as client.In general, the size of the image to be sent can be the limitation of the size more than browser,
Therefore user can also zoom in and out the image to be sent of displaying by operation transmitting terminal, so that image to be sent is showing boundary
It is global in face to show or locally shown in showing interface.Wherein, the mode that transmitting terminal obtains image to be sent can be with are as follows: uses
Image to be sent is imported into transmitting terminal at family or user can be drawn on the displaying interface of transmitting terminal by interacting with transmitting terminal
It produces image or transmitting terminal to be sent and passes through network under in the storage medium of other equipment (for example, server or database)
Carry the image to be sent.In practical applications, based on different application fields, the content carried on image to be sent is also
It is different.For example, image to be sent can be for for indicating that each equipment connection is closed in communication network when being applied in the communications field
The topological diagram of system;Or when being applied in photography, image to be sent can be the landscape image or portrait of big picture.
When user needs to export image to be sent from transmitting terminal, user can execute corresponding figure on transmitting terminal
As export operation, then, the image export operation for the user that transmitting terminal is detected by response, transmitting terminal can be based on browser
Limitation and the size of subgraph that needs to be divided into based on original image, be created that interim painting canvas.Wherein, what is be created that is interim
The size of painting canvas can be roughly the same with the subsequent size of subgraph for needing to be divided into, for example, being created that having a size of wide high
The interim painting canvas of 5000*5000.Certainly, user can also operate the interim painting canvas of transmitting terminal flexibly adjustment according to their own needs
Size, for example, transmitting terminal response user sizing operation, can temporarily will be drawn on the basis of 5000*5000
The size adjusting of cloth is the 4000*3000 or other sizes that client needs, but no more than the size of browser support, no
Image coded data can not then be obtained.
It is the explanation that can go out interim painting canvas in displaying showing interface with transmitting terminal to carry out in the present embodiment, but actually makes
In, transmitting terminal can be to be created that the interim painting canvas from the background, and can not have to show on the interim painting canvas, so that sending
End to the execution of image processing method is carried out in the state of user's unaware.
In addition, to be convenient for the segmentation of image, the image after avoiding segmentation generates trace transmitting terminal in splicing can be with
Background image will be removed in image to be sent, to obtain original image to be split.It is understood that remove background image to
The rest part that the original image of segmentation can be interpreted as on original image to be split other than figure is in pellucidity.
Transmitting terminal is based on the interim painting canvas being created that, and the original image based on the segmentation for removing background image, so that it may
Draw out the original image to be split again using original image to be split as sample on interim painting canvas using interim painting canvas as carrier
Picture.The size for the original image to be split drawn out is identical with the size of original image to be split of background image is removed, and draws
Figure on the figure on original image to be split produced and the original image to be split for removing background image is also identical, so as to
It can be split based on the original image to be split drawn out in transmitting terminal.
Step S200: the original image is divided into multiple subgraphs by the size based on the interim painting canvas, and is determined
Location information of the every subgraph in the original image.
For transmitting terminal before dividing the original image to be split, transmitting terminal may determine that whether the original image to be split has
Necessity is divided.
In the present embodiment, transmitting terminal judges whether original image to be split can be with it is necessary to divided mode are as follows: sends
The size of the original image to be split that end group obtains when drawing out original image to be split, it can be determined that the original to be split
Whether the size of image is greater than the size of interim painting canvas.
Optionally, whether transmitting terminal not only judges original image to be split it is necessary to be divided, and simultaneously, transmitting terminal is also
Original image to be split interim painting canvas can be based on to show on showing interface.The one of the original image to be split as display
Kind of optional way, since original image to be split is the drafting carried out using interim painting canvas as carrier, then draw out wait divide
The original image cut can be covered on interim painting canvas.But since the size of interim painting canvas is certain, therefore transmitting terminal can opened up
Show the image for showing that original image to be split is covered on the part on interim painting canvas display area on interface, wherein transmitting terminal
Face in the original image covering to be split after being overlapped of the center that can be original image to be split of display and the center of interim painting canvas
When painting canvas on image;But if there are also the images of other parts to have exceeded interim painting canvas for original image to be split, then transmitting terminal
Displaying interface can not have to show the image that this part exceeds, i.e., the image concealing exceeded this part.
If transmitting terminal judges that the size of original image to be split is less than or equal to the size of interim painting canvas, then sending end group
It determines in judging result without dividing original image to be split, and original image to be split is directly sent to receiving end.It can
To understand, in this case, original image to be split is also shown on interim painting canvas by whole.
If transmitting terminal judges that the size of original image to be split is less than or equal to the size of interim painting canvas, that is, judge to be split
The length of original image be greater than the length of interim painting canvas and/or judge the width for being wider than interim painting canvas of original image to be split, then
Transmitting terminal can be divided original image to be split based on judging result determination.It is appreciated that in this case, it is to be split
Original image also being shown on interim painting canvas by local.
When transmitting terminal determination can divide original image to be split, transmitting terminal can be according to the ruler of original image to be split
The size relation of the size of very little and interim painting canvas determines M part for needing to be partitioned on the original image to be split.
For example, the size of original image to be split is 9000*5000 if the size of interim painting canvas is 5000*5000, then
Transmitting terminal can be original image to be split according to the size relation of the size of the size and interim painting canvas of original image to be split
Nearly twice of length of a length of interim painting canvas.It needs to be partitioned into this way, transmitting terminal is assured that out on original image to be split
2 parts having a size of 5000*5000 and 4000*5000.In another example if the size of interim painting canvas is 5000*5000, it is to be split
The size of original image be 10000*10000, then transmitting terminal can size according to original image to be split and interim painting canvas
The size relation of size be twice of length of a length of interim painting canvas of original image to be split, and according to original image to be split
The size relation of the size of picture and the size of interim painting canvas is also that the width of original image to be split is wide twice of interim painting canvas.
In this way, transmitting terminal is assured that out 4 parts for needing to be partitioned into that size is 5000*5000 on original image to be split,
It this 4 parts can be by original image equal part to be split.
Each of it should be noted that for the size for each part divided as needed, the needs determined are divided
Partial shape is not necessarily the rectangle in the present embodiment, can also be adjusted according to the actual situation, for example, being each portion
Point shape can be with are as follows: triangle, polygon or regular shape at least one radian etc..Certainly, point to guarantee image
It cuts, no matter what the shape of each part is, the shape for requiring interim painting canvas is also same.
In the present embodiment, for convenient for accurately moving original image to be split during image segmentation, therefore can be with base
In multiple subgraphs that the needs determined are divided into, and determine that every subgraph is in original to be split in multiple subgraphs again
Location information in image.Optionally, location information of the every subgraph in original image to be split can be every subgraph
Coordinate of the central point of picture on original image to be split, but be not limited to central point, the location information of every subgraph can also be with
Location information for other points, such as every subgraph can also be the edge of every subgraph in original image to be split
On coordinate.
After the location information for determining multiple subgraphs and every subgraph that needs are divided, transmitting terminal can be according to multiple
Subgraph, in the physical slot of regularity, is determined to move this by positional shift to be split on original image to be split
The mobile route of original image.For example, original image to be split is divided into sphere of movements for the elephants by 4 parts on original image to be split,
So, transmitting terminal is in regular physical slot on original image to be split based on 4 parts, can determine mobile route
Are as follows: since first subgraph in the upper left corner, second subgraph, second subgraph from the upper right corner that are moved to the upper right corner
As being moved to the third subgraph in the lower right corner and being moved to the 4th Zhang Zi in the lower left corner from the third in the lower right corner subgraph
Image.
In this way, transmitting terminal is based on the mobile route of positional shift during movement original image to be split, so that it may
Image segmentation is carried out to original image to be split based on interim painting canvas.In the present embodiment, due to adjacent every two subgraphs
Segmentation process be it is identical, for convenient for skilled artisans appreciate that this programme, optionally, in multiple subgraphs being divided into
When as being M, M is the integer greater than 1, can with divide during movement original image to be split i-th subgraph and
It is illustrated for i+1 subgraph, wherein transmitting terminal can will successively during dividing original image to be split
True i is from 1 to M-1.
In detail, original image to be split is moved to original image to be split based on the mobile route of positional shift by transmitting terminal
When the i-th section of picture is covered on interim painting canvas, then transmitting terminal can will be covered on the image of the i-th section on interim painting canvas
As the image that can be extracted, therefore transmitting terminal can extract the image of i-th section, to obtain size no more than interim painting canvas
The coding of graphics data of i-th subgraph of size, and using the position of i-th section as the position of i-th subgraph.Obtain the
After i subgraphs, transmitting terminal can be determined according to the location information of i-th subgraph and the location information of i+1 subgraph
Out in mobile route the mobile original image to be split of i-th moving distance.Transmitting terminal can continue to move according to moving distance
The original image to be split is moved, so that original image to be split is after the mobile moving distance, i-th on original image to be split
+ 1 is partially covered on interim painting canvas.Transmitting terminal can be using the image for the i+1 part being covered on interim painting canvas as can be with
The image of extraction, therefore transmitting terminal can extract the image of i+1 part, to obtain size of the size no more than interim painting canvas
The coding of graphics data of i+1 subgraph.
It is understood that extracting the principle of the image of i-th section can be covered on for transmitting terminal based on the image of i-th section
On interim painting canvas, then being mapped to the image of i-th section on interim painting canvas, be formed on interim painting canvas and draw out this
The image of new i-th section, the image of the new i-th section then can be to extract i-th image.Extract i+1 part
The principle of image is identical as the principle of image of i-th section is extracted, then this is not just stated tired.
So, for transmitting terminal when determining i is M-1, transmitting terminal can determine the segmentation completed to original image to be split,
Therefore transmitting terminal is just based on being partitioned into every subgraph, and obtains the coding of graphics data of every subgraph.
Step S300: multiple described subgraphs and corresponding location information are sent to receiving end.
Transmitting terminal can obtain multiple subgraphs for supporting the picture format without background based on javascript native interface,
Wherein, the picture format of every subgraph can be such as png format in multiple subgraphs.Transmitting terminal can be by every son in this way
The coding of graphics data of image are sent to receiving end, and the location information of every subgraph is also sent to receiving end.It is necessary
When, M can also be opened the total quantity of subgraph by transmitting terminal and the unique identification of original image to be split is also sent to receiving end, with
Guarantee the integrality of information on receiving end.
Step S400: multiple subgraphs and corresponding location information that transmitting terminal is sent are obtained.
Correspondingly, receiving end can obtain the image coded data of multiple subgraphs based on the communication with transmitting terminal,
And obtain the location information of every subgraph.Necessity is also to obtain the total quantity of multiple subgraphs and to be split accordingly
The unique identification of original image is simultaneously stored accordingly.
Step S500: multiple described subgraphs are spliced, the original image to be split is obtained.
Receiving end can be based on the location information of every subgraph, and the image coded data based on every subgraph,
Multiple subgraphs are spliced, that is, the process spliced is according to the location information of every subgraph by the figure based on every subgraph
The every subgraph restored as coded data is put at corresponding position.So, every subgraph is all put into corresponding position
Behind place, the splicing of multiple subgraphs is just completed, multiple subgraphs positioned at corresponding position just constitute the original to be split
Image.
Certainly, a kind of optional mode is spliced into according to position progress image in the present embodiment, is not intended as this implementation
The restriction of example, in practice can also be also according to other implementations, for example, can carry out edge detection to every image, and base
Carry out stitching image in the result of edge detection.It is understood that the image of more complicated shape may be implemented in the mode of edge detection
Splicing.
Step S600: the original image to be split is synthesized with the background image received, obtains the transmitting terminal
Image to be sent.
The background image for being synthesized with original image to be split has been preset in receiving end, then, receiving end is being obtained
After obtaining original image to be split, original image to be split and preset background image can be synthesized, can thus be obtained
To the image to be sent of transmitting terminal.Certainly, it is to guarantee flexibility, the selection of user voluntarily can also be allowed according to the demand of user
The background image for needing to synthesize.For example, user may be selected, red background image is synthesized or user can choose bluetooth
Background image is synthesized or user is also an option that patterned background image synthesizes.In this way, transmitting terminal can
To respond the background image selection operation of user, the background image received and original image to be split are synthesized.In this way,
It is subsequent the image to be sent of the synthesis to be exported in the equipment that its needs stores.
Optionally, in order to enable the data volume of the image to be sent of synthesis is smaller, so that it exports or stores occupied
Resource is less, and the image to be sent that synthesis obtains can be converted to the image of such as jpg format.
3rd embodiment
Referring to Fig. 4, the embodiment of the present application provides a kind of image processing apparatus 100, the image processing apparatus 100 packet
It includes:
Painting canvas creation module 110, for obtaining original image to be split and creating interim painting canvas;
The original image is divided into multiple subgraphs for the size based on the interim painting canvas by image segmentation module 120
Picture, and determine location information of the every subgraph in the original image;
Image sending module 130, for multiple described subgraphs and corresponding location information to be sent to receiving end, so that
Splice multiple described subgraphs and obtain the original image in receiving end.
Optionally, the painting canvas creation module 110 is also used to remove back from the image to be sent limited more than browser
Scape image obtains original image to be split;It is limited based on browser, determines the size for the subgraph that the original image is divided into,
And create the interim painting canvas of correspondingly-sized;
Optionally, described image divides module 120, is also used to the original image to be split being covered on the painting canvas
On, using the method for positional shift, the original image is displaced, every subgraph is drawn out on the interim painting canvas
Come, obtains the coding of graphics data of every subgraph;
Optionally, and, described image divides module 120, is also used to every subgraph in multiple described subgraphs
Coding of graphics data and corresponding location information are sent to receiving end.
Referring to Fig. 5, the embodiment of the present application provides a kind of image processing apparatus 200, the image processing apparatus 200 packet
It includes:
Image obtains module 210, for obtaining multiple subgraphs and corresponding location information of transmitting terminal transmission, wherein
Multiple described subgraphs are that the transmitting terminal is based on the interim painting canvas of browser limitation creation, and the size based on interim painting canvas will be wait divide
Image obtained from the original image segmentation cut;
Image mosaic module 220 obtains the original image to be split for splicing multiple described subgraphs.
Image synthesis module 230 obtains institute for synthesizing the original image to be split with the background image received
State the image to be sent of transmitting terminal.
It should be noted that due to it is apparent to those skilled in the art that, for the convenience and letter of description
Clean, system, the specific work process of device and unit of foregoing description can be with reference to corresponding in preceding method embodiment
Journey, details are not described herein.
It should be understood by those skilled in the art that, the embodiment of the present application can provide as the production of method, system or computer program
Product.Therefore, in terms of the embodiment of the present application can be used complete hardware embodiment, complete software embodiment or combine software and hardware
Embodiment form.Moreover, it wherein includes computer available programs generation that the embodiment of the present application, which can be used in one or more,
The meter implemented in the computer-usable storage medium (including but not limited to magnetic disk storage, CD-ROM, optical memory etc.) of code
The form of calculation machine program product.
In conclusion the embodiment of the present application provides a kind of image processing method, device, storage medium and electronic equipment,
Method includes: to obtain original image to be split and create interim painting canvas;Original image is divided into more by the size based on interim painting canvas
Subgraph is opened, and determines location information of the every subgraph in original image;By multiple subgraphs and corresponding location information
It is sent to receiving end, so that receiving end splices multiple subgraphs and obtains original image.
Original image can be divided into multiple subgraphs and based on the interim painting canvas created in web is applied.Therefore,
Position of the every subgraph determined after multiple subgraphs are sent to receiving end, when so that receiving end is based on segmentation in original image
Confidence breath, and can splice multiple subgraphs and obtain original image, so realize by dividing export to obtain it is complete and clear
Original image.
The above is only preferred embodiment of the present application, are not intended to limit this application, for those skilled in the art
For member, various changes and changes are possible in this application.Within the spirit and principles of this application, it is made it is any modification,
Equivalent replacement, improvement etc., should be included within the scope of protection of this application.It should also be noted that similar label and letter are under
Similar terms are indicated in the attached drawing in face, therefore, once being defined in a certain Xiang Yi attached drawing, are not then needed in subsequent attached drawing
It is further defined and explained.
More than, the only specific embodiment of the application, but the protection scope of the application is not limited thereto, and it is any to be familiar with
Those skilled in the art within the technical scope of the present application, can easily think of the change or the replacement, and should all cover
Within the protection scope of the application.Therefore, the protection scope of the application should be subject to the protection scope in claims.
Claims (12)
1. a kind of image processing method, which is characterized in that the described method includes:
It obtains original image to be split and creates interim painting canvas;
The original image is divided into multiple subgraphs by the size based on the interim painting canvas, and determines every subgraph in institute
State the location information in original image;
Multiple described subgraphs and corresponding location information are sent to receiving end, so that multiple described subgraphs are spliced in receiving end
Obtain the original image.
2. image processing method according to claim 1, which is characterized in that described to obtain original image to be split and creation
Interim painting canvas, comprising:
Remove background image from the image to be sent limited more than browser, obtains original image to be split;Based on browser
Limitation, determines the size for the subgraph that the original image is divided into, and create the interim painting canvas of correspondingly-sized.
3. image processing method according to claim 1 or 2, which is characterized in that the ruler based on the interim painting canvas
It is very little that the original image is divided into multiple subgraphs, comprising:
The original image to be split is covered on the painting canvas, using the method for positional shift, the original image is carried out
Displacement, every subgraph is drawn out on the interim painting canvas, obtains the coding of graphics data of every subgraph;
It is described that multiple described subgraphs and corresponding location information are sent to receiving end, comprising:
The coding of graphics data of every subgraph in multiple described subgraphs and corresponding location information are sent to receiving end.
4. a kind of image processing method, which is characterized in that the described method includes:
Obtain multiple subgraphs and corresponding location information that transmitting terminal is sent, wherein multiple described subgraphs are the transmission
End group creates interim painting canvas in browser limitation, and the size based on interim painting canvas is schemed obtained from dividing original image to be split
Picture;
Multiple described subgraphs are spliced, the original image to be split is obtained.
5. image processing method according to claim 4, which is characterized in that multiple described subgraphs are spliced described,
After obtaining the original image to be split, which comprises
The original image to be split is synthesized with the background image received, obtains the image to be sent of the transmitting terminal.
6. a kind of image processing apparatus, which is characterized in that described device includes:
Painting canvas creation module, for obtaining original image to be split and creating interim painting canvas;
The original image is divided into multiple subgraphs for the size based on the interim painting canvas by image segmentation module, and really
Make location information of the every subgraph in the original image;
Image sending module, for multiple described subgraphs and corresponding location information to be sent to receiving end, so that receiving end
Splice multiple described subgraphs and obtains the original image.
7. image processing apparatus according to claim 6, which is characterized in that
The painting canvas creation module, is also used to from being more than to remove background image in image to be sent that browser limits, obtain to
The original image of segmentation;It is limited based on browser, determines the size for the subgraph that the original image is divided into, and create correspondingly-sized
Interim painting canvas.
8. image processing apparatus according to claim 7, which is characterized in that
Described image divides module, is also used to for the original image to be split being covered on the painting canvas, using positional shift
Method, the original image is displaced, every subgraph is drawn out on the interim painting canvas, obtain every subgraph
The coding of graphics data of picture;
And described image divide module, be also used to by the coding of graphics data of every subgraph in multiple described subgraphs with
And corresponding location information is sent to receiving end.
9. a kind of image processing apparatus, which is characterized in that described device includes:
Image obtain module, for obtain transmitting terminal transmission multiple subgraphs and corresponding location information, wherein it is described multiple
Subgraph is that the transmitting terminal is based on browser limitation and creates interim painting canvas, and the size based on interim painting canvas is by original image to be split
The image as obtained from segmentation;
Image mosaic module obtains the original image to be split for splicing multiple described subgraphs.
10. image processing apparatus according to claim 9, which is characterized in that described device further include:
Image synthesis module obtains the transmission for synthesizing the original image to be split with the background image received
The image to be sent at end.
11. a kind of computer-readable storage media for the non-volatile program code that can be performed with computer, which is characterized in that institute
Stating program code makes the computer execute image processing method or such as claim as described in any claim of claim 1-3
Image processing method described in 4 or 5.
12. a kind of electronic equipment, which is characterized in that the electronic equipment includes: processor, memory, bus and communication module;
The processor, the communication module and memory are connected by the bus;
The memory, for storing program;
The processor, for by calling the program of storage in the memory with any claim institute of such as claim 1-3
The image processing method or image processing method as described in claim 4 or 5 stated.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811464326.4A CN109559322A (en) | 2018-11-30 | 2018-11-30 | Image processing method, device, storage medium and electronic equipment |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201811464326.4A CN109559322A (en) | 2018-11-30 | 2018-11-30 | Image processing method, device, storage medium and electronic equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN109559322A true CN109559322A (en) | 2019-04-02 |
Family
ID=65868565
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201811464326.4A Pending CN109559322A (en) | 2018-11-30 | 2018-11-30 | Image processing method, device, storage medium and electronic equipment |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN109559322A (en) |
Cited By (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110675465A (en) * | 2019-09-23 | 2020-01-10 | 京东数字科技控股有限公司 | Method and apparatus for generating image |
CN110838152A (en) * | 2019-10-21 | 2020-02-25 | 稿定(厦门)科技有限公司 | Quick screenshot method and device after multi-layer mixing |
CN111161283A (en) * | 2019-12-26 | 2020-05-15 | 可牛网络技术(北京)有限公司 | Method and device for processing picture resources and electronic equipment |
CN111752512A (en) * | 2020-05-21 | 2020-10-09 | 西安万像电子科技有限公司 | Image processing system and method |
CN112306339A (en) * | 2020-09-01 | 2021-02-02 | 北京沃东天骏信息技术有限公司 | Method and apparatus for displaying image |
CN112767419A (en) * | 2021-01-29 | 2021-05-07 | 福建天晴在线互动科技有限公司 | Method and system for cutting nine-grid of atlas |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103268340A (en) * | 2013-05-21 | 2013-08-28 | 龚如宾 | Format reflowable file establishing and drawing method based on hierarchical index |
CN104867105A (en) * | 2015-05-30 | 2015-08-26 | 北京金山安全软件有限公司 | Picture processing method and device |
CN106934764A (en) * | 2016-11-03 | 2017-07-07 | 阿里巴巴集团控股有限公司 | A kind of image processing method, device |
CN107291476A (en) * | 2017-06-27 | 2017-10-24 | 北京微影时代科技有限公司 | Canvas code generating methods, device, electronic equipment and storage medium |
-
2018
- 2018-11-30 CN CN201811464326.4A patent/CN109559322A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103268340A (en) * | 2013-05-21 | 2013-08-28 | 龚如宾 | Format reflowable file establishing and drawing method based on hierarchical index |
CN104867105A (en) * | 2015-05-30 | 2015-08-26 | 北京金山安全软件有限公司 | Picture processing method and device |
CN106934764A (en) * | 2016-11-03 | 2017-07-07 | 阿里巴巴集团控股有限公司 | A kind of image processing method, device |
CN107291476A (en) * | 2017-06-27 | 2017-10-24 | 北京微影时代科技有限公司 | Canvas code generating methods, device, electronic equipment and storage medium |
Non-Patent Citations (1)
Title |
---|
张铎: "基于瓦片数据的WebGIS三维可视化研究", 《中国优秀硕士学位论文全文数据库基础科学辑》 * |
Cited By (9)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN110675465A (en) * | 2019-09-23 | 2020-01-10 | 京东数字科技控股有限公司 | Method and apparatus for generating image |
CN110675465B (en) * | 2019-09-23 | 2024-02-06 | 京东科技控股股份有限公司 | Method and apparatus for generating image |
CN110838152A (en) * | 2019-10-21 | 2020-02-25 | 稿定(厦门)科技有限公司 | Quick screenshot method and device after multi-layer mixing |
CN110838152B (en) * | 2019-10-21 | 2023-04-25 | 稿定(厦门)科技有限公司 | Method and device for quickly capturing images after multi-layer mixing |
CN111161283A (en) * | 2019-12-26 | 2020-05-15 | 可牛网络技术(北京)有限公司 | Method and device for processing picture resources and electronic equipment |
CN111752512A (en) * | 2020-05-21 | 2020-10-09 | 西安万像电子科技有限公司 | Image processing system and method |
CN112306339A (en) * | 2020-09-01 | 2021-02-02 | 北京沃东天骏信息技术有限公司 | Method and apparatus for displaying image |
CN112767419A (en) * | 2021-01-29 | 2021-05-07 | 福建天晴在线互动科技有限公司 | Method and system for cutting nine-grid of atlas |
CN112767419B (en) * | 2021-01-29 | 2024-01-30 | 福建天晴在线互动科技有限公司 | Method and system for cutting nine palace lattice of atlas |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN109559322A (en) | Image processing method, device, storage medium and electronic equipment | |
CN112184738B (en) | Image segmentation method, device, equipment and storage medium | |
CN107491174B (en) | Method, device and system for remote assistance and electronic equipment | |
CN109461199B (en) | Picture rendering method and device, storage medium and electronic device | |
JP5704363B2 (en) | Automatic synchronous navigation system for digital pathological images | |
JP6096634B2 (en) | 3D map display system using virtual reality | |
CN111833447A (en) | Three-dimensional map construction method, three-dimensional map construction device and terminal equipment | |
CN111290684B (en) | Image display method, image display device and terminal equipment | |
CN108882025A (en) | Video frame treating method and apparatus | |
CN110657804A (en) | Indoor location services | |
CN111429518A (en) | Labeling method, labeling device, computing equipment and storage medium | |
CN112487331A (en) | Page generation method and device, storage medium and electronic equipment | |
CN109978044A (en) | The training method and device of training data generation method and device and model | |
CN112232341A (en) | Text detection method, electronic device and computer readable medium | |
CN114332648B (en) | Position identification method and electronic equipment | |
CN117078888A (en) | Virtual character clothing generation method and device, medium and electronic equipment | |
CN113835595A (en) | Picture display method and device, electronic equipment and computer storage medium | |
CN110688116A (en) | Image file analysis method, device, equipment and readable medium | |
CN114356264B (en) | Signal generation method, device, equipment and readable storage medium | |
CN109115238A (en) | Map-indication method, device and equipment | |
CN113506356B (en) | Method and device for drawing area map, readable medium and electronic equipment | |
CN113961296A (en) | Page element layout method and device, readable medium and electronic equipment | |
KR102534449B1 (en) | Image processing method, device, electronic device and computer readable storage medium | |
CN114494960A (en) | Video processing method and device, electronic equipment and computer readable storage medium | |
US20220279234A1 (en) | Live stream display method and apparatus, electronic device, and readable 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 | ||
RJ01 | Rejection of invention patent application after publication | ||
RJ01 | Rejection of invention patent application after publication |
Application publication date: 20190402 |