The present disclosure belongs to the field of videos, and particularly relates to a smoothing method of a motion camera lens and a portable terminal.
At present, when a motion camera photographs a motion scene, a video lens for photographing may shake to affect the photographing quality and the watching experience of a video. Therefore, there is a need for studying a method of improving shaking of a video lens of a camera.
At present, one of solutions is to use a pan-tilt stabilization camera to enable a photographed picture to be stable. However, the disadvantages of this solution are that a pan-tilt is large in volume, and the problem that the picture shakes when a panorama photographing device is held by hands to photograph the video also exists.
In the first aspect, embodiment of the present disclosure provides a camera lens smoothing method, including:
In the second aspect, embodiment of the present disclosure provides a computer readable storage medium, wherein the computer readable storage medium stores a computer program. When the computer program is executed by a processor, the steps of the camera lens smoothing method according to the first aspect are implemented.
In the third aspect, embodiment of the present disclosure provides a portable terminal, including:
In order to make the purposes, the technical solutions and the beneficial effects of the present disclosure more clearly and unambiguously, the present disclosure is further clarified based on the following drawings and examples. It should be understood that the specific embodiments described here are for illustrating and explaining the present disclosure merely, but not used for limiting the present disclosure.
The Chinese patent “entitled with Video Image Stabilization Method For Micro-Nano Satellite with a Publication No. CN106027852B” discloses a video image stabilization method for a micro-nano satellite, aiming to using only one attitude sensor-gyroscope on a built micro-nano satellite platform to process a shaking video by physical information obtained by the attitude sensor gyroscope in combination with information of the video photographed by a micro camera, to achieve image stabilization. However, the method requires to use the video information to conduct matching between a front frame and a back frame and the like and thus is relatively complex in process.
Embodiments of the present disclosure propose a camera lens smoothing method, an apparatus and a portable terminal and aims at enabling a video lens of a motion camera to conduct adaptive adjustment and thus preventing the video lens from shaking. By using the embodiments of the present disclosure, a cropping view angle may be reduced to the maximum while smoothing is conducted.
In order to describe the technical solutions of the present disclosure, description is made through the specific embodiments below.
Referring to
A method of conducting first smoothing on the first rotation matrix to obtain the second rotation matrix specifically includes:
where q=[v,u]T is the quaternion,
After the step S10211, second smoothing may further be conducted on the second rotation matrix by employing an iterative amplitude-limiting smoothing filtering method to obtain an updated second rotation matrix. The iterative amplitude-limiting smoothing filtering method specifically includes:
The calculating the third rotation matrix (which is a smoothing rotation matrix generated by calculating the first rotation matrix of the camera) of the camera by limiting the smoothing maximum amplitude value specifically includes:
The fourth rotation matrix is a motion matrix obtained after conducting smoothing rotation on the current video frame according to the third rotation matrix.
The threshold of the pitch direction of the view angle of the camera is set as Θ, and calculation of the fourth rotation matrix is specifically as follows:
The conducting 3D rotation on the current video frame according to the fourth rotation matrix, and rebuilding the anti-shake video specifically includes:
In the embodiment of the present disclosure, the anti-shake effect for camera lens adaptive smoothing is achieved by obtaining an attitude matrix obtained through the gyroscope information of the camera, calculating the smoothing rotation matrix of the camera through smoothing and rotating the video. By using the embodiment of the present disclosure, a video photographed by an original camera keeps invariable while the view angle of the lens is smoothed, and the view angle of the lens may be automatically adjusted, so that a horizon direction keeps invariable when the lens conducts forward photographing; when photographing is conducted in a view angle of the sky or the ground, an orientation of one side (such as the left side) of an image keeps invariable; and the cropping view angle may be reduced to the maximum while smoothing is conducted.
Embodiment 2 of the present disclosure provides a computer readable storage medium. Computer programs are stored in the computer readable storage medium. When the computer programs are executed by a processor, the steps of the camera lens smoothing method according to Embodiment 1 of the present disclosure are implemented. The computer readable storage medium may be a non-transitory computer readable medium.
In the embodiments of the present disclosure, it will be appreciated by those of ordinary skill in the art that all or a part of the steps of implementing the embodiments described above in the method may be accomplished by programs instructing related hardware. The programs may be stored in one computer readable storage medium, and the storage medium may be a ROM/RAM, a magnetic disk, an optical disk or the like.
The foregoing is only preferred embodiments of the present disclosure and is not intended to be limiting of the present disclosure, and any modifications, equivalent substitutions, improvements and the like within the spirit and principles of the present disclosure are intended to be embraced by the protection range of the present disclosure.
Number | Date | Country | Kind |
---|---|---|---|
201910664290.2 | Jul 2019 | CN | national |
This application is a continuation of International Application No. PCT/CN2020/101987, with an international filing date of Jul. 15, 2020, which is based upon and claims priority to Chinese Patent Application No. 201910664290.2, filed with the Chinese Patent Office on Jul. 23, 2019, titled “CAMERA LENS SMOOTHING METHOD, APPARATUS AND PORTABLE TERMINAL”, the entire contents of which are incorporated herein by reference.
Number | Name | Date | Kind |
---|---|---|---|
5051751 | Gray | Sep 1991 | A |
20140146205 | Xu | May 2014 | A1 |
20140294361 | Acharya | Oct 2014 | A1 |
20160112701 | Chao | Apr 2016 | A1 |
20180232907 | Sung | Aug 2018 | A1 |
20210006718 | Chen | Jan 2021 | A1 |
Number | Date | Country |
---|---|---|
106027852 | Oct 2016 | CN |
106780370 | May 2017 | CN |
107241544 | Oct 2017 | CN |
109561253 | Apr 2019 | CN |
109788189 | May 2019 | CN |
109922267 | Jun 2019 | CN |
110519507 | Nov 2019 | CN |
Number | Date | Country | |
---|---|---|---|
20220141387 A1 | May 2022 | US |
Number | Date | Country | |
---|---|---|---|
Parent | PCT/CN2020/101987 | Jul 2020 | US |
Child | 17579670 | US |