CN116668836A - Photographing processing method and electronic equipment - Google Patents

Photographing processing method and electronic equipment Download PDF

Info

Publication number
CN116668836A
CN116668836A CN202211468036.3A CN202211468036A CN116668836A CN 116668836 A CN116668836 A CN 116668836A CN 202211468036 A CN202211468036 A CN 202211468036A CN 116668836 A CN116668836 A CN 116668836A
Authority
CN
China
Prior art keywords
image
data packet
shooting
electronic device
photographing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN202211468036.3A
Other languages
Chinese (zh)
Other versions
CN116668836B (en
Inventor
许集润
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Honor Device Co Ltd
Original Assignee
Honor Device Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Honor Device Co Ltd filed Critical Honor Device Co Ltd
Priority to CN202211468036.3A priority Critical patent/CN116668836B/en
Publication of CN116668836A publication Critical patent/CN116668836A/en
Application granted granted Critical
Publication of CN116668836B publication Critical patent/CN116668836B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Abstract

The application relates to the field of terminals and provides a photographing processing method and electronic equipment; the method comprises the following steps: detecting a first operation, wherein the first operation is an operation for indicating the electronic equipment to take a picture; responding to the first operation, and acquiring a first data packet in an image data queue; performing image processing on the first data packet to generate a first shooting image; detecting a second operation, the second operation including N shooting operations; responding to the second operation, and acquiring N data packets; after the first shooting image is generated, a second data packet in an image data queue is acquired; performing image processing on the second data packet to generate a second shooting image; detecting a third operation, which is an operation of clicking on the thumbnail image of the second captured image; displaying a second photographed image in response to the third operation; according to the scheme provided by the application, when the electronic equipment detects the operation of clicking the thumbnail image, the shooting image can be displayed rapidly to a certain extent, and the shooting experience is improved.

Description

Photographing processing method and electronic equipment
Technical Field
The application relates to the field of terminals, in particular to a photographing processing method and electronic equipment.
Background
With the development of shooting functions in electronic devices, camera applications are becoming more and more widely used in electronic devices. Currently, under the condition that the electronic device detects a plurality of continuous photographing operations, the electronic device generally processes a data packet with the latest photographing time at last; however, after the photographing is finished, the user usually clicks the thumbnail with the latest photographing time to view the actual photographed image; because the electronic device usually processes the photographed image with the latest photographing time at the end, the electronic device needs to display the photographed image with the latest photographing time in the gallery application program after a period of time; therefore, currently, after the user clicks on the thumbnail image with the latest photographing time, the electronic device cannot quickly display the actual photographing image; thus, the waiting time of the user is longer, and the shooting experience is poorer.
Therefore, in the case where the electronic apparatus detects a click thumbnail image, how to quickly display the actual captured image becomes a problem to be solved.
Disclosure of Invention
The application provides a photographing processing method and electronic equipment, which can quickly display a photographed image to a certain extent under the condition that the electronic equipment detects clicking of a thumbnail image, and improve photographing experience.
In a first aspect, a photographing processing method is provided, applied to an electronic device, and the photographing processing method includes:
detecting a first operation, wherein the first operation is an operation for indicating the electronic equipment to take a picture;
responding to the first operation, and acquiring a first data packet;
storing the first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue;
performing image processing on the first data packet to generate a first shooting image;
detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than a preset duration, the shooting operations are operations for indicating the electronic equipment to acquire images, and N is an integer greater than or equal to 2;
responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with the N shooting operations;
storing the N data packets in the image data queue based on the sequence from the early to the late of the acquisition time;
after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is a data packet with the latest acquisition time in the image data queue;
Performing the image processing on the second data packet to generate a second shooting image;
detecting a third operation, wherein the third operation is an operation of clicking on a thumbnail image of the second shooting image;
in response to the third operation, displaying the second captured image in the embodiment of the present application, the electronic device may generate the captured image by performing image processing on the data packets in the image data queue in an order from late to early (for example, an order of acquisition-before-processing) of the acquisition time, so that a period between the operation of the electronic device detecting clicking the thumbnail image and displaying the captured image can be shortened to some extent; it can be understood that, after processing the data packet of the first operation in the multiple continuous photographing operations, the electronic device may select the second data packet with the latest acquisition time in the stored image data queue to perform image processing, so as to generate a second photographed image; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
With reference to the first aspect, in certain implementation manners of the first aspect, the N data packets include the second data packet and N-1 data packets, and after generating the second captured image, the method further includes:
sequentially acquiring N-1 data packets in the image data queue according to the sequence from late to early based on the acquisition time of the N-1 data packets;
and sequentially carrying out image processing on the N-1 data packets to generate N-1 shooting images.
In the embodiment of the present application, after performing image processing on the first data packet and the second data packet (for example, the last data packet) in the image data queue, image processing may be performed on other data packets in the image data queue according to the order from the late to the early of the data packet acquisition time, so as to generate the corresponding captured image.
With reference to the first aspect, in certain implementations of the first aspect, the first data packet includes a first end frame, the first end frame being used to indicate an end position of the first data packet in the image data queue; the step of acquiring the second data packet in the image data queue after the step of generating the first photographed image includes:
acquiring the second data packet at a first time; wherein the first time is a time of processing the first end frame.
In the embodiment of the application, because the image data queue is a data queue updated in real time based on photographing operation, in order to ensure that the selected second data packet is the data packet with the photographing operation at the latest moment in the image data queue; when processing the first end frame in the first data packet, selecting a second data packet from the image data queue according to the sequence from the late to the early of the data packet acquisition time; thereby improving the accuracy of the selected second data packet.
With reference to the first aspect, in certain implementations of the first aspect, each of the N data packets includes a start frame for indicating a start position of one data packet in the image data queue and an end frame for indicating an end position of one data packet in the image data queue; the obtaining the second data packet at the first time includes:
determining the position information of a target initial frame in the image data queue at the first moment, wherein the target initial frame is the initial frame with the latest moment in the image data queue;
and acquiring the second data packet based on the position information of the target initial frame.
In the embodiment of the present application, since each of the N data packets includes a start frame; thus, when selecting the second data packet in the image data queue in the order from late to early according to the data packet acquisition time, the target start frame (for example, the start frame with the latest acquisition time) in the image data queue, which is the start frame of the second data packet, may be determined in the order from late to early based on the time information; selecting a second data packet in the image data queue based on the target start frame; in the embodiment of the application, the second data packet in the image data queue is selected according to the position of the initial frame of the second data packet, so that the operation amount of the electronic equipment can be reduced to a certain extent.
With reference to the first aspect, in certain implementation manners of the first aspect, the first data packet includes a first start frame, and the first start frame is used to identify a start position of the first data packet in the image data queue; m frames of image data are included between the first starting frame and the first ending frame, and M is an integer greater than or equal to 1.
With reference to the first aspect, in certain implementations of the first aspect, the M-frame image data is image data of a first color space; the image processing includes processing employing a first algorithm that is an algorithm of the first color space and a second algorithm that is an algorithm that converts an image of the first color space into an image of a second color space.
With reference to the first aspect, in certain implementation manners of the first aspect, the N times of photographing operations are continuous photographing operations.
With reference to the first aspect, in certain implementations of the first aspect, the n+1 data packets in the image data queue are data packets acquired in a zero second delay queue based on time information of the first operation and time information of the second operation.
In one possible implementation, the electronic device may obtain corresponding data packets in the zero second delay queue based on the time information of the first operation and the time information of the second operation detected, and store the data packets in the image data queue.
In a second aspect, an electronic device is provided, the electronic device comprising one or more processors and memory; the memory is coupled to the one or more processors, the memory for storing computer program code, the computer program code comprising computer instructions that the one or more processors call to cause the electronic device to perform:
detecting a first operation, wherein the first operation is an operation for indicating the electronic equipment to take a picture;
responding to the first operation, and acquiring a first data packet;
Storing the first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue;
performing image processing on the first data packet to generate a first shooting image;
detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than a preset duration, the shooting operations are operations for indicating the electronic equipment to acquire images, and N is an integer greater than or equal to 2;
responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with the N shooting operations;
storing the N data packets in the image data queue based on the sequence from the early to the late of the acquisition time;
after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is a data packet with the latest acquisition time in the image data queue;
performing the image processing on the second data packet to generate a second shooting image;
detecting a third operation, wherein the third operation is an operation of clicking on a thumbnail image of the second shooting image;
And displaying the second photographed image in response to the third operation.
With reference to the second aspect, in certain implementations of the second aspect, the N data packets include the second data packet and N-1 data packets, and after generating the second captured image, the one or more processors invoke the computer instructions to cause the electronic device to perform:
sequentially acquiring N-1 data packets in the image data queue according to the sequence from late to early based on the acquisition time of the N-1 data packets;
and sequentially carrying out image processing on the N-1 data packets to generate N-1 shooting images.
With reference to the second aspect, in certain implementations of the second aspect, the first data packet includes a first end frame, the first end frame being used to indicate an end position of the first data packet in the image data queue; the one or more processors invoke the computer instructions to cause the electronic device to perform:
acquiring the second data packet at a first time; wherein the first time is a time of processing the first end frame.
With reference to the second aspect, in certain implementations of the second aspect, each of the N data packets includes a start frame for indicating a start position of one data packet in the image data queue and an end frame for indicating an end position of one data packet in the image data queue; the one or more processors invoke the computer instructions to cause the electronic device to perform:
Determining the position information of a target initial frame in the image data queue at the first moment, wherein the target initial frame is the initial frame with the latest moment in the image data queue;
and acquiring the second data packet based on the position information of the target initial frame.
With reference to the second aspect, in certain implementations of the second aspect, the first data packet includes a first start frame, the first start frame being used to identify a start position of the first data packet in the image data queue; m frames of image data are included between the first starting frame and the first ending frame, and M is an integer greater than or equal to 1.
With reference to the second aspect, in certain implementations of the second aspect, the M-frame image data is image data of a first color space; the image processing includes processing employing a first algorithm that is an algorithm of the first color space and a second algorithm that is an algorithm that converts an image of the first color space into an image of a second color space.
With reference to the second aspect, in certain implementations of the second aspect, the N-shot operation is a continuous shooting operation.
With reference to the second aspect, in certain implementations of the second aspect, the n+1 data packets in the image data queue are data packets acquired in a zero second delay queue based on time information of the first operation and time information of the second operation.
In a third aspect, an electronic device is provided, including a module/unit for performing the photographing processing method of the first aspect or any implementation manner of the first aspect.
In a fourth aspect, an electronic device is provided that includes one or more processors and memory; the memory is coupled to the one or more processors, the memory for storing computer program code, the computer program code comprising computer instructions that the one or more processors call to cause the electronic device to perform the photographing processing method of the first aspect or any of the implementations of the first aspect.
In a fifth aspect, a chip system is provided, the chip system being applied to an electronic device, the chip system comprising one or more processors for invoking computer instructions to cause the electronic device to perform the first aspect or any of the photographic processing methods of the first aspect.
In a sixth aspect, there is provided a computer readable storage medium storing computer program code which, when executed by an electronic device, causes the electronic device to perform the photographing processing method of the first aspect or any implementation manner of the first aspect.
In a seventh aspect, there is provided a computer program product comprising: computer program code which, when run by an electronic device, causes the electronic device to perform the photographing processing method of the first aspect or any of the implementation forms of the first aspect.
In the embodiment of the application, the electronic equipment can generate the shot image by adopting image processing on the data packets in the image data queue according to the sequence from late to early (for example, the sequence of acquisition and processing before) of the acquisition time, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after processing the data packet of the first operation in the multiple continuous photographing operations, the electronic device may select the second data packet with the latest acquisition time in the stored image data queue to perform image processing, so as to generate a second photographed image; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Drawings
FIG. 1 is a schematic diagram of a hardware system suitable for use in an electronic device of the present application;
FIG. 2 is a schematic diagram of a prior art image processing sequence;
FIG. 3 is a schematic diagram of a graphical user interface provided by an embodiment of the present application;
FIG. 4 is a schematic diagram of another graphical user interface provided by an embodiment of the present application;
FIG. 5 is a schematic diagram of a software architecture according to an embodiment of the present application;
FIG. 6 is a schematic flow chart of a photographing processing method according to an embodiment of the present application;
FIG. 7 is a schematic flow chart of another photographing processing method according to an embodiment of the present application;
fig. 8 is a schematic diagram of a data packet for continuous shooting operation according to an embodiment of the present application;
FIG. 9 is a schematic diagram of a post-processing queue provided by an embodiment of the present application;
FIG. 10 is a schematic diagram of still another photographing method according to an embodiment of the present application;
fig. 11 is a schematic diagram of a sequence of generating a photographed image provided by an embodiment of the present application;
FIG. 12 is a schematic diagram of a post-processing queue storing data packets according to an embodiment of the present application;
fig. 13 is a schematic diagram of another sequence of generating a photographed image provided by an embodiment of the present application;
FIG. 14 is a schematic diagram of storing data packets in another post-processing queue according to an embodiment of the present application;
fig. 15 is a schematic diagram of still another sequence of generating a captured image provided by an embodiment of the present application;
FIG. 16 is a schematic diagram of a further post-processing queue storing data packets according to an embodiment of the present application;
FIG. 17 is a schematic diagram of yet another graphical user interface provided by an embodiment of the present application;
FIG. 18 is a schematic diagram of yet another graphical user interface provided by an embodiment of the present application;
FIG. 19 is a schematic view of yet another graphical user interface provided by an embodiment of the present application;
FIG. 20 is a schematic view of yet another graphical user interface provided by an embodiment of the present application;
fig. 21 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 22 is a schematic structural diagram of another electronic device according to an embodiment of the present application.
Detailed Description
In embodiments of the present application, the following terms "first", "second", etc. are used for descriptive purposes only and are not to be construed as indicating or implying relative importance or implicitly indicating the number of technical features indicated. Thus, a feature defining "a first" or "a second" may explicitly or implicitly include one or more such feature. In the description of the present embodiment, unless otherwise specified, the meaning of "plurality" is two or more.
In order to facilitate understanding of the embodiments of the present application, related concepts related to the embodiments of the present application will be briefly described.
1. Thumbnail image
The thumbnail image is an image with smaller resolution cached in the electronic equipment, and the quality of the thumbnail image is poorer than that of a shooting image; the resolution of the thumbnail image is smaller than the photographed image in the electronic device; alternatively, the thumbnail images through the photographing interface may be indexed to the actual photographed images in the album.
2. Shooting an image
In the embodiment of the application, the shot image may refer to a real image generated by the user detecting one shooting operation; it will be appreciated that the electronic device detects a photographing operation and generates an image that is stored in the gallery application.
3. Post-processing queues
The post-processing queue is used for storing data packets for generating shooting images; the image data stored in the post-processing queue may be image data acquired from a zero-second delay (ZSL) queue; among them, before shooting, an electronic device typically displays images of a screen to be shot in the electronic device, and these displayed images are also called preview images.
Alternatively, the images in the ZSL queue may be Raw images.
Fig. 1 shows a hardware system suitable for use in the electronic device of the application.
The electronic device 100 may be a mobile phone, a smart screen, a tablet computer, a wearable electronic device, an in-vehicle electronic device, an augmented reality (augmented reality, AR) device, a Virtual Reality (VR) device, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (personal digital assistant, PDA), a projector, etc., and the specific type of the electronic device 100 is not limited in the embodiments of the present application.
The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a universal serial bus (universal serial bus, USB) interface 130, a charge management module 140, a power management module 141, a battery 142, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, an audio module 170, a speaker 170A, a receiver 170B, a microphone 170C, an earphone interface 170D, a sensor module 180, keys 190, a motor 191, an indicator 192, a camera 193, a display 194, and a subscriber identity module (subscriber identification module, SIM) card interface 195, etc. The sensor module 180 may include a pressure sensor 180A, a gyro sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity sensor 180G, a fingerprint sensor 180H, a temperature sensor 180J, a touch sensor 180K, an ambient light sensor 180L, a bone conduction sensor 180M, and the like.
The configuration shown in fig. 1 does not constitute a specific limitation on the electronic apparatus 100. In other embodiments of the application, electronic device 100 may include more or fewer components than those shown in FIG. 1, or electronic device 100 may include a combination of some of the components shown in FIG. 1, or electronic device 100 may include sub-components of some of the components shown in FIG. 1. The components shown in fig. 1 may be implemented in hardware, software, or a combination of software and hardware.
Illustratively, the processor 110 may include one or more processing units. For example, the processor 110 may include at least one of the following processing units: application processors (application processor, AP), modem processors, graphics processors (graphics processing unit, GPU), image signal processors (image signal processor, ISP), controllers, video codecs, digital signal processors (digital signal processor, DSP), baseband processors, neural-Network Processors (NPU). The different processing units may be separate devices or integrated devices. The controller can generate operation control signals according to the instruction operation codes and the time sequence signals to finish the control of instruction fetching and instruction execution.
A memory may also be provided in the processor 110 for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may hold instructions or data that the processor 110 has just used or recycled. If the processor 110 needs to reuse the instruction or data, it can be called directly from the memory. Repeated accesses are avoided and the latency of the processor 110 is reduced, thereby improving the efficiency of the system.
In some embodiments, the processor 110 may include one or more interfaces. For example, the processor 110 may include at least one of the following interfaces: inter-integrated circuit, I2C) interfaces, inter-integrated circuit audio (inter-integrated circuit sound, I2S) interfaces, pulse code modulation (pulse code modulation, PCM) interfaces, universal asynchronous receiver transmitter (universal asynchronous receiver/transmitter, UART) interfaces, mobile industry processor interfaces (mobile industry processor interface, MIPI), general-purpose input/output (GPIO) interfaces, SIM interfaces, USB interfaces.
Illustratively, in an embodiment of the present application, the processor 110 may be configured to perform the photographing processing method provided by the embodiment of the present application; for example, a first operation is detected, the first operation being an operation of instructing the electronic device to take a picture; responding to a first operation, and acquiring a first data packet; storing a first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue; performing image processing on the first data packet to generate a first shooting image; detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than the preset duration, the shooting operations are operations for indicating the electronic equipment to collect images, and N is an integer greater than or equal to 2; responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with N shooting operations; storing N data packets in an image data queue based on the sequence from the early to the late of the acquisition time; after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is the data packet with the latest acquisition time in the image data queue; performing image processing on the second data packet to generate a second shooting image; detecting a third operation, which is an operation of clicking on the thumbnail image of the second captured image; in response to the third operation, the second captured image is displayed.
The connection relationships between the modules shown in fig. 1 are merely illustrative, and do not constitute a limitation on the connection relationships between the modules of the electronic device 100. Alternatively, the modules of the electronic device 100 may also use a combination of the various connection manners in the foregoing embodiments.
The wireless communication function of the electronic device 100 may be implemented by the antenna 1, the antenna 2, the mobile communication module 150, the wireless communication module 160, the modem processor, the baseband processor, and the like.
The antennas 1 and 2 are used for transmitting and receiving electromagnetic wave signals. Each antenna in the electronic device 100 may be used to cover a single or multiple communication bands. Different antennas may also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed into a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The electronic device 100 may implement display functions through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, and is connected to the display 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. Processor 110 may include one or more GPUs that execute program instructions to generate or change display information.
The display screen 194 may be used to display images or video.
Alternatively, the display screen 194 may be used to display images or video. The display 194 includes a display panel. The display panel may employ a liquid crystal display (liquid crystal display, LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), a Mini light-emitting diode (Mini LED), a Micro light-emitting diode (Micro LED), a Micro OLED (Micro OLED), or a quantum dot LED (quantum dot light emitting diodes, QLED). In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
Illustratively, the electronic device 100 may implement a photographing function through an ISP, a camera 193, a video codec, a GPU, a display screen 194, an application processor, and the like.
Illustratively, the ISP is used to process data fed back by the camera 193. For example, when photographing, the shutter is opened, light is transmitted to the camera photosensitive element through the camera, the optical signal is converted into an electric signal, and the camera photosensitive element transmits the electric signal to the ISP for processing and is converted into an image visible to naked eyes. The ISP can carry out algorithm optimization on noise, brightness and color of the image, and can optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in the camera 193.
Illustratively, a camera 193 (which may also be referred to as a lens) is used to capture still images or video. The shooting function can be realized by triggering and starting through an application program instruction, such as shooting and acquiring an image of any scene. The camera may include imaging lenses, filters, image sensors, and the like. Light rays emitted or reflected by the object enter the imaging lens, pass through the optical filter and finally are converged on the image sensor. The imaging lens is mainly used for converging and imaging light emitted or reflected by all objects (also called a scene to be shot and a target scene, and also called a scene image expected to be shot by a user) in a shooting view angle; the optical filter is mainly used for filtering out redundant light waves (such as light waves except visible light, such as infrared light) in the light; the image sensor may be a charge coupled device (charge coupled device, CCD) or a Complementary Metal Oxide Semiconductor (CMOS) phototransistor. The image sensor is mainly used for photoelectrically converting a received optical signal into an electrical signal, and then transmitting the electrical signal to the ISP to be converted into a digital image signal. The ISP outputs the digital image signal to the DSP for processing. The DSP converts the digital image signal into an image signal in a standard RGB, YUV, or the like format.
Illustratively, the digital signal processor is configured to process digital signals, and may process other digital signals in addition to digital image signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to fourier transform the frequency bin energy, or the like.
Illustratively, video codecs are used to compress or decompress digital video. The electronic device 100 may support one or more video codecs. In this way, the electronic device 100 may play or record video in a variety of encoding formats, such as: dynamic picture experts group (moving picture experts group, MPEG) 1, MPEG2, MPEG3, and MPEG4.
Illustratively, the gyroscopic sensor 180B may be used to determine a motion pose of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., x-axis, y-axis, and z-axis) may be determined by gyro sensor 180B. The gyro sensor 180B may be used for photographing anti-shake. For example, when the shutter is pressed, the gyro sensor 180B detects the shake angle of the electronic device 100, calculates the distance to be compensated by the lens module according to the angle, and makes the lens counteract the shake of the electronic device 100 through the reverse motion, so as to realize anti-shake. The gyro sensor 180B can also be used for scenes such as navigation and motion sensing games.
For example, the acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically, x-axis, y-axis, and z-axis). The magnitude and direction of gravity may be detected when the electronic device 100 is stationary. The acceleration sensor 180E may also be used to recognize the gesture of the electronic device 100 as an input parameter for applications such as landscape switching and pedometer.
Illustratively, a distance sensor 180F is used to measure distance. The electronic device 100 may measure the distance by infrared or laser. In some embodiments, for example, in a shooting scene, the electronic device 100 may range using the distance sensor 180F to achieve fast focus.
Illustratively, ambient light sensor 180L is used to sense ambient light level. The electronic device 100 may adaptively adjust the brightness of the display 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust white balance when taking a photograph. Ambient light sensor 180L may also cooperate with proximity light sensor 180G to detect whether electronic device 100 is in a pocket to prevent false touches.
Illustratively, the fingerprint sensor 180H is used to capture a fingerprint. The electronic device 100 may utilize the collected fingerprint feature to perform functions such as unlocking, accessing an application lock, taking a photograph, and receiving an incoming call.
Illustratively, the touch sensor 180K, also referred to as a touch device. The touch sensor 180K may be disposed on the display screen 194, and the touch sensor 180K and the display screen 194 form a touch screen, which is also called a touch screen. The touch sensor 180K is for detecting a touch operation acting thereon or thereabout. The touch sensor 180K may communicate the detected touch operation to the application processor to determine the touch event type. Visual output related to touch operations may be provided through the display 194. In other embodiments, the touch sensor 180K may also be disposed on the surface of the electronic device 100 and at a different location than the display 194.
At present, the electronic equipment generally performs image processing on a data packet acquired by an image sensor in a mode of acquisition before processing; because the electronic equipment processes the data packet in a mode of first acquisition and first processing, the image electronic equipment with the latest shooting time is usually processed finally; however, after the user finishes the photographing operation, the user typically clicks on the thumbnail to view the actual photographed image, and the thumbnail image is typically the thumbnail image with the latest photographing time; because the electronic device usually processes the photographed image with the latest photographing time at last, the electronic device needs a long time before displaying the photographed image with the latest photographing time in the gallery application program; therefore, at present, after the user clicks the thumbnail image, there is a problem that a shot image with the latest shooting time cannot be displayed quickly in the gallery application program; thus, the waiting time of the user is longer, and the shooting experience is poorer.
Illustratively, as shown in FIG. 2, the operation of the electronic device detecting 3 shots in rapid succession is illustrated; in the case where the electronic device detects 3 operations of quick continuous shooting, the order in which the electronic device detects the shooting operations is: a first photographing operation, a second photographing operation and a third photographing operation; the electronic equipment processes the acquired image in a mode of acquisition and processing; the first shooting operation corresponds to the electronic equipment collecting data packet 1, the second shooting operation corresponds to the electronic equipment collecting data packet 2, and the third shooting operation corresponds to the electronic equipment collecting data packet 3; the sequence of the data packets processed by the electronic equipment is as follows: data packet 1, data packet 2 and data packet 3; the electronic device may display the shot images (for example, the gallery application program displays the shot images) in the reverse order of time after detecting that the thumbnail images are clicked, which may be understood as that the electronic device displays the shot images in the following order: the third shot image, the second shot image and the first shot image; because one or more frames of images can be acquired in one shooting, a shooting image in one shooting is generated through processing the one or more frames of images; after the electronic device detects the third photographing operation, the electronic device may also process the first photographed image or the second photographed image; at this time, the electronic apparatus cannot quickly display the photographing image of the third photographing after the user clicks the thumbnail image of the third photographing; the waiting time of the user is longer, and the shooting experience is poorer.
For example, assume that the electronic device collects one data packet for a period of 0.1 seconds; the time required for the electronic device to process a data packet is 3 seconds, namely the time required for the electronic device to generate a shot image is 3 seconds; if the electronic equipment detects 3 continuous shooting operations rapidly, the electronic equipment can generate a third shooting image only in 9 seconds; therefore, after the user finishes the photographing operation and clicks the thumbnail image of the third photographed image, the electronic device can display the third photographed image after a period of time is required; the waiting time of the user is longer, and the shooting experience is poorer.
Illustratively, after the electronic device runs the camera application, a preview interface 201 is displayed, as shown in (a) of fig. 3; the preview interface 201 comprises a preview image, a photographing control 202 and a thumbnail display control 203, wherein the image displayed in the thumbnail display control 203 is the thumbnail image photographed last time; the electronic equipment detects a plurality of rapid continuous shooting operations; for example, the electronic device detects an operation of clicking the photographing control 202, as shown in (b) in fig. 3; after the electronic device detects the operation of clicking the photographing control 202, the electronic device detects the operation of bouncing the photographing control 202, and displays the display interface 204, as shown in (c) in fig. 3; after the electronic device detects the operation of bouncing the photographing control 202, the electronic device detects the operation of clicking the photographing control 202, as shown in (d) in fig. 3; after the electronic device detects the operation of clicking the photographing control 202, the electronic device detects the operation of bouncing the photographing control 202, and displays a display interface 205, as shown in (a) in fig. 4; after the electronic device detects the operation of bouncing the photographing control 202, the electronic device detects the operation of clicking the thumbnail display control 203, as shown in (b) in fig. 4; after the electronic device detects the operation of clicking the thumbnail display control 203, the electronic device may display a display interface 206, where the display interface 206 includes an image acquired by the second photographing operation; because the electronic device performs image processing on the data packet according to a first-acquisition-first-processing mode at present, when the electronic device detects an operation of clicking the thumbnail display control 203, the electronic device may be processing the data packet acquired by the second photographing operation but not processing the first photographing image acquired by the first photographing operation; therefore, the second shot image displayed at this time is an image obtained by performing scaling processing on the thumbnail image of the second shot, and is not a real image of the second shot; for example, as shown in (c) of fig. 4, the image displayed in the display interface 206 includes an image area 207, and detailed information in the image area 207 is poor; after a certain period of time, the electronic device generates a shooting image of the second shooting, and displays a display interface 208, wherein the display interface 208 comprises the shooting image of the second shooting, namely a real image of the second shooting; the real image of the second shot image includes an image area 209; the detail information in the image area 209 is superior to the detail information in the image area 207, as shown in (d) of fig. 4.
It should be noted that, after completing the photographing operation, the user typically clicks the thumbnail display control 203 to view the photographed image; after clicking the thumbnail display control 203, the user wishes to be able to quickly display the captured image in the gallery application; if the electronic device processes the images according to the current acquisition-first processing manner (for example, according to the sequence from the early to the late of the acquisition time), the electronic device cannot display the shot images quickly after detecting the bouncing shooting control, which results in longer shooting waiting time of the user and poorer shooting experience.
It should also be appreciated that the operation of the electronic device detecting one click on the photographing control and the operation of the one pop-up photographing control may be regarded as detecting one photographing operation; the operation of multiple quick continuous shooting may refer to that the electronic device detects multiple shooting operations in a shorter time; for example, it may be that the electronic device detects 3 photographing operations in a shorter time, where the 3 photographing operations include an operation of clicking the photographing control for the first time and an operation of bouncing the photographing control for the first time; clicking the photographing control for the second time and bouncing the photographing control for the second time; and clicking the photographing control for the third time and bouncing the photographing control for the third time.
In view of the above, embodiments of the present application provide a photographing processing method and an electronic device; in the embodiment of the application, the electronic equipment performs image processing on the acquired image data packets according to the sequence from the early to the late of the acquisition time to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Fig. 5 is a schematic diagram of a software system of an electronic device according to an embodiment of the present application.
As shown in fig. 5, an application layer 210, an application framework layer 220, a hardware abstraction layer 230, a driver layer 240, and a hardware layer 250 may be included in the system architecture.
Illustratively, the application layer 210 may include a gallery application.
Optionally, the application layer 210 may further include camera applications, calendars, calls, maps, navigation, WLAN, bluetooth, music, video, short messages, etc.
Illustratively, the application framework layer 220 provides an application programming interface (application programming interface, API) and programming framework for application-layer applications; the application framework layer may include some predefined functions.
For example, window manager, content provider, resource manager, notification manager, and view system are included in the application framework layer 220.
Wherein, the window manager is used for managing window programs; the window manager may obtain the display screen size, determine if there are status bars, lock screens, and intercept screens.
The content provider is used to store and retrieve data and make such data accessible to applications. The data may include video, images, audio, calls made and received, browsing history and bookmarks, and phonebooks.
The resource manager provides various resources for the application program, such as localization strings, icons, pictures, layout files, and video files.
The notification manager allows the application to display notification information in a status bar, can be used to communicate notification type messages, can automatically disappear after a short dwell, and does not require user interaction. Such as a notification manager, is used for download completion notification and message alerting. The notification manager may also manage notifications that appear in the system top status bar in the form of charts or scroll bar text, such as notifications for applications running in the background. The notification manager may also manage notifications that appear on the screen in the form of dialog windows, such as prompting text messages in status bars, sounding prompts, vibrating electronic devices, and flashing lights.
The view system includes visual controls, such as controls to display text and controls to display pictures. The view system may be used to build applications. The display interface may be composed of one or more views, for example, a display interface including a text notification icon may include a view displaying text and a view displaying a picture.
Illustratively, the hardware abstraction layer 230 is used to abstract hardware.
For example, the hardware abstraction layer 230 includes a post-processing queue, a frame selection module, and an image processing module; the post-processing queue is used for storing data packets for generating shooting images; the image processing module is used for performing image processing on the data packet selected by the frame selecting module to generate a shooting image; the frame selecting module is used for executing the photographing processing method provided by the embodiment of the application; for example, the frame selection module may be configured to select a data packet from the post-processing queue by using the photographing processing method provided by the embodiment of the present application and transmit the data packet to the image processing module, where the image processing module is configured to perform image processing on the acquired data packet to generate a photographed image.
Illustratively, the driver layer 240 is configured to provide drivers for different hardware devices.
For example, the drive layer may include a display screen drive and a camera drive.
Illustratively, the hardware layer 250 is located at the lowest level of the software system.
For example, the hardware layer 250 may include a display screen and a camera module; the display screen is used for displaying videos; the camera module is used for collecting images.
The photographing processing method provided by the embodiment of the application is described in detail below with reference to fig. 6 to 16.
Fig. 6 is a schematic flowchart of a photographing processing method according to an embodiment of the present application. The method 300 may be performed by the electronic device shown in fig. 1; the method 300 includes S301 to S311, and S301 to S311 are described in detail below, respectively.
It should be understood that the image data queue shown in fig. 6 may refer to the post-processing queue shown in fig. 5 or fig. 7.
S301, detecting a first operation.
The first operation is an operation for indicating the electronic equipment to take a picture.
For example, the electronic device does not detect the shooting operation within a first preset period of time; after the first preset period of time, the photographing operation detected by the electronic device may be referred to as a first operation.
For example, the first operation may include an operation of clicking on the photographing control and an operation of bouncing the photographing control.
Alternatively, the first operation may be a first photographing operation shown in fig. 7, which is not described herein.
S302, responding to a first operation, and acquiring a first data packet.
The first data packet is the data packet with the earliest acquisition time in the image data queue.
Optionally, after the electronic device detects the operation of bouncing the photographing control by the user, the electronic device is triggered to collect the first data packet in response to the operation of bouncing the photographing control.
Illustratively, the first data packet may include M image frames therein; after the electronic equipment detects the operation of bouncing the shooting control by the user, an image sensor in the electronic equipment is triggered to acquire M image frames in response to the operation of bouncing the shooting control.
Illustratively, the first data packet may be acquired in the image data queue according to time information of the first operation; the first data packet may be a data packet corresponding to a first operation, where the first operation is a photographing operation with the earliest photographing time in multiple continuous photographing operations.
Optionally, in one implementation, the first data packet includes a first start frame, the first start frame being used to identify a start position of the first data packet in the image data queue; m frames of image data are included between the first start frame and the first end frame, M being an integer greater than or equal to 1.
Illustratively, as shown in fig. 8, the first data packet may be a data packet 1, and the data packet 1 may include a start frame, an image frame 1, an image frame 2, an image frame N, and an end frame; wherein the start frame is used for identifying the start position of the data packet 1; the end frame is used to identify the end position of the data packet 1.
It should be understood that the first start frame may refer to a header of the first data packet; the first end frame may also refer to the end of the first data packet.
It should also be appreciated that the first data packet may include one image frame or the data packet may include a plurality of image frames; the number of image frames in the first data packet is not limited in the embodiment of the application.
Illustratively, as shown in (a) of fig. 9, the first data packet may be a data packet 1, and the data packet 1 may include a start frame, at least one image frame (e.g., 3 image frames), and an end frame; the initial frame is used for identifying the initial position of the data packet 1 in the post-processing queue; the end frame is used to identify the end position of packet 1 in the post-processing queue.
S303, storing the first data packet in an image data queue.
The data packets stored in the image data queue are used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue.
Optionally, the implementation of S330 may be referred to in the following description of S403 in fig. 7, which is not repeated here.
S304, performing image processing on the first data packet to generate a first shooting image.
Optionally, in one implementation, the M-frame image data is image data of a first color space; the image processing includes processing employing a first algorithm that is an algorithm of a first color space and a second algorithm that is an algorithm that converts an image of the first color space into an image of a second color space.
Alternatively, the image frame in the first data packet may be original image data, i.e. the image frame may be a Raw image; the image processing comprises a first algorithm and a second algorithm; wherein the first algorithm is an algorithm of a first color space; the second algorithm is an algorithm that converts an image of the first color space into an image of the second color space.
Illustratively, the first algorithm is an algorithm of the Raw color space; algorithms for the Raw color space may include, but are not limited to: black level correction processing (Black Level Correction, BLC), lens shading correction (Lens Shading Correction, LSC), and the like.
The black level correction processing is used for correcting the black level, wherein the black level refers to the level of a video signal which is not output by a row of brightness on a display device after a certain calibration; the reason for performing the black level correction is that: on one hand, the dark current exists in the image sensor, so that the pixel also has the problem of voltage output under the condition of no illumination; on the other hand, the accuracy is insufficient when the image sensor performs analog-to-digital conversion. Lens shading correction (Lens Shading Correction, LSC) is used to eliminate problems of color around the image and of brightness not coinciding with the center of the image due to the lens optics.
Illustratively, the second algorithm includes converting the Raw image to an image of a YUV color space; an algorithm to convert the image of YUV color space to other storage formats; other storage formats include JPEG format (JPG format), GIF format, DNG format, or RAW format, among others.
Optionally, the above is an illustration of an image processing algorithm; the above image processing process for the data packet can refer to any existing algorithm for generating a captured image, which is not limited in any way by the present application.
S305, a second operation is detected.
The second operation includes N shooting operations, wherein a time interval of the N shooting operations is smaller than a preset duration, the shooting operations are operations for indicating the electronic equipment to collect images, and N is an integer greater than or equal to 2.
Alternatively, the N photographing operations may include a second photographing operation and a third photographing operation as shown in fig. 7; the implementation may be described with reference to fig. 7, and will not be described in detail herein.
S306, responding to the second operation, and acquiring N data packets.
Wherein, N data packets are in one-to-one correspondence with N shooting operations.
Alternatively, the N data packets may include data packet 2 and data packet 3 as shown in fig. 7; the implementation may be described with reference to fig. 7, and will not be described in detail herein.
S307, N data packets are stored in the image data queue based on the sequence from the early to the late of the acquisition time.
Alternatively, as shown in fig. 9, the data packet 1 may be a first data packet; the N data packets may include data packet 2 and data packet 3; the implementation manner of storing N data packets sequentially from early to late based on the acquisition time may be referred to in the related description of fig. 9, and will not be described in detail here.
S308, after the first shot image is generated, acquiring a second data packet in the image data queue.
The second data packet is the data packet with the latest acquisition time in the image data queue.
Optionally, the first data packet includes a first end frame, the first end frame being used to indicate an end position of the first data packet in the image data queue; after generating the first captured image, acquiring a second data packet in the image data queue, comprising:
acquiring a second data packet at a first moment; the first time is a time of processing the first end frame.
In the embodiment of the application, because the image data queue is a data queue updated in real time based on photographing operation, in order to ensure that the selected second data packet is the data packet with the photographing operation at the latest moment in the image data queue; when processing the first end frame in the first data packet, selecting a second data packet from the image data queue according to the sequence from the late to the early of the data packet acquisition time; thereby improving the accuracy of the selected second data packet.
Optionally, each of the N data packets includes a start frame for indicating a start position of one data packet in the image data queue and an end frame for indicating an end position of one data packet in the image data queue; acquiring a second data packet at a first time, comprising:
determining the position information of a target initial frame in an image data queue at a first moment, wherein the target initial frame is the initial frame with the latest moment in the image data queue;
and acquiring a second data packet based on the position information of the target start frame.
In the embodiment of the present application, since each of the N data packets includes a start frame; thus, when selecting the second data packet in the image data queue in the order from late to early according to the data packet acquisition time, the target start frame (for example, the start frame with the latest acquisition time) in the image data queue, which is the start frame of the second data packet, may be determined in the order from late to early based on the time information; selecting a second data packet in the image data queue based on the target start frame; in the embodiment of the application, the second data packet in the image data queue is selected according to the position of the initial frame of the second data packet, so that the operation amount of the electronic equipment can be reduced to a certain extent.
Optionally, the implementation manner of obtaining the second data packet may be referred to in the following description of fig. 10, which is not repeated herein.
S309, performing the image processing on the second data packet to generate a second shooting image.
Optionally, the N data packets include a second data packet and N-1 data packets, and after generating the second captured image, the method further includes:
acquiring N-1 data packets in an image data queue sequentially according to the sequence from late to early based on the acquisition time of the N-1 data packets;
and sequentially performing image processing on the N-1 data packets to generate N-1 shooting images.
In the embodiment of the present application, after performing image processing on the first data packet and the second data packet (for example, the last data packet) in the image data queue, image processing may be performed on other data packets in the image data queue according to the order from the late to the early of the data packet acquisition time, so as to generate the corresponding captured image.
Alternatively, the implementation manner of generating N-1 captured images may refer to the following description of S4051, S408, or S412 in fig. 7, which is not repeated here.
Optionally, the image processing includes processing using a first algorithm and a second algorithm, the first algorithm being an algorithm of the first color space, the second algorithm being an algorithm of converting an image of the first color space into an image of a second color space.
S310, detecting a third operation.
Wherein the third operation is an operation of clicking on the thumbnail image of the second captured image.
Illustratively, the N photographing operations are illustrated as 3 photographing operations; the electronic equipment detects the first photographing operation, the second photographing operation and the third photographing operation according to the sequence from the early to the late of the photographing time respectively; the third photographing operation is the photographing operation with the latest photographing time, so if the electronic equipment does not detect the photographing operation within a period of time after the third photographing operation, the thumbnail image displayed in the photographing interface of the electronic equipment is the thumbnail image of the third photographing operation; it can be understood that the thumbnail image with the latest photographing operation time is usually displayed in the photographing interface of the electronic device; after the electronic device detects the operation of clicking on the thumbnail image of the third photographing operation, the electronic device may display the photographed image stored in the gallery application, that is, the second photographed image.
For example, an operation of detecting clicking on the thumbnail image of the third photographing operation may be as shown in (f) in 17.
Alternatively, reference may be made to the description of S409 in fig. 7, which is not repeated here.
S311, in response to the third operation, displaying a second captured image.
Alternatively, displaying the second captured image may be displaying the second captured image in a gallery application when the electronic device detects clicking on a thumbnail image of the second captured image; the second shot image refers to a shot image acquired by an operation with the latest shooting time among the N shooting operations.
It should be appreciated that after the user finishes the photographing operation, the user typically views the photographed image by clicking on the thumbnail image; it is understood that the user views the actual captured image stored in the gallery application by clicking on the thumbnail image.
For example, if it is assumed that the duration of processing a data packet by the electronic device is 3 seconds, that is, the duration of generating a shot image by the electronic device is 3 seconds; the duration of collecting one data packet is 1 second; generating a photographing image with the latest photographing moment by adopting an existing mode; for example, if the captured image is generated in a first-acquisition-first-processing manner as shown in fig. 2, the electronic device can generate a second captured image only at 9 seconds; according to the photographing processing method provided by the embodiment of the application, after the electronic equipment generates the first photographed image, the electronic equipment can generate the second photographed image; it can be understood that, according to the photographing processing manner provided by the embodiment of the application, as shown in fig. 7, the electronic device may generate the second photographed image at the 6 th second; therefore, in the embodiment of the application, when the electronic device detects that the user clicks the thumbnail image of the second photographed image, the second photographed image can be displayed quickly; thus shortening the waiting time of the user to a certain extent and improving the shooting experience of the user.
In the embodiment of the application, the electronic equipment can generate the shot image by adopting image processing on the data packets in the image data queue according to the sequence from late to early (for example, the sequence of acquisition and processing before) of the acquisition time, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after processing the data packet of the first operation in the multiple continuous photographing operations, the electronic device may select the second data packet with the latest acquisition time in the stored image data queue to perform image processing, so as to generate a second photographed image; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Optionally, the method shown in fig. 6 is exemplified by the electronic device detecting 3 or more consecutive photographing operations; the embodiment provided by the application is also suitable for the electronic equipment to detect one photographing operation and two continuous photographing operations.
For example, in a scene in which the electronic device detects a photographing operation, only the data packet 1 is included in the post-processing queue in the scene; the electronic device can perform image processing on the data packet 1 firstly, and then perform image processing on the data packet by adopting the mode of acquisition and processing firstly; in the post-processing queue, since the post-processing queue only includes the data packet 1, after the image processing is performed on the data packet 1, the electronic device does not detect other data packets, and the image processing flow may be ended.
For example, in a scenario in which the electronic device detects two consecutive photographing operations, the post-processing queue in the scenario includes only the data packet 1 and the data packet 2; the electronic device can perform image processing on the data packet 1 firstly, and then perform image processing on the data packet by adopting the mode of acquisition and processing firstly; in the post-processing queue, since the post-processing queue only includes the data packet 1 and the data packet 2, after the image processing is performed on the data packet 1, the first data packet in the current post-processing queue is selected according to the direction opposite to the first direction, that is, the image processing is performed on the data packet 2.
Fig. 7 is a schematic flowchart of a photographing processing method according to an embodiment of the present application. The method 400 may be performed by the electronic device shown in fig. 1; the method 400 includes S401 to S412, and S401 to S412 are described in detail below, respectively.
S401, running a camera application program.
Alternatively, the user may instruct the electronic device to run the camera application by clicking on an icon of the "camera" application.
For example, when the electronic device is in a locked state, the user may instruct the electronic device to run the camera application through a gesture that slides to the right on the display screen of the electronic device. Or the electronic equipment is in a screen locking state, the screen locking interface comprises an icon of the camera application program, and the user instructs the electronic equipment to run the camera application program by clicking the icon of the camera application program.
Optionally, the electronic device has the right to invoke the camera application while running other applications; the user may instruct the electronic device to run the camera application by clicking on the corresponding control.
Illustratively, while the electronic device is running an instant messaging type application, the user may instruct the electronic device to run the camera application, etc., by selecting a control for the camera functionality.
It should be appreciated that the above is illustrative of the operation of running a camera application; the camera application program can be run by the voice indication operation or other operation indication electronic equipment; the present application is not limited in any way.
It should also be understood that running the camera application may refer to launching the camera application.
It should be noted that, the photographing processing method of the present application is suitable for at least one scene of continuous photographing; as shown in fig. 8, for one continuous photographing operation, the electronic device may detect N photographing operations such as the first photographing operation, the second photographing operation, and the nth photographing operation; for one photographing operation of the N photographing operations, the electronic device may detect an operation of clicking the photographing control and an operation of bouncing the photographing control.
Alternatively, for the first photographing operation, the electronic device may generate a photographed image, i.e., a photographed true image, based on the single frame image.
Alternatively, for one photographing operation, the electronic device may also generate a photographed image based on the multi-frame image; for example, as shown in fig. 8, the electronic device may generate one photographed image based on N frame images.
S402, a first photographing operation (an example of the first operation) is detected.
For example, the first photographing operation may refer to a first photographing operation detected by the electronic device; for example, within a first preset duration, the electronic device does not detect a shooting operation; after the first preset duration, the photographing operation detected by the electronic device may refer to the first photographing operation.
For example, the first photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control.
S403, storing the data packet of the first photographing operation into a post-processing queue.
Optionally, the electronic device may obtain, in a ZSL queue of the electronic device, a data packet (e.g., data packet 1) of the first photographing operation according to detecting time information of the first photographing operation; and storing the first photographed data packet to a post-processing queue.
Optionally, the first photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control, and when the electronic device detects the operation of bouncing the photographing control, the triggering electronic device may acquire a data packet (for example, the data packet 1) of the first photographing operation in a ZSL queue of the electronic device based on time information of detecting clicking the photographing control; and storing the data packet of the first photographing operation to a post-processing queue.
Illustratively, the data packets of the first photographing operation are stored in a first direction to a post-processing queue.
It should be appreciated that the data packets in the post-processing queue are used to generate a photographed image of the photographing operation, i.e., a real image of the photographing operation; the electronic device further includes a pre-processing queue, wherein the data packets in the pre-processing queue are used for generating thumbnail images of the shooting operation.
S404, acquiring a first data packet in the post-processing queue.
Illustratively, acquiring a data packet of a first photographing operation in a post-processing queue; the first photographing operation may be the photographing operation with the earliest photographing time in the post-processing queue.
It should be noted that, the first data packet may be the data packet stored in the post-processing queue earliest; if the electronic equipment detects the photographing operation for only one time, the post-processing queue only comprises the first data packet; for example, only packet 1 is included in the post-processing queue.
Alternatively, as shown in (a) of fig. 9, the first data packet may be a data packet 1, and the data packet 1 may include a start frame, at least one image frame (e.g., 3 image frames), and an end frame; the initial frame is used for identifying the initial position of the data packet 1 in the post-processing queue; the end frame is used to identify the end position of packet 1 in the post-processing queue.
It should be appreciated that for continuously photographed scenes; after the electronic device detects the first photographing operation (e.g., the first photographing operation), the electronic device also detects a second photographing operation (e.g., the second photographing operation), a third photographing operation (e.g., the third photographing operation), or the like; after the first photographing operation is detected, the electronic equipment performs image processing on the data packet of the first photographing operation to generate a first photographing image; meanwhile, the electronic equipment can continuously update the post-processing queue according to the detected second photographing operation or third photographing operation, and data packets of the follow-up photographing operation are stored in the post-processing queue; the electronic equipment respectively processes the data packets in the post-processing queue to generate shooting images of different shooting operations; and storing the generated shooting images in a gallery application program, and when the electronic equipment detects clicking the thumbnail images, displaying shooting images corresponding to the thumbnail images in the gallery application program by the electronic equipment so as to realize review of the shooting images.
Optionally, the electronic device may execute the first procedure 405 and the second procedure 406 after step S404; wherein the first procedure 405 and the second procedure 406 may be executed synchronously; the first process 450 may refer to a process of generating a photographed image of the first photographing operation by the electronic device, where the first process 405 includes S4051; the second process 406 may refer to a process in which the electronic device detects a photographing operation and updates the post-processing queue in real time based on the photographing operation; the second flow may include S4061 to S4064, exemplified by three photographing operations.
S4051, performing image processing on the first data packet to generate a first shooting image.
The first photographed image may refer to a photographed image corresponding to the first photographing operation, that is, a real image generated by the electronic device based on the first photographing operation.
Illustratively, as shown in fig. 8, the first data packet may be a data packet 1, and the data packet 1 may include a start frame, an image frame 1, an image frame 2, an image frame N, and an end frame; wherein the start frame is used for identifying the start position of the data packet 1; the end frame is used to identify the end position of the data packet 1.
It should be appreciated that the start frame may be the header of the data packet; the end frame may also be the end of packet of the data packet.
Alternatively, in the case where the photographed image is generated based on a single frame image, only the start frame, the image frame 1, and the end frame may be included in the first data packet.
It should be appreciated that a data packet may include one image frame or a plurality of image frames may be included in the data packet; the number of image frames in the data packet is not limited in the embodiments of the present application.
Alternatively, the image frame in the first data packet may be original image data, i.e. the image frame may be a Raw image; the image processing comprises a first algorithm and a second algorithm; wherein the first algorithm is an algorithm of a first color space; the second algorithm is an algorithm that converts an image of the first color space into an image of the second color space.
Illustratively, the first algorithm is an algorithm of the Raw color space; algorithms for the Raw color space may include, but are not limited to: black level correction processing (Black Level Correction, BLC), lens shading correction (Lens Shading Correction, LSC), and the like.
The black level correction processing is used for correcting the black level, wherein the black level refers to the level of a video signal which is not output by a row of brightness on a display device after a certain calibration; the reason for performing the black level correction is that: on one hand, the dark current exists in the image sensor, so that the pixel also has the problem of voltage output under the condition of no illumination; on the other hand, the accuracy is insufficient when the image sensor performs analog-to-digital conversion. Lens shading correction (Lens Shading Correction, LSC) is used to eliminate problems of color around the image and of brightness not coinciding with the center of the image due to the lens optics.
Illustratively, the second algorithm includes converting the Raw image to an image of a YUV color space; an algorithm to convert the image of YUV color space to other storage formats; other storage formats include JPEG format (JPG format), GIF format, DNG format, or RAW format, among others.
Optionally, the above is an illustration of an image processing algorithm; the above image processing process for the data packet can refer to any existing algorithm for generating a captured image, which is not limited in any way by the present application.
S4061, the second photographing operation is detected.
Alternatively, the second photographing operation may refer to detecting the second photographing operation within a second preset time period; the interval duration between the first photographing operation and the second photographing operation is shorter; the electronic device may be in a continuous shooting scene.
For example, the second photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control.
It is to be understood that the second photographing operation is compared with the first photographing operation in S402, and the second photographing operation is after the first photographing operation, and the time at which the electronic device detects the second photographing operation is later than the time at which the first photographing operation is detected.
S4062, storing the data packet of the second photographing operation into a post-processing queue.
Optionally, the electronic device may obtain, in the ZSL queue of the electronic device, a data packet (e.g., data packet 2) of the first photographing operation according to the time information for detecting the second photographing operation; and storing the second photographed data packet to a post-processing queue.
Optionally, the second photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control, and when the electronic device detects the operation of bouncing the photographing control, the triggering electronic device may acquire a data packet (for example, the data packet 2) of the second photographing operation in a ZSL queue of the electronic device based on time information of detecting clicking the photographing control; and storing the second photographed data packet to a post-processing queue.
Illustratively, storing the data packets of the second photographing operation in a first direction to a post-processing queue; for example, according to the first direction, data packet 2 is stored to the left of data packet 1; it will be appreciated that data packet 1 is stored first and then data packet 2 is stored in a first direction.
S4063, a third photographing operation is detected.
Alternatively, the third photographing operation may refer to detecting the third photographing operation within the second preset time period; the interval duration between the second photographing operation and the third photographing operation is shorter; the electronic device may be in a continuous shooting scene.
For example, the third photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control.
It is to be understood that the third photographing operation is compared with the second photographing operation in S461, and the time at which the electronic device detects the third photographing operation is later than the time at which the third photographing operation is detected after the second photographing operation.
S4064, storing the data packet of the third photographing operation into a post-processing queue.
Optionally, the electronic device may obtain, in the ZSL queue of the electronic device, a data packet (e.g., data packet 3) of the first photographing operation according to the time information for detecting the third photographing operation; and storing the data packet of the third shot to a post-processing queue.
Optionally, the third photographing operation may include an operation of clicking the photographing control and an operation of bouncing the photographing control, and when the electronic device detects the operation of bouncing the photographing control, the triggering electronic device may acquire a data packet (e.g., the data packet 3) of the third photographing operation in a ZSL queue of the electronic device based on time information of detecting clicking the photographing control; and storing the data packet of the third shot to a post-processing queue.
Illustratively, storing the data packet of the third photographing operation in the first direction to a post-processing queue; for example, according to the first direction, data packet 3 is stored to the left of data packet 2; it will be appreciated that the data packet 1 is stored first, then the data packet 2 is stored, and then the data packet 3 is stored according to the first direction.
S407, selecting the first data packet in the current post-processing queue according to the opposite direction of the storage direction.
It should be appreciated that the storage direction may be a first direction, as shown in fig. 7, the first direction being a right-to-left direction; the opposite direction of the first direction may refer to the reverse order direction of the first direction; if the first direction is right-to-left, the reverse direction of the first direction may be the left-to-right direction; in addition, if the electronic device processes a packet, the packet may be considered as a dequeue; it can be understood that the data packets stored in the post-processing queue are all unprocessed data packets; the first packet selected in the opposite direction of the storage direction is the packet with the latest photographing operation.
Illustratively, as shown in FIG. 7, since the electronic device performs image processing on the first data packet in the first process 405; therefore, at this time, the unprocessed data packets included in the post-processing queue are the data packet 2 and the data packet 3, and the data packet in the post-processing queue is selected according to the stored reverse order direction, so as to obtain the data packet 3.
Optionally, when processing the end frame in the first data packet, the electronic device may select the first data packet in the current post-processing queue according to the stored reverse order direction.
Illustratively, as shown in (b) of fig. 9, when the electronic device processes an end frame in the first data packet (e.g., an end frame in data packet 1), the current post-processing queue includes data packet 2 and data packet 3; at this time, the electronic device may select the first data packet in the reverse order direction in the current post-processing queue, that is, select the data packet 3; and performs image processing on the data packet 3 to generate a photographed image.
In the embodiment of the application, the electronic equipment performs image processing on the acquired image data packet in a mode of acquisition before processing to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
It should be noted that, in the embodiment of the present application, the method 400 may be applicable to a scene of continuous shooting; thus, the electronic device can detect the photographing operation a plurality of times; the electronic device may also detect other photographing operations while executing S440, and new data packets are continuously stored in the processing queue based on the other photographing operations, as shown in (b) of fig. 9; in the embodiment of the application, after the electronic device processes the first data packet, the electronic device can sequentially process the data packets in the post-processing queue according to a mode of firstly collecting and then processing; the last current data packet is selected from the post-processing queue for processing, so that the shooting waiting time of a user can be shortened to a certain extent.
Optionally, when the end frame in the first data packet is processed, selecting a first start frame in the post-processing queue according to a reverse processing mode, and acquiring a last data packet.
Illustratively, as shown in fig. 10, one continuous photographing operation is exemplified including 3 photographing operations; the electronic equipment detects a first photographing operation, a second photographing operation and a third photographing operation according to the time sequence from front to back respectively; the data packet corresponding to the first photographing operation includes: a start frame, an image frame 1, an image frame 2, an image frame 3 and an end frame; the data packet corresponding to the second photographing operation includes: a start frame, an image frame 3, an image frame 4, an image frame 5 and an end frame; the data packet corresponding to the third photographing operation includes: the starting frame, the image frame 7, the image frame 8, the image frame 9 and the ending frame are data of a third photographing operation stored in a post-processing queue; after the electronic device detects the first photographing operation, the frame selection module instructs, at a first time, that the data packet of the first photographing operation starts dequeuing from the start frame (for example, starts acquiring data from the post-processing queue) through the instruction information 1; at a second moment, the frame selection module indicates that the data packet of the first photographing operation is out of the queue (for example, stopping acquiring data from the post-processing queue) through the indication information 2; at a third moment, the frame selecting module reversely traverses the whole post-processing queue to find the position of a first initial frame, namely the initial frame of a third photographing operation; the data packet of the third photographing operation is instructed to dequeue from the initial frame through the instruction information 3; at the fourth moment, the frame selection module indicates the end of dequeuing of the data packet of the third photographing operation through the indication information 4; at a fifth moment, the frame selecting module reversely traverses the whole post-processing queue to find the position of a first initial frame, namely the initial frame shot for the second time; the data packet of the second photographing operation is instructed to dequeue from the initial frame through the instruction information 5; at the sixth moment, the frame selection module indicates the end of dequeuing of the data packet of the second photographing operation through the indication information 6; the frame selecting module selects the sequence of the data from the post-processing queue as follows: the data packet of the first photographing operation, the data packet of the third photographing operation and the data packet of the second photographing operation.
S408, performing image processing on the selected data packet to generate a second shooting image.
Optionally, as shown in fig. 7, according to the direction opposite to the storage direction, selecting the first data packet in the current post-processing queue as the data packet 3; the data packet 3 is subjected to image processing to generate a second photographed image.
It should be understood that the data packet 3 corresponds to a third photographing operation, i.e., the photographing operation with the latest photographing operation time; the second photographed image is a photographed image generated according to the third photographing operation.
Alternatively, the implementation of the image processing may be referred to the above description of S4051, which is not repeated here.
S409, an operation of clicking on the thumbnail image is detected (one example of the second operation).
It should be understood that, since the electronic device detects the first photographing operation, the second photographing operation, and the third photographing operation in the order from the morning to the evening at the photographing time, respectively; the third photographing operation is the photographing operation with the latest photographing time, so if the electronic equipment does not detect the photographing operation within a period of time after the third photographing operation, the thumbnail image displayed in the photographing interface of the electronic equipment is the thumbnail image of the third photographing operation; it can be understood that the thumbnail image with the latest photographing operation time is usually displayed in the photographing interface of the electronic device; after the electronic device detects the operation of clicking on the thumbnail image of the third photographing operation, the electronic device may display the photographed image stored in the gallery application, that is, the second photographed image.
For example, an operation of detecting clicking on the thumbnail image of the third photographing operation may be as shown in (f) in 17.
S410, displaying the second shot image.
Alternatively, displaying the second photographed image may be displaying the photographed image of the third photographing operation, i.e., the actual photographed image of the third photographing operation, in the gallery application.
It should be appreciated that after the user finishes the photographing operation, the user typically views the photographed image by clicking on the thumbnail image; it is understood that the user views the actual captured image stored in the gallery application by clicking on the thumbnail image.
For example, if it is assumed that the duration of processing a data packet by the electronic device is 3 seconds, that is, the duration of generating a shot image by the electronic device is 3 seconds; the duration of collecting one data packet is 1 second; generating a photographing image with the latest photographing moment by adopting an existing mode; for example, if the captured image is generated in a first-acquisition-first-processing manner as shown in fig. 2, the electronic device can generate a second captured image only at 9 seconds; according to the photographing processing method provided by the embodiment of the application, after the electronic equipment generates the first photographed image, the electronic equipment can generate the second photographed image; it can be understood that, based on the photographing processing manner provided by the embodiment of the present application, as shown in fig. 7, the electronic device may generate the second photographed image at the 6 th second; therefore, in the embodiment of the application, when the electronic device detects that the user clicks the thumbnail image of the second photographed image, the second photographed image can be displayed quickly; thus shortening the waiting time of the user to a certain extent and improving the shooting experience of the user.
In the embodiment of the application, the electronic equipment performs image processing on the acquired image data packet in a mode of acquisition before processing to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
S411, selecting the first data packet in the current post-processing queue according to the opposite direction of the storage direction.
It should be appreciated that the storage direction may be a first direction, as shown in fig. 7, the first direction being a right-to-left direction; the opposite direction of the first direction (e.g., the reverse direction) refers to the opposite direction of the first direction; if the first direction is right-to-left, the reverse direction of the first direction may be the left-to-right direction; in addition, if the electronic device processes a packet, the packet may be considered as a dequeue; it can be understood that the data packets stored in the post-processing queue are all unprocessed data packets; the first data packet selected according to the stored reverse sequence direction refers to the data packet with the latest photographing operation time.
Illustratively, as shown in fig. 7, since the electronic device performs image processing on the first data packet in the first procedure 405, the data packet 3 is subjected to image processing in S408; therefore, at this time, the unprocessed data packet included in the post-processing queue is the data packet 3, and the first data packet in the post-processing queue is selected in the direction opposite to the storage direction, so that the data packet 2 is acquired.
S412, performing image processing on the selected data packet to generate a third shooting image.
Optionally, as shown in fig. 7, selecting the first data packet in the current post-processing queue as the data packet 2 according to the direction opposite to the storage direction; the data packet 2 is subjected to image processing to generate a third photographed image.
It will be appreciated that the data packet 2 corresponds to a second photographing operation, and that the time at which the electronic device detects the second photographing operation is located between the time at which the first photographing operation is detected and the time at which the second photographing operation is detected.
Alternatively, the implementation of the image processing may be referred to the above description of S4051, which is not repeated here.
In the embodiment of the application, the electronic equipment performs image processing on the acquired image data packet in a mode of acquisition before processing to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Alternatively, FIG. 7 is an illustration of the electronic device detecting 3 consecutive photographing operations; the photographing processing method provided by the embodiment of the application is also suitable for scenes in which the electronic equipment detects one photographing operation and two continuous photographing operations.
For example, in a scene in which the electronic device detects a photographing operation, only the data packet 1 is included in the post-processing queue in the scene; the electronic device can perform image processing on the data packet 1 firstly, and then perform image processing on the data packet by adopting the mode of acquisition and processing firstly; in the post-processing queue, since the post-processing queue only includes the data packet 1, after the image processing is performed on the data packet 1, the electronic device does not detect other data packets, and the image processing flow may be ended.
For example, in a scenario in which the electronic device detects two consecutive photographing operations, the post-processing queue in the scenario includes only the data packet 1 and the data packet 2; the electronic device can perform image processing on the data packet 1 firstly, and then perform image processing on the data packet by adopting the mode of acquisition and processing firstly; in the post-processing queue, since the post-processing queue only includes the data packet 1 and the data packet 2, after the image processing is performed on the data packet 1, the first data packet in the current post-processing queue is selected according to the direction opposite to the storage direction, that is, the image processing is performed on the data packet 2.
Alternatively, a photographing operation in which the electronic device detects three or more consecutive times is exemplified below with reference to fig. 11 to 16.
Example one
Optionally, when the electronic device detects a continuous photographing operation, the electronic device may select, according to a direction opposite to a storage direction of the data packet in the post-processing queue, a current first data packet in the post-processing queue for performing image processing, to generate a photographed image; therefore, the electronic equipment can be ensured to rapidly process the shooting images with the shooting time later, so that the electronic equipment can rapidly generate the shooting images after detecting continuous shooting operation; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
For example, the data packet of the first photographing operation in the continuous photographing operation in the post-processing queue may be processed first; after processing the data packet of the first photographing operation in the continuous photographing operation, processing the data packet with the latest time in the continuous photographing operation; sequentially processing data packets of different shooting operations from back to front according to a time sequence; the electronic equipment is ensured to be capable of rapidly processing the shooting images with the shooting time later, so that the electronic equipment can rapidly generate shooting images after detecting continuous shooting operation; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Illustratively, as shown in fig. 11, the continuous photographing operation is exemplified to include 5 photographing operations; generating 5 shooting images corresponding to 5 shooting operations, wherein the shooting images are a shooting image 1, a shooting image 2, a shooting image 3, a shooting image 4 and a shooting image 5 respectively; the data packet collected by the electronic equipment for the first shooting operation is a data packet 1; the data packet collected by the electronic equipment is shot for the second time and is a data packet 2; the data packet collected by the electronic equipment for the third shooting operation is a data packet 3; the fourth shooting operation is carried out, and the data packet acquired by the electronic equipment is a data packet 4; the fifth shooting operation is carried out on the data packet 5 collected by the electronic equipment; as shown in fig. 12, assume that the electronic device needs to process one data packet for 3 seconds; the duration of collecting one data packet is 0.1 second, namely, 1 second can collect data of 10 photographing operations; then at a first time (e.g., 0.1 seconds), the electronic device collects data packet 1; performing image processing on the data packet 1 to generate a shooting image 1; the electronic device finishes processing the data packet 1 in the 3.1 th second; at this time, since the electronic device collects the image data of one photographing operation for 0.1 seconds, the electronic device detects 5 photographing operations; the electronic device collects 5 data packets at 0.5 seconds; at a second time (e.g., 3.1 seconds), the electronic device obtains a first packet, i.e., packet 5, in the current post-processing queue in a reverse order direction; the electronic equipment performs image processing on the data packet 5 to generate a shooting image 5; repeatedly executing the above operation, after the shot image 5 is generated, the electronic device acquires the first data packet, namely the data packet 4, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 4 to generate a shooting image 4; after the shot image 4 is generated, the electronic equipment acquires a first data packet, namely a data packet 3, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 3 to generate a shooting image 3; after the shot image 3 is generated, the electronic equipment acquires a first data packet, namely a data packet 2, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 2 to generate a shooting image 2; at this time, the electronic apparatus generates a captured image 1, a captured image 2, a captured image 3, a captured image 4, and a captured image 5.
It should be noted that, acquiring a data packet of the post-processing queue, and performing image processing on the data packet may be regarded as removing the post-processing queue from the data packet; the electronic equipment can acquire new data packets based on the detected photographing operation when processing the data packets in the post-processing queue; therefore, the data packets in the post-processing queue can be regarded as being in a real-time update state, i.e. having newly written data packets and also having shifted-out data packets; when the packet tail of the previous data packet is processed, the first data packet in the current post-processing queue according to the reverse sequence direction can be selected; the reverse order is understood to be the opposite direction of the data packets stored in the post-processing queue.
Optionally, the implementation manner of the electronic device to obtain the first data packet in the current post-processing queue according to the reverse order direction may refer to the descriptions related to fig. 9 and fig. 10, which are not repeated herein.
Example two
Optionally, when the electronic device detects at least continuous photographing operation, the electronic device may select, according to an opposite direction of the data packet stored in the post-processing queue, a current first data packet in the post-processing queue for image processing, to generate a photographed image; therefore, the electronic equipment can be ensured to rapidly process the shooting images with the shooting time later, so that the electronic equipment can rapidly generate the shooting images after detecting continuous shooting operation; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Case one
For example, an illustration is made with the electronic device detecting two consecutive photographing operations, wherein the first consecutive photographing operation includes 5 photographing operations; for example, the first continuous photographing operation includes a first photographing operation to a fifth photographing operation; the second continuous photographing operation includes 2 photographing operations; for example, the second continuous photographing operation includes a sixth photographing operation and a seventh photographing operation; as shown in fig. 13, 7 shooting operations correspondingly generate 7 shooting images, namely shooting image 1, shooting image 2, shooting image 3, shooting image 4, shooting image 5, shooting image 6 and shooting image 7; the data packet collected by the electronic equipment for the first shooting operation is a data packet 1; the data packet collected by the electronic equipment is shot for the second time and is a data packet 2; the data packet collected by the electronic equipment for the third shooting operation is a data packet 3; the fourth shooting operation is carried out, and the data packet acquired by the electronic equipment is a data packet 4; the fifth shooting operation is carried out on the data packet 5 collected by the electronic equipment; a data packet 6 is a data packet acquired by the electronic equipment in the sixth shooting operation; the seventh shooting operation is performed on the data packet 7 acquired by the electronic device, as shown in fig. 14.
As shown in fig. 13 and 14, at a first moment, the electronic device acquires a first data packet in a post-processing queue according to a direction opposite to a storage direction (for example, a reverse order direction) of the data packet for image processing; for example, at a first moment, the electronic device acquires the data packet 1 to perform image processing, and generates a photographed image 1; the method comprises the steps that when the electronic equipment performs image processing on a data packet 1, based on photographing operation detected by the electronic equipment, the data packet 2 to the data packet 5 are stored in a post-processing queue; at the second moment, when the electronic equipment processes the end frame in the data packet 1, the electronic equipment acquires a first data packet, namely the data packet 5, in a post-processing queue according to the opposite direction of the storage direction of the data packet; the electronic equipment performs image processing on the data packet 5 to generate a shooting image 5; at a third moment, when the electronic equipment processes the end frame in the data packet 5, the electronic equipment acquires a first data packet, namely a data packet 7, in a post-processing queue according to the opposite direction of the storage direction; the electronic equipment performs image processing on the data packet 7 to generate a shooting image 7; repeatedly executing the above operation, after the shot image 7 is generated, the electronic device acquires the first data packet, namely the data packet 6, in the post-processing queue in the opposite direction to the storage direction of the data packet; the electronic equipment performs image processing on the data packet 6 to generate a shooting image 6; after the shot image 6 is generated, that is, when the electronic device processes to an end frame in the data packet 6, the electronic device acquires a first data packet, that is, the data packet 4, from the current post-processing queue according to the direction opposite to the storage direction; the electronic equipment performs image processing on the data packet 4 to generate a shooting image 4; after the shot image 4 is generated, the electronic device acquires a first data packet, namely a data packet 3, in the current post-processing queue according to the opposite direction of the storage direction of the data packet in the post-processing queue; the electronic equipment performs image processing on the data packet 3 to generate a shooting image 3; after the shot image 3 is generated, the electronic device acquires a first data packet, namely a data packet 2, in a post-processing queue according to the opposite direction of the storage direction of the data packet; the electronic equipment performs image processing on the data packet 2 to generate a shooting image 2; at this time, the electronic apparatus generates a captured image 1, a captured image 2, a captured image 3, a captured image 4, a captured image 5, a captured image 6, and a captured image 7.
It should be understood that, when the electronic device processes the end frame of the current data packet, the electronic device may acquire the first data packet in the post-processing queue according to the direction opposite to the storage direction of the data packet; it can be understood that, when the electronic device processes the tail of the last data packet, the electronic device can select the data packet processed next time from the post-processing queue; selecting according to the sequence from back to front of shooting time during selecting; i.e. the electronic device preferentially selects the data packet with the last shooting time.
Optionally, the implementation manner of the electronic device to obtain the first data packet in the current post-processing queue according to the reverse order direction may refer to the descriptions related to fig. 9 and fig. 10, which are not repeated herein.
Case two
For example, an illustration is made with the electronic device detecting two consecutive photographing operations, wherein the first consecutive photographing operation includes 5 photographing operations; for example, the first continuous photographing operation includes a first photographing operation to a fifth photographing operation; the second continuous photographing operation includes 2 photographing operations; for example, the second continuous photographing operation includes a sixth photographing operation and a seventh photographing operation; as shown in fig. 15, 7 shooting operations correspondingly generate 7 shooting images, namely shooting image 1, shooting image 2, shooting image 3, shooting image 4, shooting image 5, shooting image 6 and shooting image 7; the data packet collected by the electronic equipment for the first shooting operation is a data packet 1; the data packet collected by the electronic equipment is shot for the second time and is a data packet 2; the data packet collected by the electronic equipment for the third shooting operation is a data packet 3; the fourth shooting operation is carried out, and the data packet acquired by the electronic equipment is a data packet 4; the fifth shooting operation is carried out on the data packet 5 collected by the electronic equipment; a data packet 6 is a data packet acquired by the electronic equipment in the sixth shooting operation; the seventh shooting operation is performed on the data packet collected by the electronic device as a data packet 7, as shown in fig. 16.
As shown in fig. 15 and fig. 16, at a first moment, the electronic device acquires a first data packet in an inverse order direction in the post-processing queue for image processing; for example, at a first moment, the electronic device acquires the data packet 1 to perform image processing, and generates a photographed image 1; the electronic equipment performs image processing on the data packet 1, and simultaneously stores the data packets 2 to 7 in a post-processing queue based on photographing operation detected by the electronic equipment; at the second moment, when the electronic equipment processes the end frame in the data packet 1, the electronic equipment acquires a first data packet, namely a data packet 7, in the post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 7 to generate a shooting image 7; repeatedly executing the above operation, after the shot image 7 is generated, the electronic device acquires the first data packet, namely the data packet 6, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 6 to generate a shooting image 6; after the shot image 6 is generated, that is, when the electronic device processes to an end frame in the data packet 6, the electronic device acquires a first data packet, that is, the data packet 5, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 5 to generate a shooting image 5; after the shot image 5 is generated, the electronic device acquires a first data packet, namely a data packet 4, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 4 to generate a shooting image 4; after the shot image 4 is generated, the electronic equipment acquires a first data packet, namely a data packet 3, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 3 to generate a shooting image 3; after the shot image 3 is generated, the electronic equipment acquires a first data packet, namely a data packet 2, from the current post-processing queue according to the reverse sequence direction; the electronic equipment performs image processing on the data packet 2 to generate a shooting image 2; at this time, the electronic apparatus generates a captured image 1, a captured image 2, a captured image 3, a captured image 4, a captured image 5, a captured image 6, and a captured image 7.
Optionally, the implementation manner of the electronic device to obtain the first data packet in the current post-processing queue according to the reverse order direction may refer to the descriptions related to fig. 9 and fig. 10, which are not repeated herein.
It should be noted that, the second case is different from the first case in that: in the first case, after the electronic device processes the data packet 1, the post-processing queue includes the data packets 2 to 5, and at this time, the electronic device acquires the first data packet in the post-processing queue according to the opposite direction of the storage direction of the data packet, that is, acquires the data packet 5; in the second case, after the electronic device processes the data packet 1, the post-processing queue includes the data packets 2 to 7, and at this time, the electronic device acquires the first data packet in the post-processing queue according to the opposite direction of the storage direction of the data packet, that is, acquires the data packet 7; the reason for the above is that there may be a difference in the time intervals of different photographing operations at the time of continuous photographing operations of the electronic apparatus; because of the difference in time intervals, the image data stored in the post-processing queues in the electronic device may be different.
In the embodiment of the application, the electronic equipment performs image processing on the acquired image data packet in a mode of acquisition before processing to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
Interface schematic diagrams suitable for use in embodiments of the present application are described in detail below in conjunction with fig. 17-20.
Illustratively, after the electronic device runs the camera application, a preview interface 501 is displayed, as shown in (a) in fig. 17; the preview interface 501 comprises a preview image, a photographing control 502 and a thumbnail display control 503, wherein the image displayed in the thumbnail display control 503 is the thumbnail image photographed last time; the electronic equipment detects a plurality of rapid continuous shooting operations; for example, the electronic device detects an operation of clicking the photographing control 502, as shown in (b) in fig. 17; after the electronic device detects the operation of clicking the photographing control 502, the electronic device detects the operation of bouncing the photographing control 502, and displays a display interface 504, as shown in (c) in fig. 17; after the electronic device detects the operation of bouncing the photographing control 502, the electronic device detects the operation of clicking the photographing control 502, as shown in (d) in fig. 17; after the electronic device detects the operation of clicking the photographing control 502, the electronic device detects the operation of bouncing the photographing control 502, as shown in (e) in fig. 17; after the electronic device detects the operation of bouncing the photographing control 502, the electronic device detects the operation of clicking the thumbnail display control 503, as shown in (f) in fig. 17; after the electronic device detects the operation of clicking on the thumbnail display control 503, the electronic device may display a display interface in a gallery application, as shown in fig. 18.
It should be noted that, as can be seen from fig. 4 (b) to fig. 4 (d), fig. 17 (f) and fig. 18, in the photographing processing method provided by the embodiment of the application, the electronic device performs image processing on the continuously photographed data packet by a method of first collecting and then processing, so that the waiting time for generating the photographed image can be shortened when the operation of clicking the thumbnail image is detected; it can be understood that the electronic device can preferentially process the data packet with the latest shooting time, so that the waiting time after the electronic device is detected to click the thumbnail display control can be shortened on a certain program; and the shooting experience of the user is improved.
An interface schematic diagram of the electronic device for displaying a shot image quickly after starting up the electronic device, i.e. executing the shooting processing method according to the embodiment of the present application, is described below with reference to fig. 19 and 20.
In one example, after the electronic device detects the operation of clicking on the intelligent control 610 as shown in (b) in fig. 19, the electronic device performs the photographing processing method provided by the embodiment of the present application.
Illustratively, after the electronic device runs the camera application, a preview interface as shown in (a) in fig. 19 is displayed; in the preview interface, a preview image is included with the intelligent control 610; the electronic device detects an operation of clicking on the smart control 610, as shown in (b) of fig. 19; after the electronic device detects the operation of clicking the intelligent control 610, the photographing processing method provided by the embodiment of the application is executed.
In one example, after the electronic device detects the operation of clicking the control 630 as shown in (d) of fig. 20, the electronic device executes the photographing processing method provided by the embodiment of the present application.
Illustratively, after the camera application is run in the electronic device, a preview interface as shown in (a) in fig. 20 may be displayed; the preview interface includes a preview image and a setting control 620; the electronic device detects an operation of clicking the setting control 620, as shown in (b) in fig. 20; after the electronic device detects the operation of clicking the setting control 620, a setting interface is displayed, as shown in (c) in fig. 20; the setting interface includes a control 630 for rapidly displaying the photographed image; the electronic device detects clicking on the control 630 for quick display of the captured image, as shown in fig. 20 (d); after the electronic device detects the operation of the control 630 for quickly displaying the shot image, the shooting processing method provided by the embodiment of the application is executed.
In the embodiment of the application, the electronic equipment performs image processing on the acquired image data packet in a mode of acquisition before processing to generate the shot image, so that the time between the detection of clicking the thumbnail image by the electronic equipment and the display of the shot image can be shortened to a certain extent; it can be understood that, after the electronic device processes the data packet of the first photographing operation in the continuous photographing operation, the electronic device may select the first data packet in the reverse sequence direction in the stored image data queue to perform image processing, that is, acquire the data packet with the latest photographing time to perform image processing; therefore, the electronic equipment can be ensured to rapidly process the shooting image with the shooting time later, so that the shooting image can be rapidly displayed after the electronic equipment detects the operation of clicking the thumbnail image; the method and the device can shorten the time for the user to wait for shooting the image to a certain extent, and improve the shooting experience of the user.
It should be understood that the above description is intended to aid those skilled in the art in understanding the embodiments of the present application, and is not intended to limit the embodiments of the present application to the specific values or particular scenarios illustrated. It will be apparent to those skilled in the art from the foregoing description that various equivalent modifications or variations can be made, and such modifications or variations are intended to be within the scope of the embodiments of the present application.
The photographing processing method provided by the embodiment of the application is described in detail above with reference to fig. 1 to 20; an embodiment of the device of the present application will be described in detail with reference to fig. 21 to 22. It should be understood that the apparatus in the embodiments of the present application may perform the methods of the foregoing embodiments of the present application, that is, specific working procedures of the following various products may refer to corresponding procedures in the foregoing method embodiments.
Fig. 21 is a schematic structural diagram of an electronic device according to an embodiment of the present application. The electronic device 700 includes a processing module 710 and a display module 720.
The processing module 710 is configured to detect a first operation, where the first operation is an operation for indicating that the electronic device photographs; responding to the first operation, and acquiring a first data packet; storing the first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue; performing image processing on the first data packet to generate a first shooting image; detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than a preset duration, the shooting operations are operations for indicating the electronic equipment to acquire images, and N is an integer greater than or equal to 2; responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with the N shooting operations; storing the N data packets in the image data queue based on the sequence from the early to the late of the acquisition time; after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is a data packet with the latest acquisition time in the image data queue; performing the image processing on the second data packet to generate a second shooting image; detecting a third operation, wherein the third operation is an operation of clicking on a thumbnail image of the second shooting image; the display module 720 is configured to display the second captured image in response to the third operation.
Optionally, as an embodiment, the N data packets include the second data packet and N-1 data packets, and the processing module 710 is further configured to:
sequentially acquiring N-1 data packets in the image data queue according to the sequence from late to early based on the acquisition time of the N-1 data packets;
and sequentially carrying out image processing on the N-1 data packets to generate N-1 shooting images.
Optionally, as an embodiment, the first data packet includes a first end frame, where the first end frame is used to indicate an end position of the first data packet in the image data queue; the processing module 710 is specifically configured to:
acquiring the second data packet at a first time; wherein the first time is a time of processing the first end frame.
Optionally, as an embodiment, each data packet in the N data packets includes a start frame and an end frame, where the start frame is used to indicate a start position of one data packet in the image data queue, and the end frame is used to indicate an end position of one data packet in the image data queue; the processing module 710 is specifically configured to:
determining the position information of a target initial frame in the image data queue at the first moment, wherein the target initial frame is the initial frame with the latest moment in the image data queue;
And acquiring the second data packet based on the position information of the target initial frame.
Optionally, as an embodiment, the first data packet includes a first start frame, where the first start frame is used to identify a start position of the first data packet in the image data queue; m frames of image data are included between the first starting frame and the first ending frame, and M is an integer greater than or equal to 1.
Optionally, as an embodiment, the M-frame image data is image data of a first color space; the image processing includes processing employing a first algorithm that is an algorithm of the first color space and a second algorithm that is an algorithm that converts an image of the first color space into an image of a second color space.
Alternatively, as an embodiment, the N photographing operations are consecutive photographing operations.
Optionally, as an embodiment, the n+1 data packets in the image data queue are data packets acquired in a zero second delay queue based on time information of the first operation and time information of the second operation.
The electronic device 700 is embodied as a functional module. The term "module" herein may be implemented in software and/or hardware, and is not specifically limited thereto.
For example, a "module" may be a software program, a hardware circuit, or a combination of both that implements the functionality described above. The hardware circuitry may include application specific integrated circuits (application specific integrated circuit, ASICs), electronic circuits, processors (e.g., shared, proprietary, or group processors, etc.) and memory for executing one or more software or firmware programs, merged logic circuits, and/or other suitable components that support the described functions.
Thus, the elements of the examples described in the embodiments of the present application can be implemented in electronic hardware, or in a combination of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
Fig. 22 shows a schematic structural diagram of an electronic device provided by the present application. The dashed line in fig. 22 indicates that the unit or the module is optional; the electronic device 800 may be used to implement the photographing processing method described in the above method embodiment.
The electronic device 800 includes one or more processors 801, which one or more processors 801 may support the electronic device 800 to implement the photographing processing method in the method embodiments. The processor 801 may be a general purpose processor or a special purpose processor. For example, the processor 801 may be a central processing unit (central processing unit, CPU), digital signal processor (digital signal processor, DSP), application specific integrated circuit (application specific integrated circuit, ASIC), field programmable gate array (field programmable gate array, FPGA), or other programmable logic device such as discrete gates, transistor logic, or discrete hardware components.
Alternatively, the processor 801 may be used to control the electronic device 800, execute software programs, and process data for the software programs. The electronic device 800 may also include a communication unit 805 to enable input (reception) and output (transmission) of signals.
For example, the electronic device 800 may be a chip, the communication unit 805 may be an input and/or output circuit of the chip, or the communication unit 805 may be a communication interface of the chip, which may be an integral part of a terminal device or other electronic device.
For another example, the electronic device 800 may be a terminal device, the communication unit 805 may be a transceiver of the terminal device, or the communication unit 805 may include one or more memories 802 in the communication unit 800, on which a program 804 is stored, the program 804 being executable by the processor 801 to generate the instructions 803, so that the processor 801 performs the photographing processing method described in the above method embodiment according to the instructions 803.
Optionally, the memory 802 may also have data stored therein.
Optionally, processor 801 may also read data stored in memory 802, which may be stored at the same memory address as program 804, or which may be stored at a different memory address than program 804.
Alternatively, the processor 801 and the memory 802 may be provided separately or may be integrated together, for example, on a System On Chip (SOC) of the terminal device.
Illustratively, the memory 802 may be used to store a related program 804 of the photographing processing method provided in the embodiment of the present application, and the processor 801 may be used to call the related program 804 of the photographing processing method stored in the memory 802 when executing the photographing processing method, to execute the photographing processing method of the embodiment of the present application; for example, a first operation is detected, the first operation being an operation of instructing the electronic device to take a picture; responding to a first operation, and acquiring a first data packet; storing a first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue; performing image processing on the first data packet to generate a first shooting image; detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than the preset duration, the shooting operations are operations for indicating the electronic equipment to collect images, and N is an integer greater than or equal to 2; responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with N shooting operations; storing N data packets in an image data queue based on the sequence from the early to the late of the acquisition time; after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is the data packet with the latest acquisition time in the image data queue; performing image processing on the second data packet to generate a second shooting image; detecting a third operation, which is an operation of clicking on the thumbnail image of the second captured image; in response to the third operation, the second captured image is displayed.
Optionally, the present application also provides a computer program product, which when executed by the processor 801, implements the photographing processing method in any of the method embodiments of the present application.
For example, the computer program product may be stored in the memory 802, such as program 804, with the program 804 ultimately being converted into an executable object file that can be executed by the processor 801 via preprocessing, compiling, assembling, and linking processes.
Optionally, the present application further provides a computer readable storage medium having stored thereon a computer program which, when executed by a computer, implements the photographing processing method of any of the method embodiments of the present application. The computer program may be a high-level language program or an executable object program.
For example, the computer-readable storage medium is, for example, memory 802. The memory 802 may be volatile memory or nonvolatile memory, or the memory 802 may include both volatile and nonvolatile memory. The nonvolatile memory may be a read-only memory (ROM), a Programmable ROM (PROM), an Erasable PROM (EPROM), an electrically Erasable EPROM (EEPROM), or a flash memory. The volatile memory may be random access memory (random access memory, RAM) which acts as an external cache. By way of example, and not limitation, many forms of RAM are available, such as Static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDR SDRAM), enhanced SDRAM (ESDRAM), synchronous DRAM (SLDRAM), and direct memory bus RAM (DR RAM).
Those of ordinary skill in the art will appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as electronic hardware, or combinations of computer software and electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
It will be clear to those skilled in the art that, for convenience and brevity of description, specific working procedures of the above-described systems, apparatuses and units may refer to corresponding procedures in the foregoing method embodiments, and are not repeated herein.
In the several embodiments provided by the present application, it should be understood that the disclosed systems, devices, and methods may be implemented in other manners. For example, the above-described embodiments of the electronic device are merely illustrative, e.g., the division of modules is merely a logical functional division, and there may be additional divisions when actually implemented, e.g., multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be an indirect coupling or communication connection via some interfaces, devices or units, which may be in electrical, mechanical or other form.
The units described as separate units may or may not be physically separate, and units shown as units may or may not be physical units, may be located in one place, or may be distributed over a plurality of network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
In addition, each functional unit in the embodiments of the present application may be integrated in one processing unit, or each unit may exist alone physically, or two or more units may be integrated in one unit.
It should be understood that, in various embodiments of the present application, the size of the sequence number of each process does not mean that the execution sequence of each process should be determined by its functions and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
In addition, the term "and/or" herein is merely an association relation describing an association object, and means that three kinds of relations may exist, for example, a and/or B may mean: a exists alone, A and B exist together, and B exists alone. In addition, the character "/" herein generally indicates that the front and rear associated objects are an "or" relationship.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application may be embodied essentially or in a part contributing to the prior art or in a part of the technical solution in the form of a software product stored in a storage medium, comprising several instructions for causing a computer device (which may be a personal computer, a server, a network device, etc.) to perform all or part of the steps of the method of the embodiments of the present application. And the aforementioned storage medium includes: a U-disk, a removable hard disk, a read-only memory (ROM), a random access memory (random access memory, RAM), a magnetic disk, or an optical disk, or other various media capable of storing program codes.
The foregoing is merely illustrative embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily think about variations or substitutions within the technical scope of the present application, and the application should be covered. Therefore, the protection scope of the present application should be defined by the claims, and the above description is only a preferred embodiment of the technical solution of the present application, and is not intended to limit the protection scope of the present application. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the protection scope of the present application.

