Data stream configuration method and device, electronic equipment and medium

By dynamically configuring the data flow of the camera, based on the shooting mode and magnification information, the problems of resource waste and power consumption in the prior art are solved, and the smoothness and efficiency of user zoom and photography are achieved.

CN119485011APending Publication Date: 2025-02-18VIVO MOBILE COMM CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202411632920.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-11-14
Publication Date
2025-02-18

AI Technical Summary

Technical Problem

In electronic devices, the prior art configures multiple data streams for the camera when shooting each frame of the image, resulting in waste of resources and increased power consumption, making it difficult to maintain the smoothness and photo response speed of the user when previewing the image to zoom.

Method used

By obtaining shooting mode information and magnification information, dynamically configure the camera's data flow, determine the configuration of preview stream, photography stream and SAT algorithm stream according to the shooting mode and camera type, and only configure the navigation box stream when necessary to reduce unnecessary data flow Configuration.

Benefits of technology

It realizes the maintenance of user zoom and photo fluency while reducing power consumption and improving the shooting efficiency and resource utilization of electronic devices.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN119485011A_ABST
    Figure CN119485011A_ABST
Patent Text Reader

Abstract

The invention discloses a data stream configuration method and device, electronic equipment and a medium, and belongs to the technical field of electronic equipment. The method comprises the following steps: acquiring shooting mode information and first magnification information, wherein the shooting mode information comprises a preview non-zooming mode, a preview zooming mode and a photographing mode; according to the first multiplying power information, the types of N cameras used for shooting are determined, and N is a positive integer and is larger than or equal to 2; according to the first magnification information and the types of the N cameras, determining the configuration of navigation frame streams of the N cameras; and according to the shooting mode information and / or the types of the N cameras, determining configuration of preview streams, shooting streams and space alignment transformation SAT algorithm streams of the N cameras.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application belongs to the technical field of electronic equipment, and specifically relates to a data stream configuration method, device, electronic equipment and medium. Background Art

[0002] Currently, multiple cameras are configured in electronic devices in order to maintain the smoothness of switching cameras when the user zooms in on a preview image and the response speed when the user takes a photo.

[0003] When displaying a preview image and capturing a preview image in an electronic device, the electronic device will cache each frame of the preview image and the image captured of the preview image. When caching each frame of the image, the electronic device will configure multiple data streams for the camera. These data streams usually include the following four types: preview stream, photo stream, spatial alignment transformation (Spatial alignment transformation, SAT) algorithm stream and navigation frame stream. However, depending on the shooting scene, these four data streams are not required for capturing each frame of the image. If the above four data streams are configured for each frame, it will cause a waste of power resources. Summary of the invention

[0004] The purpose of the embodiments of the present application is to provide a data stream configuration method, device, electronic device and medium to dynamically configure the data stream for the camera according to the shooting scene, thereby reducing power consumption while maintaining the smoothness of switching cameras when the user zooms the preview image and the response speed when the user takes pictures.

[0005] In a first aspect, an embodiment of the present application provides a data flow configuration method, the method comprising:

[0006] Acquire shooting mode information and first magnification information, wherein the shooting mode information includes a preview zoom mode, a preview zoom mode, and a photo mode;

[0007] Determine the types of N cameras used for shooting according to the first magnification information, where N is a positive integer and N≥2;

[0008] Determining configurations of navigation frame streams of the N cameras according to the first magnification information and types of the N cameras;

[0009] According to the shooting mode information and / or the types of the N cameras, the configurations of the preview streams, the photo streams and the spatial alignment transform SAT algorithm streams of the N cameras are determined.

[0010] In a second aspect, an embodiment of the present application provides a data flow configuration device, the device comprising:

[0011] A first acquisition module, used to acquire shooting mode information and first magnification information, wherein the shooting mode information includes a preview zoom mode, a preview zoom mode, and a photo mode;

[0012] A first determining module, configured to determine the types of N cameras used for shooting according to the first magnification information, where N is a positive integer and N≥2;

[0013] A second determining module, configured to determine configurations of navigation frame streams of the N cameras according to the first magnification information and types of the N cameras;

[0014] The third determination module is used to determine the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of the N cameras according to the shooting mode information and / or the types of the N cameras.

[0015] In a third aspect, an embodiment of the present application provides a readable storage medium, on which a program or instruction is stored, and when the program or instruction is executed by a processor, the steps of the method described in the first aspect are implemented.

[0016] In a fourth aspect, an embodiment of the present application provides a chip, comprising a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run a program or instruction to implement the method described in the first aspect.

[0017] In a fifth aspect, an embodiment of the present application provides a computer program product, which is stored in a storage medium and is executed by at least one processor to implement the method described in the first aspect.

[0018] In an embodiment of the present application, when shooting a shooting scene, the types of N cameras can be determined according to the first magnification information used when shooting the shooting scene, and then the configuration of the navigation frame stream of the N cameras can be determined according to the types of the N cameras and the first magnification information, and the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of the N cameras can be determined according to the shooting mode information when shooting the shooting scene and the types of the N cameras. Compared with the prior art that configures all data streams for each frame image when shooting the shooting scene, the solution of the embodiment of the present application is to dynamically configure the data stream for each frame image according to the shooting mode information and the first magnification information of the shooting scene. This reduces power consumption while maintaining the smoothness of switching cameras when the user zooms the preview image and the response speed of the user when taking pictures. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 It is a framework diagram of a data stream configuration system provided by the prior art;

[0020] Figure 2 is a flowchart of a data flow configuration method provided by some embodiments of the present application;

[0021] Figure 3 is a framework diagram of a data stream configuration system provided by some embodiments of the present application;

[0022] Figure 4 is a flowchart of a data flow configuration method provided by some embodiments of the present application;

[0023] Figure 5 is a structural schematic diagram of a data stream configuration device shown in some embodiments of the present application;

[0024] Figure 6 is a schematic diagram of the structure of an electronic device shown in some embodiments of the present application;

[0025] Figure 7 It is a schematic diagram of the hardware structure of an electronic device shown in some embodiments of the present application. DETAILED DESCRIPTION

[0026] The following will be combined with the drawings in the embodiments of the present application to clearly describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. All other embodiments obtained by ordinary technicians in this field based on the embodiments in the present application belong to the scope of protection of this application.

[0027] The terms "first", "second", etc. in the specification and claims of this application are used to distinguish similar objects, and are not used to describe a specific order or sequence. It should be understood that the data used in this way can be interchangeable under appropriate circumstances, so that the embodiments of the present application can be implemented in an order other than those illustrated or described here, and the objects distinguished by "first", "second", etc. are generally of one type, and the number of objects is not limited. For example, the first object can be one or N. In addition, "and / or" in the specification and claims represents at least one of the connected objects, and the character " / " generally indicates that the objects associated with each other are in an "or" relationship.

[0028] Before introducing the solution of the embodiment of the present application, the background technology of the embodiment of the present application is first introduced:

[0029] refer to Figure 1Taking the electronic device having two cameras as an example, when the electronic device is used to shoot a shooting scene (whether it is previewing the shooting scene or taking a picture of the preview image of the shooting scene), each camera of the electronic device collects information of the shooting scene (i.e., raw data), and then inputs the collected information into the corresponding image processing module. The image processing module processes the collected information and outputs the preview stream, the photo stream, the SAT algorithm stream, and the navigation frame stream to the display decision module. The display decision module decides the preview stream, the photo stream, the SAT algorithm stream, and the navigation frame stream to be used to the display module. The display module processes the received preview stream, the photo stream, the SAT algorithm stream, and the navigation frame stream to display the picture of the shooting scene.

[0030] It should be noted that in Figure 1 In the figure, the data stream indicated by the solid line is the necessary data stream during the shooting process, and the data stream indicated by the dotted line is the optional data stream during the shooting process.

[0031] As described above, when an electronic device is used to shoot a shooting scene (whether it is previewing the shooting scene or shooting a preview image of the shooting scene), each frame of the image needs to be configured with all data streams for each camera of the electronic device, which will cause a waste of power consumption resources. In order to solve the above problem, the embodiments of the present application provide a data stream configuration method, device, electronic device and medium. When shooting the shooting scene, the types of N cameras can be determined according to the first magnification information used when shooting the shooting scene, and then the configuration of the navigation frame streams of the N cameras can be determined according to the types of the N cameras and the first magnification information, and the configuration of the preview streams, the shooting streams and the spatial alignment transformation SAT algorithm streams of the N cameras can be determined according to the shooting mode information when shooting the shooting scene and the types of the N cameras. Compared with the prior art in which all data streams are configured for each frame of the image when shooting the shooting scene, the solution of the embodiments of the present application is to dynamically configure the data stream for each frame of the image according to the shooting mode information and the first magnification information of the shooting scene, so that the fluency of the user switching the camera when zooming the preview image and the response speed of the user when taking pictures are maintained, while reducing the power consumption waste.

[0032] The technical solution of the embodiment of the present application can be applied to the scene of photographing a shooting scene.

[0033] Before introducing the solutions of the embodiments of the present application, the professional terms involved in the embodiments of the present application are first introduced:

[0034] Preview stream: It is the data used to display frames on the display module. It must be configured for each frame of the image during the shooting process.

[0035] Photo stream: is the data stream that needs to be retained in the album after the user clicks the photo control in the camera application. In order to give the user a faster photo response experience, when the camera application is in the preview image of the shooting scene (that is, the photo control in the camera application is not clicked), the electronic device will cache the latest frame data of the camera, which is not required for every frame in the preview scene.

[0036] SAT algorithm stream: It is a data stream used to align the images of two cameras. It is required for each frame when the user zooms the preview image.

[0037] Navigation frame stream: The data stream is needed only when the navigation frame appears after the user zooms the preview image to a certain high magnification. It is not required for every frame in the preview scene.

[0038] The data stream configuration method provided in the embodiment of the present application is described in detail below through specific embodiments and their application scenarios in conjunction with the accompanying drawings.

[0039] Figure 2 It is a flow chart of a data flow configuration method provided in an embodiment of the present application. The executor of the data flow configuration method may be an electronic device, which may be but is not limited to a personal computer (PC), a smart phone, a tablet computer or a personal digital assistant (PDA).

[0040] like Figure 2 As shown, the data flow configuration method provided in the embodiment of the present application may include steps 210 to 240.

[0041] Step 210: Acquire shooting mode information and first magnification information.

[0042] The shooting mode information may be the shooting mode of the camera application when shooting a shooting scene. The shooting scene here may be a scene to be shot, such as a building, a person, a plant, etc. The specific shooting mode information may include a preview non-zoom mode, a preview zoom mode, and a photo mode.

[0043] The above-mentioned preview non-zoom mode may refer to that the camera application is in the preview image scene of the shooting scene, and the preview image of the shooting scene is not zoomed.

[0044] The preview zoom mode mentioned above may refer to that the camera application is in the preview image scene of the shooting scene and zooms the preview image of the shooting scene.

[0045] It should be noted that the camera application being in the preview image scene of the shooting scene may mean that the user has not clicked the photo control in the camera application, and the camera application is currently in the scene of displaying the preview image of the shooting scene.

[0046] The above-mentioned photographing mode may refer to a scenario in which a user takes a photo of a preview image of a shooting scene after clicking a photographing control in a camera application.

[0047] The first magnification information may be magnification information used when photographing a photographing scene.

[0048] Step 220: Determine the types of the N cameras used for shooting according to the first magnification information.

[0049] Wherein, N is a positive integer, and N≥2.

[0050] In some embodiments of the present application, the magnification information of each camera in the N cameras is different, and the types of the N cameras may include a main camera and a sub-camera, where there is only one main camera and there may be multiple sub-cameras.

[0051] In some embodiments of the present application, in order to accurately determine the main camera and the secondary camera, step 220 may specifically include:

[0052] Calculate the difference between the first magnification information and the magnification information of the N cameras to obtain the first magnification difference values ​​corresponding to the N cameras respectively;

[0053] The camera corresponding to the smallest positive real number in the first magnification differences corresponding to the N cameras is determined as the main camera, and the other cameras among the N cameras except the main camera are determined as auxiliary cameras.

[0054] Among them, for each camera among the N cameras, the corresponding first magnification difference may be the difference between the first magnification information and the first magnification information.

[0055] In some embodiments of the present application, by calculating the difference between the first magnification information and the magnification information of N cameras, the first magnification difference values ​​corresponding to the N cameras are obtained, and then the camera corresponding to the smallest positive real number in the first magnification difference values ​​corresponding to the N cameras can be determined as the main camera, and the other cameras among the N cameras except the main camera can be determined as secondary cameras.

[0056] In an example, the electronic device has three cameras, namely camera 1, camera 2 and camera 3, wherein the magnification information of camera 1 is 0.6X, the magnification information of camera 2 is 1X, and the magnification information of camera 3 is 3X. If the first magnification information is 1.5X, the difference between the first magnification information and the magnification information of camera 1, the magnification information of camera 2 and the magnification information of camera 3 is calculated respectively, that is, D1=1.5X-0.6X=0.9X, D2=1.5X-1X=0.5X, D3=1.5X-3X=-1.5X, and the smallest positive real number among D1, D2 and D3 is D2=0.5X. Therefore, camera 2 corresponding to D2=0.5X can be used as the main camera, and camera 1 and camera 3 can be used as auxiliary cameras.

