Video image stabilization method and apparatus
By introducing stabilization controls into video stabilization methods, users can flexibly adjust optical and electronic stabilization parameters, solving the problem of limited stabilization modes in existing technologies. This achieves the effect of maintaining image quality while stabilizing images, meeting diverse recording needs of users.
Patent Information
- Application Number
- CN202310565450.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-05-18
- Publication Date
- 2025-11-18
- Estimated Expiration
- 2043-05-18
AI Technical Summary
Existing video stabilization technologies have limited stabilization modes, making it difficult to meet users' video recording needs in different scenarios, and they cannot flexibly adjust the relationship between stabilization effect and image quality.
A video stabilization method is provided, which allows users to adjust optical and electronic image stabilization parameters according to different scenarios and handheld stability by displaying stabilization controls on the preview interface, thereby coordinating the relationship between stabilization intensity and image quality and achieving flexible adjustment.
It achieves the effect of maintaining image quality while stabilizing the image, meeting the diverse video recording needs of users and avoiding the monotonous adjustments caused by using fixed stabilization parameters.
Smart Images

Figure CN116546324B_ABST
Abstract
Description
Technical Field
[0001] This application belongs to the field of image stabilization technology, specifically relating to a video image stabilization method and apparatus. Background Technology
[0002] Electronic devices with cameras generally have video recording capabilities, and these cameras typically require image stabilization. Currently, image stabilization generally includes two types: electronic image stabilization and optical image stabilization. Electronic image stabilization mainly achieves stabilization by cropping the image, which sacrifices some of the image's field of view. Optical image stabilization compensates for external shaking by adjusting the relative position between the lens and the sensor, effectively overcoming the problem of image blur caused by external shaking. Summary of the Invention
[0003] The purpose of this application is to provide a video stabilization method and apparatus that can flexibly adjust the stabilization effect and maintain image quality during the stabilization process.
[0004] In a first aspect, embodiments of this application provide a video stabilization method, the method comprising:
[0005] In response to the user's first input, a preview interface is displayed, which includes anti-shake controls for adjusting anti-shake parameters.
[0006] In response to a second input from the user to the preview interface, the video recording interface is displayed;
[0007] At least two frames of images are acquired based on the first image stabilization parameter;
[0008] Based on the second stabilization parameter, at least two frames of images are stabilized to obtain the target video;
[0009] The first and second image stabilization parameters are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first and second image stabilization parameters.
[0010] Secondly, embodiments of this application provide a video stabilization device, the device comprising:
[0011] The first display module is used to respond to the user's first input and display a preview interface. The preview interface includes a stabilization control, which is used to adjust the stabilization parameters.
[0012] The second display module is used to display the video recording interface in response to a second input from the user to the preview interface;
[0013] The acquisition module is used to acquire at least two frames of images based on the first image stabilization parameter;
[0014] The processing module is used to perform image stabilization processing on at least two frames of images based on the second image stabilization parameter to obtain the target video;
[0015] The first and second image stabilization parameters are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first and second image stabilization parameters.
[0016] Thirdly, embodiments of this application provide an electronic device including a processor and a memory, the memory storing programs or instructions executable on the processor, the programs or instructions, when executed by the processor, implementing the steps of the method described in the first aspect.
[0017] Fourthly, embodiments of this application provide a readable storage medium on which a program or instructions are stored, which, when executed by a processor, implement the steps of the method described in the first aspect.
[0018] Fifthly, embodiments of this application provide a chip, the chip including a processor and a communication interface, the communication interface being coupled to the processor, the processor being used to run programs or instructions to implement the method as described in the first aspect.
[0019] In a sixth aspect, embodiments of this application provide a computer program product stored in a storage medium, which is executed by at least one processor to implement the method described in the first aspect.
[0020] In this embodiment, a stabilization control for adjusting stabilization parameters can be displayed on the preview interface. Users can input different second values into the stabilization control based on different video shooting scenarios to determine different optical and electronic stabilization parameters. This allows for the coordination of stabilization intensity and image quality through different optical and electronic stabilization parameters, avoiding the limitation of fixed stabilization parameters and achieving flexible adjustment of the stabilization effect while maintaining image quality during stabilization, thus better meeting the user's video recording needs. Attached Figure Description
[0021] Figure 1 This is a schematic flowchart of the video stabilization method provided in the embodiments of this application;
[0022] Figure 2 This is a schematic diagram of the interface in the video stabilization method provided in the embodiments of this application;
[0023] Figure 3 This is a schematic diagram of a stabilization control in the video stabilization method provided in this application embodiment;
[0024] Figure 4 This is another schematic diagram of the anti-shake control in the video anti-shake method provided in the embodiments of this application;
[0025] Figure 5 This is a schematic diagram of the video stabilization device provided in the embodiments of this application;
[0026] Figure 6 This is a schematic diagram of the structure of the electronic device provided in the embodiments of this application;
[0027] Figure 7 This is a schematic diagram of the hardware structure of the electronic device provided in the embodiments of this application. Detailed Implementation
[0028] The technical solutions of the embodiments of this application will be clearly described below with reference to the accompanying drawings. Obviously, the described embodiments are only some, not all, of the embodiments of this application. All other embodiments obtained by those skilled in the art based on the embodiments of this application are within the scope of protection of this application.
[0029] The terms "first," "second," etc., used in the specification and claims of this application are used to distinguish similar objects and not to describe a specific order or sequence. It should be understood that such use of data can be interchanged where appropriate so that embodiments of this application can be implemented in orders other than those illustrated or described herein, and the objects distinguished by "first," "second," etc., are generally of the same class and the number of objects is not limited; for example, a first object can be one or more. Furthermore, in the specification and claims, "and / or" indicates at least one of the connected objects, and the character " / " generally indicates that the preceding and following objects are in an "or" relationship.
[0030] The video stabilization method provided in this application will be described in detail below with reference to the accompanying drawings, through specific embodiments and application scenarios.
[0031] Understandably, current video recording typically uses fixed electronic and optical image stabilization (EIS) parameters to achieve video stabilization. That is, the field of view cropping ratio is generally fixed across different stabilization modes, with the cropping ratio only switchable through a limited selection of modes. Similarly, the lens's movable angle in optical image stabilization is currently fixed, and the stabilization angle cannot usually be changed during use. However, this fixed and singular adjustment method often fails to meet the video recording needs of users.
[0032] For electronic image stabilization, it's important to consider that users prioritize different angles of view and stabilization effects in different scenarios. For example, when recording a bamboo forest, sacrificing more angle of view can often achieve better stabilization; however, when shooting close-up, tall objects, angle of view becomes more crucial. Furthermore, the stability of handheld recording varies among users. For users with relatively steady handheld recording, a higher cropping ratio is unnecessary; the angle of view can be increased by reducing the cropping ratio. Conversely, for users with shaky handheld recording, a smaller angle of view can improve recording stability.
[0033] In terms of optical image stabilization (OIS), from a practical user scenario perspective, when shooting handheld still photos, minimal shaking doesn't require a high level of stabilization. However, when the user is running or jumping, the shaking increases, necessitating a larger OIS angle for stronger stabilization. Furthermore, for users with steady hands, an excessively large OIS angle is unnecessary; reducing the OIS angle can improve image quality. Conversely, for users with significant hand shake, a larger OIS angle is needed to enhance image stability, even at the cost of sacrificing edge sharpness for optimal user experience.
[0034] Based on this, in order to solve the above-mentioned technical problems, this application provides a video stabilization method that can flexibly adjust the stabilization effect and take into account image quality during the stabilization process. Figure 1 This is a flowchart illustrating the video stabilization method provided in this application embodiment. The video stabilization method may include:
[0035] Step 101: In response to the user's first input, a preview interface is displayed. The preview interface includes a stabilization control, which is used to adjust the stabilization parameters.
[0036] In step 101, as Figure 2 As shown, when a user wants to record video using an electronic device, the electronic device can receive the user's first input and respond to the first input by displaying a preview interface 201. This preview interface 201 may include a stabilization control 202 for adjusting stabilization parameters. The first input can be a user's click, a voice command, or a specific gesture. The specific gesture can be determined according to actual usage needs, and this embodiment does not limit this. The specific gesture in this embodiment can be any one of a single-click gesture, a swipe gesture, a drag gesture, a pressure-recognition gesture, a long-press gesture, an area-change gesture, a double-press gesture, or a double-tap gesture. The click input in this embodiment can be a single-click input, a double-tap input, or any number of clicks, and can also be a long-press input or a short-press input.
[0037] Image stabilization parameters affect both stabilization strength and image quality. These parameters can be categorized into primary and secondary stabilization parameters. The primary parameter indicates optical stabilization parameters, such as the optical stabilization angle, which can be the angle at which the lens can move. The secondary parameter indicates electronic stabilization parameters, such as the field-of-view crop factor.
[0038] As we can understand, electronic image stabilization is a video stabilization technology that achieves video stability by sacrificing the image's field of view. Under the same conditions, the larger the field of view cropping ratio, the wider the compensation range of the stabilization. Therefore, by setting different field of view cropping ratios, different levels of image stabilization effects can be achieved. In other words, the strength of image stabilization is affected by the field of view cropping ratio; the stronger the image stabilization, the smaller the field of view.
[0039] Optical image stabilization (OIS) compensates for image shake caused by external factors by adjusting the relative position between the lens and the sensor. A larger OIS angle can lead to problems such as vignetting at the edges of the image and poor sharpness. In other words, a larger OIS angle is more effective at compensating for strong external shake, but it also results in a loss of image quality. A smaller OIS angle has less impact on image quality but weaker stabilization.
[0040] Therefore, both image stabilization and image quality affect the final video recording result and are important aspects of the user's experience during video recording; they are a trade-off. Based on this, users can use the image stabilization controls on the preview interface to balance the relationship between image stabilization effectiveness and image quality.
[0041] Step 102: In response to the user's second input to the preview interface, the video recording interface is displayed.
[0042] In step 102, different second inputs can correspond to different first and second stabilization parameters. In other words, the system can receive second input from the user on the preview interface and, in response to the second input, display the video recording interface. At the same time, the electronic device can determine the first and second stabilization parameters required by the user based on the second input, and perform video recording according to the first and second stabilization parameters.
[0043] The second input can be: a user's click on the preview interface, a voice command input by the user, or a specific gesture input by the user. The specific gesture can be determined according to actual usage needs, and this application embodiment does not limit this. The specific gesture in this application embodiment can be any one of a single-click gesture, a swipe gesture, a drag gesture, a pressure-recognition gesture, a long-press gesture, an area-change gesture, a double-press gesture, or a double-tap gesture. The click input in this application embodiment can be a single-click input, a double-tap input, or any number of clicks, and can also be a long-press input or a short-press input.
[0044] Step 103: Acquire at least two frames of images based on the first image stabilization parameter.
[0045] In step 103, as mentioned above, the first stabilization parameter can indicate the optical stabilization parameter, and at least two frames of images can be acquired using the specific value of the optical stabilization angle indicated by the first stabilization parameter.
[0046] Step 104: Perform image stabilization on at least two frames based on the second image stabilization parameter to obtain the target video.
[0047] In step 104, as mentioned above, the second stabilization parameter can indicate the electronic stabilization parameter. That is, the specific value of the field of view cropping ratio indicated by the second stabilization parameter can be used to crop at least two frames of the acquired image to obtain the target video after stabilization.
[0048] Considering that users prioritize field of view and image stabilization differently in various scenarios—for example, when recording a bamboo forest, sacrificing more field of view can often achieve better image stabilization; while when shooting close-up, tall objects, field of view becomes more important. Furthermore, the stability of handheld recording varies among users. For users with relatively steady handheld recording, a higher cropping ratio is unnecessary; the field of view can be expanded by reducing the cropping ratio. Conversely, for users with shaky handheld recording, a smaller field of view can improve shooting stability.
[0049] In existing technologies, the lens can only move at a fixed angle during optical image stabilization (OIS), which typically cannot be changed during use, causing inconvenience for users. From a practical user perspective, when shooting handheld and stationary, less shaking requires less stabilization. However, when the user is running or jumping, the shaking increases, necessitating a larger OIS angle for stronger stabilization. Furthermore, for users with steady hands, a smaller OIS angle is unnecessary; reducing it can improve image quality. Conversely, for users with significant hand shake, a larger OIS angle is needed to improve image stability, at the expense of some edge sharpness.
[0050] It is evident that existing video stabilization methods are relatively limited and often fail to meet the diverse video recording needs of users. Therefore, in this embodiment, the video stabilization method displays stabilization controls for adjusting stabilization parameters on the preview interface. Users can input different second parameters into these controls based on different video shooting scenarios to determine different optical and electronic stabilization parameters. This allows for the coordination of stabilization intensity and image quality through different optical and electronic stabilization parameters, avoiding the limitations of fixed parameters that lead to a single adjustment method. It achieves flexible adjustment of the stabilization effect while maintaining image quality during stabilization, better meeting the user's video recording needs.
[0051] In some embodiments, the stabilization control includes a control body and an identifier located on the control body; the second input includes a first sub-input to the identifier;
[0052] Step 102 above may include the following steps:
[0053] In response to the user's first sub-input on the identifier, a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input are determined, and the first stabilization parameter and the second stabilization parameter are related to the input parameters of the first sub-input;
[0054] The video recording interface is displayed.
[0055] In this embodiment, in response to a user's first sub-input of the identifier, a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input can be determined. The first stabilization parameter and the second stabilization parameter can be associated with the input parameters of the first sub-input.
[0056] For example, such as Figure 3 As shown, the image stabilization control may include a control body 301 and an identifier 302 located on the control body 301. The identifier 302 can be moved in response to the input position of the first sub-input. The control body 301 may be a scaled slider, with different scales corresponding to different image stabilization parameters. The left side can indicate a better image display effect, i.e., the best image quality, at which point the field of view crop ratio and optical image stabilization angle are the smallest. The right side can indicate a better image stabilization effect, at which point the field of view crop ratio and optical image stabilization angle are the largest.
[0057] In other words, different positions on the control body 301 can be associated with different image stabilization parameters. This can be achieved by responding to the first sub-input to determine the target position information of the identifier 302 on the control body 301, thereby determining the first and second image stabilization parameters associated with the target position information. In this way, based on the user's selection, the identifier can be manually adjusted to the target position information on the control body to determine the appropriate first and second image stabilization parameters. This achieves flexible adjustment of the image stabilization effect while maintaining image quality during the stabilization process, thus meeting user needs.
[0058] For example, in response to the first sub-input, the current jitter of the electronic device can be obtained to determine the required stabilization strength, and then the corresponding first and second stabilization parameters can be determined based on the stabilization strength. The specific method can be flexibly set and is not specifically limited here.
[0059] Once the first and second stabilization parameters corresponding to the first sub-input are determined, the video recording interface will automatically appear without any further user intervention, and video recording will automatically proceed based on the first and second stabilization parameters.
[0060] In this way, in response to the user's first sub-input on the identifier, the first and second stabilization parameters required by the user can be determined, so that video recording can be performed according to the first and second stabilization parameters. This achieves flexible adjustment of stabilization intensity and maintains image quality during stabilization, thus better meeting the user's video recording needs.
[0061] In some embodiments, the second input includes a second sub-input, and before displaying the video recording interface, the video stabilization method may further include the following steps:
[0062] Receive the user's second sub-input to the preview interface;
[0063] The above-mentioned video recording interface may also include the following steps:
[0064] In response to the second sub-input, the video recording interface is displayed.
[0065] In this embodiment, upon receiving the user's first sub-input on the identifier, the system can determine the first and second stabilization parameters corresponding to the first sub-input based solely on this first sub-input. At this point, the video recording interface may not be displayed, and the user can continue to adjust the stabilization parameters until the first and second stabilization parameters that best meet their needs are determined. Subsequently, the system can receive the user's second sub-input on the preview interface and display the video recording interface in response to the second sub-input.
[0066] In this way, users can freely adjust the stabilization parameters based on the stabilization controls until they determine the first and second stabilization parameters that best meet their needs. Then, in response to the user's second sub-input on the preview interface, the video recording interface can be displayed so that video can be recorded according to the first and second stabilization parameters, thus meeting the user's video recording needs.
[0067] In some embodiments, determining the first and second stabilization parameters corresponding to the first sub-input may include the following steps:
[0068] Obtain the gyroscope sensor data corresponding to N frames of preview images within the first time period, where N is an integer greater than 1;
[0069] Based on the gyroscope sensor data corresponding to the N frames of preview images, determine the N rotation matrices corresponding to the N frames of preview images;
[0070] The stabilization strength is determined based on N rotation matrices;
[0071] Determine the first and second image stabilization parameters based on the image stabilization strength.
[0072] In this embodiment, considering that users may find it difficult to determine the appropriate image stabilization effect, the stabilization parameters can be adaptively adjusted to suit the current vibration of the electronic device. For example, gyroscope sensor data from a certain number of preview frames of a video recording can be used to calculate the inter-frame rotation matrix, estimate the current level of vibration, determine the required stabilization intensity, and thus select appropriate first and second stabilization parameters.
[0073] For example, such as Figure 4 As shown, adaptive image stabilization can be activated in response to the first sub-input of the indicator being pulled down. At this time, gyroscope sensor data corresponding to N frames of preview images within a first time period can be acquired. The first time period can be a preset time period or a time period determined based on the input parameters of the first sub-input; no specific limitation is made here.
[0074] Based on the gyroscope sensor data corresponding to the N preview images, N rotation matrices corresponding to the N preview images can be determined. The rotation matrices can be calculated using Euler angles or quaternions.
[0075] In one example, gyroscope sensor data may include angular velocity ω(t) = (ω x ,ω y ,ω z This allows us to calculate the jitter angle (θ(n)) of each preview image. x ,θ(n) y ,θ(n) z), where the jitter angle (θ(n)) x ,θ(n) y ,θ(n) z The formula for calculating ) is shown in formula (1):
[0076]
[0077] Where ΔT can represent the sampling interval of the gyroscope, and k can represent the number of inter-frame gyroscope samplings.
[0078] It can be based on the jitter angle (θ(n)) x ,θ(n) y ,θ(n) z The rotation matrix of each preview image is represented by Euler angles, and the formula for calculating the rotation matrix R is shown in formula (2):
[0079]
[0080] In another example, the gyroscope sensor data may also include the unit vector of the rotation axis and the angle of rotation about that axis, so that if there is a rotation axis u, the expression for the quaternion of the rotation angle σ about the u axis is as shown in Equation (3):
[0081]
[0082] Here, q can be a single-unit quaternion, and u can represent the unit vector of the rotation axis.
[0083] Based on this, the quaternion Q = (q0, q1, q2, q3) of each preview image can be obtained, and the rotation matrix of each preview image can be calculated based on the quaternion. The formula for calculating the rotation matrix R is shown in formula (4):
[0084]
[0085] The stabilization strength can be determined based on N rotation matrices. For example, after calculating N rotation matrices for N frames of preview images, the current jitter of the electronic device can be determined based on these rotation matrices. Generally, changes in the same direction within a very short time are considered reasonable user actions, while changes in opposite directions indicate abnormal jitter. Therefore, it can be assumed that the higher the similarity of the rotation matrices between frames, the lower the jitter frequency, the less severe the jitter, and the lower the required stabilization strength; conversely, the lower the similarity, the greater the jitter, and the higher the required stabilization strength.
[0086] The first and second image stabilization parameters can be determined based on the image stabilization intensity. For example, the correspondence between image stabilization intensity and image stabilization parameters can be preset, and the first and second image stabilization parameters can be matched according to the determined image stabilization intensity. Alternatively, the first and second image stabilization parameters can be calculated based on the image stabilization intensity and the maximum or minimum image stabilization parameters supported by the electronic device. No specific limitations are imposed here.
[0087] In this way, the gyroscope sensor data of a certain number of preview images can be used to estimate the current level of shaking, determine the required stabilization strength, and obtain more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0088] In some embodiments, determining the stabilization strength based on N rotation matrices includes:
[0089] Based on the rotation matrices corresponding to two adjacent preview images, the similarity of N-1 rotation matrices is calculated.
[0090] Determine the average similarity based on the similarity of N-1 rotation matrices;
[0091] The stabilization strength is determined based on the average similarity.
[0092] In this embodiment, as mentioned above, the stabilization strength is related to the similarity of the inter-frame rotation matrix. Based on this, the similarity of the rotation matrix between two adjacent preview images can be determined according to the rotation matrix of two adjacent preview images in N preview images, thereby obtaining N-1 rotation matrix similarities.
[0093] For example, taking two adjacent preview images as the (n-1)th frame and the nth frame, the rotation matrix similarity ρ (n-1) The calculation formula can be shown in formula (5):
[0094]
[0095] Where R′(n-1) is a flattened one-dimensional vector of the rotation matrix R(n-1) of the (n-1)th frame image, and R′(n) is a flattened one-dimensional vector of the rotation matrix R(n) of the nth frame image. The similarity calculated in this embodiment is the cosine similarity.
[0096] The average similarity can be determined based on the similarity of N-1 rotation matrices. For example, average similarity It can be (ρ1+ρ2+…+ρ n-2 +ρ n-1 ) / (n-1).
[0097] The stabilization strength ξ can be determined based on the average similarity. For example, the formula for calculating the stabilization strength ξ can be shown in formula (6):
[0098]
[0099] Where ξ is the image stabilization strength, This represents the average similarity.
[0100] In this way, the average similarity can be determined by the similarity of N-1 rotation matrices of two adjacent preview images, thereby calculating the accurate stabilization strength. This allows for more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0101] In some embodiments, determining the average similarity based on the similarity of N-1 rotation matrices includes:
[0102] The average similarity is obtained by weighting the similarities of the N-1 rotation matrices.
[0103] In this embodiment, the weights corresponding to each rotation matrix similarity can be consistent or inconsistent. For example, a weight value can be pre-set for each rotation matrix similarity based on empirical values. Then, the average similarity is calculated by weighted averaging based on N-1 rotation matrix similarities and the weight values corresponding to the rotation matrix similarities.
[0104] For example, when weighting the similarity of N-1 rotation matrices, the handheld state of the user's electronic device is affected by time. The jitter vector from later frames better reflects the true jitter trend. Based on this, the rotation matrix similarity of adjacent preview images in N frames can be linearly weighted. For instance, the time information of each preview image in the N frames can be obtained, and the weights corresponding to the N-1 rotation matrix similarities of adjacent preview images can be determined based on the time information of each preview image. It can be understood that the weight corresponding to the rotation matrix similarity of adjacent preview images with later time information is greater, and the weight changes can be linearly distributed. The average similarity can be determined based on the N-1 rotation matrix similarities and their corresponding weights. The calculation formula can be shown in formula (7):
[0105]
[0106] in, For average similarity, ρ1 is the rotation matrix similarity between the first and second frames, ρ2 is the rotation matrix similarity between the second and third frames, and ρ... n-2 ρ represents the similarity of the rotation matrices between the (n-2)th frame image and the (n-1)th frame image.n-1 Let be the similarity of the rotation matrices between the (n-1)th frame image and the nth frame image.
[0107] In this way, the influence of external factors such as time on the shaking can be taken into account. By weighted averaging of the similarity of N-1 rotation matrices, the accuracy of the average similarity can be further guaranteed, thereby obtaining a more accurate stabilization strength and matching a more accurate first and second stabilization parameters, which further guarantees the stabilization effect.
[0108] In some embodiments, determining a first image stabilization parameter and a second image stabilization parameter based on the image stabilization intensity includes:
[0109] Acquire the maximum first image stabilization parameter, the minimum first image stabilization parameter, the maximum second image stabilization parameter, and the minimum second image stabilization parameter of the electronic device;
[0110] The first image stabilization parameter is determined based on the image stabilization strength, the maximum first image stabilization parameter, and the minimum first image stabilization parameter;
[0111] The second image stabilization parameter is determined based on the stabilization strength, the maximum second image stabilization parameter, and the minimum second image stabilization parameter.
[0112] In this embodiment, the maximum first stabilization parameter, the minimum first stabilization parameter, the maximum second stabilization parameter, and the minimum second stabilization parameter of the electronic device can also be obtained, that is, the maximum optical stabilization angle, the minimum optical stabilization angle, the maximum field of view cropping ratio, and the minimum field of view cropping ratio that the electronic device can support.
[0113] The first image stabilization parameter can be determined based on the stabilization strength, the maximum first image stabilization parameter, and the minimum first image stabilization parameter. As mentioned above, the first image stabilization parameter is the optical image stabilization angle (deg). ois Optical image stabilization angle (deg) ois The calculation formula can be shown in formula (8):
[0114] deg ois =ξ*Max deg +(1-ξ)*Min deg (8)
[0115] Where ξ is the image stabilization strength, Min deg For the minimum optical image stabilization angle, Max deg For the maximum optical image stabilization angle, Min deg and Max deg This is a hyperparameter.
[0116] The second stabilization parameter can be determined based on the stabilization strength, the maximum second stabilization parameter, and the minimum second stabilization parameter. As mentioned above, the second stabilization parameter is the field of view cropping ratio (marginH, marginW). For example, the calculation formula for the field of view cropping ratio (marginH, marginW) can be shown in formula (9):
[0117] marginH = marginW = ξ * Max margin +(1-ξ)*Min margin (9)
[0118] Where ξ is the image stabilization strength, Max margin Min is the cropping ratio for the maximum field of view. margin Max is the minimum field of view cropping ratio. margin and Min margin This is a hyperparameter.
[0119] In this way, the first and second stabilization parameters can be calculated by using the stabilization strength and the maximum, minimum, maximum, and minimum first stabilization parameters supported by the electronic device. This ensures the accuracy of the first and second stabilization parameters and their compatibility with the electronic device, further guaranteeing the stabilization effect.
[0120] In some embodiments, the first sub-input is a sliding input, and the first time period is determined based on the input parameters of the first sub-input, which include at least one of the following: sliding distance and input time.
[0121] In this embodiment, the first sub-input can be a sliding input, and the first time period can be determined based on the sliding distance of the sliding input. For example, such as... Figure 4 As shown, after sliding the icon down a certain distance and releasing it, the icon returns to the control body at a fixed rate v. The longer the drag distance, the longer the return time t to the control body, allowing preview images to be captured during the return process. In other words, the longer the sliding input distance, the longer the initial time period. This results in more frames n of preview images being captured. More frames mean more gyroscope sensor data can be obtained, leading to higher accuracy in subsequent calculations of image stabilization strength.
[0122] The first time period can also be determined based on the input time of the first sub-input. For example, the longer the input time, the longer the first time period; the shorter the input time, the shorter the first time period. The number of frames of the preview image acquired can be controlled by adjusting the input time, thereby controlling the accuracy of subsequent calculations of the stabilization strength.
[0123] The first time segment can also be determined based on the input time and sliding distance of the first sub-input. A larger sliding distance and a longer input time result in a longer first time segment, while a smaller sliding distance and a shorter input time result in a shorter first time segment. For example, considering both input time and sliding distance, corresponding weight values can be set for each dimension. The duration of the first time segment can then be calculated using these weight values, along with the input time and sliding distance. In this way, the number of frames acquired for the preview image can be controlled by adjusting the input time and sliding distance, thereby controlling the accuracy of subsequent calculations of the stabilization strength.
[0124] In this way, the duration of the first time period can be controlled based on the input parameters of the first sub-input, thereby achieving precise control of the stabilization intensity and further increasing the flexibility of video stabilization.
[0125] The video stabilization method provided in this application can be implemented by a video stabilization device. This application uses a video stabilization device to perform the video stabilization method as an example to illustrate the video stabilization device provided in this application.
[0126] like Figure 5 As shown, the video stabilization device 500 provided in this application embodiment may include:
[0127] The first display module 501 is used to respond to the user's first input and display a preview interface. The preview interface includes a stabilization control, which is used to adjust the stabilization parameters.
[0128] The second display module 502 is used to display the video recording interface in response to a second input from the user to the preview interface;
[0129] Acquisition module 503 is used to acquire at least two frames of images based on the first anti-shake parameter;
[0130] Processing module 504 is used to perform image stabilization processing on at least two frames of images based on the second image stabilization parameter to obtain the target video;
[0131] The first and second image stabilization parameters are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first and second image stabilization parameters.
[0132] In this embodiment, a stabilization control for adjusting stabilization parameters can be displayed on the preview interface. Users can input different second values into the stabilization control based on different video shooting scenarios to determine different optical and electronic stabilization parameters. This allows for the coordination of stabilization intensity and image quality through different optical and electronic stabilization parameters, avoiding the limitation of fixed stabilization parameters and achieving flexible adjustment of the stabilization effect while maintaining image quality during stabilization, thus better meeting the user's video recording needs.
[0133] In some embodiments, the stabilization control includes a control body and an identifier located on the control body; the second input includes a first sub-input to the identifier;
[0134] The second display module 502 may include:
[0135] The determining unit is configured to, in response to a user’s first sub-input of the identifier, determine a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input, wherein the first stabilization parameter and the second stabilization parameter are associated with the input parameters of the first sub-input;
[0136] The display unit is used to display the video recording interface.
[0137] In this way, in response to the user's first sub-input on the identifier, the first and second stabilization parameters required by the user can be determined, so that video recording can be performed according to the first and second stabilization parameters. This achieves flexible adjustment of the stabilization effect and maintains image quality during the stabilization process, thus meeting the user's needs.
[0138] In some embodiments, the second input includes a second sub-input, and the video stabilization device 500 may further include:
[0139] The receiving module is used to receive the user's second sub-input to the preview interface;
[0140] The display unit can also be used for:
[0141] In response to the second sub-input, the video recording interface is displayed.
[0142] In this way, users can freely adjust the stabilization parameters based on the stabilization controls until they determine the first and second stabilization parameters that best meet their needs. Then, in response to the user's second sub-input on the preview interface, the video recording interface can be displayed so that video can be recorded according to the first and second stabilization parameters to meet the user's video recording needs.
[0143] In some embodiments, the determining unit may further include:
[0144] The acquisition sub-unit is used to acquire the gyroscope sensor data corresponding to N frames of preview images within the first time period, where N is an integer greater than 1;
[0145] The first determining subunit is used to determine N rotation matrices corresponding to the N preview images based on the gyroscope sensor data corresponding to the N preview images.
[0146] The second determining subunit is used to determine the stabilization strength based on N rotation matrices;
[0147] The third determining subunit is used to determine the first stabilization parameter and the second stabilization parameter based on the stabilization intensity.
[0148] In this way, the gyroscope sensor data of a certain number of preview images can be used to estimate the current level of shaking, determine the required stabilization strength, and obtain more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0149] In some embodiments, the second determining subunit can also be used for:
[0150] Based on the rotation matrices corresponding to two adjacent preview images, the similarity of N-1 rotation matrices is calculated.
[0151] Determine the average similarity based on the similarity of N-1 rotation matrices;
[0152] The stabilization strength is determined based on the average similarity.
[0153] In this way, the average similarity of N preview images can be determined by the similarity of N-1 rotation matrices of two adjacent preview images, thereby calculating the accurate stabilization strength. This allows for more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0154] In some embodiments, the second determining subunit can also be used for:
[0155] The average similarity is obtained by weighting the similarities of the N-1 rotation matrices.
[0156] In this way, the influence of external factors such as time on the shaking can be taken into account. By weighted averaging of the similarity of N-1 rotation matrices, the accuracy of the average similarity can be further guaranteed, thereby obtaining a more accurate stabilization strength and matching a more accurate first and second stabilization parameters, which further guarantees the stabilization effect.
[0157] In some embodiments, the third determining subunit can also be used for:
[0158] Acquire the maximum first image stabilization parameter, the minimum first image stabilization parameter, the maximum second image stabilization parameter, and the minimum second image stabilization parameter of the electronic device;
[0159] The first image stabilization parameter is determined based on the image stabilization strength, the maximum first image stabilization parameter, and the minimum first image stabilization parameter;
[0160] The second image stabilization parameter is determined based on the stabilization strength, the maximum second image stabilization parameter, and the minimum second image stabilization parameter.
[0161] In this way, the first and second stabilization parameters can be calculated by using the stabilization strength and the maximum, minimum, maximum, and minimum first stabilization parameters supported by the electronic device. This ensures the accuracy of the first and second stabilization parameters and their compatibility with the electronic device, further guaranteeing the stabilization effect.
[0162] In some embodiments, the first sub-input is a sliding input, and the first time period is determined based on the input parameters of the first sub-input, which include at least one of the following: sliding distance and input time.
[0163] In this way, the duration of the first time period can be controlled based on the input parameters of the first sub-input, thereby achieving precise control of the stabilization intensity and further increasing the flexibility of video stabilization.
[0164] The video stabilization device in this application embodiment can be an electronic device or a component within an electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal or other devices besides a terminal. For example, the electronic device can be a mobile phone, tablet computer, laptop computer, PDA, in-vehicle electronic device, mobile internet device (MID), augmented reality (AR) / virtual reality (VR) device, robot, wearable device, ultra-mobile personal computer (UMPC), netbook, or personal digital assistant (PDA), etc. It can also be a server, network attached storage (NAS), personal computer (PC), television set (TV), ATM, or self-service machine, etc. This application embodiment does not specifically limit the device.
[0165] The video stabilization device in this application embodiment can be a device with an operating system. This operating system can be Android, iOS, or other possible operating systems; this application embodiment does not specifically limit it.
[0166] The video stabilization device provided in this application embodiment can achieve... Figures 1 to 4 The various processes implemented in the method implementation examples will not be described again here to avoid repetition.
[0167] Optionally, such as Figure 6 As shown, this application embodiment also provides an electronic device 600, including a processor 601 and a memory 602. The memory 602 stores a program or instructions that can run on the processor 601. When the program or instructions are executed by the processor 601, they implement the various steps of the above-described video stabilization method embodiment and can achieve the same technical effect. To avoid repetition, they will not be described again here.
[0168] It should be noted that the electronic devices in the embodiments of this application include the mobile electronic devices and non-mobile electronic devices described above.
[0169] Figure 7 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of this application.
[0170] The electronic device 700 includes, but is not limited to, components such as: radio frequency unit 701, network module 702, audio output unit 703, input unit 704, sensor 705, display unit 706, user input unit 707, interface unit 708, memory 709, and processor 710.
[0171] Those skilled in the art will understand that the electronic device 700 may also include a power supply (such as a battery) for supplying power to various components. The power supply may be logically connected to the processor 710 through a power management system, thereby enabling functions such as managing charging, discharging, and power consumption through the power management system. Figure 7 The electronic device structure shown does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown, or combine certain components, or have different component arrangements, which will not be elaborated here.
[0172] The display unit 706 can be used for:
[0173] In response to the user's first input, a preview interface is displayed, which includes anti-shake controls for adjusting anti-shake parameters.
[0174] In response to a second input from the user to the preview interface, the video recording interface is displayed;
[0175] The processor 710 can be used for:
[0176] At least two frames of images are acquired based on the first image stabilization parameter;
[0177] Based on the second stabilization parameter, at least two frames of images are stabilized to obtain the target video;
[0178] The first and second image stabilization parameters are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first and second image stabilization parameters.
[0179] In this embodiment, a stabilization control for adjusting stabilization parameters can be displayed on the preview interface. Users can input different second values into the stabilization control based on different video shooting scenarios to determine different optical and electronic stabilization parameters. This allows for the coordination of stabilization intensity and image quality through different optical and electronic stabilization parameters, avoiding the limitation of fixed stabilization parameters and achieving flexible adjustment of the stabilization effect while maintaining image quality during stabilization, thus better meeting the user's video recording needs.
[0180] In some embodiments, the stabilization control includes a control body and an identifier located on the control body, and the second input includes a first sub-input to the identifier;
[0181] The processor 710 can also be used for:
[0182] In response to the user's first sub-input on the identifier, a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input are determined, and the first stabilization parameter and the second stabilization parameter are related to the input parameters of the first sub-input;
[0183] The display unit 706 can also be used for:
[0184] The video recording interface is displayed.
[0185] In this way, in response to the user's first sub-input on the identifier, the first and second stabilization parameters required by the user can be determined, so that video recording can be performed according to the first and second stabilization parameters. This achieves flexible adjustment of the stabilization effect and maintains image quality during the stabilization process, thus meeting the user's needs.
[0186] In some embodiments, the second input includes a second sub-input, and the user input unit 707 can be used to: receive the user's second sub-input to the preview interface;
[0187] The display unit can also be used for:
[0188] In response to the second sub-input, the video recording interface is displayed.
[0189] In this way, users can freely adjust the stabilization parameters based on the stabilization controls until they determine the first and second stabilization parameters that best meet their needs. Then, in response to the user's second sub-input on the preview interface, the video recording interface can be displayed so that video can be recorded according to the first and second stabilization parameters to meet the user's video recording needs.
[0190] In some embodiments, the processor 710 can also be used for:
[0191] Obtain the gyroscope sensor data corresponding to N frames of preview images within the first time period, where N is an integer greater than 1;
[0192] Based on the gyroscope sensor data corresponding to the N frames of preview images, determine the N rotation matrices corresponding to the N frames of preview images;
[0193] The stabilization strength is determined based on N rotation matrices;
[0194] Determine the first and second image stabilization parameters based on the image stabilization strength.
[0195] In this way, the gyroscope sensor data of a certain number of preview images can be used to estimate the current level of shaking, determine the required stabilization strength, and obtain more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0196] In some embodiments, the processor 710 can also be used for:
[0197] Based on the rotation matrices corresponding to two adjacent preview images, the similarity of N-1 rotation matrices is calculated.
[0198] Determine the average similarity based on the similarity of N-1 rotation matrices;
[0199] The stabilization strength is determined based on the average similarity.
[0200] In this way, the average similarity of N preview images can be determined by the similarity of N-1 rotation matrices of two adjacent preview images, thereby calculating the accurate stabilization strength. This allows for more accurate first and second stabilization parameters, effectively ensuring the stabilization effect.
[0201] In some embodiments, the processor 710 can also be used for:
[0202] The average similarity is obtained by weighting the similarities of the N-1 rotation matrices.
[0203] In this way, the influence of external factors such as time on the shaking can be taken into account. By weighted averaging of the similarity of N-1 rotation matrices, the accuracy of the average similarity can be further guaranteed, thereby obtaining a more accurate stabilization strength and matching a more accurate first and second stabilization parameters, which further guarantees the stabilization effect.
[0204] In some embodiments, the processor 710 can also be used for:
[0205] Acquire the maximum first image stabilization parameter, the minimum first image stabilization parameter, the maximum second image stabilization parameter, and the minimum second image stabilization parameter of the electronic device;
[0206] The first image stabilization parameter is determined based on the image stabilization strength, the maximum first image stabilization parameter, and the minimum first image stabilization parameter;
[0207] The second image stabilization parameter is determined based on the stabilization strength, the maximum second image stabilization parameter, and the minimum second image stabilization parameter.
[0208] In this way, the first and second stabilization parameters can be calculated by using the stabilization strength and the maximum, minimum, maximum, and minimum first stabilization parameters supported by the electronic device. This ensures the accuracy of the first and second stabilization parameters and their compatibility with the electronic device, further guaranteeing the stabilization effect.
[0209] In some embodiments, the first sub-input is a sliding input, and the first time period is determined based on the input parameters of the first sub-input, which include at least one of the following: sliding distance and input time.
[0210] In this way, the duration of the first time period can be controlled based on the input parameters of the first sub-input, thereby achieving precise control of the stabilization intensity and further increasing the flexibility of video stabilization.
[0211] It should be understood that, in this embodiment, the input unit 704 may include a graphics processing unit (GPU) 7041 and a microphone 7042. The GPU 7041 processes image data of still images or videos obtained by an image capture device (such as a camera) in video capture mode or image capture mode. The display unit 706 may include a display panel 7061, which may be configured in the form of a liquid crystal display, an organic light-emitting diode, or the like. The user input unit 707 includes at least one of a touch panel 7071 and other input devices 7072. The touch panel 7071 is also called a touch screen. The touch panel 7071 may include a touch detection device and a touch controller. Other input devices 7072 may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, and joysticks, which will not be described in detail here.
[0212] The memory 709 can be used to store software programs and various data. The memory 709 may primarily include a first storage area for storing programs or instructions and a second storage area for storing data. The first storage area may store the operating system, application programs or instructions required for at least one function (such as sound playback, image playback, etc.). Furthermore, the memory 709 may include volatile memory or non-volatile memory, or both. The non-volatile memory may be read-only memory (ROM), programmable read-only memory (PROM), erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), or flash memory. Volatile memory can be random access memory (RAM), static random access memory (SRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM), and direct memory bus RAM (DRRAM). The memory 709 in the embodiments of this application includes, but is not limited to, these and any other suitable types of memory.
[0213] Processor 710 may include one or more processing units; optionally, processor 710 integrates an application processor and a modem processor, wherein the application processor mainly handles operations involving the operating system, user interface, and applications, and the modem processor mainly handles wireless communication signals, such as a baseband processor. It is understood that the aforementioned modem processor may also not be integrated into processor 710.
[0214] This application also provides a readable storage medium storing a program or instructions. When the program or instructions are executed by a processor, they implement the various processes of the above-described video stabilization method embodiments and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0215] The processor is the processor in the electronic device described in the above embodiments. The readable storage medium includes computer-readable storage media, such as computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk.
[0216] This application embodiment also provides a chip, which includes a processor and a communication interface. The communication interface is coupled to the processor. The processor is used to run programs or instructions to implement the various processes of the above-described video stabilization method embodiments and achieve the same technical effect. To avoid repetition, it will not be described again here.
[0217] It should be understood that the chip mentioned in the embodiments of this application may also be referred to as a system-on-a-chip, system chip, chip system, or system-on-a-chip, etc.
[0218] This application provides a computer program product, which is stored in a storage medium and executed by at least one processor to implement the various processes of the video stabilization method embodiments described above, and can achieve the same technical effect. To avoid repetition, it will not be described again here.
[0219] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes that element. Furthermore, it should be noted that the scope of the methods and apparatuses in the embodiments of this application is not limited to performing functions in the order shown or discussed, but may also include performing functions substantially simultaneously or in the reverse order, depending on the functions involved. For example, the described methods may be performed in a different order than described, and various steps may be added, omitted, or combined. Additionally, features described with reference to certain examples may be combined in other examples.
[0220] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a computer software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) and includes several instructions to cause a terminal (which may be a mobile phone, computer, server, or network device, etc.) to execute the methods described in the various embodiments of this application.
[0221] The embodiments of this application have been described above with reference to the accompanying drawings. However, this application is not limited to the specific embodiments described above. The specific embodiments described above are merely illustrative and not restrictive. Those skilled in the art can make many other forms under the guidance of this application without departing from the spirit and scope of the claims, and all of these forms are within the protection scope of this application.
Claims
1. A video stabilization method, characterized in that, include: In response to the user's first input, a preview interface is displayed, the preview interface including a stabilization control for adjusting stabilization parameters; In response to a second input from the user to the preview interface, the video recording interface is displayed; At least two frames of images are acquired based on the first image stabilization parameter; Based on the second anti-shake parameter, the at least two frames of images are subjected to anti-shake processing to obtain the target video; The first image stabilization parameter and the second image stabilization parameter are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first image stabilization parameters and second image stabilization parameters. The image stabilization control includes a control body and an identifier located on the control body; the second input includes a first sub-input to the identifier; the step of displaying a video recording interface in response to the user's second input to the preview interface includes: In response to a user’s first sub-input to the identifier, a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input are determined, wherein the first stabilization parameter and the second stabilization parameter are associated with the input parameters of the first sub-input; Displays the video recording interface; The determination of the first stabilization parameter and the second stabilization parameter corresponding to the first sub-input includes: Obtain the gyroscope sensor data corresponding to N frames of preview images within the first time period, where N is an integer greater than 1; Based on the gyroscope sensor data corresponding to the N frames of preview images, determine the N rotation matrices corresponding to the N frames of preview images; The stabilization strength is determined based on the N rotation matrices; Based on the stabilization intensity, the first stabilization parameter and the second stabilization parameter are determined.
2. The method according to claim 1, characterized in that, The second input includes a second sub-input, and before displaying the video recording interface, it further includes: Receive the user's second sub-input to the preview interface; The video recording interface includes: In response to the second sub-input, the video recording interface is displayed.
3. The method according to claim 1, characterized in that, The step of determining the image stabilization strength based on the N rotation matrices includes: Based on the rotation matrix corresponding to two adjacent preview images, the similarity of N-1 rotation matrices is calculated; The average similarity is determined based on the similarity of the N-1 rotation matrices. The stabilization strength is determined based on the average similarity.
4. The method according to claim 3, characterized in that, The step of determining the average similarity based on the similarity of the N-1 rotation matrices includes: The average similarity is obtained by weighting the similarities of the N-1 rotation matrices.
5. The method according to claim 1, characterized in that, The step of determining the first stabilization parameter and the second stabilization parameter based on the stabilization intensity includes: Acquire the maximum first image stabilization parameter, the minimum first image stabilization parameter, the maximum second image stabilization parameter, and the minimum second image stabilization parameter of the electronic device; The first stabilization parameter is determined based on the stabilization intensity, the maximum first stabilization parameter, and the minimum first stabilization parameter; The second image stabilization parameter is determined based on the image stabilization intensity, the maximum second image stabilization parameter, and the minimum second image stabilization parameter.
6. The method according to claim 1, characterized in that, The first sub-input is a sliding input, and the first time period is determined based on the input parameters of the first sub-input, which include at least one of the following: sliding distance and input time.
7. A video stabilization device, characterized in that, include: The first display module is used to display a preview interface in response to the user's first input. The preview interface includes a stabilization control, which is used to adjust the stabilization parameters. The second display module is used to display the video recording interface in response to a second input from the user to the preview interface; The acquisition module is used to acquire at least two frames of images based on the first image stabilization parameter; The processing module is used to perform image stabilization processing on the at least two frames of images based on the second image stabilization parameter to obtain the target video; The first image stabilization parameter and the second image stabilization parameter are determined based on the image stabilization control. The first image stabilization parameter indicates the optical image stabilization parameter, and the second image stabilization parameter indicates the electronic image stabilization parameter. Different second inputs correspond to different first image stabilization parameters and second image stabilization parameters. The image stabilization control includes a control body and an identifier located on the control body; the second input includes a first sub-input to the identifier; the second display module includes: The determining unit is configured to, in response to a user’s first sub-input to the identifier, determine a first stabilization parameter and a second stabilization parameter corresponding to the first sub-input, wherein the first stabilization parameter and the second stabilization parameter are associated with the input parameters of the first sub-input; The display unit is used to display the video recording interface; The determining unit is further configured to: Obtain the gyroscope sensor data corresponding to N frames of preview images within the first time period, where N is an integer greater than 1; Based on the gyroscope sensor data corresponding to the N frames of preview images, determine the N rotation matrices corresponding to the N frames of preview images; The stabilization strength is determined based on the N rotation matrices; Based on the stabilization intensity, the first stabilization parameter and the second stabilization parameter are determined.
Citation Information
Patent Citations
Video anti-shake method and device for electronic equipment and electronic equipment
CN110049246A
Camera anti-shake prompting method and device and electronic equipment
CN112689094A
Video shooting method and device and electronic equipment
CN112738405A