Claims (11)

1. A photographing processing method, characterized in that it is applied to an electronic device, comprising:
detecting a first operation, wherein the first operation is an operation for indicating the electronic equipment to take a picture;
responding to the first operation, and acquiring a first data packet;
storing the first data packet in an image data queue, wherein the data packet stored in the image data queue is used for generating a shooting image, and the first data packet is the data packet with the earliest acquisition time in the image data queue;
performing image processing on the first data packet to generate a first shooting image;
detecting a second operation, wherein the second operation comprises N times of shooting operations, the time interval of the N times of shooting operations is smaller than a preset duration, the shooting operations are operations for indicating the electronic equipment to acquire images, and N is an integer greater than or equal to 2;
responding to the second operation, acquiring N data packets, wherein the N data packets are in one-to-one correspondence with the N shooting operations;
storing the N data packets in the image data queue based on the sequence from the early to the late of the acquisition time;
after the first shooting image is generated, a second data packet in the image data queue is acquired, wherein the second data packet is a data packet with the latest acquisition time in the image data queue;
Performing the image processing on the second data packet to generate a second shooting image;
detecting a third operation, wherein the third operation is an operation of clicking on a thumbnail image of the second shooting image;
and displaying the second photographed image in response to the third operation.
2. The photographing processing method of claim 1, wherein the N data packets include the second data packet and N-1 data packets, and further comprising, after generating the second photographed image:
sequentially acquiring N-1 data packets in the image data queue according to the sequence from late to early based on the acquisition time of the N-1 data packets;
and sequentially carrying out image processing on the N-1 data packets to generate N-1 shooting images.
3. The photographing processing method according to claim 1 or 2, wherein the first data packet includes a first end frame for indicating an end position of the first data packet in the image data queue; the step of acquiring the second data packet in the image data queue after the step of generating the first photographed image includes:
acquiring the second data packet at a first time; wherein the first time is a time of processing the first end frame.
4. A photographing processing method as claimed in claim 3, wherein each of said N data packets comprises a start frame for indicating a start position of a data packet in said image data queue and an end frame for indicating an end position of a data packet in said image data queue; the obtaining the second data packet at the first time includes:
determining the position information of a target initial frame in the image data queue at the first moment, wherein the target initial frame is the initial frame with the latest moment in the image data queue;
and acquiring the second data packet based on the position information of the target initial frame.
5. The photographing processing method as claimed in claim 3 or 4, wherein the first data packet includes a first start frame for identifying a start position of the first data packet in the image data queue; m frames of image data are included between the first starting frame and the first ending frame, and M is an integer greater than or equal to 1.
6. The photographing processing method according to any one of claims 2 to 5, characterized in that the image processing includes a process employing a first algorithm which is an algorithm of a first color space and a second algorithm which is an algorithm of converting an image of the first color space into an image of a second color space.
7. The photographing processing method according to any one of claims 1 to 6, characterized in that the N photographing operations are consecutive photographing operations.
8. The photographing processing method according to any one of claims 1 to 7, characterized in that n+1 data packets in the image data queue are data packets acquired in a zero second delay queue based on time information of the first operation and time information of the second operation.
9. An electronic device, comprising:
one or more processors and memory;
the memory is coupled with the one or more processors, the memory is for storing computer program code, the computer program code comprising computer instructions that the one or more processors call to cause the electronic device to perform the photo processing method of any one of claims 1 to 8.
10. A chip system for application to an electronic device, the chip system comprising one or more processors for invoking computer instructions to cause the electronic device to perform the photographic processing method of any one of claims 1 to 8.
11. A computer-readable storage medium, characterized in that the computer-readable storage medium stores a computer program, which when executed by a processor, causes the processor to execute the photographing processing method of any one of claims 1 to 8.
CN202211468036.3A 2022-11-22 2022-11-22 Photographing processing method and electronic equipment Active CN116668836B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211468036.3A CN116668836B (en) 2022-11-22 2022-11-22 Photographing processing method and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211468036.3A CN116668836B (en) 2022-11-22 2022-11-22 Photographing processing method and electronic equipment

Publications (2)

Publication Number Publication Date
CN116668836A true CN116668836A (en) 2023-08-29
CN116668836B CN116668836B (en) 2024-04-19

Family

ID=87710564

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211468036.3A Active CN116668836B (en) 2022-11-22 2022-11-22 Photographing processing method and electronic equipment

Country Status (1)

Country Link
CN (1) CN116668836B (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20050075870A (en) * 2004-01-16 2005-07-25 삼성테크윈 주식회사 Digital camera saving and loading image mode information and method therefor
CN1756301A (en) * 2004-09-30 2006-04-05 英保达股份有限公司 Image broadcast system and method
JP2009302902A (en) * 2008-06-13 2009-12-24 Nikon Corp Camera
CN104754223A (en) * 2015-03-12 2015-07-01 广东欧珀移动通信有限公司 Method for generating thumbnail and shooting terminal
CN111567033A (en) * 2019-05-15 2020-08-21 深圳市大疆创新科技有限公司 Shooting device, unmanned aerial vehicle, control terminal and shooting method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20050075870A (en) * 2004-01-16 2005-07-25 삼성테크윈 주식회사 Digital camera saving and loading image mode information and method therefor
CN1756301A (en) * 2004-09-30 2006-04-05 英保达股份有限公司 Image broadcast system and method
JP2009302902A (en) * 2008-06-13 2009-12-24 Nikon Corp Camera
CN104754223A (en) * 2015-03-12 2015-07-01 广东欧珀移动通信有限公司 Method for generating thumbnail and shooting terminal
CN111567033A (en) * 2019-05-15 2020-08-21 深圳市大疆创新科技有限公司 Shooting device, unmanned aerial vehicle, control terminal and shooting method

Also Published As

Publication number Publication date
CN116668836B (en) 2024-04-19

Similar Documents

Publication Publication Date Title
CN114205522B (en) Method for long-focus shooting and electronic equipment
WO2023015981A1 (en) Image processing method and related device therefor
CN113824873B (en) Image processing method and related electronic equipment
WO2021190613A9 (en) Photographic method and device
CN113660408B (en) Anti-shake method and device for video shooting
CN116744120B (en) Image processing method and electronic device
WO2021185374A1 (en) Image capturing method and electronic device
CN115633262B (en) Image processing method and electronic device
WO2023142830A1 (en) Camera switching method, and electronic device
WO2023124202A1 (en) Image processing method and electronic device
CN116668836B (en) Photographing processing method and electronic equipment
CN115767290A (en) Image processing method and electronic device
CN116668837B (en) Method for displaying thumbnail images and electronic device
CN116723383B (en) Shooting method and related equipment
WO2023035868A1 (en) Photographing method and electronic device
CN115767262B (en) Photographing method and electronic equipment
CN114531539B (en) Shooting method and electronic equipment
CN117135448A (en) Shooting method and electronic equipment
WO2023160224A9 (en) Photographing method and related device
CN117082339A (en) Shooting mode switching method and device, electronic equipment and readable storage medium
CN117156261A (en) Image processing method and related equipment
CN116419067A (en) Shooting method, electronic device and readable storage medium
CN117133252A (en) Image processing method and electronic device
CN117560574A (en) Shooting method, electronic equipment and readable storage medium
CN117119285A (en) Shooting method

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant