CN107169926A - Image processing method and device - Google Patents

Image processing method and device Download PDF

Info

Publication number
CN107169926A
CN107169926A CN201710286940.5A CN201710286940A CN107169926A CN 107169926 A CN107169926 A CN 107169926A CN 201710286940 A CN201710286940 A CN 201710286940A CN 107169926 A CN107169926 A CN 107169926A
Authority
CN
China
Prior art keywords
image
camera
coordinate
pixel
properties parameter
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
Application number
CN201710286940.5A
Other languages
Chinese (zh)
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 CN201710286940.5A priority Critical patent/CN107169926A/en
Publication of CN107169926A publication Critical patent/CN107169926A/en
Pending legal-status Critical Current

Links

Classifications

    • G06T3/047
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformation in the plane of the image
    • G06T3/40Scaling the whole image or part thereof
    • G06T3/4038Scaling the whole image or part thereof for image mosaicing, i.e. plane images composed of plane sub-images

Abstract

The invention discloses a kind of image processing method and device.Wherein, this method includes:The first image that the first camera photographic subjects scene obtains and the second image that second camera photographic subjects scene is obtained are obtained, the first camera is located at the upper-lower position on same axial line with second camera;Polar coordinate system is carried out to the pixel in the first image and is converted to the 3rd image to rectangular coordinate system, polar coordinate system is carried out to the pixel in the second image and is converted to the 4th image to rectangular coordinate system, the position of the position polar coordinate representation of first image and the pixel in the second image, the 3rd image and the pixel in the 4th image is represented with rectangular co-ordinate;3rd image and the 4th image are synthesized, target image is obtained, target image is the corresponding panoramic picture of target scene.The present invention solves camera lens in correlation technique causes the technical problem larger to panoramic picture computational processing using left and right or front and rear arrangement.

Description

Image processing method and device
Technical field
The present invention relates to image processing field, in particular to a kind of image processing method and device.
Background technology
The VR all-in-ones and Pisces eye unit equipment of current main flow mainly employ the relative layout in camera lens back and forth or left and right Mode, two circular images before and after being formed after shooting, image is carried out deploying respectively afterwards it is main using spherical coordinate orientation method, Longitude and latitude reflection method scheduling algorithm deploys, and amount of calculation is all relatively large.Two pairs there is into overlapping region again after expansion result is obtained Image, which carries out splicing, can use the modes such as unrelated feature, feature based, similar curves matching, and masterplate splicing.
For example, the aphorama that capture apparatus as shown in Figure 1 is shot using camera lens or so relative layout type, the equipment The expansion picture of frequency wherein frame or so camera lens as shown in Figure 2 a and 2 b, can be seen that by spherical fish from Fig. 2 a and Fig. 2 b Eye pattern picture does planar development correction, and amount of calculation is than larger and need to do the angular field of view of camera lens corresponding calculating;Simultaneously because Camera lens is that left-right situs causes the deformation stretching of bottom very serious, forms common fault-big fingers deformed that current Pisces eye is shot; The later stage split algorithm amount of calculation of this photographic schemes is also relatively large simultaneously, and solid line as shown in Figure 3 draws scope for Fig. 2 a With the scope merged required for two images shown in Fig. 2 b.
To sum up, due to the arrangement mode of before and after camera lens use in correlation technique or left and right, it will cause panoramic picture Expansion and blending algorithm amount of calculation it is larger, for the live of video and record etc. need to synthesize in real time in the case of operating efficiency compared with It is low, and pattern distortion can be caused in hand-held shooting, influence attractive in appearance.
For it is above-mentioned the problem of, effective solution is not yet proposed at present.
The content of the invention
The embodiments of the invention provide a kind of image processing method and device, used with least solving camera lens in correlation technique Left and right or front and rear arrangement cause the technical problem larger to panoramic picture computational processing.
One side according to embodiments of the present invention there is provided a kind of image processing method, including:Obtain the first camera The second image that the first image and second camera photographic subjects scene that photographic subjects scene is obtained are obtained, wherein, first Camera is located on same axial line with second camera, and axial line is the axle center of the first camera and the axle center of second camera The line at place, the first camera is located at the upper end of second camera or the first camera is located at the lower end of second camera;It is right Pixel in first image carries out polar coordinate system and is converted to the 3rd image to rectangular coordinate system, to the picture in the second image Vegetarian refreshments carries out polar coordinate system and is converted to the 4th image to rectangular coordinate system, wherein, the picture in the first image and the second image The position of the position polar coordinate representation of vegetarian refreshments, the 3rd image and the pixel in the 4th image is represented with rectangular co-ordinate;By Three images are synthesized with the 4th image, obtain target image, wherein, target image is the corresponding panoramic picture of target scene.
Another aspect according to embodiments of the present invention, additionally provides a kind of image processing apparatus, including:Acquiring unit, is used In obtaining obtained the first image of the first camera photographic subjects scene and second camera photographic subjects scene is obtained the Two images, wherein, the first camera and second camera are located on same axial line, axial line for the first camera axle center with Line where the axle center of second camera, the first camera is located at the upper end of second camera or the first camera is located at second The lower end of camera;Converting unit, for carrying out polar coordinate system to the conversion of rectangular coordinate system to the pixel in the first image The 3rd image is obtained, carry out polar coordinate system to the pixel in the second image is converted to the 4th image to rectangular coordinate system, Wherein, the picture in the position polar coordinate representation of the first image and the pixel in the second image, the 3rd image and the 4th image The position of vegetarian refreshments is represented with rectangular co-ordinate;Synthesis unit, for the 3rd image and the 4th image to be synthesized, obtains target figure Picture, wherein, target image is the corresponding panoramic picture of target scene.
In embodiments of the present invention, above and below camera lens by the way of, by two lens shooting target fields up and down The image that scape is obtained carries out polar coordinate system to the conversion of rectangular coordinate system, and the image obtained after conversion is merged, with To the corresponding panoramic picture of target scene, the purpose for the amount of calculation for reducing image spread and blending algorithm is reached, and then solve Camera lens causes the technology larger to panoramic picture computational processing using left and right or front and rear arrangement in correlation technique Problem, it is achieved thereby that reducing the calculating cost of image procossing, lifts the technique effect of the efficiency of real-time Transmission image.
Brief description of the drawings
Accompanying drawing described herein is used for providing a further understanding of the present invention, constitutes the part of the application, this hair Bright schematic description and description is used to explain the present invention, does not constitute inappropriate limitation of the present invention.In the accompanying drawings:
Fig. 1 is the schematic diagram using camera lens or so relative layout type according to the capture apparatus of prior art;
Fig. 2 a are the shooting picture of the left camera lens of the capture apparatus according to prior art and the schematic diagram of expansion picture;
Fig. 2 b are the shooting picture of the right camera lens of the capture apparatus according to prior art and the schematic diagram of expansion picture;
The signal in the region that Fig. 3 is merged required for being the expansion picture of the left and right camera lens of the capture apparatus according to prior art Figure;
Fig. 4 is the schematic diagram of the hardware environment of image processing method according to embodiments of the present invention;
Fig. 5 is a kind of flow chart of optional image processing method according to embodiments of the present invention;
Fig. 6 is the schematic diagram of the first camera according to embodiments of the present invention and second camera layout type;
Fig. 7 a are the schematic diagrames of the first image obtained by the first camera according to embodiments of the present invention is shot;
Fig. 7 b are the schematic diagrames of the second image obtained by second camera according to embodiments of the present invention is shot;
Fig. 8 a are the schematic diagram of the first image spread according to embodiments of the present invention into the 3rd image;
Fig. 8 b are the schematic diagram of the second image spread according to embodiments of the present invention into the 4th image;
Fig. 9 is the schematic diagram of the 3rd image according to embodiments of the present invention and the target image of the 4th image synthesis;
Figure 10 is a kind of schematic diagram of optional image processing apparatus according to embodiments of the present invention;
Figure 11 is the schematic diagram of another optional image processing apparatus according to embodiments of the present invention;
Figure 12 is the schematic diagram of another optional image processing apparatus according to embodiments of the present invention;
Figure 13 is the schematic diagram of another optional image processing apparatus according to embodiments of the present invention;
Figure 14 is the schematic diagram of another optional image processing apparatus according to embodiments of the present invention;And
Figure 15 is a kind of structured flowchart of terminal according to embodiments of the present invention.
Embodiment
In order that those skilled in the art more fully understand the present invention program, below in conjunction with the embodiment of the present invention Accompanying drawing, the technical scheme in the embodiment of the present invention is clearly and completely described, it is clear that described embodiment is only The embodiment of a part of the invention, rather than whole embodiments.Based on the embodiment in the present invention, ordinary skill people The every other embodiment that member is obtained under the premise of creative work is not made, should all belong to the model that the present invention is protected Enclose.
It should be noted that term " first " in description and claims of this specification and above-mentioned accompanying drawing, " Two " etc. be for distinguishing similar object, without for describing specific order or precedence.It should be appreciated that so using Data can exchange in the appropriate case, so as to embodiments of the invention described herein can with except illustrating herein or Order beyond those of description is implemented.In addition, term " comprising " and " having " and their any deformation, it is intended that cover Lid is non-exclusive to be included, for example, the process, method, system, product or the equipment that contain series of steps or unit are not necessarily limited to Those steps or unit clearly listed, but may include not list clearly or for these processes, method, product Or the intrinsic other steps of equipment or unit.
Embodiment 1
There is provided a kind of embodiment of the method for image processing method according to embodiments of the present invention.
Alternatively, in the present embodiment, above-mentioned image processing method can apply to as shown in Figure 4 by server 102 In the hardware environment constituted with terminal 104.As shown in figure 4, server 102 is attached by network with terminal 104, it is above-mentioned Network includes but is not limited to:Wide area network, Metropolitan Area Network (MAN) or LAN, terminal 104 are not limited to PC, mobile phone, tablet personal computer etc..This The image processing method of inventive embodiments can be performed by server 102, can also be performed, can also be by terminal 104 Performed jointly by server 102 and terminal 104.Wherein, the image processing method of the execution of terminal 104 embodiment of the present invention can also It is to be performed by client mounted thereto.
Fig. 5 is a kind of flow chart of optional image processing method according to embodiments of the present invention, as shown in figure 5, the party Method may comprise steps of:
Step S202, obtains the first image and second camera shooting mesh that the first camera photographic subjects scene is obtained The second image that mark scene is obtained;
Step S204, carries out polar coordinate system to the pixel in the first image and is converted to the 3rd figure to rectangular coordinate system Picture, carries out polar coordinate system to the pixel in the second image and is converted to the 4th image to rectangular coordinate system;
Step S206, the 3rd image and the 4th image are synthesized, target image is obtained, wherein, target image is mesh Mark the corresponding panoramic picture of scene.
By above-mentioned steps S202 to step S206, above and below camera lens by the way of, by two camera lenses up and down The image that photographic subjects scene is obtained carries out polar coordinate system to the conversion of rectangular coordinate system, and the image obtained after conversion is carried out Fusion, to obtain the corresponding panoramic picture of target scene, has reached the purpose for the amount of calculation for reducing image spread and blending algorithm, And then solve in correlation technique camera lens using left and right or front and rear arrangement cause to panoramic picture computational processing compared with Big technical problem, it is achieved thereby that reducing the calculating cost of image procossing, lifts the technology effect of the efficiency of real-time Transmission image Really.
In the technical scheme that step S202 is provided, the first camera and second camera can be integrated two on machine Camera, can also be respectively the camera of two cameras, and this two cameras can be combined shooting.It is of the invention real Applying the first camera and second camera in example can be using the consistent top-bottom layout mode in camera lens axle center, namely the first camera It can be located at second camera on same axial line, the axial line is the axle center of the first camera and the axle center of second camera The line at place, the first camera can be located at the upper end of second camera, or the first camera can be located at second camera Lower end.For example, the video camera shown in Fig. 6 carries out the collection of content using Liang Tai Kodaks flake moving camera combination and regarded The shooting of frequency or picture, the camera lens of two cameras is located on same axial line.
It should be noted that the property parameters of the first camera and the attribute of second camera in the embodiment of the present invention are joined Number is identical, wherein, property parameters can include but is not limited to the angular field of view of camera, the resolution of image captured by camera Rate etc..The embodiment of the present invention controls the property parameters of the first camera identical with the property parameters of second camera, it is therefore an objective to be Ensure the first image that the first camera photographic subjects scene is obtained is obtained with second camera photographic subjects scene second The resolution ratio of image is identical, in order to be able to which the image after the first image and the corresponding expansion of the second image is accurately melted Close, with the effect of the degree of accuracy of the panoramic picture that improves target scene.Preferably, the first camera in the embodiment of the present invention and The angular field of view of second camera can be more than 200 degree, and optimal selection is 230 degree.
The embodiment of the present invention can be utilized to be taken the photograph using the all-in-one of the consistent top-bottom layout mode in camera lens axle center or two The unit equipment of shadow machine is shot to target scene, to obtain the panoramic picture of the target scene.Herein it should be noted that The embodiment of the present invention is to target scene and is not specifically limited, to the number or species of the subject in target scene also not It is specifically limited.In embodiments of the present invention, the image that the first camera photographic subjects scene is obtained is referred to as the first image, second The image journey that camera photographic subjects scene is obtained is the second image.For example, using capture apparatus as shown in Figure 6 to target field Scape office is shot, in Fig. 6 above camera camera be the first camera, below camera camera for second shooting Head, the first camera shoots obtained the first image of office as shown in Figure 7a, second camera shoot that office obtains the Two images are as shown in Figure 7b.It should be noted that as shown in figs. 7 a and 7b, the first camera photographic subjects scene obtain During the second image that one image and second camera photographic subjects scene are obtained is spherical chart picture, the first image and the second image The position of pixel can be indicated with the polar coordinates in polar coordinate system.
In the technical scheme that step S204 is provided, the first image that the first camera photographic subjects scene is obtained is being obtained And after obtained the second image of second camera photographic subjects scene, the embodiment of the present invention can respectively to the first image and Second image carries out expansion processing, and the essence of expansion processing is to carry out polar coordinate system to the pixel in the first image to sit to right angle Mark system is converted to the 3rd image, and polar coordinate system being converted to rectangular coordinate system is carried out to the pixel in the second image 4th image, wherein, the position of the 3rd image and the pixel in the 4th image can use the rectangular co-ordinate in rectangular coordinate system Represent, namely the 3rd image and the 4th image are rectangular image.It should be noted that due to have in deployment algorithm it is substantial amounts of just String, cosine floating point arithmetic, simultaneously because the pixel point areas of unfolded image is far longer than original image area, it is scarce in order to compensate The pixel of mistake needs to carry out interpolation arithmetic to image.The embodiment of the present invention is in order to reduce the interpolation calculation that deployment algorithm is brought Amount, can be by the way of pixel be reversely looked into, by the pixel of the rectangular coordinate system in known 3rd image and the 4th image Position-reversed calculates the pixel position of the first image and the polar coordinate system in the second image, and opening for interpolation arithmetic is reduced to realize The effect of pin.
The above-mentioned deployment algorithm in the embodiment of the present invention will be specifically described below:
As a kind of optional embodiment, obtaining the 3rd image to the deployment algorithm performed by the first image can describe For:Polar coordinate system is carried out to the pixel in the first image and is converted to the 3rd image to rectangular coordinate system, can specifically be wrapped Following steps S11 is included to step S15:
Step S11, according to the length and width of the image of width calculation the 3rd of the first image, wherein, wrapped in the 3rd image The pixel of the first quantity is included, the first quantity is the product of the length and width of the 3rd image.
, can be with after the first image that the first camera photographic subjects scene is obtained is got in above-mentioned steps S11 According to the width of the first image, namely circular picture shown in Fig. 7 a diameter, calculate the image after being deployed, namely the 3rd figure The length and width of picture.It should be noted that the pixel in the 3rd image can be determined by the length and width of the 3rd image Quantity, namely the 3rd image includes the pixel of the first quantity, wherein, the first quantity is the length and width of the 3rd image Product.Each pixel in 3rd image can use the coordinate representation in rectangular coordinate system.
Step S13, by the first Coordinate Conversion of the first pixel in the 3rd image into the second coordinate, wherein, the first quantity Pixel include the first pixel, the first coordinate is coordinate of first pixel in rectangular coordinate system, and the second coordinate is the Coordinate of one pixel in polar coordinate system.
In above-mentioned steps S13, the 3rd image includes the pixel of the first quantity, wherein, the first pixel can be Any one pixel therein, the first coordinate can be coordinate of first pixel in rectangular coordinate system.Sat according to right angle Mark is tied to the conversion formula of polar coordinate system, can obtain the second coordinate corresponding to the first coordinate, wherein, the second coordinate is first Coordinate of the pixel in polar coordinate system.
Step S15, the pixel value of the pixel in the first image positioned at the second coordinate is defined as first in the 3rd image The pixel value of pixel.
, can be from first after second coordinate of first pixel in polar coordinate system is obtained in above-mentioned steps S15 The pixel positioned at second coordinate is determined in the corresponding polar coordinate system of image, and regard the pixel value of the pixel as the 3rd figure The pixel value of the first pixel as in.
It should be noted that being performed both by above-mentioned steps S11 to step S15 to each pixel in the 3rd image, just may be used To realize the first image spread obtained by the first camera photographic subjects scene in the way of reversely searching pixel into Three images.
Similarly, obtaining the 4th image to the deployment algorithm performed by the second image can be described as:To in the second image Pixel carries out polar coordinate system and is converted to the 4th image to rectangular coordinate system, specifically may comprise steps of S12 to step Rapid S16:
Step S12, according to the length and width of the image of width calculation the 4th of the second image, wherein, wrapped in the 4th image The pixel of the second quantity is included, the second quantity is the product of the length and width of the 4th image.
, can be with after the second image that second camera photographic subjects scene is obtained is got in above-mentioned steps S12 According to the width of the second image, namely the diameter of circular picture shown in Fig. 7 b calculates the image after being deployed, namely the 4th figure The length and width of picture.It should be noted that the pixel in the 4th image can be determined by the length and width of the 4th image Quantity, namely the 4th image includes the pixel of the second quantity, wherein, the second quantity is the length and width of the 4th image Product.Each pixel in 4th image can use the coordinate representation in rectangular coordinate system.
Step S14, by the 3rd Coordinate Conversion of the second pixel in the 4th image into 4-coordinate, wherein, the second quantity Pixel include the second pixel, the 3rd coordinate is coordinate of second pixel in rectangular coordinate system, and 4-coordinate is the Coordinate of two pixels in polar coordinate system.
In above-mentioned steps S14, the 4th image includes the pixel of the second quantity, wherein, the second pixel can be Any one pixel therein, the 3rd coordinate can be coordinate of second pixel in rectangular coordinate system.Sat according to right angle Mark is tied to the conversion formula of polar coordinate system, can obtain the 4-coordinate corresponding to the 3rd coordinate, wherein, 4-coordinate is second Coordinate of the pixel in polar coordinate system.
Step S16, the pixel value of the pixel in the second image positioned at 4-coordinate is defined as second in the 4th image The pixel value of pixel.
, can be from second after 4-coordinate of second pixel in polar coordinate system is obtained in above-mentioned steps S16 The pixel positioned at the 4-coordinate is determined in the corresponding polar coordinate system of image, and regard the pixel value of the pixel as the 4th figure The pixel value of the second pixel as in.
It should be noted that being performed both by above-mentioned steps S12 to step S16 to each pixel in the 4th image, just may be used To realize the second image spread obtained by second camera photographic subjects scene in the way of reversely searching pixel into Four images.
For example, obtained after using the reverse mode for searching pixel, the first image as shown in Figure 7a is deployed the Three images can be contrasted for convenience as shown in Figure 8 a, and the first image and the 3rd image have been carried out into contrast displaying in Fig. 8 a.Profit The 4th image obtained after the second image as shown in Figure 7b is deployed with the reverse mode for searching pixel can be such as figure Shown in 8b, contrast for convenience, the second image and the 4th image have also been subjected to contrast displaying in Fig. 8 b.
It should be noted that the embodiment can realize reduction interpolation arithmetic by using the reverse mode for searching pixel Amount of calculation, and then reach reduce image procossing amount of calculation, lifted real-time Transmission image efficiency technique effect.
As a kind of optional embodiment, lens parameters, resolution sizes that the embodiment can be in known capture apparatus And rectangular co-ordinate is tried to achieve in calculating in advance in the case of field range and the corresponding relation value of polar coordinates pixel is put into result In reservations database or internal memory, in order to by the first Coordinate Conversion of the first pixel in the 3rd image into the second coordinate and Table look-at is operated when by the 3rd Coordinate Conversion of the second pixel in the 4th image into 4-coordinate, and table look-up behaviour It is only O (1) as time complexity, can so realizes the effect for reducing data amount of calculation.
Specifically, the first Coordinate Conversion of the first pixel in the 3rd image may comprise steps of into the second coordinate S131 to step S133:
Step S131, it is corresponding with coordinate transformation relation value pair according to the camera properties parameter stored in reservations database Relation determines the corresponding first coordinate transformation relation value pair of the first camera properties parameter, wherein, the first coordinate transformation relation value To for indicating that the first coordinate of the first pixel in the 3rd image is corresponding with the second coordinate.
In above-mentioned steps S131, the camera properties parameter that can be stored with precalculated in reservations database is with sitting Mark transformational relation value pair corresponding relation, herein it should be noted that different camera properties parameters can correspond to it is different Coordinate transformation relation value pair, wherein, coordinate transformation relation value is to can serve to indicate that between rectangular co-ordinate and polar coordinates pixel The corresponding relation changed.It should also be noted that, camera properties parameter can include at least one of:Camera Resolution ratio of image etc. captured by angular field of view, camera.
It should also be noted that, the first camera properties parameter can be included in the corresponding relation stored in reservations database Corresponding first coordinate transformation relation value pair, can not also include corresponding first Coordinate Conversion of the first camera properties parameter and close Set occurrence pair, wherein, the first coordinate transformation relation value to can serve to indicate that in the 3rd image the first coordinate of the first pixel with Second coordinate is corresponding.
As a kind of optional embodiment, in order to directly quickly determine the using the corresponding relation in reservations database Corresponding second coordinate of first coordinate of the first pixel in three images, the embodiment can be in step S131 according to corresponding relation Determine the corresponding first coordinate transformation relation value of the first camera properties parameter to, first judging whether deposited in reservations database before With the first camera properties parameter identical camera properties parameter.Exist and the first camera properties in reservations database In the case of parameter identical camera properties parameter, the embodiment can determine that the first camera properties are joined according to corresponding relation The corresponding first coordinate transformation relation value pair of number;It is not present and is taken the photograph with the first camera properties parameter identical in reservations database In the case of as head property parameters, the embodiment needs to adjust the first camera properties parameter first so that being deposited in reservations database With the first camera properties parameter identical camera properties parameter after adjustment, then further according to corresponding relation determine adjust The corresponding first coordinate transformation relation value pair of the first camera properties parameter afterwards.It can so guarantee to utilize tentation data The corresponding relation stored in storehouse quickly and easily finds the corresponding first coordinate transformation relation value of the first camera properties parameter It is right, the efficiency of Coordinate Conversion is drastically increased, while decreasing the amount of calculation of Coordinate Conversion.
Step S133, the first coordinate pair of the first pixel in the 3rd image is determined according to the first coordinate transformation relation value pair The second coordinate answered.
In above-mentioned steps S133, it is determined that the corresponding first coordinate transformation relation value of the first camera properties parameter is to it Afterwards, due to first coordinate and second coordinate of the first coordinate transformation relation value to the first pixel in the 3rd image that can indicate Corresponding, therefore, the embodiment can determine the first pixel in the 3rd image using the first coordinate transformation relation value to quick Corresponding second coordinate of the first coordinate.
It should be noted that by way of above-mentioned steps S131 can be realized by tabling look-up to step S133 quick and precisely Ground by the first Coordinate Conversion of the first pixel in the 3rd image into the second coordinate, and then reach reduce Coordinate Conversion calculating Amount, and then reduce the effect of the amount of calculation of graph expansion.
Similarly, the 3rd Coordinate Conversion of the second pixel in the 4th image may comprise steps of into 4-coordinate S142 to step S144:
Step S142, the corresponding second coordinate transformation relation value of second camera property parameters is determined according to corresponding relation It is right, wherein, the second coordinate transformation relation value is to the 3rd coordinate and 4-coordinate for indicating the second pixel in the 4th image It is corresponding.
Step S144, the 3rd coordinate pair of the second pixel in the 4th image is determined according to the second coordinate transformation relation value pair The 4-coordinate answered.
It should be noted that second camera property parameters pair can be included in the corresponding relation stored in reservations database The the second coordinate transformation relation value pair answered, can not also include corresponding second coordinate transformation relation of second camera property parameters Value pair, wherein, the second coordinate transformation relation value is to can serve to indicate that the 3rd coordinate and the of the second pixel in the 4th image 4-coordinate is corresponding.
As a kind of optional embodiment, in order to directly quickly determine the using the corresponding relation in reservations database The corresponding 4-coordinate of the 3rd coordinate of second pixel in four images, the embodiment can be in step S142 according to corresponding relation Determine the corresponding second coordinate transformation relation value of second camera property parameters to, first judging whether deposited in reservations database before With second camera property parameters identical camera properties parameter.Exist and second camera attribute in reservations database In the case of parameter identical camera properties parameter, the embodiment can determine that second camera attribute is joined according to corresponding relation The corresponding second coordinate transformation relation value pair of number;It is not present and is taken the photograph with second camera property parameters identical in reservations database In the case of as head property parameters, the embodiment can adjust second camera property parameters first so that being deposited in reservations database With the second camera property parameters identical camera properties parameter after adjustment, then further according to corresponding relation determine adjust The corresponding second coordinate transformation relation value pair of second camera property parameters afterwards.It is determined that second camera property parameters correspondence The second coordinate transformation relation value to after, because the second coordinate transformation relation value is to that can indicate the second pixel in the 4th image 3rd coordinate of point is corresponding with 4-coordinate, therefore, and the embodiment can be using the second coordinate transformation relation value to quick true The corresponding 4-coordinate of the 3rd coordinate of second pixel in fixed 4th image.
It should be noted that by way of above-mentioned steps S142 can be realized by tabling look-up to step S144 quick and precisely Ground by the 3rd Coordinate Conversion of the second pixel in the 4th image into 4-coordinate, and then reach reduce Coordinate Conversion calculating Amount, and then reduce the effect of the amount of calculation of graph expansion.
In the technical scheme that step S206 is provided, after the 3rd image and the 4th image after being deployed, such as scheme Exist shown in 8a and Fig. 8 b, in the 3rd image and the 4th image and overlap scope, therefore the embodiment of the present invention is needed the 3rd image Synthesized with the 4th image, to obtain target image, wherein, target image is the corresponding panoramic picture of target scene.To The 3rd image and the 4th image through expansion are synthesized, due to the 3rd image of expansion and the 4th Image Mosaic position coincidence model Enclose larger while anamorphose is smaller, the embodiment of the present invention can be closed with directly by the way of masterplate splicing or linear fusion Into trickle problem of misalignment is directed in the case of non-integral machine to be carried out smoothly to image using neighborhood averaging.Herein It should be noted that the image processing techniques such as masterplate splicing, linear fusion and neighborhood averaging is technology hand commonly used in the art Section, is no longer specifically introduced herein.
For example, the target image obtained after the 4th image shown in the 3rd image and Fig. 8 b shown in Fig. 8 a is synthesized Can be with as shown in figure 9, wherein, the solid line in Fig. 9 be the split center of linear fusion.
It should be noted that the hardware combinations mode that uses of technical solution of the present invention for above and below camera lens back to mode, it is right The transfer algorithm using polar coordinates to plane coordinates is only needed in the deployment algorithm of image, while the amount of calculation in order to reduce interpolation The mode for reversely looking into pixel can be used, the hardware of known lens parameters, resolution sizes and field range can be set The standby pixel shot carries out coordinate transformation in advance, and result of calculation is put into database or internal memory, direct when use Table look-up, reduce real-time data amount of calculation.Further, since the picture overlapping region of deployment algorithm generation is larger, afterwards Picture splicing can using masterplate splice or the unrelated splicing of feature by the way of amount of calculation it is relatively small, for trickle problem of misalignment Image can be carried out using neighborhood averaging smooth.
It should also be noted that, technical solution of the present invention can apply shooting and the content biography in panorama VR videos and picture In defeated, such as live, recorded broadcast can apply in industries such as house property, physical culture, amusements with reference to cross VR masterplate engines, realize that VR is regarded The shooting and issue of frequency.In addition, technical solution of the present invention can also be applied in multimachines such as common moving camera GOPRO, honey ants Combine in VR capture apparatus, such as:Google Jump, GoPro Odyssey, YI Jump etc., are placed on shaft core position, due to double Flake is shot has covered 360 ° × 360 ° of FOV enough, its can as multimachine panorama split strong supplement, subtract The splicing mistake that few multimachine splicing is caused due to safe distance and camera lens blind area.
In practical application scene, the VR panoramic videos scheme of standard mainly includes collection, splicing, coding transmission, broadcasting Deng four parts.Technical solution of the present invention usage scenario is main in collection and splicing part:Wherein collecting part can be using one The pattern that machine example, in hardware or two fish eye lens moving cameras are spliced and combined.After synchronous acquisition is completed, to the two-way of collection Video frame images carry out Coordinate Conversion and image co-registration.Technical solution of the present invention will due to the improvement of hardware design and composition algorithm Simplify the flow and efficiency of above-mentioned work.
Completing technical solution of the present invention after above-mentioned work can also be encoded and be compressed to resulting target image Processing, most and in different terminal equipment is played out.
The efficiency of VR pan-shots and synthesis can be lifted by technical solution of the present invention, camera is clapped simultaneously for doing more physical exercises Take the photograph the ancillary method that can optimize as image quality.
It should be noted that for foregoing each method embodiment, in order to be briefly described, therefore it is all expressed as a series of Combination of actions, but those skilled in the art should know, the present invention is not limited by described sequence of movement because According to the present invention, some steps can be carried out sequentially or simultaneously using other.Secondly, those skilled in the art should also know Know, embodiment described in this description belongs to preferred embodiment, involved action and module is not necessarily of the invention It is necessary.
Through the above description of the embodiments, those skilled in the art can be understood that according to above-mentioned implementation The method of example can add the mode of required general hardware platform to realize by software, naturally it is also possible to by hardware, but a lot In the case of the former be more preferably embodiment.Understood based on such, technical scheme is substantially in other words to existing The part that technology contributes can be embodied in the form of software product, and the computer software product is stored in a storage In medium (such as ROM/RAM, magnetic disc, CD), including some instructions are to cause a station terminal equipment (can be mobile phone, calculate Machine, server, or network equipment etc.) perform method described in each of the invention embodiment.
Embodiment 2
According to embodiments of the present invention, a kind of image processing apparatus for being used to implement above-mentioned image processing method is additionally provided. Figure 10 is a kind of schematic diagram of optional image processing apparatus according to embodiments of the present invention, as shown in Figure 10, and the device can be with Including:
Acquiring unit 22, for obtaining the first image and second camera that the first camera photographic subjects scene is obtained The second image that photographic subjects scene is obtained, wherein, the first camera is located on same axial line with second camera, axial line Axle center for the first camera and the line where the axle center of second camera, the first camera be located at second camera upper end or The camera of person first is located at the lower end of second camera;Converting unit 24, for carrying out pole seat to the pixel in the first image What mark was tied to rectangular coordinate system is converted to the 3rd image, and polar coordinate system is carried out to the pixel in the second image to rectangular co-ordinate System is converted to the 4th image, wherein, the position polar coordinate representation of the first image and the pixel in the second image, the 3rd The position of image and the pixel in the 4th image is represented with rectangular co-ordinate;Synthesis unit 26, for by the 3rd image and the 4th Image is synthesized, and obtains target image, wherein, target image is the corresponding panoramic picture of target scene.
It should be noted that the acquiring unit 22 in the embodiment can be used for performing the step in the embodiment of the present application 1 Converting unit 24 in S202, the embodiment can be used for performing in the step S204 in the embodiment of the present application 1, the embodiment Synthesis unit 26 can be used for performing the step S206 in the embodiment of the present application 1.
Herein it should be noted that above-mentioned module is identical with example and application scenarios that the step of correspondence is realized, but not It is limited to the disclosure of that of above-described embodiment 1.It should be noted that above-mentioned module as a part for device may operate in as It in hardware environment shown in Fig. 4, can be realized, can also be realized by hardware by software.
As a kind of optional embodiment, as shown in figure 11, converting unit 24 can include:First computing module 241, is used In the length and width of the image of width calculation the 3rd according to the first image, wherein, the 3rd image includes the picture of the first quantity Vegetarian refreshments, the first quantity is the product of the length and width of the 3rd image;First modular converter 243, for by the 3rd image First Coordinate Conversion of one pixel into the second coordinate, wherein, the pixel of the first quantity includes the first pixel, the first coordinate For coordinate of first pixel in rectangular coordinate system, the second coordinate is coordinate of first pixel in polar coordinate system;First Determining module 245, for the pixel value of the pixel in the first image positioned at the second coordinate to be defined as first in the 3rd image The pixel value of pixel;Converting unit 24 can also include:Second computing module 242, for the width gauge according to the second image The length and width of the 4th image is calculated, wherein, the 4th image includes the pixel of the second quantity, and the second quantity is the 4th image Length and width product;Second modular converter 244, for by the 3rd Coordinate Conversion of the second pixel in the 4th image into 4-coordinate, wherein, the pixel of the second quantity includes the second pixel, and the 3rd coordinate is the second pixel in rectangular coordinate system In coordinate, 4-coordinate be coordinate of second pixel in polar coordinate system;Second determining module 246, for by the second figure The pixel value for being located at the pixel of 4-coordinate as in is defined as the pixel value of the second pixel in the 4th image.
As a kind of optional embodiment, as shown in figure 12, the first modular converter 243 can include:First determines submodule Block 2431, it is true for the corresponding relation according to the camera properties parameter and coordinate transformation relation value pair stored in reservations database The fixed corresponding first coordinate transformation relation value pair of first camera properties parameter, wherein, the first coordinate transformation relation value to for Indicate that the first coordinate of the first pixel in the 3rd image is corresponding with the second coordinate;Second determination sub-module 2433, for root Corresponding second coordinate of the first coordinate of the first pixel in the 3rd image is determined according to the first coordinate transformation relation value pair;Second turn Mold changing block 244 can include:3rd determination sub-module 2442, for determining second camera property parameters pair according to corresponding relation The the second coordinate transformation relation value pair answered, wherein, the second coordinate transformation relation value is to for indicating the second pixel in the 4th image 3rd coordinate of point is corresponding with 4-coordinate;4th determination sub-module 2444, for according to the second coordinate transformation relation value pair Determine the corresponding 4-coordinate of the 3rd coordinate of the second pixel in the 4th image.
As a kind of optional embodiment, the property parameters of camera can include at least one of:Camera is regarded The resolution ratio of image captured by angular region, camera, wherein, camera can include the first camera and second camera.
As a kind of optional embodiment, the property parameters phase that the property parameters of the first camera can be with second camera Together.
As a kind of optional embodiment, as shown in figure 13, the first modular converter 243 can also include:First judges son Module 2401, for being closed according to the camera properties parameter stored in reservations database is corresponding with coordinate transformation relation value pair System determines the corresponding first coordinate transformation relation value of the first camera properties parameter to, judging whether deposited in reservations database before With the first camera properties parameter identical camera properties parameter;5th determination sub-module 2403, in tentation data In the case of existing in storehouse with the first camera properties parameter identical camera properties parameter, first is determined according to corresponding relation The corresponding first coordinate transformation relation value pair of camera properties parameter;6th determination sub-module 2405, in reservations database In be not present with the first camera properties parameter identical camera properties parameter in the case of, adjustment the first camera properties ginseng Number cause reservations database in exist with the first camera properties parameter identical camera properties parameter after adjustment, and according to Corresponding relation determines the corresponding first coordinate transformation relation value pair of the first camera properties parameter after adjustment.Second modular converter 244 can also include:Second judging submodule 2402, for determining second camera property parameters correspondence according to corresponding relation The second coordinate transformation relation value to before, judge in reservations database whether there is and second camera property parameters identical Camera properties parameter;7th determination sub-module 2404, for existing and second camera property parameters in reservations database In the case of identical camera properties parameter, corresponding second coordinate of second camera property parameters is determined according to corresponding relation Transformational relation value pair;8th determination sub-module 2406, for being not present and second camera property parameters in reservations database In the case of identical camera properties parameter, adjustment second camera property parameters cause exist and adjustment in reservations database Second camera property parameters identical camera properties parameter afterwards, and determine that second after adjustment images according to corresponding relation The corresponding second coordinate transformation relation value pair of head property parameters.
As a kind of optional embodiment, as shown in figure 14, the device can also include:Processing unit 27, for inciting somebody to action 3rd image is synthesized with the 4th image, obtains after target image, encoding compression processing is carried out to target image;Play single Member 28, for the target image after the playback process in terminal device.
Herein it should be noted that above-mentioned module is identical with example and application scenarios that the step of correspondence is realized, but not It is limited to the disclosure of that of above-described embodiment 1.It should be noted that above-mentioned module as a part for device may operate in as It in hardware environment shown in Fig. 1, can be realized, can also be realized by hardware by software.
By above-mentioned module, can solve camera lens in correlation technique is caused to complete using left and right or front and rear arrangement The larger technical problem of scape image procossing amount of calculation, realizes the calculating cost for reducing image procossing, lifting real-time Transmission image The technique effect of efficiency.
Embodiment 3
According to embodiments of the present invention, a kind of terminal for being used to implement above-mentioned image processing method is additionally provided.
Figure 15 is a kind of structured flowchart of terminal according to embodiments of the present invention, and as shown in figure 15, the terminal can include: One or more (one is only shown in figure) processors 201, memory 203 and transmitting device 205, as shown in figure 15, the end End can also include input-output equipment 207.
Wherein, the image processing method that memory 203 can be used in storage software program and module, such as embodiment of the present invention Method and the corresponding programmed instruction/module of device, processor 201 by operation be stored in software program in memory 203 and Module, so as to perform various function application and data processing, that is, realizes above-mentioned image processing method.Memory 203 can be wrapped Include high speed random access memory, can also include nonvolatile memory, such as one or more magnetic storage device, flash memory or Other non-volatile solid state memories of person.In some instances, memory 203 can further comprise remote relative to processor 201 The memory that journey is set, these remote memories can pass through network connection to terminal.The example of above-mentioned network includes but not limited In internet, intranet, LAN, mobile radio communication and combinations thereof.
Above-mentioned transmitting device 205 is used to data are received or sent via a network.Above-mentioned network instantiation It may include cable network and wireless network.In an example, transmitting device 205 includes a network adapter (Network Interface Controller, NIC), its can be connected by netting twine and other network equipments with router so as to interconnection Net or LAN are communicated.In an example, transmitting device 205 is radio frequency (Radio Frequency, RF) module, its For wirelessly being communicated with internet.
Wherein, specifically, memory 203 is used to store application program.
Processor 201 can call the application program that memory 203 is stored, to perform following step:First is obtained to image The second image that the first image and second camera photographic subjects scene that head photographic subjects scene is obtained are obtained, wherein, the One camera is located on same axial line with second camera, and axial line is the axle center of the first camera and the axle of second camera Line where the heart, the first camera is located at the upper end of second camera or the first camera is located at the lower end of second camera; Polar coordinate system is carried out to the pixel in the first image and is converted to the 3rd image to rectangular coordinate system, in the second image Pixel carries out polar coordinate system and is converted to the 4th image to rectangular coordinate system, wherein, in the first image and the second image The position of the position polar coordinate representation of pixel, the 3rd image and the pixel in the 4th image is represented with rectangular co-ordinate;Will 3rd image is synthesized with the 4th image, obtains target image, wherein, target image is the corresponding panorama sketch of target scene Picture.
Processor 201 is additionally operable to perform following step:According to the length and width of the image of width calculation the 3rd of the first image Degree, wherein, the 3rd image includes the pixel of the first quantity, and the first quantity is the product of the length and width of the 3rd image; By the first Coordinate Conversion of the first pixel in the 3rd image into the second coordinate, wherein, the pixel of the first quantity includes first Pixel, the first coordinate is coordinate of first pixel in rectangular coordinate system, and the second coordinate is the first pixel in polar coordinates Coordinate in system;The pixel value of pixel in first image positioned at the second coordinate is defined as the first pixel in the 3rd image Pixel value;According to the length and width of the image of width calculation the 4th of the second image, wherein, the 4th image includes the second number The pixel of amount, the second quantity is the product of the length and width of the 4th image;By the 3rd of the second pixel in the 4th image the Coordinate Conversion into 4-coordinate, wherein, the pixel of the second quantity includes the second pixel, and the 3rd coordinate is that the second pixel exists Coordinate in rectangular coordinate system, 4-coordinate is coordinate of second pixel in polar coordinate system;The will be located in second image The pixel value of the pixel of 4-coordinate is defined as the pixel value of the second pixel in the 4th image.
Processor 201 is additionally operable to perform following step:According to the camera properties parameter stored in reservations database with sitting The corresponding relation of mark transformational relation value pair determines the corresponding first coordinate transformation relation value pair of the first camera properties parameter, its In, the first coordinate transformation relation value is to for indicating that the first coordinate of the first pixel in the 3rd image is relative with the second coordinate Should;Corresponding second coordinate of the first coordinate of the first pixel in the 3rd image is determined according to the first coordinate transformation relation value pair; The corresponding second coordinate transformation relation value pair of second camera property parameters is determined according to corresponding relation, wherein, the second coordinate turns Relation value is changed to for indicating that the 3rd coordinate of the second pixel in the 4th image is corresponding with 4-coordinate;According to the second coordinate Transformational relation value pair determines the corresponding 4-coordinate of the 3rd coordinate of the second pixel in the 4th image.
Processor 201 is additionally operable to perform following step:According to the camera properties parameter that is stored in reservations database with The corresponding relation of coordinate transformation relation value pair determines the corresponding first coordinate transformation relation value of the first camera properties parameter to it Before, judge to whether there is and the first camera properties parameter identical camera properties parameter in reservations database;In predetermined number In the case of existing in storehouse with the first camera properties parameter identical camera properties parameter, the is determined according to corresponding relation The corresponding first coordinate transformation relation value pair of one camera properties parameter;It is not present and belongs to the first camera in reservations database Property parameter identical camera properties parameter in the case of, adjustment the first camera properties parameter cause exist in reservations database With the first camera properties parameter identical camera properties parameter after adjustment, and determined according to corresponding relation after adjustment the The corresponding first coordinate transformation relation value pair of one camera properties parameter;Determining that second camera attribute is joined according to corresponding relation The corresponding second coordinate transformation relation value of number is to, judging to whether there is and second camera property parameters in reservations database before Identical camera properties parameter;Exist in reservations database and join with second camera property parameters identical camera properties In the case of number, the corresponding second coordinate transformation relation value pair of second camera property parameters is determined according to corresponding relation;Pre- Determine in the case of being not present in database with second camera property parameters identical camera properties parameter, adjustment second is imaged Head property parameters to exist in reservations database joins with the second camera property parameters identical camera properties after adjustment Number, and the corresponding second coordinate transformation relation value pair of second camera property parameters after adjustment is determined according to corresponding relation.
Processor 201 is additionally operable to perform following step:Synthesized by the 3rd image and the 4th image, obtain target figure As after, encoding compression processing is carried out to target image;Target image in terminal device after playback process.
Using the embodiment of the present invention there is provided a kind of scheme of image procossing, the program using above and below camera lens back to side Formula, by carrying out polar coordinate system to the conversion of rectangular coordinate system to the image that two lens shooting target scenes are obtained up and down, and The image obtained after conversion is merged, to obtain the corresponding panoramic picture of target scene, reached reduction image spread and The purpose of the amount of calculation of blending algorithm, and then solve in correlation technique camera lens and caused using left and right or front and rear arrangement The technical problem larger to panoramic picture computational processing, it is achieved thereby that reducing the calculating cost of image procossing, lifting is real-time Transmit the technique effect of the efficiency of image.
Alternatively, the specific example in the present embodiment may be referred to showing described in above-described embodiment 1 and embodiment 2 Example, the present embodiment will not be repeated here.
It will appreciated by the skilled person that the structure shown in Figure 15 is only signal, terminal can be smart mobile phone (such as Android phone, iOS mobile phones), tablet personal computer, palm PC and mobile internet device (Mobile Internet Devices, MID), the terminal device such as PAD.Figure 15 it does not cause to limit to the structure of above-mentioned electronic installation.For example, terminal is also May include than shown in Figure 15 more either less components (such as network interface, display device etc.) or with Figure 15 institutes Show different configurations.
One of ordinary skill in the art will appreciate that all or part of step in the various methods of above-described embodiment is can To be completed by program come the device-dependent hardware of command terminal, the program can be stored in a computer-readable recording medium In, storage medium can include:Flash disk, read-only storage (Read-Only Memory, ROM), random access device (Random Access Memory, RAM), disk or CD etc..
Embodiment 4
Embodiments of the invention additionally provide a kind of storage medium.Alternatively, in the present embodiment, above-mentioned storage medium can For performing the program code of image processing method.
Alternatively, in the present embodiment, above-mentioned storage medium can be located at multiple in the network shown in above-described embodiment On at least one network equipment in the network equipment.
Alternatively, in the present embodiment, storage medium is arranged to the program code that storage is used to perform following steps:
S1, obtains the first image and second camera photographic subjects scene that the first camera photographic subjects scene is obtained The second obtained image, wherein, the first camera is located on same axial line with second camera, and axial line is the first camera Axle center and second camera axle center where line, the first camera be located at second camera upper end or the first camera Positioned at the lower end of second camera;
S2, polar coordinate system is carried out to the pixel in the first image to the 3rd image that is converted to of rectangular coordinate system, right Pixel in second image carries out polar coordinate system and is converted to the 4th image to rectangular coordinate system, wherein, the first image with The position right angle of the position polar coordinate representation of pixel in second image, the 3rd image and the pixel in the 4th image Coordinate representation;
S3, the 3rd image and the 4th image are synthesized, target image is obtained, wherein, target image is target scene Corresponding panoramic picture.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:According to the first image The image of width calculation the 3rd length and width, wherein, the 3rd image includes the pixel of the first quantity, and the first quantity is The product of the length and width of 3rd image;By the first Coordinate Conversion of the first pixel in the 3rd image into the second coordinate, its In, the pixel of the first quantity includes the first pixel, and the first coordinate is coordinate of first pixel in rectangular coordinate system, the Two coordinates are coordinate of first pixel in polar coordinate system;The pixel value of the pixel of the second coordinate will be located in first image It is defined as the pixel value of the first pixel in the 3rd image;According to the length and width of the image of width calculation the 4th of the second image Degree, wherein, the 4th image includes the pixel of the second quantity, and the second quantity is the product of the length and width of the 4th image; By the 3rd Coordinate Conversion of the second pixel in the 4th image into 4-coordinate, wherein, the pixel of the second quantity includes second Pixel, the 3rd coordinate is coordinate of second pixel in rectangular coordinate system, and 4-coordinate is the second pixel in polar coordinates Coordinate in system;The pixel value of pixel in second image positioned at 4-coordinate is defined as the second pixel in the 4th image Pixel value.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:According to tentation data The corresponding relation of the camera properties parameter stored in storehouse and coordinate transformation relation value pair determines the first camera properties parameter pair The the first coordinate transformation relation value pair answered, wherein, the first coordinate transformation relation value is to for indicating the first pixel in the 3rd image First coordinate of point is corresponding with the second coordinate;First pixel in 3rd image is determined according to the first coordinate transformation relation value pair Corresponding second coordinate of the first coordinate;Corresponding second Coordinate Conversion of second camera property parameters is determined according to corresponding relation Relation value pair, wherein, the second coordinate transformation relation value is to for indicating the 3rd coordinate of the second pixel and the in the 4th image 4-coordinate is corresponding;Determine that the 3rd coordinate of the second pixel in the 4th image is corresponding according to the second coordinate transformation relation value pair 4-coordinate.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:According to predetermined number The first camera properties parameter is determined according to the corresponding relation of the camera properties parameter stored in storehouse and coordinate transformation relation value pair Corresponding first coordinate transformation relation value is to, judging to whether there is and the first camera properties parameter phase in reservations database before Same camera properties parameter;Exist and the first camera properties parameter identical camera properties parameter in reservations database In the case of, the corresponding first coordinate transformation relation value pair of the first camera properties parameter is determined according to corresponding relation;Predetermined In the case of being not present in database with the first camera properties parameter identical camera properties parameter, the first camera is adjusted Property parameters cause in reservations database exist with the first camera properties parameter identical camera properties parameter after adjustment, And the corresponding first coordinate transformation relation value pair of the first camera properties parameter after adjustment is determined according to corresponding relation;In basis Corresponding relation determines the corresponding second coordinate transformation relation value of second camera property parameters to before, judging in reservations database With the presence or absence of with second camera property parameters identical camera properties parameter;Exist in reservations database and the second shooting In the case of head property parameters identical camera properties parameter, second camera property parameters correspondence is determined according to corresponding relation The second coordinate transformation relation value pair;It is not present and belongs to second camera property parameters identical camera in reservations database Property parameter in the case of, adjustment second camera property parameters cause in reservations database exist and the second camera after adjustment Property parameters identical camera properties parameter, and determine that the second camera property parameters after adjustment are corresponding according to corresponding relation The second coordinate transformation relation value pair.
Alternatively, storage medium is also configured to the program code that storage is used to perform following steps:By the 3rd image Synthesized with the 4th image, obtain after target image, encoding compression processing is carried out to target image;Broadcast in terminal device Put the target image after processing.
Alternatively, the specific example in the present embodiment may be referred to showing described in above-described embodiment 1 and embodiment 2 Example, the present embodiment will not be repeated here.
Alternatively, in the present embodiment, above-mentioned storage medium can include but is not limited to:USB flash disk, read-only storage (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), mobile hard disk, magnetic disc or CD etc. is various can be with the medium of store program codes.
The embodiments of the present invention are for illustration only, and the quality of embodiment is not represented.
If the integrated unit in above-described embodiment is realized using in the form of SFU software functional unit and is used as independent product Sale or in use, the storage medium that above computer can be read can be stored in.Understood based on such, skill of the invention The part or all or part of the technical scheme that art scheme substantially contributes to prior art in other words can be with soft The form of part product is embodied, and the computer software product is stored in storage medium, including some instructions are to cause one Platform or multiple stage computers equipment (can be personal computer, server or network equipment etc.) perform each embodiment institute of the invention State all or part of step of method.
In the above embodiment of the present invention, the description to each embodiment all emphasizes particularly on different fields, and does not have in some embodiment The part of detailed description, may refer to the associated description of other embodiment.
, can be by others side in several embodiments provided herein, it should be understood that disclosed client Formula is realized.Wherein, device embodiment described above is only schematical, such as division of described unit, only one Kind of division of logic function, can there is other dividing mode when actually realizing, such as multiple units or component can combine or Another system is desirably integrated into, or some features can be ignored, or do not perform.It is another, it is shown or discussed it is mutual it Between coupling or direct-coupling or communication connection can be the INDIRECT COUPLING or communication link of unit or module by some interfaces Connect, can be electrical or other forms.
The unit illustrated as separating component can be or may not be it is physically separate, it is aobvious as unit The part shown can be or may not be physical location, you can with positioned at a place, or can also be distributed to multiple On NE.Some or all of unit therein can be selected to realize the mesh of this embodiment scheme according to the actual needs 's.
In addition, each functional unit in each embodiment of the invention can be integrated in a processing unit, can also That unit is individually physically present, can also two or more units it is integrated in a unit.Above-mentioned integrated list Member can both be realized in the form of hardware, it would however also be possible to employ the form of SFU software functional unit is realized.
Described above is only the preferred embodiment of the present invention, it is noted that for the ordinary skill people of the art For member, under the premise without departing from the principles of the invention, some improvements and modifications can also be made, these improvements and modifications also should It is considered as protection scope of the present invention.

Claims (14)

1. a kind of image processing method, it is characterised in that including:
Obtain the first image and second camera that the first camera photographic subjects scene obtains and shoot the target scene and obtain The second image arrived, wherein, first camera is located on same axial line with the second camera, and the axial line is The axle center of first camera and the line where the axle center of the second camera, first camera are located at described second The upper end of camera or first camera are located at the lower end of the second camera;
Polar coordinate system is carried out to the pixel in described first image and is converted to the 3rd image to rectangular coordinate system, to described Pixel in second image carries out polar coordinate system and is converted to the 4th image to rectangular coordinate system, wherein, first figure Picture in the position polar coordinate representation of picture and the pixel in second image, the 3rd image and the 4th image The position of vegetarian refreshments is represented with rectangular co-ordinate;
3rd image and the 4th image are synthesized, target image is obtained, wherein, the target image is described The corresponding panoramic picture of target scene.
2. according to the method described in claim 1, it is characterised in that
The pixel in described first image carries out polar coordinate system and is converted to the 3rd image bag to rectangular coordinate system Include:The length and width of the 3rd image according to the width calculation of described first image, wherein, the 3rd image includes The pixel of first quantity, first quantity is the product of the length and width of the 3rd image;By the 3rd image In the first pixel the first Coordinate Conversion into the second coordinate, wherein, the pixel of first quantity includes first picture Vegetarian refreshments, first coordinate is coordinate of first pixel in rectangular coordinate system, and second coordinate is described first Coordinate of the pixel in polar coordinate system;The pixel value of pixel in described first image positioned at second coordinate is determined The pixel value of the first pixel described in the 3rd image;
The pixel in second image carries out polar coordinate system and is converted to the 4th image bag to rectangular coordinate system Include:The length and width of the 4th image according to the width calculation of second image, wherein, the 4th image includes The pixel of second quantity, second quantity is the product of the length and width of the 4th image;By the 4th image In the second pixel the 3rd Coordinate Conversion into 4-coordinate, wherein, the pixel of second quantity includes second picture Vegetarian refreshments, the 3rd coordinate is coordinate of second pixel in rectangular coordinate system, and the 4-coordinate is described second Coordinate of the pixel in polar coordinate system;The pixel value of pixel in second image positioned at the 4-coordinate is determined The pixel value of the second pixel described in the 4th image.
3. method according to claim 2, it is characterised in that
First Coordinate Conversion by the first pixel in the 3rd image includes into the second coordinate:According to reservations database The camera properties parameter of middle storage determines the first camera properties parameter with the corresponding relation of coordinate transformation relation value pair Corresponding first coordinate transformation relation value pair, wherein, the first coordinate transformation relation value is to for indicating the 3rd image Described in the first pixel first coordinate it is corresponding with second coordinate;According to the first coordinate transformation relation value Pair determine corresponding second coordinate of first coordinate of the first pixel described in the 3rd image;
The 3rd Coordinate Conversion by the second pixel in the 4th image includes into 4-coordinate:Closed according to the correspondence System determines the corresponding second coordinate transformation relation value pair of the second camera property parameters, wherein, second Coordinate Conversion Relation value is to for indicating that the 3rd coordinate of the second pixel described in the 4th image is relative with the 4-coordinate Should;The 3rd coordinate of the second pixel described in the 4th image is determined according to the second coordinate transformation relation value pair The corresponding 4-coordinate.
4. method according to claim 3, it is characterised in that the property parameters of the camera include it is following at least it One:The resolution ratio of image captured by the angular field of view of the camera, the camera, wherein, the camera includes described First camera and the second camera.
5. method according to claim 3, it is characterised in that the property parameters of first camera are taken the photograph with described second As the property parameters of head are identical.
6. method according to claim 3, it is characterised in that
It is true in the corresponding relation according to the camera properties parameter and coordinate transformation relation value pair that are stored in reservations database The corresponding first coordinate transformation relation value of the first camera properties parameter is determined to before, methods described also includes:Judge institute State in reservations database and whether there is and the first camera properties parameter identical camera properties parameter;Described predetermined In the case of existing in database with the first camera properties parameter identical camera properties parameter, according to the correspondence Relation determines the corresponding first coordinate transformation relation value pair of the first camera properties parameter;In the reservations database not In the presence of with the first camera properties parameter identical camera properties parameter in the case of, adjust first camera category Property parameter to exist in the reservations database and the first camera properties parameter identical camera after adjustment belongs to Property parameter, and determine according to the corresponding relation corresponding first coordinate of the first camera properties parameter after the adjustment Transformational relation value pair;
The corresponding second coordinate transformation relation value of the second camera property parameters determined according to the corresponding relation described To before, methods described also includes:Judge to whether there is and the second camera property parameters phase in the reservations database Same camera properties parameter;Exist and the second camera property parameters identical camera in the reservations database In the case of property parameters, corresponding second Coordinate Conversion of the second camera property parameters is determined according to the corresponding relation Relation value pair;It is not present and the second camera property parameters identical camera properties parameter in the reservations database In the case of, adjust the second camera property parameters and cause exist and described second after adjustment in the reservations database Camera properties parameter identical camera properties parameter, and determined according to the corresponding relation after the adjustment described second The corresponding second coordinate transformation relation value pair of camera properties parameter.
7. method according to any one of claim 1 to 6, it is characterised in that described by the 3rd image and institute State the 4th image to be synthesized, obtain after target image, methods described also includes:
Encoding compression processing is carried out to the target image;
The target image in terminal device after playback process.
8. a kind of image processing apparatus, it is characterised in that including:
Acquiring unit, for obtaining the first image and the second camera shooting institute that the first camera photographic subjects scene is obtained The second image that target scene is obtained is stated, wherein, first camera is located on same axial line with the second camera, The axial line is the axle center of first camera and the line where the axle center of the second camera, first camera It is located at the lower end of the second camera positioned at the upper end of the second camera or first camera;
Converting unit, the is converted to for carrying out polar coordinate system to the pixel in described first image to rectangular coordinate system Three images, carry out polar coordinate system to the pixel in second image and are converted to the 4th image to rectangular coordinate system, its In, the position polar coordinate representation of described first image and the pixel in second image, the 3rd image and described The position of pixel in 4th image is represented with rectangular co-ordinate;
Synthesis unit, for the 3rd image and the 4th image to be synthesized, obtains target image, wherein, it is described Target image is the corresponding panoramic picture of the target scene.
9. device according to claim 8, it is characterised in that
The converting unit includes:First computing module, for the 3rd image described in the width calculation according to described first image Length and width, wherein, the 3rd image includes the pixel of the first quantity, and first quantity is the 3rd figure The product of the length and width of picture;First modular converter, for the first coordinate of the first pixel in the 3rd image to be turned Change the second coordinate into, wherein, the pixel of first quantity includes first pixel, and first coordinate is described the Coordinate of one pixel in rectangular coordinate system, second coordinate is coordinate of first pixel in polar coordinate system; First determining module, for the pixel value in described first image positioned at the pixel of second coordinate to be defined as into described the The pixel value of first pixel described in three images;
The converting unit also includes:Second computing module, for the 4th figure described in the width calculation according to second image The length and width of picture, wherein, the 4th image includes the pixel of the second quantity, and second quantity is the described 4th The product of the length and width of image;Second modular converter, for by the 3rd coordinate of the second pixel in the 4th image 4-coordinate is converted into, wherein, the pixel of second quantity includes second pixel, and the 3rd coordinate is described Coordinate of second pixel in rectangular coordinate system, the 4-coordinate is seat of second pixel in polar coordinate system Mark;Second determining module, for the pixel value of the pixel in second image positioned at the 4-coordinate to be defined as into institute State the pixel value of the second pixel described in the 4th image.
10. device according to claim 9, it is characterised in that
First modular converter includes:First determination sub-module, for according to the camera properties stored in reservations database Parameter and the corresponding relation of coordinate transformation relation value pair determine corresponding first Coordinate Conversion of the first camera properties parameter Relation value pair, wherein, the first coordinate transformation relation value is to for indicating the first pixel described in the 3rd image First coordinate is corresponding with second coordinate;Second determination sub-module, for according to first coordinate transformation relation Value pair determines corresponding second coordinate of first coordinate of the first pixel described in the 3rd image;
Second modular converter includes:3rd determination sub-module, for determining second shooting according to the corresponding relation The corresponding second coordinate transformation relation value pair of head property parameters, wherein, the second coordinate transformation relation value is to for indicating The 3rd coordinate for stating the second pixel described in the 4th image is corresponding with the 4-coordinate;4th determination sub-module, For determining that the described 3rd of the second pixel described in the 4th image sits according to the second coordinate transformation relation value pair Mark the corresponding 4-coordinate.
11. device according to claim 10, it is characterised in that the property parameters of the camera include it is following at least it One:The resolution ratio of image captured by the angular field of view of the camera, the camera, wherein, the camera includes described First camera and the second camera.
12. device according to claim 10, it is characterised in that the property parameters of first camera and described second The property parameters of camera are identical.
13. device according to claim 10, it is characterised in that
First modular converter also includes:First judging submodule, for described according to taking the photograph for being stored in reservations database As head property parameters and the corresponding relation of coordinate transformation relation value pair determine the first camera properties parameter corresponding first Coordinate transformation relation value is to before, judging in the reservations database with the presence or absence of identical with the first camera properties parameter Camera properties parameter;5th determination sub-module, belongs to for existing in the reservations database with first camera In the case of property parameter identical camera properties parameter, the first camera properties parameter is determined according to the corresponding relation Corresponding first coordinate transformation relation value pair;6th determination sub-module, in the reservations database be not present with it is described In the case of first camera properties parameter identical camera properties parameter, adjust the first camera properties parameter and cause Exist in the reservations database and the first camera properties parameter identical camera properties parameter after adjustment, and root The corresponding first coordinate transformation relation value of the first camera properties parameter after the adjustment is determined according to the corresponding relation It is right;
Second modular converter also includes:Second judging submodule, for it is described according to the corresponding relation determine described in The corresponding second coordinate transformation relation value of second camera property parameters is to, judging to whether there is in the reservations database before With the second camera property parameters identical camera properties parameter;7th determination sub-module, in the predetermined number In the case of existing in storehouse with the second camera property parameters identical camera properties parameter, closed according to the correspondence System determines the corresponding second coordinate transformation relation value pair of the second camera property parameters;8th determination sub-module, for In the case of being not present in the reservations database with the second camera property parameters identical camera properties parameter, adjust The whole second camera property parameters cause exist and the second camera attribute after adjustment in the reservations database Parameter identical camera properties parameter, and determine according to the corresponding relation second camera attribute after the adjustment The corresponding second coordinate transformation relation value pair of parameter.
14. the device according to any one of claim 8 to 13, it is characterised in that described device also includes:
Processing unit, for 3rd image and the 4th image to be synthesized described, after obtaining target image, Encoding compression processing is carried out to the target image;
Broadcast unit, for the target image after the playback process in terminal device.
CN201710286940.5A 2017-04-26 2017-04-26 Image processing method and device Pending CN107169926A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710286940.5A CN107169926A (en) 2017-04-26 2017-04-26 Image processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710286940.5A CN107169926A (en) 2017-04-26 2017-04-26 Image processing method and device

Publications (1)

Publication Number Publication Date
CN107169926A true CN107169926A (en) 2017-09-15

Family

ID=59813685

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710286940.5A Pending CN107169926A (en) 2017-04-26 2017-04-26 Image processing method and device

Country Status (1)

Country Link
CN (1) CN107169926A (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107995421A (en) * 2017-11-30 2018-05-04 潍坊歌尔电子有限公司 A kind of panorama camera and its image generating method, system, equipment, storage medium
GB2555916A (en) * 2016-10-28 2018-05-16 Adobe Systems Inc Environmental map generation from a digital image
US10282815B2 (en) 2016-10-28 2019-05-07 Adobe Inc. Environmental map generation from a digital image
WO2019091391A1 (en) * 2017-11-09 2019-05-16 Zhejiang Dahua Technology Co., Ltd. Systems and methods for generating panorama image
CN110458755A (en) * 2018-05-07 2019-11-15 华为技术有限公司 Image processing method, relevant device and computer storage medium
CN111292245A (en) * 2018-12-07 2020-06-16 北京字节跳动网络技术有限公司 Image processing method and device
CN111401377A (en) * 2020-03-13 2020-07-10 北京市商汤科技开发有限公司 Instrument data reading method and device, electronic equipment and storage medium

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030103063A1 (en) * 2001-12-03 2003-06-05 Tempest Microsystems Panoramic imaging and display system with canonical magnifier
CN101119482A (en) * 2007-09-28 2008-02-06 北京智安邦科技有限公司 Overall view monitoring method and apparatus
CN104880805A (en) * 2015-06-12 2015-09-02 武汉赫天光电股份有限公司 360-degree panoramic superhigh definition camera lens
CN105530431A (en) * 2015-12-16 2016-04-27 景好 Reflective panoramic imaging system and method
CN105550984A (en) * 2015-12-30 2016-05-04 北京奇艺世纪科技有限公司 Fisheye image correction and wandering display method and apparatus
CN205430338U (en) * 2016-03-11 2016-08-03 依法儿环球有限公司 Take VR content to gather smart mobile phone or portable electronic communication device of subassembly
CN106357991A (en) * 2015-07-14 2017-01-25 旺玖科技股份有限公司 Image processing method, image processing apparatus, and display system

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20030103063A1 (en) * 2001-12-03 2003-06-05 Tempest Microsystems Panoramic imaging and display system with canonical magnifier
CN101119482A (en) * 2007-09-28 2008-02-06 北京智安邦科技有限公司 Overall view monitoring method and apparatus
CN104880805A (en) * 2015-06-12 2015-09-02 武汉赫天光电股份有限公司 360-degree panoramic superhigh definition camera lens
CN106357991A (en) * 2015-07-14 2017-01-25 旺玖科技股份有限公司 Image processing method, image processing apparatus, and display system
CN105530431A (en) * 2015-12-16 2016-04-27 景好 Reflective panoramic imaging system and method
CN105550984A (en) * 2015-12-30 2016-05-04 北京奇艺世纪科技有限公司 Fisheye image correction and wandering display method and apparatus
CN205430338U (en) * 2016-03-11 2016-08-03 依法儿环球有限公司 Take VR content to gather smart mobile phone or portable electronic communication device of subassembly

Non-Patent Citations (3)

* Cited by examiner, † Cited by third party
Title
何东健 等: "《数字图像处理》", 28 February 2015, 西安:西安电子科技大学出版社 *
朱教君 等: "《森林干扰生态研究》", 31 December 2007, 北京:中国林业出版社 *
沈天行 等: "《沈天行建筑物理学术论文选集》", 31 December 2013, 天津:天津大学出版社 *

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2555916A (en) * 2016-10-28 2018-05-16 Adobe Systems Inc Environmental map generation from a digital image
US10282815B2 (en) 2016-10-28 2019-05-07 Adobe Inc. Environmental map generation from a digital image
US10650490B2 (en) 2016-10-28 2020-05-12 Adobe Inc. Environmental map generation from a digital image
GB2555916B (en) * 2016-10-28 2020-05-27 Adobe Inc Environmental map generation from a digital image
WO2019091391A1 (en) * 2017-11-09 2019-05-16 Zhejiang Dahua Technology Co., Ltd. Systems and methods for generating panorama image
US11551330B2 (en) 2017-11-09 2023-01-10 Zhejiang Dahua Technology Co., Ltd. Systems and methods for generating panorama image
CN107995421A (en) * 2017-11-30 2018-05-04 潍坊歌尔电子有限公司 A kind of panorama camera and its image generating method, system, equipment, storage medium
CN110458755A (en) * 2018-05-07 2019-11-15 华为技术有限公司 Image processing method, relevant device and computer storage medium
CN111292245A (en) * 2018-12-07 2020-06-16 北京字节跳动网络技术有限公司 Image processing method and device
CN111401377A (en) * 2020-03-13 2020-07-10 北京市商汤科技开发有限公司 Instrument data reading method and device, electronic equipment and storage medium
CN111401377B (en) * 2020-03-13 2024-03-08 北京市商汤科技开发有限公司 Meter data reading method and device, electronic equipment and storage medium

Similar Documents

Publication Publication Date Title
CN107169926A (en) Image processing method and device
JP6471777B2 (en) Image processing apparatus, image processing method, and program
CN107301620B (en) Method for panoramic imaging based on camera array
CN101689292B (en) Banana codec
CN110463176A (en) Image quality measure
JP5567235B2 (en) Image processing apparatus, photographing apparatus, program, and image processing method
CN107925753A (en) The method and system of 3D rendering seizure is carried out using dynamic camera
CN106651808B (en) Fisheye diagram conversion method and device
CN106357991A (en) Image processing method, image processing apparatus, and display system
US8509518B2 (en) Real-time image collage method and apparatus
CN105009563B (en) Restore wave filter generating means and method, image processing apparatus, camera device, recovery wave filter generation program and recording medium
CN201523430U (en) Panoramic video monitoring system
JP2002171398A (en) Image processing method and electronic camera
WO2022042776A1 (en) Photographing method and terminal
CN103716529B (en) Threshold value setting device, object detection device, threshold setting method
CN106815802A (en) A kind of image split-joint method and device
CN107623819B (en) A kind of method taken pictures and mobile terminal and related media production
CN110689476A (en) Panoramic image splicing method and device, readable storage medium and electronic equipment
CN109600556B (en) High-quality precise panoramic imaging system and method based on single lens reflex
CN111385461B (en) Panoramic shooting method and device, camera and mobile terminal
CN111654624A (en) Shooting prompting method and device and electronic equipment
CN110675319A (en) Mobile phone photographing panoramic image splicing method based on minimum spanning tree
CN106888353A (en) A kind of image-pickup method and equipment
US20100165153A1 (en) Image pickup device, image pickup method and integrated circuit
CN106572313B (en) Video capture box and video capture method and apparatus

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: 20170915