CN102682415A - Image processing method and device - Google Patents

Image processing method and device Download PDF

Info

Publication number
CN102682415A
CN102682415A CN2011100565056A CN201110056505A CN102682415A CN 102682415 A CN102682415 A CN 102682415A CN 2011100565056 A CN2011100565056 A CN 2011100565056A CN 201110056505 A CN201110056505 A CN 201110056505A CN 102682415 A CN102682415 A CN 102682415A
Authority
CN
China
Prior art keywords
pixel
data
channel data
deal
characteristic
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
CN2011100565056A
Other languages
Chinese (zh)
Other versions
CN102682415B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent Technology Shenzhen 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201110056505.6A priority Critical patent/CN102682415B/en
Publication of CN102682415A publication Critical patent/CN102682415A/en
Application granted granted Critical
Publication of CN102682415B publication Critical patent/CN102682415B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention provides an image processing method and device, wherein the method comprises the following steps of: deleting characteristic channel data of each pixel in an original image so as to obtain processing data corresponding with the pixel; and forming a processing image by using each obtained processing data according to the location of each pixel corresponding with each processing data in the original image. By using the image processing method and device, provided by the invention, image storage resources can be reduced.

Description

Image processing method and device
Technical field
The present invention relates to the picture treatment technology, particularly image processing method and device.
Background technology
In existing 2D recreation, picture resource is excessive not only can to reduce the games operational efficiency, the difficulty of operation in the time of also can increasing the recreation issue simultaneously.Though a lot of at present recreation; Adopted picture resource to be merged into the drafting number of times that a whole method of magnifying picture reduces picture resource quantity and scene of game with a map in all recreation; But; Can must not carry out any processing to picture, such as piecemeal owing to the resource that should whole magnify picture is very huge so on the one hand; Also need Load Image according to player position at that time on the other hand, so that composing picture, this has just improved the games development difficulty greatly.
Therefore, a kind of image processing method that simply, effectively reduces the picture-storage resource is the current technical matters that needs to be resolved hurrily.
Summary of the invention
The invention provides image processing method, so that reduce the picture-storage resource.
Technical scheme provided by the invention comprises:
A kind of image processing method, this method comprises:
Characteristic channel data to each pixel in the original image is deleted processing, obtains deal with data that should pixel;
Each deal with data that obtains is formed the processing picture according to the corresponding position of each pixel in original image of this each deal with data.
A kind of figure piece treating apparatus comprises:
Processing unit is used for the characteristic channel data of each pixel of original image is deleted processing, obtains deal with data that should pixel;
Component units is used for each deal with data that obtains is formed the processing picture according to each corresponding pixel of this each deal with data in the position of original image.
Can find out by above technical scheme; The present invention also is combined into a whole picture that magnifies unlike the prior art that kind with all original images; But delete processing to each characteristic channel data of opening each pixel of original image; Obtain deal with data that should pixel, each deal with data that obtains is formed according to the corresponding position of each pixel in original image of this each deal with data handled picture.This obviously can reduce the picture-storage resource.
Description of drawings
The basic flow sheet that Fig. 1 provides for the embodiment of the invention;
Fig. 2 is four characteristic channel data synoptic diagram of a pixel in the original image provided by the invention;
The pixel I corresponding memory space synoptic diagram that Fig. 3 provides for the embodiment of the invention;
The pixel I that Fig. 4 provides for the embodiment of the invention is to the synoptic diagram after the data processing of R passage;
The pixel I that Fig. 5 provides for the embodiment of the invention is to the synoptic diagram after the data processing of G passage;
The pixel I that Fig. 6 provides for the embodiment of the invention is to the synoptic diagram after the data processing of B passage;
The pixel I corresponding processing schematic diagram data that Fig. 7 provides for the embodiment of the invention;
The structure drawing of device that Fig. 8 provides for the embodiment of the invention.
Embodiment
In order to make the object of the invention, technical scheme and advantage clearer, describe the present invention below in conjunction with accompanying drawing and specific embodiment.
The basic flow sheet that Fig. 1 provides for the embodiment of the invention.As shown in Figure 1, this flow process can may further comprise the steps:
Step 101 is deleted processing to the characteristic channel data of each pixel in the original image, obtains deal with data that should pixel.
In the present embodiment, the characteristic channel data of each pixel in the original image is deleted that handling is to carry out according to the principle of the picture precision that guarantees setting.
Step 102 is formed the processing picture with each deal with data that obtains according to the corresponding position of each pixel in original image of this each deal with data.Afterwards, issue as the scene picture of recreation handling picture.
So far, accomplish flow process shown in Figure 1.
In flow process shown in Figure 1; The characteristic channel data of each pixel comprises: three Color Channel data and transparent (ALPHA) channel data; Wherein, three Color Channel data are: red (R) channel data, green (G) channel data and blueness (B) channel data.Usually, in the original image, the size of each pixel is 32, and the size of each characteristic channel data is 8.Based on this, above-mentioned steps 101 is concrete can be comprised when realizing: to each pixel, obtain the data on each characteristic passage of this pixel; To each characteristic channel data of this pixel, according to the preceding N position of this characteristic channel data of principles of selected that guarantees the picture precision, said N is greater than 1; To merge successively from the data that each characteristic channel data is chosen, form deal with data that should pixel.
Be that 4 pairs of embodiment of the invention are described in detail with N below:
At first, from original image, obtain four characteristic channel datas of a pixel.Referring to Fig. 2, Fig. 2 is four characteristic channel data synoptic diagram of a pixel in the original image provided by the invention.
Preferably, for the ease of depositing each pixel corresponding processing data, also need set up corresponding memory space for this pixel (being designated as pixel I).Because the N value is 4, then this storage space can be set to 16 and gets final product, specifically referring to Fig. 3.
Next, elder generation copies the preceding four figures certificate on the R passage of pixel I to 0 to 3 of storage space shown in Figure 3.Also promptly, directly delete the back four figures certificate on the R passage, specifically referring to shown in Figure 4.
Once more, with the preceding four figures on the G passage of pixel I according to copying 4 to 7 of storage space shown in Figure 3 to.Also promptly, directly delete the back four figures certificate on the G passage, specifically referring to shown in Figure 5.
Afterwards, with the preceding four figures on the B passage of pixel I according to copying 8 to 11 of storage space shown in Figure 3 to.Also promptly, directly delete the back four figures certificate on the B passage, specifically referring to shown in Figure 6.
At last, with the preceding four figures on the alpha channel of pixel I according to copying 12 to 15 of storage space shown in Figure 3 to.Also promptly, directly delete the back four figures certificate on the alpha channel, specifically referring to shown in Figure 7.Data shown in Figure 7 are pixel I corresponding processing data.
So far, delete processing to the characteristic channel data completion of pixel I.Can find out from top description, through top processing, can be that 32 pixel I has converted 16 to a size.Afterwards, other pixels in the original image are all carried out according to top-operation, can obtain other pixel corresponding processing data.After all pixels in original image are all carried out according to top-operation, each deal with data that obtains is formed the processing picture according to the corresponding position of each pixel in original image of this each deal with data.It is half that this obviously can make the size of original image reduce, and reduces the picture-storage space.
So far, accomplish the description of the method that the embodiment of the invention provides.
The device that provides in the face of the embodiment of the invention is down described.
Referring to Fig. 8, the structure drawing of device that Fig. 8 provides for the embodiment of the invention.This device can be applicable in the online recreation of many people.As shown in Figure 8, this device can comprise:
Processing unit is used for the characteristic channel data of each pixel of original image is deleted processing, obtains deal with data that should pixel;
Component units is used for each deal with data that obtains is formed the processing picture according to each corresponding pixel of this each deal with data in the position of original image.
Wherein, said processing unit specifically comprises following subelement:
Obtain subelement, be used for obtaining the data of each characteristic passage on this pixel to each pixel;
Choose subelement, be used for each characteristic channel data of obtaining this pixel that subelement obtains to said, choose the preceding N position of this characteristic channel data, said N is greater than 1;
Merge subelement, be used for choosing the data that subelement chooses from each characteristic channel data and merging successively, form deal with data that should pixel with said.
In the present embodiment, the characteristic channel data of said each pixel comprises: three Color Channel data and transparent data, wherein, three Color Channel data are: red R channel data, green G channel data and blue B channel data.Wherein, said N is 4.
So far, accomplish the description of the device that the embodiment of the invention provides.
Can find out by above technical scheme; The present invention also is combined into a whole picture that magnifies unlike the prior art that kind with all original images; But delete processing to each characteristic channel data of opening each pixel of original image; Obtain deal with data that should pixel, each deal with data that obtains is formed according to the corresponding position of each pixel in original image of this each deal with data handled picture.This obviously can reduce the picture-storage resource.
The above is merely preferred embodiment of the present invention, and is in order to restriction the present invention, not all within spirit of the present invention and principle, any modification of being made, is equal to replacement, improvement etc., all should be included within the scope that the present invention protects.

