CN113518189B - Shooting method, shooting system, electronic equipment and storage medium - Google Patents

Shooting method, shooting system, electronic equipment and storage medium Download PDF

Info

Publication number
CN113518189B
CN113518189B CN202010275152.8A CN202010275152A CN113518189B CN 113518189 B CN113518189 B CN 113518189B CN 202010275152 A CN202010275152 A CN 202010275152A CN 113518189 B CN113518189 B CN 113518189B
Authority
CN
China
Prior art keywords
image
equipment
electronic device
electronic equipment
wearable
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.)
Active
Application number
CN202010275152.8A
Other languages
Chinese (zh)
Other versions
CN113518189A (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.)
Huawei Technologies Co Ltd
Original Assignee
Huawei Technologies 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 Huawei Technologies Co Ltd filed Critical Huawei Technologies Co Ltd
Priority to CN202010275152.8A priority Critical patent/CN113518189B/en
Publication of CN113518189A publication Critical patent/CN113518189A/en
Application granted granted Critical
Publication of CN113518189B publication Critical patent/CN113518189B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/80Camera processing pipelines; Components thereof
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/011Arrangements for interaction with the human body, e.g. for user immersion in virtual reality
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N5/00Details of television systems
    • H04N5/222Studio circuitry; Studio devices; Studio equipment
    • H04N5/262Studio circuits, e.g. for mixing, switching-over, change of character of image, other special effects ; Cameras specially adapted for the electronic generation of special effects
    • H04N5/265Mixing

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)
  • Studio Devices (AREA)

Abstract

The application relates to the field of image processing, and provides a shooting method, a shooting system, electronic equipment and a storage medium, wherein the shooting method comprises the following steps: the method comprises the steps that the electronic equipment acquires the relative position of the electronic equipment and the wearable equipment, wherein the relative position is determined by the electronic equipment or the wearable equipment, and the wearable equipment comprises VR equipment, AR equipment or MR equipment; the electronic equipment calculates the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment; the wearable device acquires images shot by the virtual camera in the virtual space and sends the images shot by the virtual camera in the virtual space to the electronic device; wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic equipment in the virtual space; the electronic equipment acquires the image of the target object, the image of the target object and the image shot by the virtual camera are overlapped, the overlapped image is output, and VR shooting can be achieved only through the electronic equipment and the wearable equipment.

Description

Shooting method, shooting system, electronic equipment and storage medium
Technical Field
The present application relates to the field of image processing, and in particular, to a shooting method, a shooting system, an electronic device, and a storage medium.
Background
Virtual Reality (VR) shooting is a shooting method for synthesizing a target object and a Virtual scene, and a user can see a picture synthesized by the target object and the Virtual scene through VR glasses. The existing shooting method can be realized generally by means of additional auxiliary equipment and software tools, the requirement on hardware equipment is high, the building process is complex, and the shooting difficulty is high.
Disclosure of Invention
The application provides a shooting method, a shooting system, electronic equipment and a storage medium, which can conveniently and quickly carry out VR shooting.
In order to achieve the purpose, the following technical scheme is adopted in the application:
in a first aspect, a shooting method is provided, including:
the method comprises the steps that the electronic device obtains the relative position of the electronic device and the wearable device, wherein the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device;
the electronic equipment calculates the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment;
the wearable device acquires images shot by a virtual camera in a virtual space according to the position information of the electronic device in the virtual space, and sends the images shot by the virtual camera in the virtual space to the electronic device; wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic device in the virtual space;
the electronic equipment acquires an image of a target object;
and the electronic equipment superposes the image of the target object and the image shot by the virtual camera and outputs the superposed image.
In the above embodiment, the electronic device calculates the position information of the electronic device in the virtual space according to the relative position between the electronic device and the wearable device, the wearable device adjusts the position information of the virtual camera in the virtual space to be the same as the position information of the electronic device in the virtual space, obtains the image shot by the virtual camera, and sends the image shot by the virtual camera to the electronic device; the electronic equipment superposes the image of the target object and the image shot by the virtual camera to obtain a superposed image. Because the relative position of electronic equipment and wearing equipment is confirmed by electronic equipment or wearing equipment, consequently only need electronic equipment and wearing equipment can obtain the image after the stack to can conveniently, carry out the VR to shoot fast.
In a second aspect, a shooting method is provided, including:
the method comprises the steps that the electronic device obtains the relative position of the electronic device and the wearable device, wherein the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device;
the electronic equipment calculates the position information of the electronic equipment in a virtual space according to the relative position of the electronic equipment and the wearable equipment;
the electronic equipment acquires an image shot by a virtual camera in the virtual space, wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic equipment in the virtual space;
the electronic equipment acquires an image of a target object;
and the electronic equipment superposes the image of the target object and the image shot by the virtual camera and outputs the superposed image.
In the above embodiment, the electronic device calculates the position information of the electronic device in the virtual space according to the relative position between the electronic device and the wearable device, adjusts the position information of the virtual camera in the virtual space to the position information of the electronic device in the virtual space, obtains the image shot by the virtual camera, and then superimposes the image of the target object and the image shot by the virtual camera to obtain the superimposed image. Because the relative position of electronic equipment and wearing equipment is confirmed by electronic equipment or wearing equipment, consequently only need electronic equipment and wearing equipment can obtain the image after the stack to can conveniently, carry out VR shooting fast.
In a possible implementation manner of the second aspect, if the relative position between the electronic device and the wearable device is determined by the wearable device, the obtaining, by the electronic device, the relative position between the electronic device and the wearable device includes:
the electronic equipment acquires an image of the electronic equipment, which is shot by a depth camera on the wearable equipment; the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the depth image of the electronic equipment shot by the depth camera.
The electronic equipment can calculate the Euler rotation angle and the distance of the electronic equipment relative to the wearable equipment according to the depth image, namely the relative position of the electronic equipment and the wearable equipment, so that the relative position of the electronic equipment and the wearable equipment can be calculated through the wearable equipment without the aid of auxiliary equipment.
In a possible implementation manner of the second aspect, if the relative position between the electronic device and the wearable device is determined by the electronic device, the acquiring, by the electronic device, the relative position between the electronic device and the wearable device includes:
the electronic equipment acquires the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment; and the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment.
The rotation angle of the electronic equipment can be calculated according to a gyroscope on the electronic equipment, the fixed position of the electronic equipment, which is fixed in the front of the wearable equipment, is unchanged, and the relative position of the electronic equipment and the wearable equipment can be calculated according to the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment, so that the relative position of the electronic equipment and the wearable equipment can be calculated through the electronic equipment without the help of auxiliary equipment.
In a possible implementation manner of the second aspect, the superimposing, by the electronic device, the image of the target object and the image captured by the virtual camera includes:
the electronic equipment removes the background of the image of the target object; the electronic equipment takes the image of the target object without the background as the foreground, takes the image shot by the virtual camera as the background, and superposes the foreground and the background, namely, the image of the target object and the image shot by the virtual camera are synthesized to obtain the image of the target object in the virtual scene.
In a possible implementation manner of the second aspect, after the outputting the superimposed image, the shooting method further includes:
and the electronic equipment stores the superposed images according to the shooting instruction. For example, if it is detected that the user presses a "shooting" key on the mobile phone, the mobile phone stores the superimposed image, and when the user wears the wearable device, the electronic device sends the superimposed image to the wearable device, so that the user can browse the superimposed image stored in the electronic device.
In a possible implementation manner of the second aspect, before the outputting the superimposed image, the method further includes:
and the electronic equipment restores the image of the target object according to a preset three-dimensional image model. For example, in the self-timer shooting process, the wearable device on the self-timer image is removed through restoration processing, and the user experience is improved.
In one possible implementation manner of the second aspect, the position information of the electronic device in the virtual space includes a position coordinate and a rotation angle of the electronic device in the virtual space.
In a third aspect, there is provided a photographing apparatus including:
the wearable device comprises a first acquisition module, a second acquisition module and a display module, wherein the first acquisition module is used for acquiring the relative position of the electronic device and the wearable device, the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device;
the computing module is used for computing the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment;
a second obtaining module, configured to obtain, by an electronic device, an image captured by a virtual camera in the virtual space, where position information of the virtual camera in the virtual space is the same as position information of the electronic device in the virtual space;
the third acquisition module is used for acquiring an image of the target object;
and the superposition module is used for superposing the image of the target object and the image shot by the virtual camera and outputting the superposed image.
In a possible implementation manner of the third aspect, if the relative position between the electronic device and the wearable device is determined by the wearable device, the first obtaining module is specifically configured to:
the electronic equipment acquires an image of the electronic equipment, which is shot by a depth camera on the wearable equipment;
the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the depth image of the electronic equipment shot by the depth camera.
In a possible implementation manner of the third aspect, if the relative position between the electronic device and the wearable device is determined by the electronic device, the first obtaining module is specifically configured to:
the electronic equipment acquires the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment;
the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment.
In a possible implementation manner of the third aspect, the superimposing module is specifically configured to:
the electronic equipment removes the background of the image of the target object;
and the electronic equipment takes the image of the target object without the background as the foreground, takes the image shot by the virtual camera as the background, and superposes the foreground and the background.
In a possible implementation manner of the third aspect, the shooting device further includes a storage module, and the storage module is configured to store the superimposed image according to a shooting instruction.
In a possible implementation manner of the third aspect, the shooting device further includes a restoring module, and the restoring module is configured to restore the image of the target object according to a preset three-dimensional image model.
In a possible implementation manner of the third aspect, the position information of the electronic device in the virtual space includes a position coordinate and a rotation angle of the electronic device in the virtual space.
In a fourth aspect, an electronic device is provided, which includes a memory, a processor, and a computer program stored in the memory and executable on the processor, and the processor implements the shooting method according to the second aspect when executing the computer program.
In a fifth aspect, a shooting system is provided, which includes a wearable device and the electronic device as described in the fourth aspect.
A sixth aspect provides a computer-readable storage medium storing a computer program which, when executed by a processor, implements the photographing method according to the second aspect.
In a seventh aspect, a computer program product is provided, which, when run on a terminal device, causes the terminal device to execute the shooting method according to the second aspect.
It is to be understood that, the beneficial effects of the third to seventh aspects may be referred to the related description of the second aspect, and are not repeated herein.
Drawings
Fig. 1 is a schematic diagram of a shooting system provided in an embodiment of the present application;
fig. 2 is a schematic structural diagram of an electronic device according to an embodiment of the present application;
fig. 3 is a schematic flowchart of a shooting method according to an embodiment of the present application;
fig. 4 is a schematic diagram of a shooting method in an application scenario provided in an embodiment of the present application;
fig. 5 is a schematic diagram of a shooting method in another application scenario provided in the embodiment of the present application;
fig. 6 is an application scene diagram of the shooting method provided in the embodiment of the present application;
fig. 7 is another application scenario diagram of the shooting method provided in the embodiment of the present application;
fig. 8 is a diagram of another application scenario of the shooting method provided in the embodiment of the present application;
fig. 9 is a schematic flowchart of a shooting method according to another embodiment of the present application.
Detailed Description
In the following description, for purposes of explanation and not limitation, specific details are set forth such as particular system structures, techniques, etc. in order to provide a thorough understanding of the embodiments of the present application. It will be apparent, however, to one skilled in the art that the present application may be practiced in other embodiments that depart from these specific details. In other instances, detailed descriptions of well-known systems, devices, circuits, and methods are omitted so as not to obscure the description of the present application with unnecessary detail.
It will be understood that the terms "comprises" and/or "comprising," when used in this specification and the appended claims, specify the presence of stated features, integers, steps, operations, elements, and/or components, but do not preclude the presence or addition of one or more other features, integers, steps, operations, elements, components, and/or groups thereof.
It should also be understood that the term "and/or" as used in this specification and the appended claims refers to and includes any and all possible combinations of one or more of the associated listed items.
As used in this specification and the appended claims, the term "if" may be interpreted contextually as "when", "upon" or "in response to" determining "or" in response to detecting ". Similarly, the phrase "if it is determined" or "if a [ described condition or event ] is detected" may be interpreted contextually to mean "upon determining" or "in response to determining" or "upon detecting [ described condition or event ]" or "in response to detecting [ described condition or event ]".
Reference throughout this specification to "one embodiment" or "some embodiments," or the like, means that a particular feature, structure, or characteristic described in connection with the embodiment is included in one or more embodiments of the present application. Thus, appearances of the phrases "in one embodiment," "in some embodiments," "in other embodiments," or the like, in various places throughout this specification are not necessarily all referring to the same embodiment, but rather "one or more but not all embodiments" unless specifically stated otherwise. The terms "comprising," "including," "having," and variations thereof mean "including, but not limited to," unless otherwise specifically stated.
The shooting method provided by the embodiment of the application is applied to a shooting system, please refer to fig. 1, fig. 1 is a schematic diagram of a shooting system provided by the embodiment of the application, the system includes an electronic device 100 and a wearable device 200, the wearable device may be a Virtual Reality (VR) device, an Augmented Reality (AR) device or a Mixed Reality (MR) device, after a user wears the wearable device 200, the electronic device 100 obtains a relative position of the electronic device 100 and the wearable device 200 from the wearable device, or the electronic device 100 calculates a relative position of the electronic device 100 and the wearable device 200 according to preset parameters, calculates position information of the electronic device 100 in a Virtual space 300 according to the relative position of the electronic device 100 and the wearable device 200, and uses the position information of the electronic device 100 in the Virtual space 300 as position information of a Virtual camera in the Virtual space, that is, a shooting angle of view of a camera of the electronic device 100 is the same as a shooting angle of the Virtual camera in the Virtual space, and the electronic device obtains an image shot by the Virtual camera in the Virtual space from the Virtual space; the image of the target object shot by the camera of the electronic device is obtained, the image of the target object and the image shot by the virtual camera are superposed, the superposed image is sent to the wearable device, a user can observe the superposed image on a screen of a 3D mobile phone model of the virtual space by wearing the wearable device, namely the image superposed by the image of the virtual space and the target object can be obtained only through the electronic device 100 and the wearable device 200 without the help of auxiliary devices, and therefore VR shooting can be conveniently and quickly carried out.
First, an electronic device 100 according to an embodiment of the present application is described, in which the electronic device may be a mobile phone, a tablet computer, a camera, or the like.
Referring to fig. 2, fig. 2 is a schematic structural diagram of an electronic device 100 according to an embodiment of the present disclosure.
The electronic device 100 may include a processor 110, an external memory interface 120, an internal memory 121, a Universal Serial Bus (USB) interface 130, a charging 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, a button 190, a motor 191, an indicator 192, a camera 193, a display screen 194, a Subscriber Identity Module (SIM) card interface 195, and the like. The sensor module 180 may include a pressure sensor 180A, a gyroscope sensor 180B, an air pressure sensor 180C, a magnetic sensor 180D, an acceleration sensor 180E, a distance sensor 180F, a proximity light 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.
It is to be understood that the illustrated structure of the embodiment of the present invention does not specifically limit the electronic device 100. In other embodiments of the present application, electronic device 100 may include more or fewer components than shown, or some components may be combined, some components may be split, or a different arrangement of components. The illustrated components may be implemented in hardware, software, or a combination of software and hardware.
Processor 110 may include one or more processing units, such as: the processor 110 may include an Application Processor (AP), a modem processor, a Graphics Processing Unit (GPU), an Image Signal Processor (ISP), a controller, a video codec, a Digital Signal Processor (DSP), a baseband processor, and/or a neural-Network Processing Unit (NPU), etc. The different processing units may be separate devices or may be integrated into one or more processors.
The controller can generate an operation control signal according to the instruction operation code and the timing signal to complete 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 have just been used or recycled by the processor 110. If the processor 110 needs to reuse the instruction or data, it can be called directly from the memory. Avoiding repeated accesses reduces the latency of the processor 110, thereby increasing the efficiency of the system.
In some embodiments, processor 110 may include one or more interfaces. The interface may include an integrated circuit (I2C) interface, an integrated circuit built-in audio (I2S) interface, a Pulse Code Modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a Mobile Industry Processor Interface (MIPI), a general-purpose input/output (GPIO) interface, a Subscriber Identity Module (SIM) interface, and/or a Universal Serial Bus (USB) interface, etc.
The I2C interface is a bidirectional synchronous serial bus comprising a serial data line (SDA) and a Serial Clock Line (SCL). In some embodiments, processor 110 may include multiple sets of I2C buses. The processor 110 may be coupled to the touch sensor 180K, the charger, the flash, the camera 193, etc. through different I2C bus interfaces, respectively. For example: the processor 110 may be coupled to the touch sensor 180K through an I2C interface, so that the processor 110 and the touch sensor 180K communicate through an I2C bus interface to implement a touch function of the electronic device 100.
The I2S interface may be used for audio communication. In some embodiments, processor 110 may include multiple sets of I2S buses. The processor 110 may be coupled to the audio module 170 through an I2S bus, enabling communication between the processor 110 and the audio module 170. In some embodiments, the audio module 170 may transmit an audio signal to the wireless communication module 160 through the I2S interface, so as to implement a function of answering a call through a bluetooth headset.
The PCM interface may also be used for audio communication, sampling, quantizing and encoding analog signals. In some embodiments, the audio module 170 and the wireless communication module 160 may be coupled by a PCM bus interface. In some embodiments, the audio module 170 may also transmit audio signals to the wireless communication module 160 through the PCM interface, so as to implement a function of answering a call through a bluetooth headset. Both the I2S interface and the PCM interface may be used for audio communication.
The UART interface is a universal serial data bus used for asynchronous communications. The bus may be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, a UART interface is generally used to connect the processor 110 and the wireless communication module 160. For example: the processor 110 communicates with a bluetooth module in the wireless communication module 160 through a UART interface to implement a bluetooth function. In some embodiments, the audio module 170 may transmit the audio signal to the wireless communication module 160 through a UART interface, so as to implement the function of playing music through a bluetooth headset.
MIPI interfaces may be used to connect processor 110 with peripheral devices such as display screen 194, camera 193, and the like. The MIPI interface includes a Camera Serial Interface (CSI), a Display Serial Interface (DSI), and the like. In some embodiments, processor 110 and camera 193 communicate through a CSI interface to implement the capture functionality of electronic device 100. The processor 110 and the display screen 194 communicate through the DSI interface to implement the display function of the electronic device 100.
The GPIO interface may be configured by software. The GPIO interface may be configured as a control signal and may also be configured as a data signal. In some embodiments, a GPIO interface may be used to connect the processor 110 with the camera 193, the display 194, the wireless communication module 160, the audio module 170, the sensor module 180, and the like. The GPIO interface may also be configured as an I2C interface, an I2S interface, a UART interface, an MIPI interface, and the like.
The USB interface 130 is an interface conforming to the USB standard specification, and may specifically be a Mini USB interface, a Micro USB interface, a USB Type C interface, or the like. The USB interface 130 may be used to connect a charger to charge the electronic device 100, and may also be used to transmit data between the electronic device 100 and a peripheral device. And the method can also be used for connecting a headset and playing audio through the headset. The interface may also be used to connect other electronic devices, such as AR devices and the like.
It should be understood that the connection relationship between the modules according to the embodiment of the present invention is only illustrative, and is not limited to the structure of the electronic device 100. In other embodiments of the present application, the electronic device 100 may also adopt different interface connection manners or a combination of multiple interface connection manners in the above embodiments.
The charging management module 140 is configured to receive charging input from a charger. The charger may be a wireless charger or a wired charger. In some wired charging embodiments, the charging management module 140 may receive charging input from a wired charger via the USB interface 130. In some wireless charging embodiments, the charging management module 140 may receive a wireless charging input through a wireless charging coil of the electronic device 100. The charging management module 140 may also supply power to the electronic device through the power management module 141 while charging the battery 142.
The power management module 141 is used to connect the battery 142, the charging management module 140 and the processor 110. The power management module 141 receives input from the battery 142 and/or the charge management module 140, and supplies power to the processor 110, the internal memory 121, the display 194, the camera 193, the wireless communication module 160, and the like. The power management module 141 may also be used to monitor parameters such as battery capacity, battery cycle count, battery state of health (leakage, impedance), etc. In some other embodiments, the power management module 141 may also be disposed in the processor 110. In other embodiments, the power management module 141 and the charging management module 140 may also be disposed in the same device.
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, a modem processor, a 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 can also be multiplexed to improve the utilization of the antennas. For example: the antenna 1 may be multiplexed as a diversity antenna of a wireless local area network. In other embodiments, the antenna may be used in conjunction with a tuning switch.
The mobile communication module 150 may provide a solution including 2G/3G/4G/5G wireless communication applied to the electronic device 100. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a Low Noise Amplifier (LNA), and the like. The mobile communication module 150 may receive the electromagnetic wave from the antenna 1, filter, amplify, etc. the received electromagnetic wave, and transmit the electromagnetic wave to the modem processor for demodulation. The mobile communication module 150 may also amplify the signal modulated by the modem processor, and convert the signal into electromagnetic wave through the antenna 1 to radiate the electromagnetic wave. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 may be disposed in the same device as at least some of the modules of the processor 110.
The modem processor may include a modulator and a demodulator. The modulator is used for modulating a low-frequency baseband signal to be transmitted into a medium-high frequency signal. The demodulator is used for demodulating the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then passes the demodulated low frequency baseband signal to a baseband processor for processing. The low frequency baseband signal is processed by the baseband processor and then transferred to the application processor. The application processor outputs a sound signal through an audio device (not limited to the speaker 170A, the receiver 170B, etc.) or displays an image or video through the display screen 194. In some embodiments, the modem processor may be a stand-alone device. In other embodiments, the modem processor may be provided in the same device as the mobile communication module 150 or other functional modules, independent of the processor 110.
The wireless communication module 160 may provide solutions for wireless communication applied to the electronic device 100, including Wireless Local Area Networks (WLANs) (e.g., wireless fidelity (Wi-Fi) networks), bluetooth (bluetooth, BT), global Navigation Satellite System (GNSS), frequency Modulation (FM), near Field Communication (NFC), infrared (IR), and the like. The wireless communication module 160 may be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, performs frequency modulation and filtering on electromagnetic wave signals, and transmits the processed signals to the processor 110. The wireless communication module 160 may also receive a signal to be transmitted from the processor 110, perform frequency modulation and amplification on the signal, and convert the signal into electromagnetic waves through the antenna 2 to radiate the electromagnetic waves.
In some embodiments, antenna 1 of electronic device 100 is coupled to mobile communication module 150 and antenna 2 is coupled to wireless communication module 160 so that electronic device 100 can communicate with networks and other devices through wireless communication techniques. The wireless communication technology may include global system for mobile communications (GSM), general Packet Radio Service (GPRS), code division multiple access (code division multiple access, CDMA), wideband Code Division Multiple Access (WCDMA), time-division code division multiple access (time-division code division multiple access, TD-SCDMA), long Term Evolution (LTE), BT, GNSS, WLAN, NFC, FM, and/or IR technologies, etc. The GNSS may include a Global Positioning System (GPS), a global navigation satellite system (GLONASS), a beidou navigation satellite system (BDS), a quasi-zenith satellite system (QZSS), and/or a Satellite Based Augmentation System (SBAS).
The electronic device 100 implements display functions via the GPU, the display screen 194, and the application processor. The GPU is a microprocessor for image processing, and is connected to the display screen 194 and an application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or alter display information.
The display screen 194 is used to display images, video, and the like. The display screen 194 includes a display panel. The display panel may adopt a Liquid Crystal Display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode (active-matrix organic light-emitting diode, AMOLED), a flexible light-emitting diode (FLED), a miniature, a Micro-oeld, a quantum dot light-emitting diode (QLED), and the like. In some embodiments, the electronic device 100 may include 1 or N display screens 194, N being a positive integer greater than 1.
The electronic device 100 may implement a photographing function through the ISP, the camera 193, the video codec, the GPU, the display screen 194, and the application processor, etc.
The ISP is used to process the data fed back by the camera 193. For example, when a photo is taken, the shutter is opened, light is transmitted to the camera photosensitive element through the lens, the optical signal is converted into an electrical signal, and the camera photosensitive element transmits the electrical signal to the ISP for processing and converting into an image visible to naked eyes. The ISP can also carry out algorithm optimization on the noise, brightness and skin color of the image. The ISP can also optimize parameters such as exposure, color temperature and the like of a shooting scene. In some embodiments, the ISP may be provided in camera 193.
The camera 193 is used to capture still images or video. The object generates an optical image through the lens and projects the optical image to the photosensitive element. The photosensitive element may be a Charge Coupled Device (CCD) or a complementary metal-oxide-semiconductor (CMOS) phototransistor. The light sensing element converts the optical signal into an electrical signal, which is then passed to the ISP where it is converted into a digital image signal. And 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 and other formats. In some embodiments, electronic device 100 may include 1 or N cameras 193, N being a positive integer greater than 1.
The digital signal processor is used for processing digital signals, and can process digital image signals and other digital signals. For example, when the electronic device 100 selects a frequency bin, the digital signal processor is used to perform fourier transform or the like on the frequency bin energy.
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: moving Picture Experts Group (MPEG) 1, MPEG2, MPEG3, MPEG4, and the like.
The NPU is a neural-network (NN) computing processor that processes input information quickly by using a biological neural network structure, for example, by using a transfer mode between neurons of a human brain, and can also learn by itself continuously. Applications such as intelligent recognition of the electronic device 100 can be implemented by the NPU, for example: image recognition, face recognition, speech recognition, text understanding, and the like.
The external memory interface 120 may be used to connect an external memory card, such as a Micro SD card, to extend the storage capability of the electronic device 100. The external memory card communicates with the processor 110 through the external memory interface 120 to implement a data storage function. For example, files such as music, video, etc. are saved in an external memory card.
The internal memory 121 may be used to store computer-executable program code, which includes instructions. The internal memory 121 may include a program storage area and a data storage area. The storage program area may store an operating system, an application program (such as a sound playing function, an image playing function, etc.) required by at least one function, and the like. The storage data area may store data (such as audio data, phone book, etc.) created during use of the electronic device 100, and the like. In addition, the internal memory 121 may include a high-speed random access memory, and may further include a nonvolatile memory, such as at least one magnetic disk storage device, a flash memory device, a universal flash memory (UFS), and the like. The processor 110 executes various functional applications of the electronic device 100 and data processing by executing instructions stored in the internal memory 121 and/or instructions stored in a memory provided in the processor.
The electronic device 100 may implement audio functions via the audio module 170, the speaker 170A, the receiver 170B, the microphone 170C, the headphone interface 170D, and the application processor. Such as music playing, recording, etc.
The audio module 170 is used to convert digital audio information into analog audio signals for output, and also used to convert analog audio inputs into digital audio signals. The audio module 170 may also be used to encode and decode audio signals. In some embodiments, the audio module 170 may be disposed in the processor 110, or some functional modules of the audio module 170 may be disposed in the processor 110.
The speaker 170A, also called a "horn", is used to convert the audio electrical signal into a sound signal. The electronic apparatus 100 can listen to music through the speaker 170A or listen to a handsfree call.
The receiver 170B, also called "earpiece", is used to convert the electrical audio signal into a sound signal. When the electronic apparatus 100 receives a call or voice information, it can receive voice by placing the receiver 170B close to the ear of the person.
The microphone 170C, also referred to as a "microphone," is used to convert sound signals into electrical signals. When making a call or transmitting voice information, the user can input a voice signal to the microphone 170C by speaking near the microphone 170C through the mouth. The electronic device 100 may be provided with at least one microphone 170C. In other embodiments, the electronic device 100 may be provided with two microphones 170C to achieve a noise reduction function in addition to collecting sound signals. In other embodiments, the electronic device 100 may further include three, four or more microphones 170C to collect sound signals, reduce noise, identify sound sources, and perform directional recording.
The earphone interface 170D is used to connect a wired earphone. The headset interface 170D may be the USB interface 130, or may be a 3.5mm open mobile electronic device platform (OMTP) standard interface, a cellular telecommunications industry association (cellular telecommunications industry association) standard interface of the USA.
The pressure sensor 180A is used for sensing a pressure signal, and can convert the pressure signal into an electrical signal. In some embodiments, the pressure sensor 180A may be disposed on the display screen 194. The pressure sensor 180A can be of a variety of types, such as a resistive pressure sensor, an inductive pressure sensor, a capacitive pressure sensor, and the like. The capacitive pressure sensor may be a sensor comprising at least two parallel plates having an electrically conductive material. When a force acts on the pressure sensor 180A, the capacitance between the electrodes changes. The electronic device 100 determines the strength of the pressure from the change in capacitance. When a touch operation is applied to the display screen 194, the electronic device 100 detects the intensity of the touch operation according to the pressure sensor 180A. The electronic apparatus 100 may also calculate the touched position from the detection signal of the pressure sensor 180A. In some embodiments, the touch operations that are applied to the same touch position but have different touch operation intensities may correspond to different operation instructions. For example: and when the touch operation with the touch operation intensity smaller than the first pressure threshold value acts on the short message application icon, executing an instruction for viewing the short message. And when the touch operation with the touch operation intensity larger than or equal to the first pressure threshold value acts on the short message application icon, executing an instruction of newly building the short message.
The gyro sensor 180B may be used to determine the motion attitude of the electronic device 100. In some embodiments, the angular velocity of electronic device 100 about three axes (i.e., the x, y, and z axes) may be determined by gyroscope 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 a shake angle of the electronic device 100, calculates a distance to be compensated for by the lens module according to the shake angle, and allows the lens to counteract the shake of the electronic device 100 through a reverse movement, thereby achieving anti-shake. The gyroscope sensor 180B may also be used for navigation, somatosensory gaming scenes.
The air pressure sensor 180C is used to measure air pressure. In some embodiments, electronic device 100 calculates altitude from barometric pressure values measured by barometric pressure sensor 180C to assist in positioning and navigation.
The magnetic sensor 180D includes a hall sensor. The electronic device 100 may detect the opening and closing of the flip holster using the magnetic sensor 180D. In some embodiments, when the electronic device 100 is a flip phone, the electronic device 100 may detect the opening and closing of the flip according to the magnetic sensor 180D. And then according to the opening and closing state of the leather sheath or the opening and closing state of the flip cover, the automatic unlocking of the flip cover is set.
The acceleration sensor 180E may detect the magnitude of acceleration of the electronic device 100 in various directions (typically three axes). The magnitude and direction of gravity can be detected when the electronic device 100 is stationary. The method can also be used for recognizing the posture of the electronic equipment, and is applied to horizontal and vertical screen switching, pedometers and other applications.
A distance sensor 180F for measuring a distance. The electronic device 100 may measure the distance by infrared or laser. In some embodiments, taking a picture of a scene, electronic device 100 may utilize range sensor 180F to range for fast focus.
The proximity light sensor 180G may include, for example, a Light Emitting Diode (LED) and a light detector, such as a photodiode. The light emitting diode may be an infrared light emitting diode. The electronic apparatus 100 emits infrared light to the outside through the light emitting diode. The electronic device 100 detects infrared reflected light from a nearby object using a photodiode. When sufficient reflected light is detected, it can be determined that there is an object near the electronic device 100. When insufficient reflected light is detected, the electronic device 100 may determine that there are no objects near the electronic device 100. The electronic device 100 can utilize the proximity sensor 180G to detect that the user holds the electronic device 100 close to the ear for talking, so as to automatically turn off the screen to save power. The proximity light sensor 180G may also be used in a holster mode, a pocket mode automatically unlocks and locks the screen.
The ambient light sensor 180L is used to sense ambient light brightness. Electronic device 100 may adaptively adjust the brightness of display screen 194 based on the perceived ambient light level. The ambient light sensor 180L may also be used to automatically adjust the white balance when taking a picture. The ambient light sensor 180L may also cooperate with the proximity light sensor 180G to detect whether the electronic device 100 is in a pocket to prevent accidental touches.
The fingerprint sensor 180H is used to collect a fingerprint. The electronic device 100 can utilize the collected fingerprint characteristics to unlock the fingerprint, access the application lock, photograph the fingerprint, answer an incoming call with the fingerprint, and so on.
The temperature sensor 180J is used to detect temperature. In some embodiments, electronic device 100 implements a temperature processing strategy using the temperature detected by temperature sensor 180J. For example, when the temperature reported by the temperature sensor 180J exceeds a threshold, the electronic device 100 performs a reduction in performance of a processor located near the temperature sensor 180J, so as to reduce power consumption and implement thermal protection. In other embodiments, the electronic device 100 heats the battery 142 when the temperature is below another threshold to avoid abnormal shutdown of the electronic device 100 due to low temperature. In other embodiments, when the temperature is lower than a further threshold, the electronic device 100 performs boosting on the output voltage of the battery 142 to avoid abnormal shutdown due to low temperature.
The touch sensor 180K is also called 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 used to detect a touch operation acting thereon or nearby. The touch sensor may communicate the detected touch operation to the application processor to determine the touch event type. Visual output associated with the touch operation may be provided via the display screen 194. In other embodiments, the touch sensor 180K may be disposed on a surface of the electronic device 100, different from the position of the display screen 194.
The bone conduction sensor 180M may acquire a vibration signal. In some embodiments, the bone conduction sensor 180M may acquire a vibration signal of the human vocal part vibrating the bone mass. The bone conduction sensor 180M may also contact the human body pulse to receive the blood pressure pulsation signal. In some embodiments, the bone conduction sensor 180M may also be disposed in a headset, integrated into a bone conduction headset. The audio module 170 may analyze a voice signal based on the vibration signal of the bone mass vibrated by the sound part acquired by the bone conduction sensor 180M, so as to implement a voice function. The application processor can analyze heart rate information based on the blood pressure beating signal acquired by the bone conduction sensor 180M, so as to realize the heart rate detection function.
The keys 190 include a power-on key, a volume key, and the like. The keys 190 may be mechanical keys. Or may be touch keys. The electronic apparatus 100 may receive a key input, and generate a key signal input related to user setting and function control of the electronic apparatus 100.
The motor 191 may generate a vibration cue. The motor 191 may be used for incoming call vibration prompts as well as for touch vibration feedback. For example, touch operations applied to different applications (e.g., photographing, audio playing, etc.) may correspond to different vibration feedback effects. The motor 191 may also respond to different vibration feedback effects for touch operations applied to different areas of the display screen 194. Different application scenes (such as time reminding, receiving information, alarm clock, game and the like) can also correspond to different vibration feedback effects. The touch vibration feedback effect may also support customization.
Indicator 192 may be an indicator light that may be used to indicate a state of charge, a change in charge, or a message, missed call, notification, etc.
The SIM card interface 195 is used to connect a SIM card. The SIM card can be attached to and detached from the electronic device 100 by being inserted into the SIM card interface 195 or being pulled out of the SIM card interface 195. The electronic device 100 may support 1 or N SIM card interfaces, N being a positive integer greater than 1. The SIM card interface 195 may support a Nano SIM card, a Micro SIM card, a SIM card, etc. Multiple cards can be inserted into the same SIM card interface 195 at the same time. The types of the plurality of cards can be the same or different. The SIM card interface 195 is also compatible with different types of SIM cards. The SIM card interface 195 may also be compatible with external memory cards. The electronic device 100 interacts with the network through the SIM card to implement functions such as communication and data communication. In some embodiments, the electronic device 100 employs esims, namely: an embedded SIM card. The eSIM card can be embedded in the electronic device 100 and cannot be separated from the electronic device 100.
The shooting method provided by the embodiment of the application is explained with reference to fig. 1-2. Referring to fig. 3, fig. 3 is a schematic flowchart illustrating a shooting method provided in an embodiment of the present application, where an execution subject of the method is an electronic device. As shown in fig. 3, the method includes:
s101: acquiring the relative position of an electronic device and a wearable device, wherein the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device.
In one possible implementation, the relative position of the electronic device and the wearable device is determined by the wearable device. In particular, the wearable device may be a VR device, but also an AR device or an MR device. As shown in fig. 4, a depth camera 201 is disposed on the wearable device 200, and when the electronic device is located in front of the wearable device, the depth camera 201 can capture a depth image of the electronic device, where the depth image of the electronic device includes position information of the electronic device relative to the depth camera 201. In the embodiment of the application, the wearable device may calculate the relative position between the electronic device and the wearable device according to the depth image of the electronic device, or the wearable device may send the taken depth image of the electronic device to the electronic device, and the electronic device calculates the relative position between the wearable device and the wearable device. Wherein, the relative position includes the distance of electronic equipment and wearing equipment to and the rotation angle of electronic equipment for wearing equipment, this rotation angle can be euler rotation angle.
In another possible implementation, the relative position of the electronic device and the wearable device is determined by the electronic device. Specifically, as shown in fig. 5, a gyroscope is disposed on the electronic device, and the gyroscope can record angle information of the electronic device during rotation. The method comprises the steps of firstly setting an initial position of the electronic equipment, calculating a rotation angle of the electronic equipment according to angle information corresponding to the electronic equipment at the initial position and angle information corresponding to the electronic equipment at the current position, and then combining a preset distance between the electronic equipment and the wearable equipment to obtain the relative position of the electronic equipment and the wearable equipment. For example, the initial position of the electronic device may be set to: the distance from the front of the wearable device is a position at a fixed distance, for example, a position at a distance of 0.8 meter from the front of the wearable device. In the process that the electronic equipment rotates by taking the initial position as a center, the distance between the electronic equipment and the wearable equipment is unchanged, the electronic equipment calculates the rotation angle of the electronic equipment according to the angle information recorded by the gyroscope, the electronic equipment calculates the rotation angle of the electronic equipment relative to the wearable equipment according to the angle of the initial position relative to the wearable equipment and the rotation angle of the electronic equipment, and then the relative position of the electronic equipment and the wearable equipment is obtained by combining the fixed distance between the electronic equipment and the wearable equipment.
S102: and calculating the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment.
In one possible implementation, the wearable device performs position calibration before use, specifically, establishes a coordinate system of a virtual space so that the coordinate system of the virtual space coincides with a coordinate system of a pre-established real space. After carrying out position calibration, if the user is stationary, the positional information of wearing equipment in virtual space is unanimous with the positional information of wearing equipment in real space, and wherein, wearing equipment can calculate the positional information of wearing equipment in real space according to the distance between the initial point of wearing equipment and real space's coordinate system to regard the positional information of wearing equipment in real space as the positional information of wearing equipment in virtual space. The electronic equipment obtains the position information of the electronic equipment in the virtual space according to the position information of the wearable equipment in the virtual space and the relative position of the electronic equipment and the wearable equipment, wherein the position information comprises a position coordinate and a rotation angle, and the position coordinate and the rotation angle of the electronic equipment in the virtual space are obtained.
In another possible implementation, for example, for a VR glasses with 6 degrees of freedom (DOF), the VR glasses are position-calibrated before use to obtain a mapping relationship between a coordinate system of a virtual space and a coordinate system of a real space. Specifically, after the user wears the VR glasses, a depth camera on the VR glasses scans a reference object in a real space, for example, a static object such as a ground, a wall, a table, a chair, and the like, to obtain a depth image of the reference object, and a relative position between the reference object and the VR glasses is calculated according to the depth image of the reference object. The position information of the VR glasses in the virtual space is obtained according to a pre-established coordinate system of the virtual space, for example, if the pre-established coordinate system of the virtual space uses the center of the VR glasses as the origin of coordinates, the position of the VR glasses in the virtual space is the origin of coordinates. Then obtaining the position information of the reference object in the virtual space according to the relative position of the reference object and the VR glasses and the position information of the VR glasses in the virtual space; and obtaining the position information of the reference object in the real space according to the pre-established coordinate system of the real space and the depth image of the reference object, and obtaining the mapping relation between the coordinate system of the virtual space and the coordinate system of the real space according to the position information of the reference object in the virtual space and the position information of the reference object in the real space. After the position calibration is performed, if the user is stationary, the electronic device can calculate the position information of the electronic device in the virtual space according to the position information of the VR glasses in the virtual space and the relative position of the electronic device and the VR glasses. If the user walks in the real space, the distance between the VR glasses and the reference object changes, the depth camera on the VR glasses shoots the depth image of the reference object again to obtain the relative position of the reference object and the VR glasses, and then the position information of the VR glasses in the real space is obtained according to the position information of the reference object in the real space. And obtaining the position information of the VR glasses in the virtual space according to the position information of the VR glasses in the real space and the mapping relation between the coordinate system of the virtual space and the coordinate system of the real space, and obtaining the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the VR glasses.
In one possible implementation, the position information of the camera 193 on the electronic device in the virtual space can be calculated according to the position information of the electronic device in the virtual space and the position of the camera on the electronic device. For example, the electronic device is a mobile phone, the mobile phone is provided with a front camera and a rear camera, when a user opens the front camera, the position information of the front camera in the virtual space is calculated, and when the user opens the rear camera, the position information of the rear camera in the virtual space is calculated.
S103: acquiring an image shot by a virtual camera in the virtual space, wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic equipment in the virtual space.
Specifically, the electronic device sends the position information of the electronic device in the virtual space to the wearable device, and the wearable device takes the position information of the electronic device in the virtual space as the position information of the virtual camera in the virtual space, that is, the shooting angle of the electronic device in the virtual space is the same as the shooting angle of the virtual camera in the virtual space. In other feasible implementation manners, the electronic device sends the position information of the camera used by the electronic device currently in the virtual space to the wearable device, and the wearable device uses the position information of the camera used by the electronic device currently in the virtual space as the position information of the virtual camera in the virtual space. After the position information of the virtual camera in the virtual space is determined, the wearable device sends the image shot by the virtual camera to the electronic device, namely, the image of the virtual space under the current view angle of the virtual camera, and meanwhile, the user can see the image shot by the virtual camera on the screen of the 3D mobile phone model of the virtual space through the wearable device. When the angle of the electronic equipment is changed, the angle of the virtual camera is correspondingly adjusted to obtain the image shot by the virtual camera with the angle of view adjusted, and the wearable equipment sends the image shot by the virtual camera with the angle of view adjusted to the electronic equipment.
S104: an image of the target object is acquired.
Wherein the target object is a human object or a real scene.
S105: and superposing the image of the target object and the image shot by the virtual camera, and outputting the superposed image.
Specifically, the electronic device removes the background of the image of the target object, for example, an image segmentation algorithm may be used to remove the background of the image of the target object, take the image of the target object from which the background is removed as the foreground, take the image captured by the virtual camera as the background, superimpose the foreground and the background, and output the superimposed image. Specifically, the electronic device sends the superposed image to the wearable device, and the user can see the superposed image on a screen of the 3D mobile phone model in the virtual space through the wearable device. Further, when the electronic device acquires a shooting instruction, the superposed image can be stored, when the wearing device is worn by a user, the electronic device sends the stored superposed image to the wearing device, and the user can browse the stored image on the 3D mobile phone model in the virtual space, namely the image synthesized by the target object and the virtual space.
The image of the target object and the image captured by the virtual camera may be two images captured synchronously or two images captured asynchronously. In one application scenario, the image of the target object and the image captured by the virtual camera are not captured simultaneously, for example, as shown in fig. 6 (a), after receiving the image captured by the virtual camera, the electronic device imports the image of the target object captured in advance according to the user operation, performs preprocessing operations such as moving or zooming on the image of the target object, removes the background of the preprocessed image of the target object, uses the image of the target object as the foreground, and uses the image captured by the virtual camera as the background, thereby obtaining the superimposed image as shown in fig. 6 (B). In another application scenario, the image of the target object and the image captured by the virtual camera are captured synchronously, for example, as shown in fig. 7, when the electronic device receives the image captured by the virtual camera, the electronic device performs background removal processing on the image of the target object currently captured by the camera of the electronic device, uses the image of the target object with the background removed as a foreground, uses the image captured by the virtual camera as a background, obtains a superimposed image, and sends the superimposed image to the wearable device, so that the user can see the superimposed effect of the images of the virtual space and the target object through the wearable device, and can adjust the target object. After the user adjusts the target object, for example, the distance between the target object and the electronic device is adjusted, or the angle of the target object is adjusted, the electronic device superimposes the image of the adjusted target object with the image captured by the virtual camera again, and outputs the superimposed image.
Taking the electronic device as a mobile phone as an example, the image of the target object may be captured by a front camera of the mobile phone or a rear camera of the mobile phone. The scene of the image of the target object shot by the front-facing camera is generally a scene of self-shooting of the user, if the image of the target object, namely the self-shooting image and the image shot by the virtual camera are shot synchronously, the user needs to wear the wearable device to adjust the visual angle of the virtual camera, so that the self-shooting image in the superposed images is generally the image of the wearable device worn by the user as shown in fig. 8 (a), and the image of the target object, namely the self-shooting image, can be restored according to a preset three-dimensional image model to obtain the image without the wearable device as shown in fig. 8 (B). For example, images of the user head portrait at various visual angles are shot in advance, a three-dimensional image model of the user head portrait is constructed, when a user carries out self-shooting by using the shooting method, the user head portrait is restored by adopting a face shielding restoration algorithm according to the self-shooting image shot by the electronic equipment and the pre-constructed three-dimensional image model of the user head portrait, the restored user head portrait is overlapped with the image shot by the virtual camera, and the overlapped image is output.
In the above embodiment, the electronic device calculates the position information of the electronic device in the virtual space according to the relative position of the electronic device and the wearable device, adjusts the position information of the virtual camera in the virtual space to the position information of the electronic device in the virtual space, acquires the image captured by the virtual camera, and superimposes the image of the target object and the image captured by the virtual camera to obtain the superimposed image. Because the relative position of the electronic equipment and the wearable equipment is determined by the electronic equipment or the wearable equipment, the image of the virtual space and the superposed target object can be obtained only by the electronic equipment and the wearable equipment, so that VR shooting can be conveniently and quickly carried out.
Referring to fig. 9, fig. 9 is a schematic specific flow chart of a shooting method according to an embodiment of the present application, and as shown in fig. 9, the method includes:
s201: the electronic equipment acquires the relative position of the electronic equipment and the wearable equipment, wherein the relative position of the electronic equipment and the wearable equipment is determined by the electronic equipment or the wearable equipment, and the wearable equipment comprises VR equipment, AR equipment or MR equipment.
S202: the electronic equipment calculates the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment.
S203: the wearable device acquires images shot by the virtual camera in the virtual space according to the position information of the electronic device in the virtual space, and sends the images shot by the virtual camera in the virtual space to the electronic device; wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic device in the virtual space.
Specifically, the wearable device acquires the position information of the electronic device in a virtual space, adjusts the position of the virtual camera in the virtual space until the position information of the virtual camera in the virtual space is the same as the position information of the electronic device in the virtual space, and transmits the image shot by the virtual camera at the visual angle to the electronic device.
S204: the electronic device acquires an image of a target object.
S205: and the electronic equipment superposes the image of the target object and the image shot by the virtual camera and outputs the superposed image.
In the above embodiment, the electronic device calculates the position information of the electronic device in the virtual space according to the relative position of the electronic device and the wearable device, the wearable device obtains an image shot by the virtual camera with the same position information as the electronic device, and sends the image shot by the virtual camera to the electronic device, the electronic device superimposes the image of the target object and the image shot by the virtual camera, and outputs the superimposed image, and the VR shooting can be completed only by the electronic device and the wearable device, so that the method is convenient and fast, and improves the user experience.
It should be understood that, the sequence numbers of the steps in the foregoing embodiments do not imply an execution sequence, and the execution sequence of each process should be determined by its function and inherent logic, and should not constitute any limitation to the implementation process of the embodiments of the present application.
In the above embodiments, the description of each embodiment has its own emphasis, and reference may be made to the related description of other embodiments for parts that are not described or recited in any embodiment.
It will be apparent to those skilled in the art that, for convenience and brevity of description, only the above-mentioned division of the functional units and modules is illustrated, and in practical applications, the above-mentioned function distribution may be performed by different functional units and modules according to needs, that is, the internal structure of the apparatus is divided into different functional units or modules to perform all or part of the above-mentioned functions. Each functional unit and module in the embodiments may be integrated in one processing unit, or each unit may exist alone physically, or two or more units are integrated in one unit, and the integrated unit may be implemented in a form of hardware, or in a form of software functional unit. In addition, specific names of the functional units and modules are only used for distinguishing one functional unit from another, and are not used for limiting the protection scope of the present application. The specific working processes of the units and modules in the system may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
The integrated unit, if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in a computer readable storage medium. Based on such understanding, all or part of the processes in the methods of the embodiments described above can be implemented by a computer program, which can be stored in a computer-readable storage medium and can implement the steps of the embodiments of the methods described above when the computer program is executed by a processor. Wherein the computer program comprises computer program code, which may be in the form of source code, object code, an executable file or some intermediate form, etc. The computer readable medium may include at least: any entity or device capable of carrying computer program code to a photographing apparatus/electronic device, a recording medium, computer Memory, read-Only Memory (ROM), random Access Memory (RAM), an electrical carrier signal, a telecommunications signal, and a software distribution medium. Such as a usb-drive, a removable hard drive, a magnetic or optical disk, etc.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one position, or may be distributed on multiple network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus/network device and method may be implemented in other ways. For example, the above-described apparatus/network device embodiments are merely illustrative, and for example, the division of the modules or units is only one logical function division, and other divisions may be realized in practice, for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection through some interfaces, devices or units, and may be in an electrical, mechanical or other form.
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 implementation. 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.
Finally, it should be noted that: the above description is only an embodiment of the present application, but the scope of the present application is not limited thereto, and any changes or substitutions within the technical scope of the present disclosure should be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (11)

1. A photographing method, characterized by comprising:
the method comprises the steps that the electronic device obtains the relative position of the electronic device and the wearable device, wherein the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device;
the electronic equipment calculates the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment;
the wearable device acquires images shot by a virtual camera in a virtual space according to the position information of the electronic device in the virtual space, and sends the images shot by the virtual camera in the virtual space to the electronic device; wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic device in the virtual space;
the electronic equipment acquires an image of a target object, wherein the image of the target object comprises a portrait of a person wearing the wearable equipment;
and the electronic equipment superposes the image of the target object without the wearable equipment and the image shot by the virtual camera and outputs the superposed image.
2. A shooting method, characterized by comprising:
the method comprises the steps that the electronic device obtains the relative position of the electronic device and the wearable device, wherein the relative position of the electronic device and the wearable device is determined by the electronic device or the wearable device, and the wearable device comprises a VR device, an AR device or an MR device;
the electronic equipment calculates the position information of the electronic equipment in the virtual space according to the relative position of the electronic equipment and the wearable equipment;
the electronic equipment acquires an image shot by a virtual camera in the virtual space, wherein the position information of the virtual camera in the virtual space is the same as the position information of the electronic equipment in the virtual space;
the electronic equipment acquires an image of a target object, wherein the image of the target object comprises a portrait wearing the wearable equipment;
and the electronic equipment superposes the image of the target object without the wearable equipment and the image shot by the virtual camera and outputs the superposed image.
3. The shooting method according to any one of claims 1 to 2, wherein if the relative position between the electronic device and the wearable device is determined by the wearable device, the acquiring, by the electronic device, the relative position between the electronic device and the wearable device includes:
the method comprises the steps that the electronic equipment obtains an image of the electronic equipment shot by a depth camera on the wearable equipment;
the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the depth image of the electronic equipment shot by the depth camera.
4. The shooting method according to claim 1 or 2, wherein if the relative position between the electronic device and the wearable device is determined by the electronic device, the acquiring, by the electronic device, the relative position between the electronic device and the wearable device includes:
the electronic equipment acquires the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment;
and the electronic equipment calculates the relative position of the electronic equipment and the wearable equipment according to the rotation angle of the electronic equipment and the distance between the electronic equipment and the wearable equipment.
5. The shooting method according to claim 1 or 2, wherein the electronic device superimposes the image of the target object with the wearable device removed and the image shot by the virtual camera, and the method comprises:
the electronic equipment removes the wearable equipment in the image of the target object;
the electronic equipment removes the background of the image of the target object;
and the electronic equipment takes the image of the target object with the wearing equipment and the background removed as a foreground, takes the image shot by the virtual camera as a background, and superposes the foreground and the background.
6. The photographing method according to claim 1 or 2, wherein after the outputting of the superimposed image, the photographing method further comprises:
and the electronic equipment stores the superposed images according to the shooting instruction.
7. The photographing method according to claim 1 or 2, wherein before the outputting the superimposed image, the method further comprises:
and the electronic equipment removes the wearable equipment worn by the image of the target object, and restores the image of the target object according to a preset three-dimensional image model.
8. The photographing method according to claim 1 or 2, wherein the position information of the electronic device in the virtual space includes a position coordinate and a rotation angle of the electronic device in the virtual space.
9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the photographing method according to any one of claims 2 to 8 when executing the computer program.
10. A camera system comprising a wearable device and the electronic device of claim 9.
11. A computer-readable storage medium, in which a computer program is stored which, when being executed by a processor, implements the photographing method according to any one of claims 2 to 8.
CN202010275152.8A 2020-04-09 2020-04-09 Shooting method, shooting system, electronic equipment and storage medium Active CN113518189B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010275152.8A CN113518189B (en) 2020-04-09 2020-04-09 Shooting method, shooting system, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010275152.8A CN113518189B (en) 2020-04-09 2020-04-09 Shooting method, shooting system, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113518189A CN113518189A (en) 2021-10-19
CN113518189B true CN113518189B (en) 2022-10-18

Family

ID=78060394

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010275152.8A Active CN113518189B (en) 2020-04-09 2020-04-09 Shooting method, shooting system, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113518189B (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114757829A (en) * 2022-04-25 2022-07-15 歌尔股份有限公司 Shooting calibration method, system, equipment and storage medium
CN114900624A (en) * 2022-04-25 2022-08-12 歌尔股份有限公司 Shooting calibration method, system, equipment and storage medium

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10434415B1 (en) * 2012-07-30 2019-10-08 Yaacov Barki Method of modifying locations
CN203070360U (en) * 2012-10-22 2013-07-17 广州新节奏数码科技有限公司 Virtual dressing equipment
CA2888943C (en) * 2013-10-03 2015-08-18 Sulon Technologies Inc. Augmented reality system and method for positioning and mapping
CN105759963A (en) * 2016-02-15 2016-07-13 众景视界(北京)科技有限公司 Method for positioning motion trail of human hand in virtual space based on relative position relation
CN106768361B (en) * 2016-12-19 2019-10-22 北京小鸟看看科技有限公司 The position tracking method and system of handle matched with VR helmet
CN106875493B (en) * 2017-02-24 2018-03-09 广东电网有限责任公司教育培训评价中心 The stacking method of virtual target thing in AR glasses
CN107133002B (en) * 2017-03-22 2020-07-24 联想(北京)有限公司 Information processing method and electronic equipment
CN107168515A (en) * 2017-03-31 2017-09-15 北京奇艺世纪科技有限公司 The localization method and device of handle in a kind of VR all-in-ones
CN107172414A (en) * 2017-04-20 2017-09-15 北京安云世纪科技有限公司 A kind of method of virtual reality head-mounted display equipment and its processing information
WO2018227098A1 (en) * 2017-06-09 2018-12-13 Vid Scale, Inc. External camera assisted virtual reality
CN206650796U (en) * 2017-08-04 2017-11-17 深圳超多维科技有限公司 Virtual reality device
CN107517372B (en) * 2017-08-17 2022-07-26 腾讯科技(深圳)有限公司 VR content shooting method, related equipment and system
WO2019037040A1 (en) * 2017-08-24 2019-02-28 腾讯科技(深圳)有限公司 Method for recording video on the basis of a virtual reality application, terminal device, and storage medium
CN109507686B (en) * 2018-11-08 2021-03-30 歌尔光学科技有限公司 Control method, head-mounted display device, electronic device and storage medium
CN110460794A (en) * 2019-09-09 2019-11-15 北京西山居互动娱乐科技有限公司 A kind of method and device of video record

Also Published As

Publication number Publication date
CN113518189A (en) 2021-10-19

Similar Documents

Publication Publication Date Title
CN110798568B (en) Display control method of electronic equipment with folding screen and electronic equipment
CN110458902B (en) 3D illumination estimation method and electronic equipment
CN113810601B (en) Terminal image processing method and device and terminal equipment
CN113395382B (en) Method for data interaction between devices and related devices
CN111182140B (en) Motor control method and device, computer readable medium and terminal equipment
CN112085647B (en) Face correction method and electronic equipment
CN114489533A (en) Screen projection method and device, electronic equipment and computer readable storage medium
CN114257920B (en) Audio playing method and system and electronic equipment
CN113518189B (en) Shooting method, shooting system, electronic equipment and storage medium
CN114880251A (en) Access method and access device of storage unit and terminal equipment
CN113572957B (en) Shooting focusing method and related equipment
CN113542613A (en) Device and method for photographing
CN114500901A (en) Double-scene video recording method and device and electronic equipment
CN113467735A (en) Image adjusting method, electronic device and storage medium
CN113781548A (en) Multi-device pose measurement method, electronic device and system
CN113129916A (en) Audio acquisition method, system and related device
CN114257737B (en) Shooting mode switching method and related equipment
CN113923351B (en) Method, device and storage medium for exiting multi-channel video shooting
CN115665632A (en) Audio circuit, related device and control method
CN115393676A (en) Gesture control optimization method and device, terminal and storage medium
CN113391735A (en) Display form adjusting method and device, electronic equipment and storage medium
CN114915888A (en) Earphone wearing error recognition method and related equipment
CN114466238A (en) Frame demultiplexing method, electronic device and storage medium
CN116782023A (en) Shooting method and electronic equipment
CN114745508B (en) Shooting method, terminal equipment and storage medium

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
GR01 Patent grant