[0057] In an embodiment of the present application, by calculating the difference between the first magnification information and the magnification information of N cameras, the first magnification difference values ​​corresponding to the N cameras are obtained, and then the camera corresponding to the smallest positive real number in the first magnification difference values ​​corresponding to the N cameras can be determined as the main camera, and the other cameras among the N cameras except the main camera can be determined as secondary cameras. In this way, the main camera and the secondary camera can be accurately determined.

[0058] Step 230: Determine the configuration of the navigation frame streams of the N cameras according to the first magnification information and the types of the N cameras.

[0059] In some embodiments of the present application, since the navigation frame stream is a data stream that needs to be configured only after the shooting magnification reaches a certain level and the navigation frame appears, when configuring the data stream, the navigation frame stream can be configured first. Specifically, the configuration of the navigation frame streams of N cameras can be determined based on the first magnification information and the types of N cameras.

[0060] In some embodiments of the present application, in order to reduce power consumption, step 230 may specifically include:

[0061] When it is determined that the camera used to preview the shooting scene according to the first magnification information is the main camera, and the first magnification information is less than the first threshold, the navigation frame stream is not configured for the main camera;

[0062] When it is determined that the camera used to preview the shooting scene according to the first magnification information is the main camera, and the first magnification information is greater than or equal to the first threshold, configuring a navigation frame stream for the main camera;

[0063] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, and the first magnification information is less than a first threshold, the navigation frame stream is not configured for the secondary camera;

[0064] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera and the first magnification information is greater than or equal to the first threshold, the navigation frame stream is not configured for the main camera.

[0065] Among them, the first threshold can be a pre-set threshold of the first magnification information, and the first threshold can be the threshold at which the first magnification information reaches a value at which the navigation box can appear. For example, the first threshold can be 20X. The specific value of the first threshold can be determined based on user needs and the magnification required for the navigation box to appear, and is not limited in the embodiments of the present application.

[0066] In some embodiments of the present application, when it is determined that the camera used when previewing the shooting scene according to the first magnification information is the main camera, and the first magnification information is less than a first threshold, the navigation frame stream is not configured for the main camera; when the camera used when previewing the shooting scene according to the first magnification information is the main camera, and the first magnification information is greater than or equal to the first threshold, the navigation frame stream is configured for the main camera; when it is determined that the camera used when previewing the shooting scene according to the first magnification information is the secondary camera, and the first magnification information is less than the first threshold, the navigation frame stream is not configured for the secondary camera; when it is determined that the camera used when previewing the shooting scene according to the first magnification information is the secondary camera, and the first magnification information is greater than or equal to the first threshold, the navigation frame stream is not configured for the main camera.

[0067] In some embodiments of the present application, compared to the prior art in which a navigation frame stream is configured for each frame of an image when shooting a shooting scene, the embodiments of the present application dynamically configure a navigation frame stream for the camera used when previewing the shooting scene according to the first magnification information, based on whether the first magnification information reaches a first threshold for the appearance of a navigation frame and the type of camera used when previewing the shooting scene according to the first magnification information. This reduces power consumption while maintaining the smoothness of switching cameras when the user zooms the preview image and the response speed of the user when taking pictures.

[0068] Step 240: Determine the configuration of the preview streams, the photo streams, and the spatial alignment transform SAT algorithm streams of the N cameras according to the shooting mode information and / or the types of the N cameras.

[0069] In some embodiments of the present application, after the configuration of the navigation frame stream is determined, the configuration of the N camera preview streams, photo streams and spatial alignment transform SAT algorithm streams can be determined according to the shooting mode information and / or the types of the N cameras.

[0070] In some embodiments of the present application, in order to accurately determine the configuration of the preview stream, the photo stream, and the SAT algorithm stream, step 240 may specifically include:

[0071] When it is determined that the camera used for previewing the shooting scene according to the first magnification information is the main camera, a preview stream, a photo stream, and a SAT algorithm stream are configured for the main camera;

[0072] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, the configuration of each secondary camera's preview stream, photo stream and spatial alignment transform SAT algorithm stream is determined according to the shooting mode information.

[0073] In some embodiments of the present application, when it is determined that the camera used when previewing the shooting scene according to the first magnification information is a main camera, the preview stream, the photo stream and the SAT algorithm stream are configured for the main camera; when it is determined that the camera used when previewing the shooting scene according to the first magnification information is a secondary camera, the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of each secondary camera can be determined according to the shooting mode information.

[0074] In an embodiment of the present application, the configurations of the preview stream, photo stream and SAT algorithm stream of N cameras are dynamically determined according to the shooting mode information and / or the types of the N cameras, so that the configurations of the preview stream, photo stream and SAT algorithm stream can be accurately determined.

[0075] In some embodiments of the present application, when the shooting mode information includes a preview non-zoom mode, in order to accurately determine the data stream configured by the secondary camera, the configuration of the preview stream, the photo stream, and the SAT algorithm stream of each secondary camera may be determined according to the shooting mode information, and specifically may include:

[0076] Select a secondary camera whose magnification is closest to the first magnification information from each secondary camera to obtain a target secondary camera;

[0077] When it is determined that the first magnification difference corresponding to the target secondary camera is less than the second threshold, a preview stream and a SAT algorithm stream are configured for the target secondary camera, and preview streams and SAT algorithm streams are not configured for other secondary cameras except the target secondary camera.

[0078] The target secondary camera may be a secondary camera selected from the secondary cameras and having a magnification closest to the first magnification information.

[0079] Continuing to refer to the above example, camera 2 is the main camera, camera 1 and camera 3 are secondary cameras, and the camera closest to the first magnification information 1.5X between camera 1 and camera 3 is camera 1, so camera 1 is the target secondary camera.

[0080] The second threshold may be a pre-set threshold of the first magnification difference corresponding to the target secondary camera. The second threshold may be, for example, 1. The specific value of the second threshold may be selected according to user needs and is not limited in the embodiment of the present application.

[0081] It should be noted that the camera application is in the preview image scene of the shooting scene, and the preview image of the shooting scene is not zoomed in the preview image scene, that is, the current camera application is in the preview image scene of the shooting scene, and in the process of displaying the preview image of the shooting scene, the user has not zoomed the preview image, for example, when displaying the preview image, the user has not changed the shooting magnification information.

[0082] In some embodiments of the present application, when it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, a preview stream and a SAT algorithm stream are configured for the target sub-camera, and preview streams and SAT algorithm streams are not configured for other sub-cameras except the target sub-camera.

[0083] Continuing to refer to the above example, taking the second threshold value of 1 as an example, camera 1 is the target secondary camera, and the first magnification difference D1 corresponding to camera 1 is D1=0.9X, D1<1, then the preview stream and SAT algorithm stream are configured for camera 1, and the preview stream and SAT algorithm stream are not configured for camera 3.

[0084] In some embodiments of the present application, when it is determined that the first magnification difference corresponding to the target secondary camera is greater than or equal to the second threshold, no preview stream and no SAT algorithm stream are configured for each secondary camera.

[0085] Continuing to refer to the above example, taking the second threshold value of 0.5 as an example, camera 1 is the target secondary camera, and the first magnification difference corresponding to camera 1 is D1=0.9X, D1>0.5, then camera 1 and camera 3 are not configured with preview stream and SAT algorithm stream.

[0086] In an embodiment of the present application, a target sub-camera is obtained by selecting a sub-camera whose magnification is closest to the first magnification information from each sub-camera. When it is determined that the first magnification difference corresponding to the target sub-camera is less than a second threshold, a preview stream and a SAT algorithm stream are configured for the target sub-camera, and preview streams and SAT algorithm streams are not configured for other sub-cameras except the target sub-camera. In this way, the data stream configured for the sub-camera can be accurately determined.

[0087] In some embodiments of the present application, when the shooting mode information includes a preview zoom mode, determining the configuration of the preview stream, the photo stream, and the SAT algorithm stream of each secondary camera according to the shooting mode information may specifically include:

[0088] Determining a magnification change speed when previewing the shooting scene according to the first magnification information, the second magnification information, and a preview frame rate of a preview image of the shooting scene;

[0089] When it is determined that the change speed is greater than the first speed threshold, a preview stream and a SAT algorithm stream are configured for each secondary camera;

[0090] When it is determined that the change speed is less than or equal to the first speed threshold, the sub-camera whose magnification is closest to the first magnification information is selected from each sub-camera to obtain the target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras except the target sub-camera.

[0091] The second magnification information may be magnification information collected before the shooting scene is shot using the first magnification information, that is, the second magnification information is the magnification information before the shooting magnification of the preview image is zoomed to the first magnification information. That is to say, when the camera application is in the preview image scene of the shooting scene, the preview image of the shooting scene is zoomed from the second magnification information to the first magnification information.

[0092] For example, when displaying a preview image of a shooting scene in a camera application, the user initially captures the preview image of the shooting scene at a magnification of 1X, and then the user changes the magnification information from 1X to 1.5X in the preview image interface. In this case, 1X is the second magnification information and 1.5X is the first magnification information.

[0093] The first speed threshold may be a pre-set threshold for the speed of change of the magnification when previewing the shooting scene. The value of the first speed threshold may be selected according to user needs and is not limited in the embodiments of the present application.

[0094] In some embodiments of the present application, the magnification change speed when previewing the shooting scene can be determined according to the first magnification information, the second magnification information and the preview frame rate of the preview image of the shooting scene. Specifically, the magnification change speed when previewing the shooting scene can be determined according to the following formula (1):

[0095] V= | N1X-N2X | ·F (1)

[0096] Wherein, N1X is the first magnification information, N2X is the second magnification information, and F is the preview frame rate of the preview image of the shooting scene.

[0097] If the changing speed is greater than the first speed threshold, a preview stream and a SAT algorithm stream may be configured for each sub-camera; if the changing speed is less than or equal to the first speed threshold, the focal length difference of each sub-camera is further calculated, and the preview stream and the SAT algorithm stream are configured in accordance with the configuration method in which the preview image of the shooting scene is not zoomed in the preview image scene, that is, when the changing speed is less than or equal to the first speed threshold, a sub-camera whose magnification is closest to the first magnification information is selected from each sub-camera to obtain a target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, a preview stream and a SAT algorithm stream are configured for the target sub-camera, and preview streams and SAT algorithm streams are not configured for other sub-cameras except the target sub-camera among the sub-cameras.

[0098] Continuing to refer to the above example, taking the first speed threshold as 20, the second magnification information as 1X, and the preview frame rate of the preview image of the shooting scene as 45fps, calculate the magnification change speed V when previewing the shooting scene = |1-1.5|·45 = 22.5, 22.5>20, then both camera 1 and camera 3 are configured with preview stream and SAT algorithm stream.

[0099] Continuing to refer to the above example, taking the first speed threshold as 25, the second magnification information as 1X, the preview frame rate of the preview image of the shooting scene as 45fps, and the second threshold as 1 as an example, calculate the magnification change speed V = |1-1.5|·45 = 22.5 when previewing the shooting scene, 22.5 < 25, then select camera 1 from camera 1 and camera 3 as the target secondary camera, and the first magnification difference D1 = 0.9X corresponding to camera 1, D1 < 1, then configure the preview stream and SAT algorithm stream for camera 1, and do not configure the preview stream and SAT algorithm stream for camera 3.

[0100] Continuing to refer to the above example, taking the first speed threshold as 25, the second magnification information as 1X, the preview frame rate of the preview image of the shooting scene as 45fps, and the second threshold as 0.5 as an example, calculate the magnification change speed V = |1-1.5|·45 = 22.5 when previewing the shooting scene. 22.5 < 25, then camera 1 is selected from camera 1 and camera 3 as the target secondary camera, and the first magnification difference D1 corresponding to camera 1 is D1 = 0.9X. D1 > 0.5, then neither camera 1 nor camera 3 is configured with preview stream and SAT algorithm stream.

[0101] In an embodiment of the present application, when the shooting mode information includes a preview zoom mode, the magnification change speed when previewing the shooting scene is determined based on the first magnification information, the second magnification information and the preview frame rate of the preview image of the shooting scene, and the preview stream and SAT algorithm stream are dynamically configured for each sub-camera based on the comparison between the change speed and the first speed threshold, so that the configuration of the preview stream and SAT algorithm stream of each sub-camera can be accurately determined.

[0102] In some embodiments of the present application, when the shooting mode information includes a photo mode, determining the configuration of each secondary camera preview stream, photo stream, and SAT algorithm stream according to the shooting mode information may specifically include:

[0103] The photo stream, preview stream, and SAT algorithm stream are not configured for each secondary camera.

[0104] In some embodiments of the present application, when the camera application is in photo mode, the photo stream, preview stream and SAT algorithm stream may not be configured for each secondary camera, and only the photo stream, preview stream and SAT algorithm stream may be configured for the main camera.

[0105] In an embodiment of the present application, when the camera application is in the photo mode, the photo stream, preview stream and SAT algorithm stream are not configured for each secondary camera, so as to avoid power consumption.

[0106] In some embodiments of the present application, the above steps 210 to 240 may be applied to an outflow control module in an electronic device, that is, in the embodiment of the present application, it may be in the existing Figure 1 An outbound flow control module is added to the illustrated architecture, and decisions on the configuration of the data flow are made based on the outbound flow control module.

[0107] refer to Figure 3 , Figure 3 A framework diagram of a data flow configuration system for implementing the data flow configuration method of an embodiment of the present application is shown in FIG. Figure 3 As shown, the data stream configuration system may include multiple cameras, an outflow control module, an image processing module, a display decision module and a display module.

[0108] It should be noted that in Figure 3 In the process, the camera, image processing module, display decision module and display module have the same functions as Figure 1 The functions of the camera, image processing module, display decision module and display module in the framework diagram are the same and will not be repeated here.

[0109] exist Figure 3 In the example, the outbound flow control module is used to implement the data flow configuration method shown in steps 210 to 240 in the above embodiment.

[0110] It should be noted that in Figure 3 In the figure, the data stream indicated by the solid line is the necessary data stream during the shooting process, and the data stream indicated by the dotted line is the optional data stream during the shooting process.

[0111] In some embodiments of the present application, in order to facilitate a better understanding of the data flow configuration method provided in the embodiments of the present application, the data flow configuration method provided in the embodiments of the present application is described in detail with specific examples below. Figure 4 As shown, the data flow configuration method provided in the embodiment of the present application includes steps 401 to 412.

[0112] Step 401: Acquire shooting mode information and first magnification information.

[0113] This step 401 is consistent with the above-mentioned step 210 and will not be described again here.

[0114] Step 402 , determining whether the camera used to preview the shooting scene according to the first magnification information is the main camera, if so, executing step 403 , if not, executing step 404 .

[0115] Before step 402, the types of the N cameras need to be determined first. The specific determination method can refer to the above embodiment and will not be described again here.

[0116] Step 403: Configure everything except the navigation frame flow.

[0117] In step 403, when it is determined that the camera used to preview the shooting scene according to the first magnification information is the main camera, a preview stream, a photo stream and a SAT algorithm stream are configured for the main camera.

[0118] Step 404: Determine the configuration of the navigation frame flow.

[0119] Step 405 , determine whether the first magnification information is greater than a first threshold, if not, execute step 406 , if yes, execute step 407 .

[0120] Step 406: Neither the main camera nor the secondary camera is configured with a navigation frame stream.

[0121] Step 407 , determine whether it is the main camera, if so, execute step 408 , if not, execute step 409 .

[0122] In step 407 , it may be determined whether the camera used to preview the shooting scene according to the first magnification information is a main camera. If so, step 408 is executed; if not, step 409 is executed.

[0123] Step 408: Configure the navigation frame flow.

[0124] Step 409: Do not configure the navigation frame flow.

[0125] Step 410: Preview the non-zoom scene.

[0126] In step 410, in the preview non-zoom scenario, determine whether the first magnification difference between the target sub-camera in each sub-camera and the first magnification information is less than a second threshold value. If so, a preview stream and a SAT algorithm stream are configured for the target sub-camera, and preview streams and SAT algorithm streams are not configured for other sub-cameras except the target sub-camera. If not, no preview stream and SAT algorithm stream are configured for each sub-camera.

[0127] In this step 410, before determining whether the first magnification difference between the target sub-camera among each sub-camera and the first magnification information is less than the second threshold, it is necessary to first select the target sub-camera from each sub-camera. The specific selection method can be referred to the above embodiment and will not be repeated here.

[0128] Step 411: Preview the zoom scene.

[0129] In step 410, in the preview zoom scenario, the zoom speed is first calculated to determine whether the zoom speed is greater than a first speed threshold. If so, a preview stream and a SAT algorithm stream are configured for each sub-camera. If not, it is determined whether a first magnification difference between a target sub-camera in each sub-camera and the first magnification information is less than a second threshold. If so, a preview stream and a SAT algorithm stream are configured for the target sub-camera, and preview streams and SAT algorithm streams are not configured for other sub-cameras except the target sub-camera. If not, no preview stream and SAT algorithm stream are configured for each sub-camera.

[0130] In step 410, when calculating the zoom speed, reference may be made to the method for calculating the zoom speed in the above embodiment, which will not be described in detail herein.

[0131] Step 412: Photographing the scene.

[0132] In step 412, in the photo scene, all secondary cameras are not configured with a photo stream, a preview stream, and a SAT algorithm stream.

[0133] The data flow configuration method provided in the embodiment of the present application can be executed by a data flow configuration device. In the embodiment of the present application, the data flow configuration device provided in the embodiment of the present application is described by taking the data flow configuration device executing the data flow configuration method as an example.

[0134] Figure 5 FIG. 1 is a schematic diagram showing a structure of a data stream configuration device according to an exemplary embodiment. Figure 5 As shown, the data flow configuration device 500 may include:

[0135] A first acquisition module 510 is used to acquire shooting mode information and first magnification information, wherein the shooting mode information includes a preview zoom mode, a preview zoom mode, and a photo mode;

[0136] A first determination module 520 is used to determine the types of N cameras used for shooting according to the first magnification information, where N is a positive integer and N≥2;

[0137] A second determining module 530, configured to determine configurations of navigation frame streams of the N cameras according to the first magnification information and types of the N cameras;

[0138] The third determination module 540 is used to determine the configuration of the preview stream, the photo stream and the spatial alignment transform SAT algorithm stream of the N cameras according to the shooting mode information and / or the types of the N cameras.

[0139] In an embodiment of the present application, when shooting a shooting scene, the types of N cameras can be determined according to the first magnification information used when shooting the shooting scene, and then the configuration of the navigation frame stream of the N cameras can be determined according to the types of the N cameras and the first magnification information, as well as the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of the N cameras can be determined according to the shooting mode information of the camera application when shooting the shooting scene and the types of the N cameras. Compared with the prior art that configures all data streams for each frame image when shooting the shooting scene, the solution of the embodiment of the present application is to dynamically configure the data stream for each frame image according to the shooting mode information and the first magnification information of the shooting scene. In this way, while maintaining the smoothness of switching cameras when the user zooms the preview image and the response speed of the user when taking pictures, power consumption is reduced.

[0140] In some embodiments of the present application, the magnification information of each camera in the N cameras is different, and the types of the N cameras include a main camera and a secondary camera; the first determination module 520 is specifically used to:

[0141] Calculate the difference between the first magnification information and the magnification information of the N cameras to obtain the first magnification difference values ​​corresponding to the N cameras respectively;

[0142] The camera corresponding to the smallest positive real number in the first magnification differences corresponding to the N cameras is determined as the main camera, and the other cameras among the N cameras except the main camera are determined as secondary cameras.

[0143] In some embodiments of the present application, the second determination module 530 is specifically used to:

[0144] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a main camera, and the first magnification information is less than a first threshold, not configuring a navigation frame stream for the main camera;

[0145] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a main camera, and the first magnification information is greater than or equal to the first threshold, configuring a navigation frame stream for the main camera;

[0146] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, and the first magnification information is less than the first threshold, not configuring a navigation frame stream for the secondary camera;

[0147] When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, and the first magnification information is greater than or equal to the first threshold, a navigation frame stream is not configured for the main camera.

[0148] In some embodiments of the present application, the third determination module 540 may include:

[0149] A first determining unit is configured to configure the preview stream, the photo stream, and the SAT algorithm stream for the main camera when determining that the camera used to preview the shooting scene according to the first magnification information is the main camera;

[0150] The second determination unit is used to determine the configuration of the preview stream, photo stream and SAT algorithm stream of each of the secondary cameras according to the shooting mode information when it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera.

[0151] In some embodiments of the present application, when the shooting mode information includes a preview-unchanged zoom mode, the second determining unit is specifically configured to:

[0152] Selecting a secondary camera whose magnification is closest to the first magnification information from the secondary cameras to obtain a target secondary camera;

[0153] When it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

[0154] In some embodiments of the present application, when the shooting mode information includes a preview zoom mode, the second determining unit screenshot is used to:

[0155] determining a magnification change speed when previewing the shooting scene according to the first magnification information, the second magnification information and a preview frame rate of a preview image of the shooting scene, wherein the second magnification information is magnification information before the shooting magnification of the preview image is zoomed to the first magnification information;

[0156] When it is determined that the change speed is greater than a first speed threshold, configuring the preview stream and the SAT algorithm stream for each of the secondary cameras;

[0157] When it is determined that the change speed is less than or equal to the first speed threshold, a sub-camera whose magnification is closest to the first magnification information is selected from each of the sub-cameras to obtain a target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than a second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

[0158] In some embodiments of the present application, when the shooting mode information includes a photographing mode, the second determining unit is specifically configured to:

[0159] The photo stream, preview stream and SAT algorithm stream are not configured for each of the secondary cameras.

[0160] The data stream configuration device in the embodiment of the present application can be an electronic device, or a component in the electronic device, such as an integrated circuit or a chip. The electronic device can be a terminal, or other devices other than a terminal. Exemplarily, the electronic device can be a mobile phone, a tablet computer, a laptop computer, a PDA, a car electronic device, a mobile Internet device (Mobile Internet Device, MID), an augmented reality (augmented reality, AR) / virtual reality (virtual reality, VR) device, a robot, a wearable device, an ultra-mobile personal computer (ultra-mobile personal computer, UMPC), a netbook or a personal digital assistant (personal digital assistant, PDA), etc., and can also be a server, a network attached storage (Network Attached Storage, NAS), a personal computer (personal computer, PC), a television (television, TV), a teller machine or a self-service machine, etc., and the embodiment of the present application is not specifically limited.

[0161] The data flow configuration device in the embodiment of the present application may be a device having an operating system. The operating system may be an Android operating system, an iOS operating system, or other possible operating systems, which are not specifically limited in the embodiment of the present application.

[0162] The data flow configuration device provided in the embodiment of the present application can achieve Figure 2 To avoid repetition, the various processes implemented by the method embodiment are not described here.

[0163] Alternatively, if Figure 6 As shown, an embodiment of the present application also provides an electronic device 600, including a processor 601 and a memory 602, wherein the memory 602 stores programs or instructions that can be executed on the processor 601, and when the program or instructions are executed by the processor 601, the various steps of the above-mentioned data flow configuration method embodiment are implemented, and the same technical effect can be achieved. To avoid repetition, they are not repeated here.

[0164] It should be noted that the electronic devices in the embodiments of the present application include the mobile electronic devices and non-mobile electronic devices mentioned above.

[0165] Figure 7 A schematic diagram of the hardware structure of an electronic device to implement an embodiment of the present application.

[0166] The electronic device 700 includes but is not limited to: a radio frequency unit 701, a network module 702, an audio output unit 703, an input unit 704, a sensor 705, a display unit 706, a user input unit 707, an interface unit 708, a memory 709, and a processor 710.

[0167] Those skilled in the art will appreciate that the electronic device 700 may also include a power source (such as a battery) for supplying power to each component, and the power source may be logically connected to the processor 710 through a power management system, thereby implementing functions such as managing charging, discharging, and power consumption management through the power management system. Figure 7 The electronic device structure shown in the figure does not constitute a limitation on the electronic device. The electronic device may include more or fewer components than shown in the figure, or combine certain components, or arrange the components differently, which will not be described in detail here.

[0168] Among them, the processor 710 is used to obtain shooting mode information and first magnification information, the shooting mode information including preview non-zoom mode, preview zoom mode and photo mode; determine the types of N cameras used for shooting according to the first magnification information, N is a positive integer, and N≥2; determine the configuration of the navigation frame stream of the N cameras according to the first magnification information and the types of the N cameras; determine the configuration of the preview stream, photo stream and spatial alignment transform SAT algorithm stream of the N cameras according to the shooting mode information and / or the types of the N cameras.

[0169] In this way, when shooting a shooting scene, the types of N cameras can be determined according to the first magnification information used when shooting the shooting scene, and then the configuration of the navigation frame stream of the N cameras can be determined according to the types of the N cameras and the first magnification information, as well as the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of the N cameras can be determined according to the shooting mode information of the camera application when shooting the shooting scene and the types of the N cameras. Compared with the prior art that configures all data streams for each frame image when shooting a shooting scene, the solution of the embodiment of the present application is to dynamically configure the data stream for each frame image according to the shooting mode information and the first magnification information of the shooting scene. In this way, while maintaining the smoothness of the user switching the camera when zooming the preview image and the response speed of the user when taking pictures, the power consumption waste is reduced.

[0170] Optionally, the magnification information of each camera in the N cameras is different, and the types of the N cameras include a main camera and a secondary camera; the processor 710 is also used to calculate the difference between the first magnification information and the magnification information of the N cameras, and obtain the first magnification difference values ​​corresponding to the N cameras respectively; the camera corresponding to the smallest positive real number in the first magnification differences corresponding to the N cameras is determined as the main camera, and the other cameras in the N cameras except the main camera are determined as secondary cameras.

[0171] In this way, by calculating the difference between the first magnification information and the magnification information of N cameras, we can get the first magnification difference values ​​corresponding to the N cameras respectively. Then, the camera corresponding to the smallest positive real number in the first magnification difference values ​​corresponding to the N cameras can be determined as the main camera, and the other cameras among the N cameras except the main camera can be determined as secondary cameras. In this way, the main camera and the secondary camera can be accurately determined.

[0172] Optionally, the processor 710 is further used to, if it is determined that the camera used when previewing the shooting scene according to the first magnification information is a main camera and the first magnification information is less than a first threshold, not configure a navigation frame stream for the main camera; if it is determined that the camera used when previewing the shooting scene according to the first magnification information is the main camera and the first magnification information is greater than or equal to the first threshold, configure a navigation frame stream for the main camera; if it is determined that the camera used when previewing the shooting scene according to the first magnification information is a secondary camera and the first magnification information is less than the first threshold, not configure a navigation frame stream for the secondary camera; if it is determined that the camera used when previewing the shooting scene according to the first magnification information is a secondary camera and the first magnification information is greater than or equal to the first threshold, not configure a navigation frame stream for the main camera.

[0173] In this way, compared to the prior art in which a navigation frame stream is configured for each frame of an image when shooting a shooting scene, the embodiment of the present application dynamically configures a navigation frame stream for the camera used when previewing the shooting scene according to the first magnification information, based on whether the first magnification information reaches a first threshold at which a navigation frame may appear, and the type of camera used when previewing the shooting scene according to the first magnification information. This reduces power consumption while maintaining the smoothness of switching cameras when the user zooms the preview image and the response speed of the user when taking pictures.

[0174] Optionally, the processor 710 is further used to configure the preview stream, the photo stream and the SAT algorithm stream for the main camera when it is determined that the camera used to preview the shooting scene according to the first magnification information is a main camera; and when it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, determine the configuration of the preview stream, photo stream and SAT algorithm stream of each of the secondary cameras according to the shooting mode information.

[0175] In this way, by dynamically determining the configuration of the preview stream, photo stream and SAT algorithm stream of the N cameras according to the shooting mode information and / or the types of the N cameras, the configuration of the preview stream, photo stream and SAT algorithm stream can be accurately determined.

[0176] Optionally, when the shooting mode information includes a preview non-zoom mode, the processor 710 is further used to select a sub-camera having a magnification closest to the first magnification information from each of the sub-cameras to obtain a target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than a second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

[0177] In this way, by selecting the sub-camera whose magnification is closest to the first magnification information from each sub-camera, the target sub-camera is obtained. When it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras except the target sub-camera. In this way, the data stream configured for the sub-camera can be accurately determined.

[0178] Optionally, when the shooting mode information includes a preview zoom mode, the processor 710 is further used to determine a magnification change speed when previewing the shooting scene according to the first magnification information, the second magnification information and a preview frame rate of the preview image of the shooting scene, wherein the second magnification information is magnification information before the shooting magnification of the preview image is zoomed to the first magnification information; when it is determined that the change speed is greater than a first speed threshold, the preview stream and the SAT algorithm stream are configured for each of the sub-cameras; when it is determined that the change speed is less than or equal to the first speed threshold, a sub-camera whose magnification is closest to the first magnification information is selected from each of the sub-cameras to obtain a target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than a second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

[0179] In this way, when the shooting mode information includes a preview zoom mode, the magnification change speed when previewing the shooting scene is determined according to the first magnification information, the second magnification information and the preview frame rate of the preview image of the shooting scene. Based on the comparison between the change speed and the first speed threshold, the preview stream and SAT algorithm stream are dynamically configured for each sub-camera. In this way, the configuration of the preview stream and SAT algorithm stream of each sub-camera can be accurately determined.

[0180] Optionally, when the shooting mode information includes a photo mode, the processor 710 is further configured not to configure a photo stream, a preview stream and a SAT algorithm stream for each of the secondary cameras.

[0181] In this way, when the camera application is in the photo mode, the photo stream, preview stream and SAT algorithm stream are not configured for each secondary camera, thus avoiding power consumption waste.

[0182] It should be understood that in the embodiment of the present application, the input unit 704 may include a graphics processor (Graphics Processing Unit, GPU) 7041 and a microphone 7042, and the graphics processor 7041 processes the image data of the static picture or video obtained by the image capture device (such as a color camera) in the video capture mode or the image capture mode. The display unit 706 may include a display panel 7061, and the display panel 7061 may be configured in the form of a liquid crystal display, an organic light emitting diode, etc. The user input unit 707 includes a touch panel 7071 and at least one of other input devices 7072. The touch panel 7071 is also called a touch screen. The touch panel 7071 may include two parts: a touch detection device and a touch controller. Other input devices 7072 may include, but are not limited to, a physical keyboard, function keys (such as volume control keys, switch keys, etc.), a trackball, a mouse, and a joystick, which will not be repeated here.

[0183] The memory 709 can be used to store software programs and various data. The memory 709 may mainly include a first storage area for storing programs or instructions and a second storage area for storing data, wherein the first storage area may store an operating system, an application program or instructions required for at least one function (such as a sound playback function, an image playback function, etc.), etc. In addition, the memory 709 may include a volatile memory or a non-volatile memory, or the memory 709 may include both volatile and non-volatile memories. Among them, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), or a flash memory. The volatile memory may be a random access memory (RAM), a static random access memory (SRAM), a dynamic random access memory (DRAM), a synchronous dynamic random access memory (SDRAM), a double data rate synchronous dynamic random access memory (DDRSDRAM), an enhanced synchronous dynamic random access memory (ESDRAM), a synchronous link dynamic random access memory (SLDRAM) and a direct memory bus random access memory (DRRAM). The memory 709 in the embodiment of the present application includes but is not limited to these and any other suitable types of memory.

[0184] The processor 710 may include one or more processing units; optionally, the processor 710 integrates an application processor and a modem processor, wherein the application processor mainly processes operations related to an operating system, a user interface, and application programs, and the modem processor mainly processes wireless communication signals, such as a baseband processor. It is understandable that the modem processor may not be integrated into the processor 710.

[0185] An embodiment of the present application also provides a readable storage medium, on which a program or instruction is stored. When the program or instruction is executed by a processor, each process of the above-mentioned data flow configuration method embodiment is implemented, and the same technical effect can be achieved. To avoid repetition, it will not be repeated here.

[0186] The processor is the processor in the electronic device described in the above embodiment. The readable storage medium includes a computer readable storage medium, such as a computer read-only memory ROM, a random access memory RAM, a magnetic disk or an optical disk.

[0187] An embodiment of the present application further provides a chip, which includes a processor and a communication interface, wherein the communication interface is coupled to the processor, and the processor is used to run programs or instructions to implement the various processes of the above-mentioned data flow configuration method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0188] It should be understood that the chip mentioned in the embodiments of the present application can also be called a system-level chip, a system chip, a chip system or a system-on-chip chip, etc.

[0189] An embodiment of the present application provides a computer program product, which is stored in a storage medium. The program product is executed by at least one processor to implement the various processes of the above-mentioned data flow configuration method embodiment, and can achieve the same technical effect. To avoid repetition, it will not be repeated here.

[0190] It should be noted that, in this article, the terms "comprise", "include" or any other variant thereof are intended to cover non-exclusive inclusion, so that the process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise one..." do not exclude the presence of other identical elements in the process, method, article or device including the element. In addition, it should be pointed out that the scope of the methods and devices in the embodiments of the present application is not limited to performing functions in the order shown or discussed, and may also include performing functions in a substantially simultaneous manner or in reverse order according to the functions involved, for example, the described method may be performed in an order different from that described, and various steps may also be added, omitted, or combined. In addition, the features described with reference to certain examples may be combined in other examples.

[0191] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a computer software product, which is stored in a storage medium (such as ROM / RAM, a disk, or an optical disk), and includes a number of instructions for a terminal (which can be a mobile phone, a computer, a server, or a network device, etc.) to execute the methods described in each embodiment of the present application.

[0192] The embodiments of the present application are described above in conjunction with the accompanying drawings, but the present application is not limited to the above-mentioned specific implementation methods. The above-mentioned specific implementation methods are merely illustrative and not restrictive. Under the guidance of the present application, ordinary technicians in this field can also make many forms without departing from the purpose of the present application and the scope of protection of the claims, all of which are within the protection of the present application.

Claims

1. A data stream configuration method, characterized in that: The method comprises: Acquire shooting mode information and first magnification information, wherein the shooting mode information includes a preview non-zoom mode, a preview zoom mode, and a photo mode; Determine the types of N cameras used for shooting according to the first magnification information, where N is a positive integer and N≥2; Determining configurations of navigation frame streams of the N cameras according to the first magnification information and types of the N cameras; According to the shooting mode information and / or the types of the N cameras, the configurations of the preview streams, the photo streams and the spatial alignment transform SAT algorithm streams of the N cameras are determined.

2. The method according to claim 1, characterized in that The magnification information of each camera in the N cameras is different, and the types of the N cameras include a main camera and a secondary camera; The determining, according to the first magnification information, types of N cameras used for shooting includes: Calculate the difference between the first magnification information and the magnification information of the N cameras to obtain the first magnification difference values ​​corresponding to the N cameras respectively; The camera corresponding to the smallest positive real number in the first magnification differences corresponding to the N cameras is determined as the main camera, and the other cameras among the N cameras except the main camera are determined as secondary cameras.

3. The method according to claim 2, characterized in that The determining, according to the first magnification information and the types of the N cameras, configurations of the navigation frame streams of the N cameras includes: When it is determined that the camera used to preview the shooting scene according to the first magnification information is a main camera, and the first magnification information is less than a first threshold, not configuring a navigation frame stream for the main camera; When it is determined that the camera used to preview the shooting scene according to the first magnification information is a main camera, and the first magnification information is greater than or equal to the first threshold, configuring a navigation frame stream for the main camera; When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, and the first magnification information is less than the first threshold, not configuring a navigation frame stream for the secondary camera; When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, and the first magnification information is greater than or equal to the first threshold, a navigation frame stream is not configured for the main camera.

4. The method according to claim 2, characterized in that: The determining, according to the shooting mode information and / or the types of the N cameras, configurations of the N camera preview streams, the photo streams, and the spatial alignment transform SAT algorithm streams includes: When it is determined that the camera used for previewing the shooting scene according to the first magnification information is the main camera, configuring the preview stream, the photo stream, and the SAT algorithm stream for the main camera; When it is determined that the camera used to preview the shooting scene according to the first magnification information is a secondary camera, the configuration of the preview stream, the photo stream and the SAT algorithm stream of each secondary camera is determined according to the shooting mode information.

5. The method according to claim 4, characterized in that In the case where the shooting mode information includes a preview non-zoom mode, determining the configuration of the preview stream, the photo stream, and the SAT algorithm stream of each of the secondary cameras according to the shooting mode information includes: Selecting a secondary camera whose magnification is closest to the first magnification information from the secondary cameras to obtain a target secondary camera; When it is determined that the first magnification difference corresponding to the target sub-camera is less than the second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

6. The method according to claim 4, characterized in that In the case where the shooting mode information includes a preview zoom mode, determining the configuration of the preview stream, the photo stream, and the SAT algorithm stream of each of the secondary cameras according to the shooting mode information includes: determining a magnification change speed when previewing the shooting scene according to the first magnification information, the second magnification information and a preview frame rate of a preview image of the shooting scene, wherein the second magnification information is magnification information before the shooting magnification of the preview image is zoomed to the first magnification information; When it is determined that the change speed is greater than a first speed threshold, configuring the preview stream and the SAT algorithm stream for each of the secondary cameras; When it is determined that the change speed is less than or equal to the first speed threshold, a sub-camera whose magnification is closest to the first magnification information is selected from each of the sub-cameras to obtain a target sub-camera; when it is determined that the first magnification difference corresponding to the target sub-camera is less than a second threshold, the preview stream and the SAT algorithm stream are configured for the target sub-camera, and the preview stream and the SAT algorithm stream are not configured for other sub-cameras among the sub-cameras except the target sub-camera.

7. The method according to claim 4, characterized in that In the case where the shooting mode information includes a photo mode, determining the configuration of each of the auxiliary camera preview streams, the photo stream, and the spatial alignment transform SAT algorithm stream according to the shooting mode information includes: The photo stream, preview stream and SAT algorithm stream are not configured for each of the secondary cameras.

8. A data stream configuration device, characterized in that: The device comprises: A first acquisition module, used to acquire shooting mode information and first magnification information, wherein the shooting mode information includes a preview zoom mode, a preview zoom mode, and a photo mode; A first determining module, configured to determine the types of N cameras used for shooting according to the first magnification information, where N is a positive integer and N≥2; A second determining module, configured to determine configurations of navigation frame streams of the N cameras according to the first magnification information and types of the N cameras; The third determination module is used to determine the configuration of the preview stream, the photo stream and the spatial alignment transformation SAT algorithm stream of the N cameras according to the shooting mode information and / or the types of the N cameras.

9. An electronic device, characterized in that: It comprises a processor and a memory, wherein the memory stores a program or instruction that can be run on the processor, and when the program or instruction is executed by the processor, the steps of the data flow configuration method according to any one of claims 1 to 7 are implemented.

10. A readable storage medium, characterized in that: The readable storage medium stores a program or instruction, and when the program or instruction is executed by a processor, the steps of the data flow configuration method according to any one of claims 1 to 7 are implemented.

Citation Information

Patent Citations

  • Shooting method and electronic equipment

    CN111010506A

  • Shooting zooming method, electronic equipment and storage medium

    CN113840076A

  • Image sensor control method and device, system on chip, equipment and medium

    CN117915165A

  • Shooting control method and device, equipment and storage medium

    CN117979160A