Claims (8)

1. an image processing method is characterized in that, this method comprises:
Characteristic channel data to each pixel in the original image is deleted processing, obtains deal with data that should pixel;
Each deal with data that obtains is formed the processing picture according to the corresponding position of each pixel in original image of this each deal with data.
2. method according to claim 1 is characterized in that, said characteristic channel data to each pixel in the original image is deleted processing, obtains deal with data that should pixel is comprised:
To each pixel, obtain the data of each characteristic passage on this pixel;
To each characteristic channel data on this pixel, choose the preceding N position of this characteristic channel data, said N is greater than 1;
To merge successively from the data that each characteristic channel data is chosen, form deal with data that should pixel.
3. method according to claim 1 and 2; It is characterized in that; The characteristic channel data of said each pixel comprises: three Color Channel data and transparent channel data, wherein, three Color Channel data are: red R channel data, green G channel data and blue B channel data.
4. method according to claim 3 is characterized in that, said N is 4.
5. scheme piece treating apparatus for one kind, it is characterized in that said device comprises:
Processing unit is used for the characteristic channel data of each pixel of original image is deleted processing, obtains deal with data that should pixel;
Component units is used for each deal with data that obtains is formed the processing picture according to each corresponding pixel of this each deal with data in the position of original image.
6. device according to claim 5 is characterized in that, said processing unit comprises:
Obtain subelement, be used for obtaining the data of each characteristic passage on this pixel to each pixel;
Choose subelement, be used for each characteristic channel data of obtaining this pixel that subelement obtains to said, choose the preceding N position of this characteristic channel data, said N is greater than 1;
Merge subelement, be used for choosing the data that subelement chooses from each characteristic channel data and merging successively, form deal with data that should pixel with said.
7. according to claim 5 or 6 described devices; It is characterized in that; The characteristic channel data of said each pixel comprises: three Color Channel data and transparent channel data, wherein, three Color Channel data are: red R channel data, green G channel data and blue B channel data.
8. device according to claim 7 is characterized in that, said N is 4.
CN201110056505.6A 2011-03-09 2011-03-09 Image processing method and device Active CN102682415B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110056505.6A CN102682415B (en) 2011-03-09 2011-03-09 Image processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110056505.6A CN102682415B (en) 2011-03-09 2011-03-09 Image processing method and device

