CN104616246B - A kind of method, apparatus and terminal device for handling image - Google Patents
A kind of method, apparatus and terminal device for handling image Download PDFInfo
- Publication number
- CN104616246B CN104616246B CN201510050059.6A CN201510050059A CN104616246B CN 104616246 B CN104616246 B CN 104616246B CN 201510050059 A CN201510050059 A CN 201510050059A CN 104616246 B CN104616246 B CN 104616246B
- Authority
- CN
- China
- Prior art keywords
- pending areas
- pending
- background images
- scaling
- images
- 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.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 43
- 238000009877 rendering Methods 0.000 claims abstract description 36
- 239000000203 mixture Substances 0.000 claims description 20
- 238000005516 engineering process Methods 0.000 abstract description 4
- 238000004891 communication Methods 0.000 abstract description 3
- 238000010586 diagram Methods 0.000 description 5
- 230000003321 amplification Effects 0.000 description 1
- 238000004364 calculation method Methods 0.000 description 1
- 230000009977 dual effect Effects 0.000 description 1
- 239000000284 extract Substances 0.000 description 1
- 238000007689 inspection Methods 0.000 description 1
- 238000010297 mechanical methods and process Methods 0.000 description 1
- 230000005226 mechanical processes and functions Effects 0.000 description 1
- 238000003199 nucleic acid amplification method Methods 0.000 description 1
- 230000000750 progressive effect Effects 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T3/00—Geometric image transformations in the plane of the image
- G06T3/40—Scaling of whole images or parts thereof, e.g. expanding or contracting
- G06T3/4038—Image mosaicing, e.g. composing plane images from plane sub-images
Landscapes
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Engineering & Computer Science (AREA)
- Theoretical Computer Science (AREA)
- Image Processing (AREA)
- Processing Or Creating Images (AREA)
Abstract
The embodiment of the invention discloses a kind of method, apparatus and terminal device for handling image, are related to field of communication technology, can improve the validity of image after processing.The method of the embodiment of the present invention includes:Obtain the initial position of 3D pending areas and the 3D pending areas in 3D initial pictures;The 3D pending areas are moved to the target location in 3D background images from the initial position in the 3D initial pictures;According to the initial position and the target location, scaling is obtained;The 3D pending areas in the 3D background images are handled according to the scaling, and the 3D rendering that 3D pending areas described after processing and the 3D background images are formed, as 3D target images.The present invention is suitable for a kind of terminal device.
Description
Technical field
The present invention relates to field of communication technology more particularly to a kind of method, apparatus and terminal device for handling image.
Background technology
With popularizing for the development of the communication technology, especially smart mobile phone, gradually instead of the function of camera.In reality
In the application of border, user can carry out image procossing by third party software after smart mobile phone completion is used to take pictures to photo, than
Such as:The character image of position a certain in photo is moved to any position in photo.Smart mobile phone can pass through image procossing
Device extracts the profile of character image, character image is moved to any position in the background image of photo later, using right
The profile of character image and being further processed for background image obtain carrying out the photo after image procossing.
2D (English in photo:2Dimension, Chinese:2 dimension) character image moving process in, by 2D figure maps
As being moved in the plane away from camera lens certain distance, 2D character images it are not related in moving process to the distance of camera lens
Variation, that is, 2D character images change position in 2D background images and occur in the case where ensureing that size is constant, make through
The position for the 2D character images crossed in the photo after image procossing changes, and size does not change, however, in reality
During taking pictures, after the position of personage changes, sent out by the position of the 2D character images in the photo taken pictures
The size of 2D character images can also change while raw change, and therefore, the photo after image procossing can not be accurate
The variation in 2D character image moving process is embodied, making that treated, image is distorted.
Invention content
The embodiment of the present invention provides a kind of method, apparatus and terminal device for handling image, can improve image after processing
Validity.
In order to achieve the above objectives, the embodiment of the present invention adopts the following technical scheme that:
In a first aspect, the embodiment of the present invention provides a kind of method for handling image, the method includes:
Obtain the initial position of 3D pending areas and the 3D pending areas in 3D initial pictures;
The mesh 3D pending areas being moved to from the initial position in the 3D initial pictures in 3D background images
Cursor position;
According to the initial position and the target location, scaling is obtained;
The 3D pending areas in the 3D background images are handled according to the scaling, and will processing
The 3D rendering of the 3D pending areas and 3D background images composition afterwards, as 3D target images.
Second aspect, the embodiment of the present invention provide a kind of device for handling image, and described device includes:
Acquisition module, it is initial in 3D initial pictures for obtaining 3D pending areas and the 3D pending areas
Position;
Processing module, for the 3D pending areas to be moved to the 3D back ofs the body from the initial position in the 3D initial pictures
Target location in scape image;
Computing module, for according to the initial position and the target location, obtaining scaling;
The processing module is additionally operable to the 3D pending areas in the 3D background images according to the pantograph ratio
Example is handled, and the 3D rendering that 3D pending areas described after processing and the 3D background images are formed, as 3D targets
Image.
The third aspect, the embodiment of the present invention provide a kind of terminal device, and the terminal device includes at least the second party
Any one described device in face.
A kind of method, apparatus and terminal device for handling image provided in an embodiment of the present invention, obtains 3D pending areas,
With initial position of the 3D pending areas in 3D initial pictures, then 3D pending areas are moved to 3D backgrounds from initial position
Target location in image, and the scaling of 3D pending areas is obtained, and according to contracting according to initial position and target location
It puts ratio to handle 3D pending areas, the 3D figures of the 3D pending areas that obtain that treated and 3D background images composition
Picture, as 3D target images.The prior art is compared to, the embodiment of the present invention can move front and rear according to 3D pending areas
Position relationship obtains scaling, and will be moved into the 3D pending areas in 3D background images according to scaling at
The 3D rendering of reason, the 3D pending areas that obtain that treated and 3D background images composition, as 3D target images rather than obtains
In the image processing process carried out after 2D images only in the case where 2D character images do not change size, 2D character images are existed
Moved in 2D background images, the embodiment of the present invention by obtaining 3D rendering, and by 3D character images according to scaling at
Reason meets ratio of the 3D character images after movement in 3D background images and is existed by the 3D character images normally taken pictures
Ratio in 3D background images, so as to improve processing after image validity.
Description of the drawings
It to describe the technical solutions in the embodiments of the present invention more clearly, below will be to needed in the embodiment
Attached drawing is briefly described, it should be apparent that, the accompanying drawings in the following description is only some embodiments of the present invention, for ability
For the those of ordinary skill of domain, without creative efforts, it can also be obtained according to these attached drawings other attached
Figure.
Fig. 1 is a kind of method flow diagram for handling image provided in an embodiment of the present invention;
Fig. 2 is another method flow diagram for handling image provided in an embodiment of the present invention;
Fig. 3 is the schematic diagram of the three-dimensional cartesian coordinate system in a kind of concrete application scene provided in an embodiment of the present invention;
Fig. 4 is another method flow diagram for handling image provided in an embodiment of the present invention;
Fig. 5 is a kind of apparatus structure schematic diagram for handling image provided in an embodiment of the present invention.
Specific embodiment
Below in conjunction with the attached drawing in the embodiment of the present invention, the technical solution in the embodiment of the present invention is carried out clear, complete
Site preparation describes, it is clear that described embodiment is only part of the embodiment of the present invention, instead of all the embodiments.It is based on
Embodiment in the present invention, those of ordinary skill in the art are obtained all other without making creative work
Embodiment shall fall within the protection scope of the present invention.
The term used in embodiments of the present invention is only merely for the purpose of description specific embodiment, and is not intended to be limiting
The present invention.It is also intended in " one kind " and " described " of the embodiment of the present invention and singulative used in the attached claims
Including most forms, unless context clearly shows that other meanings.It is also understood that term "and/or" used herein
Refer to and comprising one or more associated list items purposes are any or all possible combinations.
The embodiment of the present invention provides a kind of method for handling image, as shown in Figure 1, the method includes:
101st, the initial position of 3D pending areas and the 3D pending areas in 3D initial pictures is obtained.
102nd, the 3D pending areas are moved to from the initial position in the 3D initial pictures in 3D background images
Target location.
It should be noted that 3D initial pictures and 3D background images are two different images, wherein, 3D initial pictures and
3D background images are in acquisition process, and the position of finding a view of terminal can be identical with mode, i.e. background in 3D initial pictures
Part is identical with 3D background images.
By taking the terminal device with dual camera as an example, terminal device includes the first camera and second camera, with the
The photosensitive sensor of one camera is starting point, and the midpoint using the photosensitive sensor of second camera as the line segment of terminal is three-dimensional
The origin of rectangular coordinate system, straight line where line segment are the x-axis of three-dimensional cartesian coordinate system, wherein, the positive direction of x-axis can be origin
To the direction of the first camera or origin to the direction of second camera, the photosensitive sensor of the first camera and the second camera shooting
Head photosensitive sensor institute straight line vertical with x-axis in the plane for three-dimensional cartesian coordinate system y-axis, wherein, the positive direction of y-axis
Can be origin to ground direction or origin to ground negative direction, perpendicular to x-axis and y-axis place plane, i.e. x/y plane,
And intersect at original with plane where the photosensitive sensor of the photosensitive sensor of the first camera on x/y plane and second camera
The straight line of point is the z-axis of three-dimensional cartesian coordinate system.The image processor of terminal device can according to above-mentioned three-dimensional cartesian coordinate system,
3D pending areas are obtained, and obtain point coordinates (x of the 3D pending areas central point in 3D initial pictures1, y1, z1), later
User can choose the 3D pending areas in the 3D initial pictures shown by terminal device display screen by contact action, and
3D pending areas are moved to the target location in 3D background images from the initial position in 3D initial pictures, after obtaining movement
Point coordinates (x of the 3D pending areas central point in 3D background images2, y2, z2)。
Wherein, the representation of the position in three-dimensional cartesian coordinate system can there are many, such as:Coordinate, vector etc..It needs
It is noted that the mode for obtaining initial position and target location be not limited only to mention in the embodiment of the present invention establish three-dimensional straight
The mode of angular coordinate system can also be determined position coordinates or be measured using other by establishing other kinds of coordinate system
Means obtain location information, such as:Initial position and target location are for the angle of the first camera and/or second camera
Degree;In three-dimensional cartesian coordinate system, the mode for obtaining the position coordinates of 3D pending areas is not limited only in the embodiment of the present invention
The point coordinates of the central point of 3D pending areas mentioned can also obtain the profile of 3D pending areas by the prior art,
Obtain again later the point coordinates of each pixel on the profile of 3D pending areas or some/multiple specified pixel points
Point coordinates, so as to obtain initial position and target location, it should be noted that for determining the point of initial position and target location
Coordinate should meet certain correspondence, such as:3D pending areas are quadrangle, for representing that the point coordinates of initial position is four
The coordinate on four vertex of side shape, the then point coordinates for being used for the target location of 3D pending areas after representing mobile are after movement four
The coordinate on four vertex of side shape, and the point coordinates before each vertex movement and after mobile corresponds.
In actual mechanical process, wait to locate by the 3D that touch screen is chosen when terminal device receives user by sensor
After managing region, and when terminal device receives user's selected " perspective movement starts " button, the display screen of terminal device
On user can be made intuitively to see position of the chosen 3D pending areas in z-axis by showing three-dimensional cartesian coordinate system
It puts, is later dragged the 3D pending areas chosen in z-axis by way of touch screen by user, in order to realize that 3D waits to locate
It is moved in z-axis in reason region;Terminal device is after selected " the perspective movement finishes " button of user is received, terminal device
Display screen on there are still three-dimensional cartesian coordinate system and other button promptings, user can continue that other buttons is selected
3D rendering is operated;After all operating process are completed, terminal device receives user, and selected " image procossing is complete
Finish " button when, display eventually passes through 3D rendering after image processing process, does not show three on the display screen of terminal device at this time
Tie up rectangular coordinate system.It should be noted that the method for mobile 3 D pending area is not limited only in the embodiment of the present invention in z-axis
The method mentioned can also by other means move 3D pending areas, such as:It is pressed by the direction of terminal device
Key come select it is mobile after position of the 3D pending areas in z-axis.
3D rendering includes multiple figure layers, wherein, 3D pending areas can include multiple pixels in multiple figure layers, eventually
After the image processor of end equipment detects the 3D pending areas that user is chosen, obtain in 3D pending areas respectively
Figure layer where each pixel, later after user drags 3D pending areas on a display screen, image processor inspection
The figure layer where original each pixel that the 3D pending areas after user's movement are covered is measured, it is right that image processor passes through
The position of original each pixel that 3D pending areas are covered after movement is analyzed, and will it is mobile after 3D pending areas
The position of original each pixel covered replaces with each pixel in 3D pending areas.
103rd, according to the initial position and the target location, scaling is obtained.
Wherein, the scaling is the 3D pending areas ratio with the 3D pending areas after treatment.
Image processor can be according to point coordinates of the 3D pending areas central point in 3D initial pictures acquired in 101 and 103
(x1, y1, z1) and it is mobile after point coordinates (x of the 3D pending areas central point in 3D background images2, y2, z2) in z1With
z2, to obtain scaling.
It should be noted that due to three-dimensional cartesian coordinate system origin be using the photosensitive sensor of the first camera for
Point, using the photosensitive sensor of second camera as the midpoint of the line segment of terminal, and 3D pending districts after 3D pending areas, movement
Domain, 3D initial pictures and 3D background images belong to the picture of 3D in kind generated by the first camera and second camera, because
This, during mobile 3 D pending area, 3D pending areas and 3D pending areas after movement are always three before movement
Tie up the positive axis side of z-axis of rectangular coordinate system or the negative semiaxis side of z-axis, z1And z2Jack per line, i.e. z1And z2It is just or z1And z2
It is negative, therefore with z1And z2The scaling being calculated for parameter is just.
104th, the 3D pending areas in the 3D background images are handled according to the scaling.
105th, the 3D rendering for forming 3D pending areas described after processing and the 3D background images, as 3D target figures
Picture.
3D pending areas are handled according to by the scaling acquired in 103, i.e., by 3D pending areas according to contracting
The size of 3D pending areas before putting scale smaller or amplifying certain multiple or keep mobile.
A kind of method for handling image provided in an embodiment of the present invention, obtains 3D pending areas and 3D pending areas
Initial position in 3D initial pictures, then 3D pending areas are moved to the target position in 3D background images from initial position
It puts, and the scaling of 3D pending areas is obtained according to initial position and target location, and wait to locate by 3D according to scaling
Reason region is handled, the 3D rendering of the 3D pending areas that obtain that treated and 3D background images composition, as 3D target figures
Picture.The prior art is compared to, the embodiment of the present invention can move front and rear position relationship according to 3D pending areas, be contracted
Ratio is put, and the 3D pending areas that will be moved into 3D background images are handled according to scaling, obtain that treated
The 3D rendering of 3D pending areas and 3D background images composition as 3D target images rather than obtains the progress later of 2D images
Image processing process in only in the case where 2D character images do not change size, 2D character images are moved in 2D background images
Dynamic, the embodiment of the present invention is handled by obtaining 3D rendering, and by 3D character images according to scaling, makes the 3D after movement
Ratio of the character image in 3D background images meets through the 3D character images normally taken pictures in 3D background images
Ratio, so as to improve processing after image validity.
In embodiments of the present invention, the method is used for a kind of terminal device, and the terminal device includes the first camera
And second camera, using the photosensitive sensor of first camera as starting point, and with the light sensor of the second camera
Device for the line segment of terminal midpoint as specified point, in the arbitrary figure layer and the 3D background images in the 3D initial pictures
Arbitrary figure layer is parallel, and therefore, on the basis of realization method as shown in Figure 1,103 can be implemented as 1031- as shown in Figure 2
1033:
1031st, the 3D pending districts in the specified point to the 3D initial pictures are obtained from the initial position
The distance in domain, as the first distance.
1032nd, it is obtained from the target location described in after the specified point to the movement in the 3D background images
The distance of 3D pending areas, as second distance.
Image processor can be according to the 3D pending areas central point acquired in 101 and 103 in 3D initial pictures
Point coordinates (x1, y1, z1) and it is mobile after point coordinates (x of the 3D pending areas central point in 3D background images2, y2, z2)
To z1And z2Value, i.e., first distance be z1, second distance z2。
It should be noted that the method for obtaining the first distance and second distance is not limited only to what is mentioned in the embodiment of the present invention
Method can also obtain the first distance and second distance respectively according to the principle of parallax of the first camera and second camera.
1033rd, according to first distance and the second distance, the scaling is obtained.
Image processor can be according to the first distance z acquired in 107 and 1081With second distance z2, it is obtained by calculation
Scaling.Such as:In three-dimensional cartesian coordinate system as shown in Figure 3,3D pending areas are square, and specified point is origin
(0,0,0), specified point distance of 3D pending areas to before moving is 18, the distance of 3D pending areas after specified point to movement
It is 9, scaling is (182/92)=4:1, therefore, the basis of 3D pending areas 3D pending areas before movement after movement
Upper quadruplication.
It should be noted that as preferred plan, it can be during specified point be determined, with the photosensitive of the first camera
The center of sensor be starting point, and using the center of the photosensitive sensor of second camera as the line segment of terminal midpoint as specify
Point.
A kind of method for handling image provided in an embodiment of the present invention, using the photosensitive sensor of the first camera as starting point,
And using the midpoint that the photosensitive sensor of second camera is the line segment of terminal as specified point, obtain 3D pending areas and refer to
Pinpoint 3D after the first distance of the 3D pending areas in 3D initial pictures and specified point to the movement in 3D background images
The second distance of pending area, and the scaling of 3D pending areas is obtained, and press according to the first distance and second distance
3D pending areas are handled according to scaling, the 3D of the 3D pending areas that obtain that treated and 3D background images composition
Image, as 3D target images.The prior art is compared to, before and after the embodiment of the present invention can be moved according to 3D pending areas
Position relationship, obtain scaling, and the 3D pending areas that will be moved into 3D background images are carried out according to scaling
The 3D rendering of processing, the 3D pending areas that obtain that treated and 3D background images composition, as 3D target images rather than is obtained
It takes in the image processing process carried out after 2D images only in the case where 2D character images do not change size, by 2D character images
It is moved in 2D background images, the embodiment of the present invention is carried out by obtaining 3D rendering, and by 3D character images according to scaling
Processing makes ratio of the 3D character images after movement in 3D background images meet the 3D character images by normally taking pictures
Ratio in 3D background images, so as to improve processing after image validity.
In embodiments of the present invention, on the basis of realization method as shown in Figure 2,105 can be implemented as such as Fig. 4
Shown 1051-1053:
1051st, judge whether the scaling is equal to 1.
1052nd, when the scaling is equal to 1, the 3D pending areas and the 3D background images after the movement
The 3D rendering of composition, as the 3D target images.
It should be noted that in the three-dimensional cartesian coordinate system established in 101 and 103 acquisition point coordinates, when 3D waits to locate
When being moved in the plane that reason region is formed in x-axis and y-axis, the scaling of 3D pending areas is 1.
1053rd, when the scaling is more than 1 or during less than 1, according to the scaling by the 3D after the movement
The 3D rendering that pending area forms after zooming in or out with the 3D background images, as the 3D target images.
It should be noted that by 3D pending areas after processing and the mode of 3D background images composition 3D rendering, can wrap
It includes:By the pixel of same position in each pixel covering 3D background images in 3D pending areas after processing.
A kind of method for handling image provided in an embodiment of the present invention, using the photosensitive sensor of the first camera as starting point,
And using the midpoint that the photosensitive sensor of second camera is the line segment of terminal as specified point, specified point is obtained to 3D initial pictures
In the first distance of 3D pending areas and specified point to the movement in 3D background images after 3D pending areas second
Distance, and the scaling of 3D pending areas is obtained, and treat 3D according to scaling according to the first distance and second distance
Processing region is handled, the 3D rendering of the 3D pending areas that obtain that treated and 3D background images composition, as 3D targets
Image.The prior art is compared to, the embodiment of the present invention can move front and rear position relationship according to 3D pending areas, obtain
Scaling, and the 3D pending areas that will be moved into 3D background images are handled according to scaling, work as scaling
During equal to 1, the 3D rendering of 3D pending areas and 3D background images composition after movement as 3D target images, works as scaling
During more than 1 or less than 1, formed after according to scaling, 3D pending areas after movement are zoomed in or out with 3D background images
3D rendering, as 3D target images rather than obtain in the image processing process carried out after 2D images only in 2D figure maps
As in the case of not changing size, 2D character images are moved in 2D background images, the embodiment of the present invention is schemed by obtaining 3D
Picture, and 3D character images are handled according to scaling, make ratio of the 3D character images after movement in 3D background images
Example meets the ratio in 3D background images by the 3D character images normally taken pictures, so as to improve the true of image after processing
Solidity.
The embodiment of the present invention provides a kind of device 20 for handling image, as shown in figure 5, described device 20 includes:
Acquisition module 21, it is first in 3D initial pictures for obtaining 3D pending areas and the 3D pending areas
Beginning position.
Processing module 22, for the 3D pending areas to be moved to 3D from the initial position in the 3D initial pictures
Target location in background image.
Computing module 23, for according to the initial position and the target location, obtaining scaling.
The processing module 22 is additionally operable to the 3D pending areas in the 3D background images according to the scaling
Ratio is handled, and the 3D rendering that 3D pending areas described after processing and the 3D background images are formed, as 3D mesh
Logo image.
In embodiments of the present invention, described device 20 is used for a kind of terminal device, and the terminal device includes the first camera shooting
Head and second camera, using the photosensitive sensor of first camera as starting point, and with the photosensitive biography of the second camera
Sensor for the line segment of terminal midpoint as specified point, in the arbitrary figure layer and the 3D background images in the 3D initial pictures
Arbitrary figure layer it is parallel.
The computing module 23, specifically for obtaining the specified point from the initial position to the 3D initial pictures
In the 3D pending areas distance, as the first distance.
The computing module 23 is specifically additionally operable to obtain the specified point from the target location to the 3D Backgrounds
The distance of the 3D pending areas after the movement as in, as second distance.
The computing module 23 is specifically additionally operable to, according to first distance and the second distance, obtain the scaling
Ratio.
In embodiments of the present invention, the processing module 22, specifically for judging whether the scaling is equal to 1;
When the scaling is equal to 1, the 3D pending areas and 3D background images composition after the movement
3D rendering, as the 3D target images;
It is according to the scaling that the 3D after the movement is pending when the scaling is more than or less than 1
The 3D rendering formed after area reduction or amplification with the 3D background images, as the 3D target images.
In embodiments of the present invention, it is described by the 3D pending areas after processing and 3D background images composition 3D figures
The mode of picture, including:The pixel of 3D pending areas described after processing is covered to the pixel of the 3D background images.
A kind of device for handling image provided in an embodiment of the present invention, obtains 3D pending areas and 3D pending areas
Initial position in 3D initial pictures, then 3D pending areas are moved to the target position in 3D background images from initial position
It puts, and the scaling of 3D pending areas is obtained according to initial position and target location, and wait to locate by 3D according to scaling
Reason region is handled, the 3D rendering of the 3D pending areas that obtain that treated and 3D background images composition, as 3D target figures
Picture.The prior art is compared to, the embodiment of the present invention can move front and rear position relationship according to 3D pending areas, be contracted
Ratio is put, and the 3D pending areas that will be moved into 3D background images are handled according to scaling, obtain that treated
The 3D rendering of 3D pending areas and 3D background images composition as 3D target images rather than obtains the progress later of 2D images
Image processing process in only in the case where 2D character images do not change size, 2D character images are moved in 2D background images
Dynamic, the embodiment of the present invention is handled by obtaining 3D rendering, and by 3D character images according to scaling, makes the 3D after movement
Ratio of the character image in 3D background images meets through the 3D character images normally taken pictures in 3D background images
Ratio, so as to improve processing after image validity.
An embodiment of the present invention provides a kind of terminal device, the terminal device includes at least dress described in above-mentioned any one
Put 20.
A kind of terminal device for handling image provided in an embodiment of the present invention, obtains 3D pending areas and 3D is pending
Initial position of the region in 3D initial pictures, then mesh 3D pending areas being moved to from initial position in 3D background images
Cursor position, and the scaling of 3D pending areas is obtained according to initial position and target location, and according to scaling by 3D
Pending area is handled, the 3D rendering of the 3D pending areas that obtain that treated and 3D background images composition, as 3D mesh
Logo image.The prior art is compared to, the embodiment of the present invention can move front and rear position relationship according to 3D pending areas, obtain
To scaling, and the 3D pending areas that will be moved into 3D background images are handled according to scaling, are handled
3D pending areas afterwards and the 3D rendering of 3D background images composition, after 3D target images rather than acquisition 2D images
In the image processing process of progress only in the case where 2D character images do not change size, by 2D character images in 2D background images
Middle movement, the embodiment of the present invention are handled by obtaining 3D rendering, and by 3D character images according to scaling, after making movement
Ratio of the 3D character images in 3D background images meet through the 3D character images normally taken pictures in 3D background images
In ratio, so as to improve processing after image validity.
Each embodiment in this specification is described by the way of progressive, identical similar portion between each embodiment
Point just to refer each other, the highlights of each of the examples are it is different from other embodiment it
Place.For apparatus embodiments, since it is substantially similar to embodiment of the method, so describing to compare
Simply, the relevent part can refer to the partial explaination of embodiments of method.
The above description is merely a specific embodiment, but protection scope of the present invention is not limited thereto, any
Those familiar with the art in the technical scope disclosed by the present invention, all should by the change or replacement that can be readily occurred in
It is included within the scope of the present invention.Therefore, protection scope of the present invention should be subject to the protection scope in claims.
Claims (7)
- A kind of 1. method for handling image, which is characterized in that the method is used for a kind of terminal device, and the terminal device includes First camera and second camera, using the photosensitive sensor of first camera as starting point, and with the second camera Photosensitive sensor for the line segment of terminal midpoint as specified point, in the arbitrary figure layer and 3D background images in 3D initial pictures Arbitrary figure layer it is parallel, the method includes:Obtain the initial position of 3D pending areas and the 3D pending areas in 3D initial pictures;The 3D pending areas are moved to the target position in 3D background images from the initial position in the 3D initial pictures It puts, wherein, the 3D initial pictures and 3D background images difference;The distance of the 3D pending areas in the specified point to the 3D initial pictures is obtained from the initial position, As the first distance;The 3D is pending after the specified point to the movement in the 3D background images is obtained from the target location The distance in region, as second distance;According to first distance and the second distance, scaling is obtained;The 3D pending areas in the 3D background images are handled according to the scaling, and will processing after institute The 3D rendering of 3D pending areas and 3D background images composition is stated, as 3D target images.
- It is 2. according to the method described in claim 1, it is characterized in that, described that the 3D in the 3D background images is pending Region is handled according to the scaling, and 3D pending areas described after processing and the 3D background images are formed 3D rendering, as 3D target images, including:Judge whether the scaling is equal to 1;When the scaling is equal to 1, the 3D of the 3D pending areas and 3D background images composition after the movement Image, as the 3D target images;When the scaling is more than 1 or during less than 1, according to the scaling by 3D pending areas described after the movement The 3D rendering formed after zooming in or out with the 3D background images, as the 3D target images.
- It is 3. according to the method described in claim 1, it is characterized in that, described by the 3D pending areas and the 3D after processing Background image forms the mode of 3D rendering, including:The pixel of 3D pending areas described after processing is covered into the 3D backgrounds The pixel of image.
- 4. a kind of device for handling image, which is characterized in that described device is used for a kind of terminal device, and the terminal device includes First camera and second camera, using the photosensitive sensor of first camera as starting point, and with the second camera Photosensitive sensor for the line segment of terminal midpoint as specified point, in the arbitrary figure layer and 3D background images in 3D initial pictures Arbitrary figure layer it is parallel, described device includes:Acquisition module, for obtaining the initial position of 3D pending areas and the 3D pending areas in 3D initial pictures;Processing module, for the 3D pending areas to be moved to 3D Backgrounds from the initial position in the 3D initial pictures Target location as in, wherein, the 3D initial pictures and 3D background images difference;Computing module, specifically for obtaining the specified point from the initial position to the 3D in the 3D initial pictures The distance of pending area, as the first distance;The computing module is specifically additionally operable to obtain from the target location in the specified point to the 3D background images The distance of the 3D pending areas after the movement, as second distance;The computing module is specifically additionally operable to, according to first distance and the second distance, obtain scaling;The processing module, be additionally operable to by the 3D pending areas in the 3D background images according to the scaling into Row processing, and the 3D rendering that 3D pending areas described after processing and the 3D background images are formed, as 3D target images.
- 5. device according to claim 4, which is characterized in that the processing module, specifically for judging the pantograph ratio Whether example is equal to 1;When the scaling is equal to 1, the 3D of the 3D pending areas and 3D background images composition after the movement Image, as the 3D target images;When the scaling is more than 1 or during less than 1, according to the scaling by 3D pending areas described after the movement The 3D rendering formed after zooming in or out with the 3D background images, as the 3D target images.
- 6. device according to claim 4, which is characterized in that described by the 3D pending areas and the 3D after processing Background image forms the mode of 3D rendering, including:The pixel of 3D pending areas described after processing is covered into the 3D backgrounds The pixel of image.
- 7. a kind of terminal device, which is characterized in that the terminal device includes at least any one in the claims 4 to 6 Item described device.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510050059.6A CN104616246B (en) | 2015-01-30 | 2015-01-30 | A kind of method, apparatus and terminal device for handling image |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201510050059.6A CN104616246B (en) | 2015-01-30 | 2015-01-30 | A kind of method, apparatus and terminal device for handling image |
Publications (2)
Publication Number | Publication Date |
---|---|
CN104616246A CN104616246A (en) | 2015-05-13 |
CN104616246B true CN104616246B (en) | 2018-06-15 |
Family
ID=53150679
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201510050059.6A Active CN104616246B (en) | 2015-01-30 | 2015-01-30 | A kind of method, apparatus and terminal device for handling image |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN104616246B (en) |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN107393018A (en) * | 2017-07-27 | 2017-11-24 | 北京中达金桥技术股份有限公司 | A kind of method that the superposition of real-time virtual image is realized using Kinect |
Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1343341A (en) * | 1999-03-01 | 2002-04-03 | 索尼电脑娱乐公司 | Image forming method and apparatus |
EP2383701A1 (en) * | 2009-01-22 | 2011-11-02 | Huawei Device Co., Ltd. | Image processing method and apparatus |
CN103595912A (en) * | 2013-09-30 | 2014-02-19 | 北京智谷睿拓技术服务有限公司 | Method and device for local zoom imaging |
-
2015
- 2015-01-30 CN CN201510050059.6A patent/CN104616246B/en active Active
Patent Citations (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN1343341A (en) * | 1999-03-01 | 2002-04-03 | 索尼电脑娱乐公司 | Image forming method and apparatus |
EP2383701A1 (en) * | 2009-01-22 | 2011-11-02 | Huawei Device Co., Ltd. | Image processing method and apparatus |
CN103595912A (en) * | 2013-09-30 | 2014-02-19 | 北京智谷睿拓技术服务有限公司 | Method and device for local zoom imaging |
Also Published As
Publication number | Publication date |
---|---|
CN104616246A (en) | 2015-05-13 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US9311565B2 (en) | 3D scanning with depth cameras using mesh sculpting | |
CN110214340B (en) | Refinement of structured light depth map using RGB color data | |
KR102461232B1 (en) | Image processing method and apparatus, electronic device, and storage medium | |
CN103679788B (en) | The generation method and device of 3D rendering in a kind of mobile terminal | |
KR101703013B1 (en) | 3d scanner and 3d scanning method | |
CN105118021A (en) | Feature point-based image registering method and system | |
JP2012212345A (en) | Terminal device, object control method and program | |
CN106846410A (en) | Based on three-dimensional environment imaging method and device | |
US20150009119A1 (en) | Built-in design of camera system for imaging and gesture processing applications | |
JP2012256110A (en) | Information processing apparatus, information processing method, and program | |
WO2022022449A1 (en) | Method and apparatus for spatial positioning | |
JP6640294B1 (en) | Mixed reality system, program, portable terminal device, and method | |
CN109920004A (en) | Image processing method, device, the combination of calibration object, terminal device and calibration system | |
CN108553895B (en) | Method and device for associating user interface element with three-dimensional space model | |
CN111784841B (en) | Method, device, electronic equipment and medium for reconstructing three-dimensional image | |
EP4432214A1 (en) | Panoramic video acquiring method, apparatus and system, device, and storage medium | |
CN105227948B (en) | The method and device of distorted region in a kind of lookup image | |
KR101496441B1 (en) | Apparatus and Method for registration of flat panel display device and imaging sensor, and Electronic device having flat panel display device and imaging sensor which are registered using the method | |
US20130187852A1 (en) | Three-dimensional image processing apparatus, three-dimensional image processing method, and program | |
CN104616246B (en) | A kind of method, apparatus and terminal device for handling image | |
JP2019185475A (en) | Specification program, specification method, and information processing device | |
EP3059663B1 (en) | A method and a system for interacting with virtual objects in a three-dimensional space | |
KR102191061B1 (en) | Method, system and non-transitory computer-readable recording medium for supporting object control by using a 2d camera | |
CN104850383A (en) | Information processing method and electronic equipment | |
WO2013121468A1 (en) | 3d image display device and 3d image display 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 | ||
GR01 | Patent grant | ||
GR01 | Patent grant |