Publications (2)

Publication Number Publication Date
CN102682415A true CN102682415A (en) 2012-09-19
CN102682415B CN102682415B (en) 2015-02-18

Family

ID=46814287

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110056505.6A Active CN102682415B (en) 2011-03-09 2011-03-09 Image processing method and device

Country Status (1)

Country Link
CN (1) CN102682415B (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101106709A (en) * 2006-07-10 2008-01-16 逐点半导体(上海)有限公司 Image compression method
CN101742317A (en) * 2009-12-31 2010-06-16 北京中科大洋科技发展股份有限公司 Video compressing and encoding method with alpha transparent channel

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101106709A (en) * 2006-07-10 2008-01-16 逐点半导体(上海)有限公司 Image compression method
CN101742317A (en) * 2009-12-31 2010-06-16 北京中科大洋科技发展股份有限公司 Video compressing and encoding method with alpha transparent channel

Also Published As

Publication number Publication date
CN102682415B (en) 2015-02-18

Similar Documents

Publication Publication Date Title
US10861133B1 (en) Super-resolution video reconstruction method, device, apparatus and computer-readable storage medium
US20160323505A1 (en) Photographing processing method, device and computer storage medium
TWI695295B (en) Image processing method, device and electronic equipment based on augmented reality
CN107203966A (en) A kind of coloured image synthetic method and device
CN104361559B (en) A kind of image enlargement processing method and system based on small image memory
CN104639834A (en) Method and system for transmitting camera image data
CN108230454B (en) Panorama picture cutting method and device and storage medium
CN106296026A (en) A kind of virtual model based on BIM technology is led the way quality management-control method
US8786616B2 (en) Parallel processing for distance transforms
CN107204024A (en) Handle the method and device of sequence of pictures frame
CN111562869B (en) Screenshot method and device, storage medium and electronic device
CN110910485B (en) Immersion type cave image manufacturing method
CN103473754A (en) Novel mural digitalized archiving method
CN102129664B (en) Method for compressing, storing and restoring pixel information of RGB (Red, Green and Blue) space image region
CN102682415A (en) Image processing method and device
CN103942543B (en) A kind of image-recognizing method and device
TW200937340A (en) Method for processing image, methods for applying to digital photo frame and interaction image process
CN102982507A (en) Method and device of video image processing
CN100481880C (en) Method of searching mid value of pixel
CN104079915B (en) A kind of parallel virtual visual point synthesizing method
CN102685363A (en) Picture storing method for copying equipment
CN114677319A (en) Stem cell distribution determination method and device, electronic equipment and storage medium
CN111354058A (en) Image coloring method and device, image acquisition equipment and readable storage medium
CN103700132A (en) Wide area size rendering method for 3D (three dimensional) scene
CN104240191A (en) Batch-image enhancement processing method

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant