WO2022052613A1 - Camera control method and apparatus, electronic device, and storage medium - Google Patents

Camera control method and apparatus, electronic device, and storage medium Download PDF

Info

Publication number
WO2022052613A1
WO2022052613A1 PCT/CN2021/105304 CN2021105304W WO2022052613A1 WO 2022052613 A1 WO2022052613 A1 WO 2022052613A1 CN 2021105304 W CN2021105304 W CN 2021105304W WO 2022052613 A1 WO2022052613 A1 WO 2022052613A1
Authority
WO
WIPO (PCT)
Prior art keywords
camera
rotation
progress
real
control
Prior art date
Application number
PCT/CN2021/105304
Other languages
French (fr)
Chinese (zh)
Inventor
钟浩华
Original Assignee
Oppo广东移动通信有限公司
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 Oppo广东移动通信有限公司 filed Critical Oppo广东移动通信有限公司
Publication of WO2022052613A1 publication Critical patent/WO2022052613A1/en

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/66Remote control of cameras or camera parts, e.g. by remote control devices
    • H04N23/661Transmitting camera control signals through networks, e.g. control via the Internet
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04NPICTORIAL COMMUNICATION, e.g. TELEVISION
    • H04N23/00Cameras or camera modules comprising electronic image sensors; Control thereof
    • H04N23/60Control of cameras or camera modules
    • H04N23/695Control of camera direction for changing a field of view, e.g. pan, tilt or based on tracking of objects

Definitions

  • the present application relates to the field of smart home technology, and more particularly, to a camera control method, device, electronic device and storage medium.
  • monitoring technology is widely used as an important part of the emerging smart home field.
  • the house is usually monitored by the installed camera, and the user can control the position captured by the camera on the control interface displayed by the electronic device (such as a smart phone, tablet, etc.), and then view different monitoring Monitoring content within the location area.
  • the electronic device such as a smart phone, tablet, etc.
  • the user cannot view the state of the camera when the camera rotates, resulting in low user experience.
  • the present application proposes a camera control method, device, electronic device and storage medium.
  • an embodiment of the present application provides a method for controlling a camera, which is applied to an electronic device, and the method includes: displaying a control interface of the camera; responding to a control operation for controlling the rotation of the camera, reporting to the camera The camera sends a rotation instruction, and the rotation instruction is used to control the camera to rotate to the target position; obtain the real-time rotation progress of the camera, and the real-time rotation progress is used to represent the progress of the camera rotation to the target position; The real-time rotation progress is displayed in the control interface.
  • an embodiment of the present application provides a camera control device, which is applied to electronic equipment.
  • the device includes: an interface display module, a rotation control module, a progress acquisition module, and a progress display module, wherein the interface display module A control interface for displaying the camera; the rotation control module is used for sending a rotation instruction to the camera in response to a control operation for controlling the rotation of the camera, and the rotation instruction is used to control the camera to rotate to a target position; the progress acquisition module is used to acquire the real-time rotation progress of the camera; the progress display module is used to display the real-time rotation progress in the control interface.
  • embodiments of the present application provide an electronic device, comprising: one or more processors; a memory; and one or more application programs, wherein the one or more application programs are stored in the memory and The one or more programs are configured to be executed by the one or more processors, and the one or more programs are configured to execute the camera control method provided by the first aspect above.
  • an embodiment of the present application provides a computer-readable storage medium, where a program code is stored in the computer-readable storage medium, and the program code can be invoked by a processor to execute the camera provided in the first aspect above control method.
  • a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the real-time rotation progress of the camera,
  • the real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that the progress of the camera rotation process can be displayed when the camera rotation is controlled, so that the user can understand the camera rotation. state to improve user experience.
  • FIG. 1 shows a schematic diagram of an application scenario provided by an embodiment of the present application.
  • FIG. 2 shows a flowchart of a control method of a camera according to an embodiment of the present application.
  • FIG. 3 shows a schematic diagram of a first interface provided by an embodiment of the present application.
  • FIG. 4 shows a schematic diagram of a second interface provided by an embodiment of the present application.
  • FIG. 5 shows a flowchart of a method for controlling a camera according to another embodiment of the present application.
  • FIG. 6 shows a schematic diagram of a third interface provided by an embodiment of the present application.
  • FIG. 7 shows a flowchart of a method for controlling a camera according to yet another embodiment of the present application.
  • FIG. 8 shows a schematic diagram of a fourth interface provided by an embodiment of the present application.
  • FIG. 9 shows a flowchart of step S330 in a method for controlling a camera provided by another embodiment of the present application.
  • FIG. 10 shows a schematic diagram of the principle of determining the position coordinates of a camera provided by an embodiment of the present application.
  • FIG. 11 shows a schematic diagram of a fifth interface provided by an embodiment of the present application.
  • FIG. 12 shows a schematic diagram of a sixth interface provided by an embodiment of the present application.
  • FIG. 13 shows a schematic diagram of a seventh interface provided by an embodiment of the present application.
  • FIG. 14 shows a schematic diagram of an eighth interface provided by an embodiment of the present application.
  • Fig. 15 shows a block diagram of a control apparatus of a camera according to an embodiment of the present application.
  • FIG. 16 is a block diagram of an electronic device for executing the camera control method according to the embodiment of the present application according to the embodiment of the present application.
  • FIG. 17 is a storage unit used to store or carry a program code for implementing a camera control method according to an embodiment of the present application according to an embodiment of the present application.
  • smart home is based on the residential platform, using integrated wiring technology, network communication technology, security technology, automatic control technology, audio and video technology to integrate the facilities related to home life, and build an efficient management system for residential facilities and family schedule affairs.
  • monitoring technology is widely used as an important part of the emerging smart home field.
  • a camera is usually installed in the house to monitor the house.
  • users can view the monitoring screen through electronic devices (such as smartphones, tablet computers, etc.), and can also use electronic devices to shoot the camera. position for remote control and adjustment.
  • the user when the user remotely controls and adjusts the shooting position of the camera through the electronic device, the user usually sends the control command remotely through the electronic device, and observes the monitoring screen in real time, and moves the camera up, down, left and right.
  • the rotation of the direction, so that the field of view of the camera is the range of the position that the user needs to view.
  • the location of the shooting area of the camera can be set as the frequently viewed position, and the angle corresponding to the frequently viewed position can be recorded.
  • the frequently viewed position can quickly control the camera to turn to the corresponding recorded angle, which is convenient for users to view the monitoring screen of a specific location.
  • the inventor found that when the user controls the camera to rotate to the desired position through the electronic device, the user cannot view the state of the camera when it is rotated, so it is impossible to know in real time how long it will take to rotate to the desired position. It is possible to wait for the monitoring screen to be completely still before confirming that the camera has been rotated to the required position, resulting in a large uncertainty in the experience, resulting in a low user experience.
  • the inventor proposes a camera control method, device, electronic device, and storage medium provided by the embodiments of the present application, which can realize the display of the progress of the camera rotation process when controlling the camera rotation, so that the user can know when the camera rotates. state to improve user experience.
  • the specific control method of the camera will be described in detail in the following embodiments.
  • FIG. 1 shows a network structure diagram of an application scenario of an embodiment of the present application.
  • the application scenario may include a smart home system 10, and the smart home system 10 may include an electronic device 100, a home device 200, a server 300 and The router 400, the electronic device can establish a wireless connection with the router 400, and the way of establishing a wireless connection between the home device 200 and the router 400 realizes data interaction between the electronic device 100 and the home device.
  • the electronic device 100 and the router 400 are connected in communication with the server 400 , and the electronic device 100 can perform data interaction with the home device 200 through the server 400 and the router 400 .
  • the home equipment 200 may be air conditioners, lighting fixtures, smart lights, cameras, smart sockets, wireless switches, smart curtain motors, smart speakers, and various sensors (eg, human sensors, door and window sensors, smoke alarms, etc.).
  • the electronic device 100 can remotely control the camera, for example, control the rotation and working parameters of the camera.
  • FIG. 2 shows a schematic flowchart of a method for controlling a camera provided by an embodiment of the present application.
  • the camera control method is applied to the camera control device 400 shown in FIG. 15 and the electronic device 100 ( FIG. 16 ) equipped with the camera control device 400 .
  • the following will take an electronic device as an example to describe the specific process of this embodiment.
  • the electronic device applied in this embodiment may be a smart phone, a tablet computer, a smart watch, a notebook computer, etc., which is not limited here. .
  • the flow shown in FIG. 2 will be described in detail below, and the control method of the camera may specifically include the following steps:
  • Step S110 Display the control interface of the camera.
  • the electronic device can display a control interface of the camera, and the control interface can be used to remotely control the shooting position, working mode, working parameters, etc. of the camera in the smart home system.
  • the shooting position of the camera may be the location area corresponding to the field of view of the camera;
  • the working mode of the camera may be the scene mode of the current working of the camera, such as night mode, day mode, sleep mode, snapshot mode, etc.
  • the specific working mode may be It is not limited; the working parameters can refer to the parameters of the current working of the camera, and these parameters can be adjustable parameters, so as to control and adjust these parameters, for example, the working parameters can include focal length, automatic gain control, backlight compensation, white balance, signal Noise ratio, etc., the specific working parameters may not be limited.
  • control interface may include controls or options for implementing different control functions of the camera, and when the electronic device detects operations on these controls or options, it may trigger corresponding control of the camera.
  • the control interface may also include a monitoring screen, that is, the area corresponding to the monitoring image collected by the camera. The user can view the monitoring screen while remotely controlling the camera in the control interface, which is convenient for the user to control the camera according to the monitoring screen.
  • the specific control interface may not be limited.
  • the electronic device may display a device list for managing and controlling household devices, and the device list may include controls corresponding to different household devices.
  • a client for managing household devices may be installed in the electronic device, the electronic device may run the client, and when a selection operation on the device list is detected, the device list may be displayed.
  • the electronic device detects the selection operation of the control corresponding to the camera, it can respond to the selection operation and display the current display interface as the control interface of the camera.
  • FIG. 3 shows a schematic interface diagram of the device list interface A1.
  • the device list interface A1 includes controls corresponding to multiple home devices.
  • the user can also add devices in the device list interface, thereby To meet the user's needs for adding new devices, of course, the specific device list interface may not be limited.
  • Step S120 In response to the control operation for controlling the rotation of the camera, send a rotation instruction to the camera, where the rotation instruction is used to control the camera to rotate to a target position.
  • the electronic device may detect operations in the control interface, for example, detect click operations, pressing operations, sliding operations, etc. in the control interface.
  • the operation on the control interface may be an operation on a control used to control the camera in the control interface, or may be an operation on other areas, which is not limited herein.
  • the control interface may include controls for controlling the camera to rotate in four directions: up, down, left, and right, respectively.
  • the control interface may include four rotating controls, each of the four rotating controls corresponds to a direction, and by detecting the operation of the four rotating controls, the camera can be controlled according to the operation of the rotating controls rotate, and then control the shooting position of the camera to change;
  • the control interface may include a control for controlling the rotation of the camera, the control includes four touchable areas, and each of the four touchable areas Each touchable area corresponds to a rotation direction, and by detecting the touch operation on the four touchable areas, the camera can be controlled to rotate, and then the shooting position of the camera can be controlled to change.
  • the operations of the controls for controlling the camera may not be limited above, for example, it may be a pressing operation, etc.; the specific form of the controls for controlling the camera may also not be limited.
  • the electronic device can store the position and angle of the camera after each adjustment according to the user's adjustment operation on the shooting position of the camera, and receive the position name input by the user, and store it with the position angle, so that the electronic device can store the position and angle of each camera.
  • the historical shooting position of the shooting and the position angle corresponding to the historical shooting position are formed, and the corresponding relationship between the shooting position and the position angle is formed, and the corresponding relationship is stored.
  • the electronic device responds to the control operation, it can obtain the target position to be photographed according to the control operation, and then obtain the position angle corresponding to the target position based on the pre-stored correspondence; and then generate a rotation based on the position angle corresponding to the target position. command to control the camera to rotate to the position angle corresponding to the target position.
  • the control interface may include an input area for inputting historical positions, and the electronic device may read the position angle corresponding to the target position according to the target position input by the user, and based on the read The position angle generates a corresponding rotation command and sends it to the camera to control the camera to rotate to the position angle corresponding to the target position, so that the user only needs to input the shooting position to be viewed on the control interface, and then the camera can be controlled to rotate to different angles.
  • the monitoring image area A3 corresponding to the monitoring image captured by the camera is included.
  • the area for input adjustment adjustment can be displayed in other areas except the monitoring image area A3, and the user can Input the target position to be adjusted, such as "the sofa in the living room” in Figure 4.
  • the electronic device responds to the input target position and sends a rotation command to the camera, thereby controlling the camera to rotate to the target position.
  • the electronic device can acquire images captured by the camera at each shooting angle, and identify the location name corresponding to each shooting location according to the captured images. Then, the recognized position name and its corresponding shooting angle are stored, so that the electronic device can generate a rotation instruction according to the target position input by the user in the above control interface, and according to the stored shooting angle corresponding to the target position to control the The camera rotates to the position angle corresponding to the target position.
  • the electronic device can use a pre-trained location recognition model to recognize location names corresponding to images with different shooting angles.
  • the location recognition model can be obtained by training the initial model according to a large number of indoor images of houses of different types and the location name marked on each indoor image.
  • the initial model can be a neural network model, etc., which is not limited here. .
  • the electronic device can receive the input floor plan, select the corresponding image recognition model according to the floor plan, and then input the images captured by the camera at different shooting angles into the position recognition model, and the position recognition model can be based on the input image. to identify the corresponding location name.
  • the image recognition model can be trained correspondingly according to different house types, so that the image recognition model can be trained accordingly.
  • the image recognition model can obtain more accurate recognition results when recognizing the location names corresponding to the images of each shooting angle.
  • the above location recognition model can be stored in the electronic device or in the server, which is not limited here.
  • the electronic device can directly call the image recognition model for recognition.
  • the location recognition model is stored in the server, the electronic device can send images of different shooting locations to the server, and the server calls the location recognition model to recognize the location name and returns it to the electronic device.
  • the electronic device when the electronic device detects the control operation for controlling the rotation of the camera input in the control interface, the electronic device can respond to the control operation for controlling the rotation of the camera, and send a rotation instruction to the server that manages the smart home equipment, and the server It is used to send the rotation instruction to the camera, so as to realize the remote control of the camera to rotate to the target position by using the electronic device.
  • the camera when controlling the camera to rotate, the camera may be in a stationary state at the moment, or may be in the process of rotating, for example, the user is in the process of controlling the camera to rotate to a specified position, therefore, the camera is controlled to rotate to the target position , which can be to control the camera to rotate from the position in response to the above control operation to the target position.
  • the position when responding to the control operation may be the position when the camera does not rotate, or the position when the camera detects the control operation during the previous rotation process and responds to the control operation.
  • the target position refers to the shooting position of the camera, that is, in the embodiment of the present application, the shooting position of the camera is controlled so that the camera is rotated to the shooting position required by the user.
  • Step S130 Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
  • the electronic device when it sends a rotation instruction to the camera, it can also acquire the real-time rotation progress of the camera during the rotation of the camera.
  • the real-time rotation progress is used to represent the real-time progress of the process of rotating the camera to the target position, and the real-time rotation progress corresponds to the current moment.
  • the rotation progress can refer to the degree of progress of the camera rotation, that is, the degree of progress of the camera rotation from the position when the response is rotated to the target position. Rotate 30°, then the rotation progress is 50%.
  • the electronic device can obtain the real-time rotation progress of the camera from a server for managing smart home devices, wherein the server can calculate the required rotation of the camera according to the position of the camera in response to the above control operation and the target position Then, according to the rotated angle reported by the camera in real time and the calculated required rotation angle, calculate the ratio of the rotated angle to the required rotation angle, and use the ratio as the real-time rotation progress.
  • the electronic device can also obtain the position of the camera in response to the control operation as the initial position; then, according to the initial position and the target position, calculate the angle that the camera needs to rotate as the angle to be rotated; according to the angle that the camera has rotated obtained from the server in real time , and the ratio of the angle to be rotated to determine the real-time rotation progress of the camera.
  • the electronic device can determine the position angle corresponding to the target position according to the target position and the stored correspondence between each shooting position and the position angle, and then according to the position corresponding to the position of the camera in response to the above control operation Angle, and the position angle corresponding to the target position, determine the angle to be rotated as the angle to be rotated, and then calculate the real-time rotation progress according to the rotation speed and the angle to be rotated.
  • the electronic can determine the rotated angle based on the rotation speed and the rotated duration at the current moment; then, determine the real-time rotation progress of the camera based on the ratio of the rotated angle to the to-be-rotated angle.
  • the manner in which the electronic device obtains the camera from the position in response to the control operation and rotates to the target position may not be limited.
  • Step S140 Display the real-time rotation progress on the control interface.
  • the electronic device after acquiring the real-time rotation progress, can display the real-time rotation progress on the control interface, so that the user can view the rotation process in real time after triggering the control of the camera to rotate to the target position.
  • the progress of the camera is convenient for the user to understand the process of the camera rotation.
  • the electronic device can continuously obtain the real-time rotation progress and update the real-time rotation progress displayed in the control interface, thereby realizing the display of the rotation progress in the entire rotation process.
  • the manner of implementing the rotation progress displayed by the electronic device may not be limited, for example, the electronic device may also display the real-time rotation progress in the form of text, specifically, display the real-time rotation progress in the form of a percentage of text.
  • a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera.
  • the real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that when the camera is controlled to rotate, the progress in the process of the camera rotation can be displayed, so that the The user understands the state of the camera when it is rotated, which improves the user experience.
  • FIG. 5 shows a schematic flowchart of a method for controlling a camera provided by another embodiment of the present application.
  • the control method of the camera is applied to the above-mentioned electronic equipment.
  • the flow shown in FIG. 5 will be described in detail below.
  • the control method of the camera may specifically include the following steps:
  • Step S210 Display the control interface of the camera, the control interface includes a first designated area, and the first designated area is used to display the monitoring image collected by the camera in real time.
  • the control interface may include a first designated area, and the first designated area is used to display a monitoring image collected by a camera in real time.
  • the first designated area can be understood as the area where the monitoring screen is located.
  • the user can use the monitoring screen as a reference to determine whether the camera is adjusted to the desired position when controlling the camera. For example, when the user determines that the position to which the camera is adjusted is not the area he wants to shoot based on the monitored image area, the shooting position of the camera can be controlled again to adjust to the position required by the user.
  • Step S220 In response to the control operation for controlling the rotation of the camera, send a rotation instruction to the camera, where the rotation instruction is used to control the camera to rotate to a target position.
  • Step S230 Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
  • step S220 and step S230 reference may be made to the content of the foregoing embodiments, and details are not described herein.
  • Step S240 Display the real-time rotation progress in the form of a progress bar in a second designated area in the control interface, wherein the second designated area is located in an area other than the first designated area in the control interface .
  • the real-time rotation progress when the electronic device displays the real-time rotation progress in the control interface, the real-time rotation progress may be displayed in the form of a progress bar in the second designated area in the control interface.
  • the progress bar is that when the computer is processing the task, the speed of the processing task, the degree of completion, the size of the remaining unfinished task, and the possible processing time, etc. are displayed in real time in the form of pictures.
  • the progress in the progress bar is positively correlated with the real-time rotation progress, that is, the greater the progress in the progress bar, the greater the real-time rotation progress, so that the user can
  • the progress bar knows the rotation progress of the camera from the position in response to the control operation to the target position.
  • the second designated area may be located in an area other than the first designated area in the control interface, so that the user can view the monitoring image in the first designated area and pass the progress of the second designated area.
  • the specific position of the second designated area in the areas other than the first designated area in the above control interface may not be limited.
  • the first designated area A3 corresponding to the monitoring image collected by the camera is included.
  • the input adjustment can be displayed in other areas except the first designated area A3.
  • the user can input the target position to be adjusted, such as "the sofa in the living room" in Figure 4.
  • the electronic device responds to the input target position and sends a rotation command to the camera, so as to control the camera to rotate to The target position; in addition, when sending the rotation command to the camera, a progress bar A4 can be displayed in the area where the adjustment position is input, and the progress bar A4 is located below the monitoring image area A3, so that the user can know the rotation progress of the camera at a glance .
  • a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera.
  • the real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface in the form of a progress bar in the area other than the first designated area where the monitoring image is displayed, Therefore, while viewing the monitoring image, the user can know the real-time rotation progress of the camera through the progress bar, and the progress bar is displayed in the control interface except for the first designated area above, which does not affect the monitoring image area. Display, improve user experience.
  • FIG. 7 shows a schematic flowchart of a method for controlling a camera provided by another embodiment of the present application.
  • the control method of the camera is applied to the above-mentioned electronic equipment.
  • the flow shown in FIG. 7 will be described in detail below.
  • the control method of the camera may specifically include the following steps:
  • Step S310 Display the control interface of the camera, the control interface includes a first designated area and a second designated area, the first designated area is used to display the monitoring image collected by the camera in real time, and the second designated area It includes interface thumbnails of monitoring images corresponding to multiple historical viewing positions.
  • the control interface of the camera displayed by the electronic device may include a first designated area for displaying surveillance images captured by the camera in real time, and an interface thumbnail for displaying surveillance images corresponding to multiple historical viewing locations.
  • the first designated area can be understood as the area where the monitoring screen is displayed.
  • the user can set the frequently viewed viewing position, and set to the above historical viewing position, the electronic device can display it in the displayed control interface, so that the user can select the frequently viewed position, And control the camera to rotate to the required common viewing position for shooting.
  • the control interface A2 may include the interface thumbnail A5 of the monitoring image corresponding to the frequently viewed position, such as the interface thumbnail corresponding to “the sofa in the living room” shown in FIG. 8 , the “balcony in the living room” The corresponding interface thumbnail.
  • control interface may include controls with different functions, for example, controls corresponding to functions such as “sleep”, “frequently viewed position”, “snapshot”, “recording”, “album”, etc. shown in FIG. 8 , Among them, the “sleep” control is used to control the camera to be in sleep mode; the “frequently viewed position” control is used to trigger the display of the interface thumbnail corresponding to the frequently viewed position; the “snapshot” control is used to control the camera to take snapshots; the “recording” control is used to View surveillance video; “Album” control is used to trigger viewing album of surveillance images.
  • the functional controls specifically included in the control interface may not be limited.
  • the electronic device when it detects the selection operation of the control of the "frequently viewed position", it can display the interface thumbnail corresponding to the frequently viewed position in the control interface.
  • the color of the selected control can be distinguished from the colors of other controls, so that the user can know the currently selected control.
  • the electronic device can also add frequently viewed positions according to the user's operation.
  • a “+” may be displayed in one of the interface thumbnails corresponding to the frequently viewed positions, when the electronic device detects a touch operation on the interface thumbnail , you can trigger the addition of frequently viewed positions; for another example, the electronic device can detect the duration of continuous pressing when detecting the pressing operation in the bottom area of the control interface, and when the duration of continuous pressing exceeds the specified duration, trigger the addition of frequently viewed positions for the specified duration It can be 2 seconds, 3 seconds, etc., which is not limited here. Therefore, it is possible to realize the addition of frequently viewed positions by the user.
  • control interface may include controls for controlling the camera to rotate in four directions: up, down, left and right, so that the user can control the camera to rotate to the desired position, and then rotate the camera to the desired position.
  • the completed location angle is recorded; then according to the location name edited by the user, the location name and the recorded location angle are associated and stored, so as to complete the addition of frequently seen locations.
  • Step S320 In response to the selection operation of the interface thumbnail corresponding to the target position, send a rotation instruction to the camera, and the rotation instruction is used to control the camera to rotate to the target position, wherein the target position is the plurality of Any of the historical viewing locations.
  • the electronic device may detect operations in the control interface, for example, detect click operations, pressing operations, sliding operations, etc. in the control interface.
  • the operation on the control interface may be an operation on a control used to control the camera in the control interface, or may be an operation on other areas, which is not limited herein.
  • the electronic device when it detects the selection operation of the interface thumbnail, it can determine the target position corresponding to the selected interface thumbnail according to the selected interface thumbnail, and then according to the recorded position corresponding to the target position Angle, generate a rotation command, and send the rotation command to the camera, so as to control the camera to rotate to the target position.
  • the selection operation may be a click operation, a double-click operation, or a pressing operation whose pressing duration exceeds a preset duration, etc., which is not limited herein.
  • Step S330 Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
  • the electronic device can calculate the real-time rotation progress of the camera according to the rotation speed of the camera, so that the rotation progress of the camera can be displayed in a more real-time manner.
  • step S330 may include:
  • Step S331 Acquire the position of the camera in response to the control operation as an initial position.
  • the electronic device can send a camera position acquisition request to a server that manages smart home devices, and then receive the camera position returned by the server.
  • the camera position acquisition request can be used to request the camera position when the recorded response control operation is obtained from the server, wherein the electronic device can add the time when the response control operation is performed in the camera position acquisition request to obtain the response control operation. The position of the camera during the operation; then, the electronic device receives the response returned by the server to control the position of the camera during the operation.
  • Step S332 Determine the real-time rotation progress of the camera based on the initial position, the target position, and the rotation speed of the camera.
  • the electronic device may calculate the real-time rotation progress of the camera based on the initial position obtained above, the target position to which the camera needs to be rotated, and the rotation speed of the camera. Specifically, the electronic device can determine the rotation angle that the camera needs to rotate based on the initial position and the target position, where the initial position and the target position are both position angles; then, based on the rotation angle and the rotation speed, determine the total time the camera needs to rotate. ; and then determine the real-time rotation progress of the camera based on the ratio of the rotation duration of the camera at the current moment to the total duration.
  • Fig. 10 When recording the angular orientation of the camera, it can be recorded by using a Cartesian coordinate system.
  • the angle of the camera's sitting and right rotation can be represented by the X-axis, and the camera's up and down rotation angles. It can be represented by the Y-axis, and the units on the X-axis and the Y-axis can be angles, and a coordinate represents a position.
  • the camera needs to be controlled to move to the target position, it actually moves along one or more straight lines. For example, moving from position A to position B in FIG. 10 needs to move three times along three straight lines. Therefore, when the position coordinates of the initial position of the camera in the above coordinate system and the rotation speed of the camera are known, the total duration of rotation can be accurately calculated, and the ratio of the rotation duration to the total duration can be obtained to obtain the rotation schedule.
  • Step S340 Display a progress bar around the interface thumbnail corresponding to the target position, where the progress bar is used to represent the real-time rotation progress.
  • a progress bar can be displayed around the interface thumbnail corresponding to the above target position.
  • the progress bar is used to represent the real-time rotation progress, that is to say , the progress represented by the progress bar can correspond to the real-time rotation progress, and the user can know the real-time rotation progress of the camera by observing the progress bar.
  • the electronic device detects the selection operation of the interface thumbnail of the “balcony in the living room”, it can send a message for controlling the camera to rotate to the “balcony in the living room”.
  • the rotation command of the shooting position is obtained, and the real-time rotation progress of the camera is obtained, and the progress bar A4 is displayed around the thumbnail of the interface of the "balcony in the living room".
  • the starting position of the progress bar is not limited. For example, it can be the middle position of the left edge of the interface thumbnail in FIG. 11.
  • the progress bar can gradually fill the surrounding area of the interface thumbnail as time changes.
  • the camera After the camera rotates to the target position, the camera completes the entire rotation process, and at this time, the progress bar fills the periphery of the interface thumbnail. Therefore, the user can observe the change of the progress bar around the selected interface thumbnail, and know the rotation progress of the camera during the rotation of the camera, thereby improving the user experience.
  • the progress bar when using the above interface thumbnails to display the real-time rotation progress, in addition to displaying the progress bar around the interface thumbnail corresponding to the target position, the progress bar may also be displayed in the interface thumbnail corresponding to the target position.
  • the progress bar is used to represent the real-time rotation progress.
  • the electronic device when it detects the selection operation of the interface thumbnail of the “balcony in the living room”, it can send a message for controlling the camera to rotate to the “balcony in the living room”.
  • the rotation command of the shooting position is obtained, and the real-time rotation progress of the camera is obtained, and the progress bar is displayed in the interface thumbnail of the "balcony in the living room”.
  • the starting position of the progress bar can be the leftmost side of the interface thumbnail.
  • the progress bar gradually fills from the left edge to the right as time changes.
  • the camera rotates to the target position, the camera completes the entire process.
  • the progress bar fills the thumbnails of the entire interface. Therefore, the user can observe the change of the progress bar in the selected interface thumbnail, and know the rotation progress of the camera during the rotation of the camera, thereby improving the user experience.
  • the electronic device in addition to displaying a progress bar corresponding to the real-time rotation progress in the control interface, can also generate text prompt information based on the real-time rotation progress, and the text prompt information is used to prompt the user of the real-time rotation progress of the camera; then Display the generated text prompt information in the control interface.
  • the specific content of the text prompt information is not limited, and its function is to indicate the completion of the rotation process, so that the user can not only know the rotation process through the progress bar, but also know whether the rotation process is completed directly according to the text prompt information. .
  • the camera can send abnormal information to the server when abnormal rotation occurs, for example, the camera is stuck during rotation, and the server can generate abnormal indication information according to the abnormal information, and the abnormal indication information can carry the abnormal rotation abnormality. type, etc.
  • the electronic device After receiving the abnormality indication information sent by the server, the electronic device can generate corresponding first prompt information according to the abnormality indication information, and display the first prompt information to remind the camera of abnormal rotation and the type of abnormal rotation Wait.
  • the electronic device may stop updating the above real-time rotation progress when receiving abnormal indication information. For example, stop updating the progress in the progress bar so the user knows that the camera is not moving to the target position.
  • the above real-time rotation progress may be calculated by the electronic device according to the rotation speed of the camera, there may be situations where the actual rotation progress of the camera is inconsistent with the rotation progress calculated by the electronic device, or the camera does not rotate when it actually rotates to the target position.
  • the electronic device can obtain the image captured by the current camera as the current captured image, and match the image features between the current captured image and the historical monitoring image of the target location to obtain the matching degree;
  • the matching degree between the currently captured image and the historical monitoring image is greater than or equal to the preset matching degree, it is determined that the camera has been rotated to the target position;
  • the matching degree between the currently captured image and the historical monitoring image of the target position is less than the preset matching degree, it is determined that If the camera does not rotate to the target position, second prompt information may be output, and the second prompt information is used to indicate that the camera rotates abnormally and does not rotate to the target position.
  • the electronic device since the camera shoots indoor images, there may also be indoor characters occupying a large area within the camera's field of view, resulting in the match between the currently captured image and the historical monitoring image of the target location. Less than the preset matching degree. Therefore, before the electronic device matches the image captured by the current camera with the historical monitoring image of the target location, it can also determine the portrait area in the image captured by the current camera, and calculate the proportion of the portrait area in the captured image.
  • the image captured by the current camera can be matched with the historical monitoring image of the target location, and the subsequent steps can be performed; if the ratio is greater than the specified ratio, the electronic device can be separated by a preset period of time Then obtain the image captured by the camera again, and execute the portrait area in the image captured by the current camera again, and calculate the proportion of the portrait area in the captured image. If the ratio is not greater than the specified ratio, the image captured by the current camera can be Image features are matched with historical surveillance images of the target location, and subsequent steps are performed.
  • the preset duration may be 3 seconds, 5 seconds, etc., which is not limited here; the specified ratio may be 40%, 50%, etc., and the specific value may not be limited.
  • N is a positive integer greater than the specified value, and the specified value can be for 4, 6, etc.
  • the monitoring image can be displayed in the control interface, and the control interface includes the interface thumbnail corresponding to the historical viewing position, and responds to the interface thumbnail corresponding to the target position.
  • the select operation send a rotation instruction to the camera, the rotation instruction is used to control the camera to rotate to the target position, and obtain the real-time rotation progress of the camera, the real-time rotation progress is used to represent the progress of the camera rotation to the target position, and then the real-time rotation progress
  • the progress bar is displayed around the thumbnail of the interface, so that the user can view the monitoring image area and know the real-time rotation progress of the camera through the displayed progress bar, and the progress bar is in the control interface except the above Displaying in areas other than the monitoring image area does not affect the display of the monitoring image area and improves user experience.
  • the user can select the historical viewing positions and control the camera to move to the corresponding historical viewing positions, which facilitates the user to control the shooting position of the camera.
  • FIG. 15 shows a structural block diagram of a camera control apparatus 400 provided by an embodiment of the present application.
  • the camera control apparatus 400 applies the above-mentioned electronic equipment.
  • the camera control apparatus 400 includes an interface display module 410 , a rotation control module 420 , a progress acquisition module 430 and a progress display module 440 .
  • the interface display module 410 is used to display the control interface of the camera; the rotation control module 420 is used to respond to the control operation for controlling the rotation of the camera, and send a rotation instruction to the camera, the rotation instruction Used to control the camera to rotate to the target position; the progress acquisition module 430 is used to acquire the real-time rotation progress of the camera; the progress display module 440 is used to display the real-time rotation progress in the control interface .
  • control interface includes a first designated area, and the first designated area is used to display the monitoring image collected by the camera in real time.
  • the progress display module 440 may be specifically configured to: display the real-time rotation progress in the form of a progress bar in a second designated area in the control interface, wherein the second designated area is located in the control interface except for the first designated area. an area outside the designated area.
  • the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position.
  • the progress display module 440 may be specifically configured to: display a progress bar around the interface thumbnail, where the progress bar is used to represent the real-time rotation progress.
  • the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position.
  • the progress display module 440 may be specifically configured to: display a progress bar in the interface thumbnail, where the progress bar is used to represent the real-time rotation progress.
  • the progress obtaining module 430 may include: a position obtaining unit and a progress determining unit.
  • the position acquisition unit is used to acquire the position of the camera in response to the control operation as the initial position;
  • the progress determination unit is used to determine the position of the camera based on the initial position, the target position and the rotation speed of the camera The real-time rotation progress of the camera.
  • the progress acquisition unit may be specifically configured to: determine the rotation angle of the camera to be rotated based on the initial position and the target position; determine the rotation angle of the camera based on the rotation angle and the rotation speed The total duration of rotation; the real-time rotation progress of the camera is determined based on the ratio of the rotation duration of the camera at the current moment to the total duration.
  • the location acquiring unit may be specifically configured to: send a request for acquiring the location of the camera to a server that manages smart home devices; and receive the location of the camera returned by the server.
  • control interface includes interface thumbnails of multiple monitoring images corresponding to multiple historical viewing positions.
  • the rotation control module 420 may be specifically configured to send a rotation instruction to the camera in response to a selection operation of an interface thumbnail corresponding to a target position, where the target position is any position among the multiple historical viewing positions.
  • the camera control apparatus 400 may further include: an information generating module and an information prompting module.
  • the information generation module is used to generate text prompt information based on the real-time rotation progress, and the text prompt information is used to prompt the user of the real-time rotation progress of the camera; the information prompt module is used to display the text prompt in the control interface information.
  • the rotation control module 420 may be specifically configured to: in response to a control operation for controlling the rotation of the camera, send a rotation instruction to a server that manages smart home devices, and the server is configured to send the rotation instruction to the camera.
  • the coupling between the modules may be electrical, mechanical or other forms of coupling.
  • each functional module in each embodiment of the present application may be integrated into one processing module, or each module may exist physically alone, or two or more modules may be integrated into one module.
  • the above-mentioned integrated modules can be implemented in the form of hardware, and can also be implemented in the form of software function modules.
  • a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera.
  • the real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that when the camera is controlled to rotate, the progress in the process of the camera rotation can be displayed, so that the The user understands the state of the camera when it is rotated, which improves the user experience.
  • FIG. 16 shows a structural block diagram of an electronic device provided by an embodiment of the present application. It shows a structural block diagram of an electronic device provided by an embodiment of the present application.
  • the electronic device 100 may be an electronic device capable of running an application program, such as a smart phone, a tablet computer, a smart watch, and a notebook computer.
  • the electronic device 100 in the present application may include one or more of the following components: a processor 110, a memory 120, a display screen 130, and one or more application programs, wherein the one or more application programs may be stored in the memory 120 and accessed by Configured to be executed by one or more processors 110, the one or more programs are configured to execute the methods described in the foregoing method embodiments.
  • the processor 110 may include one or more processing cores.
  • the processor 110 uses various interfaces and lines to connect various parts of the entire electronic device 100, and executes by running or executing the instructions, programs, code sets or instruction sets stored in the memory 120, and calling the data stored in the memory 120.
  • the processor 110 may adopt at least one of a digital signal processing (Digital Signal Processing, DSP), a Field-Programmable Gate Array (Field-Programmable Gate Array, FPGA), and a Programmable Logic Array (Programmable Logic Array, PLA).
  • DSP Digital Signal Processing
  • FPGA Field-Programmable Gate Array
  • PLA Programmable Logic Array
  • the processor 110 may integrate one or a combination of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU), a modem, and the like.
  • CPU Central Processing Unit
  • GPU Graphics Processing Unit
  • the CPU mainly handles the operating system, user interface and application programs, etc.
  • the GPU is used for rendering and drawing of the display content
  • the modem is used to handle wireless communication. It can be understood that, the above-mentioned modem may also not be integrated into the processor 110, and is implemented by a communication chip alone.
  • the memory 120 may include random access memory (Random Access Memory, RAM), or may include read-only memory (Read-Only Memory). Memory 120 may be used to store instructions, programs, codes, sets of codes, or sets of instructions.
  • the memory 120 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.) , instructions for implementing the following method embodiments, and the like.
  • the storage data area may also store data (such as phone book, audio and video data, chat record data) created by the electronic device 100 during use.
  • the display screen 130 is used to display information input by the user, information provided to the user, and various graphical user interfaces of the electronic device 100, which may be composed of graphics, text, icons, numbers, videos, and any combination thereof.
  • the display screen 130 may be a liquid crystal display (Liquid Crystal Display, LCD) or an organic light-emitting diode (Organic Light-Emitting Diode, OLED), which is not limited herein.
  • FIG. 17 shows a structural block diagram of a computer-readable storage medium provided by an embodiment of the present application.
  • the computer-readable medium 800 stores program codes, and the program codes can be invoked by the processor to execute the methods described in the above method embodiments.
  • the computer readable storage medium 800 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read Only Memory), EPROM, hard disk, or ROM.
  • the computer-readable storage medium 800 includes a non-transitory computer-readable storage medium.
  • Computer readable storage medium 800 has storage space for program code 810 to perform any of the method steps in the above-described methods. These program codes can be read from or written to one or more computer program products.
  • Program code 810 may be compressed, for example, in a suitable form.

Landscapes

  • Engineering & Computer Science (AREA)
  • Multimedia (AREA)
  • Signal Processing (AREA)
  • Studio Devices (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

The present application discloses a camera control method and apparatus, an electronic device, and a storage medium. The camera control method is applied to an electronic device, and the camera control method comprises: displaying a control interface of a camera; in response to a control operation for controlling the rotation of the camera, sending a rotation instruction to the camera, the rotation instruction being used for controlling the camera to rotate to a target position; acquiring a real-time rotation progress of the camera, the real-time rotation progress being used for representing the progress of the camera rotating to the target position; and displaying the real-time rotation progress in the control interface. Said method can display the rotation progress of a camera when the camera is controlled to rotate.

Description

摄像头的控制方法、装置、电子设备及存储介质Camera control method, device, electronic device and storage medium
相关申请的交叉引用CROSS-REFERENCE TO RELATED APPLICATIONS
本申请要求于2020年9月14日提交的申请号为202010962150.6的中国申请的优先权,其在此出于所有目的通过引用将其全部内容并入本文。This application claims priority to Chinese Application No. 202010962150.6 filed on September 14, 2020, which is hereby incorporated by reference in its entirety for all purposes.
技术领域technical field
本申请涉及智能家居技术领域,更具体地,涉及一种摄像头的控制方法、装置、电子设备及存储介质。The present application relates to the field of smart home technology, and more particularly, to a camera control method, device, electronic device and storage medium.
背景技术Background technique
在智能家居技术中,监控技术作为目前兴起的智能家居领域中的重要一环,被广泛的应用。在智能家居领域中,通常是通过安装的摄像头对房屋进行监控,用户可以通过在电子设备(例如智能手机、平板电脑等)显示的控制界面上对摄像头拍摄的位置进行控制,进而查看不同的监控位置区域内的监控内容。但是,在控制摄像头进行转动时,用户无法查看到摄像头转动时的状态,造成用户体验较低。In smart home technology, monitoring technology is widely used as an important part of the emerging smart home field. In the field of smart home, the house is usually monitored by the installed camera, and the user can control the position captured by the camera on the control interface displayed by the electronic device (such as a smart phone, tablet, etc.), and then view different monitoring Monitoring content within the location area. However, when controlling the camera to rotate, the user cannot view the state of the camera when the camera rotates, resulting in low user experience.
发明内容SUMMARY OF THE INVENTION
鉴于上述问题,本申请提出了一种摄像头的控制方法、装置、电子设备及存储介质。In view of the above problems, the present application proposes a camera control method, device, electronic device and storage medium.
第一方面,本申请实施例提供了一种摄像头的控制方法,应用于电子设备,所述方法包括:展示所述摄像头的控制界面;响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置;获取所述摄像头的实时转动进度,所述实时转动进度用于表征所述摄像头转动至所述目标位置的进度;将所述实时转动进度于所述控制界面中进行展示。In a first aspect, an embodiment of the present application provides a method for controlling a camera, which is applied to an electronic device, and the method includes: displaying a control interface of the camera; responding to a control operation for controlling the rotation of the camera, reporting to the camera The camera sends a rotation instruction, and the rotation instruction is used to control the camera to rotate to the target position; obtain the real-time rotation progress of the camera, and the real-time rotation progress is used to represent the progress of the camera rotation to the target position; The real-time rotation progress is displayed in the control interface.
第二方面,本申请实施例提供了一种摄像头的控制装置,应用于电子设备,所述装置包括:界面展示模块、转动控制模块、进度获取模块以及进度展示模块,其中,所述界面展示模块用于展示所述摄像头的控制界面;所述转动控制模块用于响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置;所述进度获取模块用于获取所述摄像头的实时转动进度;所述进度展示模块用于将所述实时转动进度于所述控制界面中进行展示。In a second aspect, an embodiment of the present application provides a camera control device, which is applied to electronic equipment. The device includes: an interface display module, a rotation control module, a progress acquisition module, and a progress display module, wherein the interface display module A control interface for displaying the camera; the rotation control module is used for sending a rotation instruction to the camera in response to a control operation for controlling the rotation of the camera, and the rotation instruction is used to control the camera to rotate to a target position; the progress acquisition module is used to acquire the real-time rotation progress of the camera; the progress display module is used to display the real-time rotation progress in the control interface.
第三方面,本申请实施例提供了一种电子设备,包括:一个或多个处理器;存储器;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个程序配置用于执行上述第一方面提供的摄像头的控制方法。In a third aspect, embodiments of the present application provide an electronic device, comprising: one or more processors; a memory; and one or more application programs, wherein the one or more application programs are stored in the memory and The one or more programs are configured to be executed by the one or more processors, and the one or more programs are configured to execute the camera control method provided by the first aspect above.
第四方面,本申请实施例提供了一种计算机可读取存储介质,所述计算机可读取存储介质中存储有程序代码,所述程序代码可被处理器调用执行上述第一方面提供的摄像头的控制方法。In a fourth aspect, an embodiment of the present application provides a computer-readable storage medium, where a program code is stored in the computer-readable storage medium, and the program code can be invoked by a processor to execute the camera provided in the first aspect above control method.
本申请提供的方案,通过展示摄像头的控制界面,响应用于控制摄像头转动的控制操作,向摄像头发送转动指令,该转动指令用于控制该摄像头转动至目标位置,并获取摄像头的实时转动进度,该实时转动进度用于表征摄像头转动至目标位置的进度,然后将实时转动进度于控制界面中进行展示,从而可以实现在控制摄像头转动时,展 示摄像头转动过程中的进度,使用户了解到摄像头转动时的状态,提升用户体验。In the solution provided by the present application, by displaying the control interface of the camera, in response to the control operation for controlling the rotation of the camera, a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the real-time rotation progress of the camera, The real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that the progress of the camera rotation process can be displayed when the camera rotation is controlled, so that the user can understand the camera rotation. state to improve user experience.
附图说明Description of drawings
为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to illustrate the technical solutions in the embodiments of the present application more clearly, the following briefly introduces the drawings that are used in the description of the embodiments. Obviously, the drawings in the following description are only some embodiments of the present application. For those skilled in the art, other drawings can also be obtained from these drawings without creative effort.
图1示出了本申请实施例提供的应用场景的示意图。FIG. 1 shows a schematic diagram of an application scenario provided by an embodiment of the present application.
图2示出了根据本申请一个实施例的摄像头的控制方法流程图。FIG. 2 shows a flowchart of a control method of a camera according to an embodiment of the present application.
图3示出了本申请实施例提供的第一种界面示意图。FIG. 3 shows a schematic diagram of a first interface provided by an embodiment of the present application.
图4示出了本申请实施例提供的第二种界面示意图。FIG. 4 shows a schematic diagram of a second interface provided by an embodiment of the present application.
图5示出了根据本申请另一个实施例的摄像头的控制方法流程图。FIG. 5 shows a flowchart of a method for controlling a camera according to another embodiment of the present application.
图6示出了本申请实施例提供的第三种界面示意图。FIG. 6 shows a schematic diagram of a third interface provided by an embodiment of the present application.
图7示出了根据本申请又一个实施例的摄像头的控制方法流程图。FIG. 7 shows a flowchart of a method for controlling a camera according to yet another embodiment of the present application.
图8示出了本申请实施例提供的第四种界面示意图。FIG. 8 shows a schematic diagram of a fourth interface provided by an embodiment of the present application.
图9示出了本申请又一个实施例提供的摄像头的控制方法中步骤S330的流程图。FIG. 9 shows a flowchart of step S330 in a method for controlling a camera provided by another embodiment of the present application.
图10示出了本申请实施例提供的确定摄像头的位置坐标的原理示意图。FIG. 10 shows a schematic diagram of the principle of determining the position coordinates of a camera provided by an embodiment of the present application.
图11示出了本申请实施例提供的第五种界面示意图。FIG. 11 shows a schematic diagram of a fifth interface provided by an embodiment of the present application.
图12示出了本申请实施例提供的第六种界面示意图。FIG. 12 shows a schematic diagram of a sixth interface provided by an embodiment of the present application.
图13示出了本申请实施例提供的第七种界面示意图。FIG. 13 shows a schematic diagram of a seventh interface provided by an embodiment of the present application.
图14示出了本申请实施例提供的第八种界面示意图。FIG. 14 shows a schematic diagram of an eighth interface provided by an embodiment of the present application.
图15示出了根据本申请一个实施例的摄像头的控制装置的一种框图。Fig. 15 shows a block diagram of a control apparatus of a camera according to an embodiment of the present application.
图16是本申请实施例的用于执行根据本申请实施例的摄像头的控制方法的电子设备的框图。FIG. 16 is a block diagram of an electronic device for executing the camera control method according to the embodiment of the present application according to the embodiment of the present application.
图17是本申请实施例的用于保存或者携带实现根据本申请实施例的摄像头的控制方法的程序代码的存储单元。FIG. 17 is a storage unit used to store or carry a program code for implementing a camera control method according to an embodiment of the present application according to an embodiment of the present application.
具体实施方式detailed description
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述。In order to make those skilled in the art better understand the solutions of the present application, the following will clearly and completely describe the technical solutions in the embodiments of the present application with reference to the accompanying drawings in the embodiments of the present application.
随着生活水平的不断提高,人们更加关注安全和便捷性问题,家居智能化***的概念由此而产生。所谓的智能家居是以住宅为平台,利用综合布线技术、网络通信技术、安全防范技术、自动控制技术、音视频技术将家居生活有关的设施集成,构建高效的住宅设施与家庭日程事务的管理***。With the continuous improvement of living standards, people pay more attention to safety and convenience issues, and the concept of home intelligent system is born. The so-called smart home is based on the residential platform, using integrated wiring technology, network communication technology, security technology, automatic control technology, audio and video technology to integrate the facilities related to home life, and build an efficient management system for residential facilities and family schedule affairs. .
在智能家居技术中,监控技术作为目前兴起的智能家居领域中的重要一环,被广泛的应用。在监控技术中,通常在房屋内安装摄像头,以实现对房屋内的监控,另外用户可以通过电子设备(例如智能手机、平板电脑等)对监控画面进行查看,还可以通过电子设备对摄像头的拍摄位置进行远程的控制和调整。In smart home technology, monitoring technology is widely used as an important part of the emerging smart home field. In monitoring technology, a camera is usually installed in the house to monitor the house. In addition, users can view the monitoring screen through electronic devices (such as smartphones, tablet computers, etc.), and can also use electronic devices to shoot the camera. position for remote control and adjustment.
在相关技术中,用户通过电子设备对摄像头的拍摄位置进行远程的控制和调整时,通常是通过电子设备远程发送控制指令,并且实时观察监控画面,对摄像头进行上、下、左和右四个方向的转动,从而使摄像头的视野范围为用户需求查看的位置所处范围。当然,也有的相关技术中,可以把摄像头的拍摄区域所处位置设为常看位置,并记录该常看位置对应的角度,当用户下次需求查看该常看位置的监控画面时,通过选择该常看位置,即可快速控制摄像头转到对应记录的角度,方便用户查看某个特定地点的监控画面。In the related art, when the user remotely controls and adjusts the shooting position of the camera through the electronic device, the user usually sends the control command remotely through the electronic device, and observes the monitoring screen in real time, and moves the camera up, down, left and right. The rotation of the direction, so that the field of view of the camera is the range of the position that the user needs to view. Of course, in some related technologies, the location of the shooting area of the camera can be set as the frequently viewed position, and the angle corresponding to the frequently viewed position can be recorded. The frequently viewed position can quickly control the camera to turn to the corresponding recorded angle, which is convenient for users to view the monitoring screen of a specific location.
发明人经过长期的研究发现,用户在通过电子设备控制摄像头转动至需求的位置时,无法查看到摄像头转动时的状态,因此无法实时的知道还需要等待多长时间才能 转动到需求的位置,只能等待监控画面完全静止时才能确认摄像头已转动至需求的位置,体验上的不确定性较大,造成用户体验较低。After long-term research, the inventor found that when the user controls the camera to rotate to the desired position through the electronic device, the user cannot view the state of the camera when it is rotated, so it is impossible to know in real time how long it will take to rotate to the desired position. It is possible to wait for the monitoring screen to be completely still before confirming that the camera has been rotated to the required position, resulting in a large uncertainty in the experience, resulting in a low user experience.
针对上述问题,发明人提出了本申请实施例提供的摄像头的控制方法、装置、电子设备以及存储介质,可以实现在控制摄像头转动时,展示摄像头转动过程中的进度,使用户了解到摄像头转动时的状态,提升用户体验。其中,具体的摄像头的控制方法在后续的实施例中进行详细的说明。In view of the above problems, the inventor proposes a camera control method, device, electronic device, and storage medium provided by the embodiments of the present application, which can realize the display of the progress of the camera rotation process when controlling the camera rotation, so that the user can know when the camera rotates. state to improve user experience. The specific control method of the camera will be described in detail in the following embodiments.
下面对本申请实施例提供的摄像头的控制方法的应用环境进行介绍。The following describes an application environment of the camera control method provided by the embodiments of the present application.
请参阅图1,图1示出了为本申请实施例应用场景的一种网络结构图,应用场景可以包括智能家居***10,智能家居***10可以包括电子设备100、家居设备200、服务器300以及路由器400,电子设备可以与路由器400建立无线连接,并且家居设备200与路由器400建立无线连接的方式,实现电子设备100与家居设备之间的数据交互。另外,电子设备100以及路由器400与服务器400通信连接,电子设备100可以通过服务器400以及路由器400,与家居设备200进行数据交互。家居设备200可以是空调、照明灯具、智能灯、摄像头、智能插座、无线开关、智能窗帘电机、智能音箱以及各类传感器(例如人体传感器、门窗传感器、烟雾报警器等)。通过以上数据交互的方式,电子设备100可以实现远程对摄像头进行控制,例如,控制摄像头的转动、工作参数等。Please refer to FIG. 1. FIG. 1 shows a network structure diagram of an application scenario of an embodiment of the present application. The application scenario may include a smart home system 10, and the smart home system 10 may include an electronic device 100, a home device 200, a server 300 and The router 400, the electronic device can establish a wireless connection with the router 400, and the way of establishing a wireless connection between the home device 200 and the router 400 realizes data interaction between the electronic device 100 and the home device. In addition, the electronic device 100 and the router 400 are connected in communication with the server 400 , and the electronic device 100 can perform data interaction with the home device 200 through the server 400 and the router 400 . The home equipment 200 may be air conditioners, lighting fixtures, smart lights, cameras, smart sockets, wireless switches, smart curtain motors, smart speakers, and various sensors (eg, human sensors, door and window sensors, smoke alarms, etc.). By means of the above data interaction, the electronic device 100 can remotely control the camera, for example, control the rotation and working parameters of the camera.
请参阅图2,图2示出了本申请一个实施例提供的摄像头的控制方法的流程示意图。在具体的实施例中,所述摄像头的控制方法应用于如图15所示的摄像头的控制装置400以及配置有所述摄像头的控制装置400的电子设备100(图16)。下面将以电子设备为例,说明本实施例的具体流程,当然,可以理解的,本实施例所应用的电子设备可以为智能手机、平板电脑、智能手表、笔记本电脑等,在此不做限定。下面将针对图2所示的流程进行详细的阐述,所述摄像头的控制方法具体可以包括以下步骤:Referring to FIG. 2 , FIG. 2 shows a schematic flowchart of a method for controlling a camera provided by an embodiment of the present application. In a specific embodiment, the camera control method is applied to the camera control device 400 shown in FIG. 15 and the electronic device 100 ( FIG. 16 ) equipped with the camera control device 400 . The following will take an electronic device as an example to describe the specific process of this embodiment. Of course, it can be understood that the electronic device applied in this embodiment may be a smart phone, a tablet computer, a smart watch, a notebook computer, etc., which is not limited here. . The flow shown in FIG. 2 will be described in detail below, and the control method of the camera may specifically include the following steps:
步骤S110:展示所述摄像头的控制界面。Step S110: Display the control interface of the camera.
在本申请实施例中,电子设备可以展示摄像头的控制界面,该控制界面可以用于对智能家居***中的摄像头的拍摄位置、工作模式、工作参数等进行远程控制。其中,摄像头的拍摄位置可以是摄像头的视野范围所对应的位置区域;摄像头的工作模式可以是摄像头当前工作的场景模式,例如夜间模式、白天模式、休眠模式、抓拍模式等,具体的工作模式可以不做限定;工作参数可以指摄像头当前工作的参数,这些参数可以为可调整参数,从而对这些参数进行控制和调整,例如,工作参数可以包括焦距、自动增益控制、背光补偿、白平衡、信噪比等,具体的工作参数可以不做限定。In the embodiment of the present application, the electronic device can display a control interface of the camera, and the control interface can be used to remotely control the shooting position, working mode, working parameters, etc. of the camera in the smart home system. Wherein, the shooting position of the camera may be the location area corresponding to the field of view of the camera; the working mode of the camera may be the scene mode of the current working of the camera, such as night mode, day mode, sleep mode, snapshot mode, etc. The specific working mode may be It is not limited; the working parameters can refer to the parameters of the current working of the camera, and these parameters can be adjustable parameters, so as to control and adjust these parameters, for example, the working parameters can include focal length, automatic gain control, backlight compensation, white balance, signal Noise ratio, etc., the specific working parameters may not be limited.
在一些实施方式中,该控制界面中可以包括用于实现对摄像头的不同控制功能的控件或者选项,当电子设备检测到对这些控件或者选项的操作时,可以触发对摄像头进行相应的控制。该控制界面中还可以包括监控画面,即摄像头采集的监控图像对应的区域,用户可以在控制界面中对摄像头进行远程控制的同时,对监控画面进行查看,方便用户根据监控画面对摄像头进行控制。当然,具体的控制界面可以不做限定。In some embodiments, the control interface may include controls or options for implementing different control functions of the camera, and when the electronic device detects operations on these controls or options, it may trigger corresponding control of the camera. The control interface may also include a monitoring screen, that is, the area corresponding to the monitoring image collected by the camera. The user can view the monitoring screen while remotely controlling the camera in the control interface, which is convenient for the user to control the camera according to the monitoring screen. Of course, the specific control interface may not be limited.
在一些实施方式中,电子设备可以展示用于管理和控制家居设备的设备列表,该设备列表中可以包括不同家居设备对应的控件。具体地,电子设备中可以安装有用于管理家居设备的客户端,电子设备可以运行该客户端,在检测到对设备列表的选取操作时,可以展示设备列表。当电子设备检测到对摄像头对应的控件的选取操作时,可以响应该选取操作,将当前显示界面展示为摄像头的控制界面。例如,请参阅图3,图3示出了设备列表界面A1的界面示意图,设备列表界面A1中包括多个家居设备对应的控件,另外,用户还可以于设备列表界面中进行设备的添加,从而满足用户对新设备的添加等需求,当然,具体的设备列表界面可以不做限定。In some embodiments, the electronic device may display a device list for managing and controlling household devices, and the device list may include controls corresponding to different household devices. Specifically, a client for managing household devices may be installed in the electronic device, the electronic device may run the client, and when a selection operation on the device list is detected, the device list may be displayed. When the electronic device detects the selection operation of the control corresponding to the camera, it can respond to the selection operation and display the current display interface as the control interface of the camera. For example, please refer to FIG. 3. FIG. 3 shows a schematic interface diagram of the device list interface A1. The device list interface A1 includes controls corresponding to multiple home devices. In addition, the user can also add devices in the device list interface, thereby To meet the user's needs for adding new devices, of course, the specific device list interface may not be limited.
步骤S120:响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置。Step S120: In response to the control operation for controlling the rotation of the camera, send a rotation instruction to the camera, where the rotation instruction is used to control the camera to rotate to a target position.
在本申请实施例中,电子设备在展示摄像头的控制界面之后,可以对该控制界面中的操作进行检测,例如,对控制界面中的点击操作、按压操作、滑动操作等进行检测。对控制界面中的操作可以为对控制界面中用于控制摄像头的控件的操作,也可以为对其他区域的操作,在此不做限定。In the embodiment of the present application, after displaying the control interface of the camera, the electronic device may detect operations in the control interface, for example, detect click operations, pressing operations, sliding operations, etc. in the control interface. The operation on the control interface may be an operation on a control used to control the camera in the control interface, or may be an operation on other areas, which is not limited herein.
在一些实施方式中,控制界面中可以包括用于控制摄像头分别进行上、下、左和右四个方向的转动的控件。作为一种实施方式,控制界面中可以包括四个转动控件,四个转动控件中每个控件分别对应一个方向,通过检测对这四个转动控件的操作,可以根据对转动控件的操作,控制摄像头转动,进而控制摄像头的拍摄位置发生变化;作为另一种实施方式,控制界面可以包括一个用于控制摄像头转动的控件,该控件上包括四个可触控区域,四个可触控区域中每个可触控区域对应一个转动方向,通过检测对这个四个可触控区域的触控操作,可以控制摄像头进行转动,进而控制摄像头的拍摄位置发生变化。其中,以上对用于控制摄像头的控件的操作可以不做限定,例如可以为按压操作等;用于控制摄像头的控件的具体形式也可以不做限定。In some embodiments, the control interface may include controls for controlling the camera to rotate in four directions: up, down, left, and right, respectively. As an embodiment, the control interface may include four rotating controls, each of the four rotating controls corresponds to a direction, and by detecting the operation of the four rotating controls, the camera can be controlled according to the operation of the rotating controls rotate, and then control the shooting position of the camera to change; as another implementation manner, the control interface may include a control for controlling the rotation of the camera, the control includes four touchable areas, and each of the four touchable areas Each touchable area corresponds to a rotation direction, and by detecting the touch operation on the four touchable areas, the camera can be controlled to rotate, and then the shooting position of the camera can be controlled to change. Wherein, the operations of the controls for controlling the camera may not be limited above, for example, it may be a pressing operation, etc.; the specific form of the controls for controlling the camera may also not be limited.
电子设备可以根据用户对摄像头的拍摄位置的调整操作,把每次调整后的摄像头的位置角度进行存储,并且接收用户输入的位置名称,与该位置角度进行存储,从而电子设备可以存储每次摄像头拍摄的历史拍摄位置以及该历史拍摄位置对应的位置角度,并形成拍摄位置与位置角度的对应关系,并将该对应关系进行存储。电子设备在响应于控制操作时,可以根据控制操作,获取待拍摄的目标位置,然后基于预先存储的该对应关系,获取与目标位置对应的位置角度;然后基于目标位置对应的位置角度,生成转动指令,以控制摄像头转动至目标位置对应的位置角度。The electronic device can store the position and angle of the camera after each adjustment according to the user's adjustment operation on the shooting position of the camera, and receive the position name input by the user, and store it with the position angle, so that the electronic device can store the position and angle of each camera. The historical shooting position of the shooting and the position angle corresponding to the historical shooting position are formed, and the corresponding relationship between the shooting position and the position angle is formed, and the corresponding relationship is stored. When the electronic device responds to the control operation, it can obtain the target position to be photographed according to the control operation, and then obtain the position angle corresponding to the target position based on the pre-stored correspondence; and then generate a rotation based on the position angle corresponding to the target position. command to control the camera to rotate to the position angle corresponding to the target position.
可选地,电子设备在展示控制界面时,控制界面中可以包括输入历史位置的输入区域,电子设备可以根据用户输入的目标位置,并读取该目标位置对应的位置角度,并基于读取的位置角度生成相应的转动指令,发送至摄像头,以控制该摄像头转动至目标位置对应的位置角度,从而用户仅需要在控制界面输入需要查看的拍摄位置,即可实现控制摄像头转动至不同的角度。Optionally, when the electronic device displays the control interface, the control interface may include an input area for inputting historical positions, and the electronic device may read the position angle corresponding to the target position according to the target position input by the user, and based on the read The position angle generates a corresponding rotation command and sends it to the camera to control the camera to rotate to the position angle corresponding to the target position, so that the user only needs to input the shooting position to be viewed on the control interface, and then the camera can be controlled to rotate to different angles.
示例性的,请参阅图4,在控制界面A2中,包括摄像头采集的监控图像对应的监控图像区域A3,另外,在除监控图像区域A3的其他区域中可以显示输入调整调整的区域,用户可以输入需要调整至的目标位置,例如图4中的“客厅的沙发处”,电子设备通过对输入的该目标位置进行响应,发送转动指令至摄像头,从而实现控制摄像头转动至该目标位置。Exemplarily, please refer to FIG. 4 , in the control interface A2, the monitoring image area A3 corresponding to the monitoring image captured by the camera is included. In addition, the area for input adjustment adjustment can be displayed in other areas except the monitoring image area A3, and the user can Input the target position to be adjusted, such as "the sofa in the living room" in Figure 4. The electronic device responds to the input target position and sends a rotation command to the camera, thereby controlling the camera to rotate to the target position.
在一些实施方式中,在将摄像头安装于室内,并进行入网之后,电子设备可以获取摄像头在每个拍摄角度拍摄的图像,并根据拍摄的图像识别出每个拍摄位置所对应位置名称。然后将识别得到的位置名称与其对应的拍摄角度进行存储,从而电子设备可以根据用户于以上控制界面中输入的目标位置,而根据存储的该目标位置所对应的拍摄角度,生成转动指令,以控制该摄像头转动至目标位置对应的位置角度。In some embodiments, after the camera is installed indoors and connected to the network, the electronic device can acquire images captured by the camera at each shooting angle, and identify the location name corresponding to each shooting location according to the captured images. Then, the recognized position name and its corresponding shooting angle are stored, so that the electronic device can generate a rotation instruction according to the target position input by the user in the above control interface, and according to the stored shooting angle corresponding to the target position to control the The camera rotates to the position angle corresponding to the target position.
在该实施方式中,电子设备可以利用预先训练的位置识别模型,识别不同拍摄角度的图像对应的位置名称。其中,该位置识别模型可以根据大量的不同户型的房屋的室内图像,以及每张室内图像标注的位置名称,对初始模型进行训练而得到,初始模型可以为神经网络模型等,在此不做限定。具体地,电子设备可以接收输入的户型图,并根据户型图,选择相应的图像识别模型,然后将摄像头在不同拍摄角度拍摄的图像,输入至该位置识别模型,位置识别模型可以根据输入的图像,识别出相应的位置名称。可以理解地,由于房屋户型不同,房屋内的各个区域的位置也不同,而相同的户型在同一位置区域的区域图像的特征相同,因此,可以根据不同的户型来对应训练图像识别模型,从而使得图像识别模型在识别各个拍摄角度的图像对应的位置名称时,获得的识别结果更为准确。需要说明的是,以上位置识别模型可以存储于电子设备,也可以存储于服务器,在此不做限定,当位置识别模型存储于电子设备时,电子设备可以 直接调用该图像识别模型进行识别,当位置识别模型存储于服务器时,电子设备可以将不同拍摄位置的图像发送给服务器,服务器调用位置识别模型识别位置名称后,返回给电子设备。In this embodiment, the electronic device can use a pre-trained location recognition model to recognize location names corresponding to images with different shooting angles. Among them, the location recognition model can be obtained by training the initial model according to a large number of indoor images of houses of different types and the location name marked on each indoor image. The initial model can be a neural network model, etc., which is not limited here. . Specifically, the electronic device can receive the input floor plan, select the corresponding image recognition model according to the floor plan, and then input the images captured by the camera at different shooting angles into the position recognition model, and the position recognition model can be based on the input image. to identify the corresponding location name. It can be understood that due to the different house types, the positions of various areas in the house are also different, and the regional images of the same house type in the same location area have the same characteristics. Therefore, the image recognition model can be trained correspondingly according to different house types, so that the image recognition model can be trained accordingly. The image recognition model can obtain more accurate recognition results when recognizing the location names corresponding to the images of each shooting angle. It should be noted that the above location recognition model can be stored in the electronic device or in the server, which is not limited here. When the location recognition model is stored in the electronic device, the electronic device can directly call the image recognition model for recognition. When the location recognition model is stored in the server, the electronic device can send images of different shooting locations to the server, and the server calls the location recognition model to recognize the location name and returns it to the electronic device.
在本申请实施例中,电子设备在检测到控制界面中输入的用于控制摄像头转动的控制操作时,可以响应用于控制摄像头转动的控制操作,向管理智能家居设备的服务器发送转动指令,服务器用于将转动指令发送至所述摄像头,从而实现利用电子设备远程控制摄像头转动至目标位置。In the embodiment of the present application, when the electronic device detects the control operation for controlling the rotation of the camera input in the control interface, the electronic device can respond to the control operation for controlling the rotation of the camera, and send a rotation instruction to the server that manages the smart home equipment, and the server It is used to send the rotation instruction to the camera, so as to realize the remote control of the camera to rotate to the target position by using the electronic device.
在一些实施方式中,由于在控制摄像头转动时,可能摄像头此时处于静止状态,也可能处于转动过程中,例如,用户在控制摄像头转动至指定位置的过程中,因此,控制摄像头转动至目标位置,可以是控制摄像头由响应以上控制操作时的位置转动至目标位置。其中,响应控制操作时的位置可以为摄像头未发生转动时的位置,也可以为摄像头在此前的转动过程中,而检测到控制操作,响应该控制操作时的位置。目标位置指摄像头的拍摄位置,也就是说,本申请实施例中对摄像头的拍摄位置进行控制,而使得摄像头转动至用户需求的拍摄位置。In some embodiments, when controlling the camera to rotate, the camera may be in a stationary state at the moment, or may be in the process of rotating, for example, the user is in the process of controlling the camera to rotate to a specified position, therefore, the camera is controlled to rotate to the target position , which can be to control the camera to rotate from the position in response to the above control operation to the target position. The position when responding to the control operation may be the position when the camera does not rotate, or the position when the camera detects the control operation during the previous rotation process and responds to the control operation. The target position refers to the shooting position of the camera, that is, in the embodiment of the present application, the shooting position of the camera is controlled so that the camera is rotated to the shooting position required by the user.
步骤S130:获取所述摄像头的实时转动进度,所述实时转动进度用于表征所述摄像头转动至所述目标位置的进度。Step S130: Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
在本申请实施例中,电子设备在向摄像头发送转动指令的同时,还可以在摄像头转动的过程中,获取摄像头的实时转动进度。该实时转动进度用于表征摄像头转动至目标位置的过程的实时进度,该实时转动进度是与当前时刻对应的。其中,转动进度可以指摄像头转动的进展的程度,也就是摄像头由响应转动时的位置,转动至目标位置的进展程度,例如,由响应转动时的位置转动至目标位置需要转动60°,当前已转动30°,则转动进度为50%。In this embodiment of the present application, when the electronic device sends a rotation instruction to the camera, it can also acquire the real-time rotation progress of the camera during the rotation of the camera. The real-time rotation progress is used to represent the real-time progress of the process of rotating the camera to the target position, and the real-time rotation progress corresponds to the current moment. Among them, the rotation progress can refer to the degree of progress of the camera rotation, that is, the degree of progress of the camera rotation from the position when the response is rotated to the target position. Rotate 30°, then the rotation progress is 50%.
在一些实施方式中,电子设备可以从用于管理智能家居设备的服务器获取摄像头的实时转动进度,其中,服务器可以根据在响应以上控制操作时的摄像头的位置,以及目标位置,计算摄像头所需转动的角度,然后根据摄像头实时上报的已转动角度,以及计算的所需转动的角度,计算已转动角度与所需转动的角度的比值,将该比值作为实时转动进度。当然,电子设备也可以获取响应控制操作时摄像头的位置,作为初始位置;然后根据初始位置以及目标位置,计算摄像头所需转动的角度作待转动角度;根据实时从服务器获取的摄像头已转动的角度,与待转动角度的比值,确定摄像头的实时转动进度。In some embodiments, the electronic device can obtain the real-time rotation progress of the camera from a server for managing smart home devices, wherein the server can calculate the required rotation of the camera according to the position of the camera in response to the above control operation and the target position Then, according to the rotated angle reported by the camera in real time and the calculated required rotation angle, calculate the ratio of the rotated angle to the required rotation angle, and use the ratio as the real-time rotation progress. Of course, the electronic device can also obtain the position of the camera in response to the control operation as the initial position; then, according to the initial position and the target position, calculate the angle that the camera needs to rotate as the angle to be rotated; according to the angle that the camera has rotated obtained from the server in real time , and the ratio of the angle to be rotated to determine the real-time rotation progress of the camera.
在另一些实施方式中,电子设备可以根据目标位置,从而存储的各个拍摄位置与位置角度的对应关系中,确定目标位置对应的位置角度,然后根据响应以上控制操作时的摄像头的位置对应的位置角度,以及目标位置对应的位置角度,确定需要转动的角度作为待转动角度,再根据转动速度以及作为待转动角度,计算实时转动进度。可选地,电子可以基于转动速度以及在当前时刻的已转动的时长,确定已转动角度;然后,基于已转动角度与待转动角度比值,确定摄像头的实时转动进度。In other embodiments, the electronic device can determine the position angle corresponding to the target position according to the target position and the stored correspondence between each shooting position and the position angle, and then according to the position corresponding to the position of the camera in response to the above control operation Angle, and the position angle corresponding to the target position, determine the angle to be rotated as the angle to be rotated, and then calculate the real-time rotation progress according to the rotation speed and the angle to be rotated. Optionally, the electronic can determine the rotated angle based on the rotation speed and the rotated duration at the current moment; then, determine the real-time rotation progress of the camera based on the ratio of the rotated angle to the to-be-rotated angle.
当然,电子设备获取摄像头由响应控制操作时的位置转动至目标位置的方式可以不做限定。Of course, the manner in which the electronic device obtains the camera from the position in response to the control operation and rotates to the target position may not be limited.
步骤S140:将所述实时转动进度于所述控制界面中进行展示。Step S140: Display the real-time rotation progress on the control interface.
在本申请实施例中,电子设备在获取实时转动进度之后,则可以将实时转动进度于控制界面中进行展示,从而使得用户在触发对摄像头转动至目标位置的控制之后,可以实时查看到转动过程的进度,方便用户了解到摄像头转动的过程。电子设备可以不断的获取实时转动进度和更新控制界面中展示的实时转动进度,从而实现对整个转动过程中的转动进度进行展示。In this embodiment of the present application, after acquiring the real-time rotation progress, the electronic device can display the real-time rotation progress on the control interface, so that the user can view the rotation process in real time after triggering the control of the camera to rotate to the target position. The progress of the camera is convenient for the user to understand the process of the camera rotation. The electronic device can continuously obtain the real-time rotation progress and update the real-time rotation progress displayed in the control interface, thereby realizing the display of the rotation progress in the entire rotation process.
在一些实施方式中,电子设备展示的实施转动进度的方式可以不做限定,例如,电子设备也可以以文字的形式显示实时转动进度,具体地,以百分比的文字形式展示 实时转动进度。In some embodiments, the manner of implementing the rotation progress displayed by the electronic device may not be limited, for example, the electronic device may also display the real-time rotation progress in the form of text, specifically, display the real-time rotation progress in the form of a percentage of text.
本申请实施例提供的摄像头的控制方法,通过展示摄像头的控制界面,响应用于控制摄像头转动的控制操作,向摄像头发送转动指令,该转动指令用于控制该摄像头转动至目标位置,并且获取摄像头的实时转动进度,该实时转动进度用于表征摄像头转动至目标位置的进度,然后将实时转动进度于控制界面中进行展示,从而可以实现在控制摄像头转动时,展示摄像头转动过程中的进度,使用户了解到摄像头转动时的状态,提升用户体验。In the camera control method provided by the embodiment of the present application, by displaying the control interface of the camera, in response to the control operation for controlling the rotation of the camera, a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera. The real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that when the camera is controlled to rotate, the progress in the process of the camera rotation can be displayed, so that the The user understands the state of the camera when it is rotated, which improves the user experience.
请参阅图5,图5示出了本申请另一个实施例提供的摄像头的控制方法的流程示意图。该摄像头的控制方法应用于上述电子设备,下面将针对图5所示的流程进行详细的阐述,所述摄像头的控制方法具体可以包括以下步骤:Referring to FIG. 5 , FIG. 5 shows a schematic flowchart of a method for controlling a camera provided by another embodiment of the present application. The control method of the camera is applied to the above-mentioned electronic equipment. The flow shown in FIG. 5 will be described in detail below. The control method of the camera may specifically include the following steps:
步骤S210:展示所述摄像头的控制界面,所述控制界面包括第一指定区域,所述第一指定区域用于显示所述摄像头实时采集的监控图像。Step S210: Display the control interface of the camera, the control interface includes a first designated area, and the first designated area is used to display the monitoring image collected by the camera in real time.
在本申请实施例中,控制界面中可以包括第一指定区域,第一指定区域用于显示摄像头实时采集的监控图像。其中,该第一指定区域可以理解为监控画面所在区域,通过在控制界面中展示监控画面,可以使得用户在对摄像头进行控制时,可以以监控画面作为参考,确定摄像头是否调整至需求的位置。例如,当用户根据监控图像区域,确定摄像头调整至的位置并不是其想要拍摄的区域时,可以再次对摄像头的拍摄位置进行控制,以调整至用户需求的位置。In this embodiment of the present application, the control interface may include a first designated area, and the first designated area is used to display a monitoring image collected by a camera in real time. The first designated area can be understood as the area where the monitoring screen is located. By displaying the monitoring screen on the control interface, the user can use the monitoring screen as a reference to determine whether the camera is adjusted to the desired position when controlling the camera. For example, when the user determines that the position to which the camera is adjusted is not the area he wants to shoot based on the monitored image area, the shooting position of the camera can be controlled again to adjust to the position required by the user.
步骤S220:响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置。Step S220: In response to the control operation for controlling the rotation of the camera, send a rotation instruction to the camera, where the rotation instruction is used to control the camera to rotate to a target position.
步骤S230:获取所述摄像头的实时转动进度,所述实时转动进度用于表征所述摄像头转动至所述目标位置的进度。Step S230: Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
在本申请实施例中,步骤S220以及步骤S230可以参阅前述实施例的内容,在此不做赘述。In this embodiment of the present application, for step S220 and step S230, reference may be made to the content of the foregoing embodiments, and details are not described herein.
步骤S240:在所述控制界面中的第二指定区域以进度条的形式展示所述实时转动进度,其中,所述第二指定区域位于所述控制界面中除所述第一指定区域以外的区域。Step S240: Display the real-time rotation progress in the form of a progress bar in a second designated area in the control interface, wherein the second designated area is located in an area other than the first designated area in the control interface .
在本申请实施例中,电子设备在控制界面中展示实时转动进度时,可以在控制界面中的第二指定区域以进度条的形式展示实时转动进度。其中,进度条即计算机在处理任务时,实时的以图片形式显示处理任务的速度、完成度、剩余未完成任务量的大小、和可能需要处理时间等。In the embodiment of the present application, when the electronic device displays the real-time rotation progress in the control interface, the real-time rotation progress may be displayed in the form of a progress bar in the second designated area in the control interface. Among them, the progress bar is that when the computer is processing the task, the speed of the processing task, the degree of completion, the size of the remaining unfinished task, and the possible processing time, etc. are displayed in real time in the form of pictures.
在一些实施方式中,电子设备展示的进度条中,进度条中的进度与实时转动进度呈正相关,也就是说,进度条中的进度越大,则实时转动进度也越大,从而用户可以根据进度条了解到摄像头由响应控制操作时的位置转动至目标位置的转动进度。In some embodiments, in the progress bar displayed by the electronic device, the progress in the progress bar is positively correlated with the real-time rotation progress, that is, the greater the progress in the progress bar, the greater the real-time rotation progress, so that the user can The progress bar knows the rotation progress of the camera from the position in response to the control operation to the target position.
在本申请实施例中,第二指定区域可以位于控制界面中除以上第一指定区域以外的区域,从而用户可以在查看第一指定区域中的监控图像的同时,可以通过第二指定区域的进度条,了解到摄像头的实时转动进度,并且,进度条于控制界面中除以上监控图像区域以外的其他区域进行展示,可以不影响监控图像区域的显示,提升用户体验。其中,第二指定区域在以上控制界面中除第一指定区域以外的区域中的具***置可以不做限定。In this embodiment of the present application, the second designated area may be located in an area other than the first designated area in the control interface, so that the user can view the monitoring image in the first designated area and pass the progress of the second designated area. bar to know the real-time rotation progress of the camera, and the progress bar is displayed in other areas of the control interface except the above monitoring image area, which does not affect the display of the monitoring image area and improves user experience. The specific position of the second designated area in the areas other than the first designated area in the above control interface may not be limited.
示例性的,请同时参阅图4及图6,在控制界面A2中,包括摄像头采集的监控图像对应的第一指定区域A3,另外,在除第一指定区域A3的其他区域中可以显示输入调整位置的区域,用户可以输入需要调整至的目标位置,例如图4中的“客厅的沙发处”,电子设备通过对输入的该目标位置进行响应,发送转动指令至摄像头,从而实现控制摄像头转动至该目标位置;另外,在发送转动指令至摄像头的同时,可以在输入调整位置的区域中显示进度条A4,进度条A4位于监控图像区域A3的下方,从而可以使得用户一目了然的知晓摄像头的转动进度。Exemplarily, please refer to FIG. 4 and FIG. 6 at the same time. In the control interface A2, the first designated area A3 corresponding to the monitoring image collected by the camera is included. In addition, the input adjustment can be displayed in other areas except the first designated area A3. In the location area, the user can input the target position to be adjusted, such as "the sofa in the living room" in Figure 4. The electronic device responds to the input target position and sends a rotation command to the camera, so as to control the camera to rotate to The target position; in addition, when sending the rotation command to the camera, a progress bar A4 can be displayed in the area where the adjustment position is input, and the progress bar A4 is located below the monitoring image area A3, so that the user can know the rotation progress of the camera at a glance .
本申请实施例提供的摄像头的控制方法,通过展示摄像头的控制界面,响应用于控制摄像头转动的控制操作,向摄像头发送转动指令,该转动指令用于控制该摄像头转动至目标位置,并获取摄像头的实时转动进度,该实时转动进度用于表征摄像头转动至目标位置的进度,然后将实时转动进度以进度条的方式于控制界面中除显示监控图像的第一指定区域以外的区域中进行展示,从而用户可以在查看监控图像的同时,可以通过进度条,了解到摄像头的实时转动进度,并且,进度条于控制界面中除以上第一指定区域以外的区域进行展示,可以不影响监控图像区域的显示,提升用户体验。In the camera control method provided by the embodiment of the present application, by displaying the control interface of the camera, in response to the control operation for controlling the rotation of the camera, a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera. The real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface in the form of a progress bar in the area other than the first designated area where the monitoring image is displayed, Therefore, while viewing the monitoring image, the user can know the real-time rotation progress of the camera through the progress bar, and the progress bar is displayed in the control interface except for the first designated area above, which does not affect the monitoring image area. Display, improve user experience.
请参阅图7,图7示出了本申请又一个实施例提供的摄像头的控制方法的流程示意图。该摄像头的控制方法应用于上述电子设备,下面将针对图7所示的流程进行详细的阐述,所述摄像头的控制方法具体可以包括以下步骤:Referring to FIG. 7 , FIG. 7 shows a schematic flowchart of a method for controlling a camera provided by another embodiment of the present application. The control method of the camera is applied to the above-mentioned electronic equipment. The flow shown in FIG. 7 will be described in detail below. The control method of the camera may specifically include the following steps:
步骤S310:展示所述摄像头的控制界面,所述控制界面包括第一指定区域以及第二指定区域,所述第一指定区域用于显示所述摄像头实时采集的监控图像,所述第二指定区域包括多个历史查看位置对应的监控图像的界面缩略图。Step S310: Display the control interface of the camera, the control interface includes a first designated area and a second designated area, the first designated area is used to display the monitoring image collected by the camera in real time, and the second designated area It includes interface thumbnails of monitoring images corresponding to multiple historical viewing positions.
在本申请实施例中,电子设备展示的摄像头的控制界面中,可以包括用于显示摄像头实时采集的监控图像的第一指定区域,以及用于显示多个历史查看位置对应的监控图像的界面缩略图的第二指定区域。该第一指定区域可以理解为显示监控画面的区域,通过在控制界面中展示监控画面,可以使得用户在对摄像头进行控制时,可以以监控画面作为参考,确定摄像头是否调整至需求的位置;历史查看位置可以为用户历史调整摄像头的拍摄位置,并且电子设备记录有每个历史查看位置对应的摄像头的位置角度,从而电子设备可以根据用户选择的历史查看位置所对应的位置角度,生成转动指令发送至摄像头,可以实现控制摄像头转动至历史查看位置。其中,各个历史查看位置对应的界面缩略图,可以根据历史拍摄的该查看位置的监控图像生成,当然,界面缩略图的具体内容可以不做限定。In this embodiment of the present application, the control interface of the camera displayed by the electronic device may include a first designated area for displaying surveillance images captured by the camera in real time, and an interface thumbnail for displaying surveillance images corresponding to multiple historical viewing locations. The second designated area of the thumbnail. The first designated area can be understood as the area where the monitoring screen is displayed. By displaying the monitoring screen on the control interface, the user can use the monitoring screen as a reference to determine whether the camera is adjusted to the desired position when controlling the camera; history The viewing position can adjust the shooting position of the camera for the user's history, and the electronic device records the position angle of the camera corresponding to each historical viewing position, so that the electronic device can generate a rotation instruction according to the position angle corresponding to the historical viewing position selected by the user. To the camera, you can control the camera to rotate to the historical viewing position. The interface thumbnail corresponding to each historical viewing position may be generated according to the historically photographed monitoring image of the viewing position. Of course, the specific content of the interface thumbnail may not be limited.
在一些场景中,用户可以经常查看的查看位置进行设置,而设置为以上的历史查看位置,电子设备可以在展示的控制界面中,将其进行展示,从而使得用户可以对常看位置进行选择,而控制摄像头转动至需求的常看位置进行拍摄。例如,请参阅图8,控制界面A2中可以包括常看位置对应的监控图像的界面缩略图A5,例如图8中所示的“客厅的沙发处”对应的界面缩略图、“客厅的阳台”对应的界面缩略图。In some scenarios, the user can set the frequently viewed viewing position, and set to the above historical viewing position, the electronic device can display it in the displayed control interface, so that the user can select the frequently viewed position, And control the camera to rotate to the required common viewing position for shooting. For example, referring to FIG. 8 , the control interface A2 may include the interface thumbnail A5 of the monitoring image corresponding to the frequently viewed position, such as the interface thumbnail corresponding to “the sofa in the living room” shown in FIG. 8 , the “balcony in the living room” The corresponding interface thumbnail.
在一些实施方式中,控制界面中可以包括不同功能的控件,例如图8中所示的“休眠”、“常看位置”、“抓拍”、“录像”、“相册”等功能对应的控件,其中,“休眠”控件用于控制摄像头处于休眠模式;“常看位置”控件用于触发展示常看位置对应的界面缩略图;“抓拍”控件用于控制摄像头进行抓拍;“录像”控件用于查看监控录像;“相册”控件用于触发查看监控图像的相册。当然,控制界面中具体包括的功能控件可以不做限定。In some embodiments, the control interface may include controls with different functions, for example, controls corresponding to functions such as "sleep", "frequently viewed position", "snapshot", "recording", "album", etc. shown in FIG. 8 , Among them, the "sleep" control is used to control the camera to be in sleep mode; the "frequently viewed position" control is used to trigger the display of the interface thumbnail corresponding to the frequently viewed position; the "snapshot" control is used to control the camera to take snapshots; the "recording" control is used to View surveillance video; "Album" control is used to trigger viewing album of surveillance images. Of course, the functional controls specifically included in the control interface may not be limited.
在该实施方式中,电子设备检测到对“常看位置”的控件的选取操作时,可以在控制界面中展示常看位置对应的界面缩略图。当以上控件中,某个功能对应的控件被选中时,则可以将该被选中的控件的颜色与其他控件的颜色进行区分,以便用户知晓当前选中的控件。In this implementation manner, when the electronic device detects the selection operation of the control of the "frequently viewed position", it can display the interface thumbnail corresponding to the frequently viewed position in the control interface. When a control corresponding to a certain function is selected among the above controls, the color of the selected control can be distinguished from the colors of other controls, so that the user can know the currently selected control.
另外,电子设备也可以根据用户的操作,对常看位置进行添加。作为一种方式,例如,如图8所示,可以在常看位置对应的界面缩略图中其中一个界面缩略图中显示“+”,当电子设备检测到对该界面缩略图的触控操作时,则可以触发添加常看位置;又例如,电子设备可以在检测到控制界面中底部区域的按压操作时,检测持续按压时长,在持续按压时长超过指定时长时,触发添加常看位置,指定时长可以为2秒、3秒等,在此不做限定。从而,可以实现用户对于常看位置的添加。In addition, the electronic device can also add frequently viewed positions according to the user's operation. As a way, for example, as shown in FIG. 8 , a “+” may be displayed in one of the interface thumbnails corresponding to the frequently viewed positions, when the electronic device detects a touch operation on the interface thumbnail , you can trigger the addition of frequently viewed positions; for another example, the electronic device can detect the duration of continuous pressing when detecting the pressing operation in the bottom area of the control interface, and when the duration of continuous pressing exceeds the specified duration, trigger the addition of frequently viewed positions for the specified duration It can be 2 seconds, 3 seconds, etc., which is not limited here. Therefore, it is possible to realize the addition of frequently viewed positions by the user.
其中,触发添加常看位置时,控制界面中可以包括用于控制摄像头分别进行上、下、左和右四个方向的转动的控件,从而使得用户可以控制摄像头转动至需求的位置, 然后将转动完成的位置角度进行记录;然后根据用户编辑的位置名称,将位置名称与记录的位置角度进行关联存储,从而完成常看位置的添加。Among them, when triggering the addition of frequently viewed positions, the control interface may include controls for controlling the camera to rotate in four directions: up, down, left and right, so that the user can control the camera to rotate to the desired position, and then rotate the camera to the desired position. The completed location angle is recorded; then according to the location name edited by the user, the location name and the recorded location angle are associated and stored, so as to complete the addition of frequently seen locations.
步骤S320:响应针对目标位置对应的界面缩略图的选取操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置,其中,所述目标位置为所述多个历史查看位置中的任一位置。Step S320: In response to the selection operation of the interface thumbnail corresponding to the target position, send a rotation instruction to the camera, and the rotation instruction is used to control the camera to rotate to the target position, wherein the target position is the plurality of Any of the historical viewing locations.
在本申请实施例中,电子设备在展示摄像头的控制界面之后,可以对该控制界面中的操作进行检测,例如,对控制界面中的点击操作、按压操作、滑动操作等进行检测。对控制界面中的操作可以为对控制界面中用于控制摄像头的控件的操作,也可以为对其他区域的操作,在此不做限定。In the embodiment of the present application, after displaying the control interface of the camera, the electronic device may detect operations in the control interface, for example, detect click operations, pressing operations, sliding operations, etc. in the control interface. The operation on the control interface may be an operation on a control used to control the camera in the control interface, or may be an operation on other areas, which is not limited herein.
在本申请实施例中,当电子设备检测到对界面缩略图的选取操作时,则可以根据选取的界面缩略图,确定选取的界面缩略图对应的目标位置,然后根据记录的目标位置对应的位置角度,生成转动指令,并将转动指令发送至摄像头,从而实现控制摄像头转动至目标位置。其中,选取操作可以为点击操作,也可以为双击操作,也可以为按压时长超过预设时长的按压操作等,在此不做限定。In the embodiment of the present application, when the electronic device detects the selection operation of the interface thumbnail, it can determine the target position corresponding to the selected interface thumbnail according to the selected interface thumbnail, and then according to the recorded position corresponding to the target position Angle, generate a rotation command, and send the rotation command to the camera, so as to control the camera to rotate to the target position. The selection operation may be a click operation, a double-click operation, or a pressing operation whose pressing duration exceeds a preset duration, etc., which is not limited herein.
步骤S330:获取所述摄像头的实时转动进度,所述实时转动进度用于表征所述摄像头转动至所述目标位置的进度。Step S330: Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position.
在本申请实施例中,电子设备可以自行根据摄像头的转动速度,计算摄像头的实时转动进度,从而可以更为实时的将摄像头的转动进度进行展示。In the embodiment of the present application, the electronic device can calculate the real-time rotation progress of the camera according to the rotation speed of the camera, so that the rotation progress of the camera can be displayed in a more real-time manner.
在一些实施方式中,请参阅图9,步骤S330可以包括:In some embodiments, referring to FIG. 9 , step S330 may include:
步骤S331:获取响应所述控制操作时所述摄像头的位置,作为初始位置。Step S331: Acquire the position of the camera in response to the control operation as an initial position.
在该方式中,电子设备可以向管理智能家居设备的服务器发送摄像头位置获取请求,然后接收服务器返回的摄像头的位置。In this manner, the electronic device can send a camera position acquisition request to a server that manages smart home devices, and then receive the camera position returned by the server.
在一些方式中,该摄像头位置获取请求可以用于请求从服务器获取记录的响应控制操作时摄像头的位置,其中,电子设备可以在摄像头位置获取请求中添加响应控制操作时的时刻,以获取响应控制操作时摄像头的位置;然后,电子设备接收服务器返回的响应控制操作时所述摄像头的位置。In some manners, the camera position acquisition request can be used to request the camera position when the recorded response control operation is obtained from the server, wherein the electronic device can add the time when the response control operation is performed in the camera position acquisition request to obtain the response control operation. The position of the camera during the operation; then, the electronic device receives the response returned by the server to control the position of the camera during the operation.
步骤S332:基于所述初始位置、所述目标位置以及所述摄像头的转动速度,确定所述摄像头的实时转动进度。Step S332: Determine the real-time rotation progress of the camera based on the initial position, the target position, and the rotation speed of the camera.
在该实施方式中,电子设备可以基于以上获得的初始位置、摄像头需转动至的目标位置以及摄像头的转动速度,来计算摄像头的实时转动进度。具体地,电子设备可以基于初始位置以及目标位置,确定摄像头需转动的转动角度,其中,初始位置以及目标位置均为位置角度;然后基于转动角度以及所述转动速度,确定摄像头需转动的总时长;再基于摄像头在当前时刻的已转动时长与所述总时长的比值,确定摄像头的实时转动进度。In this embodiment, the electronic device may calculate the real-time rotation progress of the camera based on the initial position obtained above, the target position to which the camera needs to be rotated, and the rotation speed of the camera. Specifically, the electronic device can determine the rotation angle that the camera needs to rotate based on the initial position and the target position, where the initial position and the target position are both position angles; then, based on the rotation angle and the rotation speed, determine the total time the camera needs to rotate. ; and then determine the real-time rotation progress of the camera based on the ratio of the rotation duration of the camera at the current moment to the total duration.
示例性的,请参阅图10,在摄像头的角度方位进行记录时,可以利用直角坐标系进行记录,摄像头进行坐和右的转动的角度可以利用X轴进行表示,摄像头进行上和下的转动角度可以利用Y轴进行表示,X轴以及Y轴上的单位可以为角度,一个坐标即代表了一个位置。当需要控制摄像头移动至目标位置时,实际上是沿一条或多条直线进行移动,例如,图10中的由位置A移动至位置B需要沿着三条直线移动三次。因此,在已知摄像头在以上坐标系中的初始位置的位置坐标,以及摄像头的转动速度的情况下,则可以精确计算需要转动的总时长,并且获知已转动时长与总时长的比值,得到转动进度。Exemplarily, please refer to Fig. 10. When recording the angular orientation of the camera, it can be recorded by using a Cartesian coordinate system. The angle of the camera's sitting and right rotation can be represented by the X-axis, and the camera's up and down rotation angles. It can be represented by the Y-axis, and the units on the X-axis and the Y-axis can be angles, and a coordinate represents a position. When the camera needs to be controlled to move to the target position, it actually moves along one or more straight lines. For example, moving from position A to position B in FIG. 10 needs to move three times along three straight lines. Therefore, when the position coordinates of the initial position of the camera in the above coordinate system and the rotation speed of the camera are known, the total duration of rotation can be accurately calculated, and the ratio of the rotation duration to the total duration can be obtained to obtain the rotation schedule.
当然,计算摄像头的实时转动进度的具体方式可以不做限定。Of course, the specific manner of calculating the real-time rotation progress of the camera may not be limited.
步骤S340:在所述目标位置对应的界面缩略图的四周展示进度条,所述进度条用于表征所述实时转动进度。Step S340: Display a progress bar around the interface thumbnail corresponding to the target position, where the progress bar is used to represent the real-time rotation progress.
在本申请实施例中,电子设备在控制界面中展示摄像头的实时转动进度时,可以 在以上目标位置对应的界面缩略图的四周展示进度条,该进度条用于表征实时转动进度,也就是说,进度条表征的进度可以与实时转动进度对应,用户通过观察进度条,即可获知摄像头的实时转动进度。In the embodiment of the present application, when the electronic device displays the real-time rotation progress of the camera in the control interface, a progress bar can be displayed around the interface thumbnail corresponding to the above target position. The progress bar is used to represent the real-time rotation progress, that is to say , the progress represented by the progress bar can correspond to the real-time rotation progress, and the user can know the real-time rotation progress of the camera by observing the progress bar.
示例性的,请同时参阅图8、图11以及图12,当电子设备检测到对“客厅的阳台”的界面缩略图的选取操作之后,可以发送用于控制摄像头转动至“客厅的阳台”的拍摄位置的转动指令,并且获取摄像头的实时转动进度,在“客厅的阳台”的界面缩略图的四周展示进度条A4。其中,进度条的起始位置可以不做限定,例如,可以为图11中的界面缩略图的左侧边缘的中间位置,进度条随着时间的变化,可以逐渐填充满界面缩略图的四周,当摄像头转动至目标位置之后,则摄像头完成了整个转动过程,此时,进度条填充满界面缩略图的四周。从而用户可以观察到选择的界面缩略图的四周的进度条的变化,而知晓摄像头的转动过程中摄像头的转动进度,提升用户体验。Exemplarily, please refer to FIG. 8 , FIG. 11 and FIG. 12 at the same time, after the electronic device detects the selection operation of the interface thumbnail of the “balcony in the living room”, it can send a message for controlling the camera to rotate to the “balcony in the living room”. The rotation command of the shooting position is obtained, and the real-time rotation progress of the camera is obtained, and the progress bar A4 is displayed around the thumbnail of the interface of the "balcony in the living room". The starting position of the progress bar is not limited. For example, it can be the middle position of the left edge of the interface thumbnail in FIG. 11. The progress bar can gradually fill the surrounding area of the interface thumbnail as time changes. After the camera rotates to the target position, the camera completes the entire rotation process, and at this time, the progress bar fills the periphery of the interface thumbnail. Therefore, the user can observe the change of the progress bar around the selected interface thumbnail, and know the rotation progress of the camera during the rotation of the camera, thereby improving the user experience.
在另一些实施方式中,在利用以上界面缩略图展示实时转动进度时,除了在目标位置对应的界面缩略图的四周展示进度条,也可以是在目标位置对应的界面缩略图中展示进度条,进度条用于表征实时转动进度。In other embodiments, when using the above interface thumbnails to display the real-time rotation progress, in addition to displaying the progress bar around the interface thumbnail corresponding to the target position, the progress bar may also be displayed in the interface thumbnail corresponding to the target position. The progress bar is used to represent the real-time rotation progress.
示例性的,请同时参阅图8、图13以及图14,当电子设备检测到对“客厅的阳台”的界面缩略图的选取操作之后,可以发送用于控制摄像头转动至“客厅的阳台”的拍摄位置的转动指令,并且获取摄像头的实时转动进度,在“客厅的阳台”的界面缩略图中展示进度条。其中,进度条的起始位置可以为界面缩略图的最左侧,进度条随着时间的变化,从左侧边缘逐渐往右侧进行填充,当摄像头转动至目标位置之后,则摄像头完成了整个转动过程,此时,进度条填充满整个界面缩略图。从而用户可以观察到选择的界面缩略图中的进度条的变化,而知晓摄像头的转动过程中摄像头的转动进度,提升用户体验。Exemplarily, please refer to FIG. 8 , FIG. 13 and FIG. 14 at the same time, when the electronic device detects the selection operation of the interface thumbnail of the “balcony in the living room”, it can send a message for controlling the camera to rotate to the “balcony in the living room”. The rotation command of the shooting position is obtained, and the real-time rotation progress of the camera is obtained, and the progress bar is displayed in the interface thumbnail of the "balcony in the living room". Among them, the starting position of the progress bar can be the leftmost side of the interface thumbnail. The progress bar gradually fills from the left edge to the right as time changes. When the camera rotates to the target position, the camera completes the entire process. During the rotation process, at this time, the progress bar fills the thumbnails of the entire interface. Therefore, the user can observe the change of the progress bar in the selected interface thumbnail, and know the rotation progress of the camera during the rotation of the camera, thereby improving the user experience.
在一些实施方式中,电子设备除了在控制界面中展示与实时转动进度对应的进度条以外,还可以基于实时转动进度,生成文本提示信息,文本提示信息用于提示用户摄像头的实时转动进度;然后在控制界面中展示生成的文本提示信息。其中,文本提示信息的具体内容可以不做限定,其作用是用于表示转动过程的完成情况,使用户不仅通过进度条可以了解转动的进程,也能直接根据文本提示信息了解到转动过程是否完成。In some embodiments, in addition to displaying a progress bar corresponding to the real-time rotation progress in the control interface, the electronic device can also generate text prompt information based on the real-time rotation progress, and the text prompt information is used to prompt the user of the real-time rotation progress of the camera; then Display the generated text prompt information in the control interface. Among them, the specific content of the text prompt information is not limited, and its function is to indicate the completion of the rotation process, so that the user can not only know the rotation process through the progress bar, but also know whether the rotation process is completed directly according to the text prompt information. .
示例性的,请再次参阅图11,在摄像头未转动至目标位置时,进度条此时未填充满界面缩略图的四周,并且可以在界面缩略图中显示“正在转动”的提示信息;请再次参阅图12,在摄像头转动至目标位置后,此时的实时转动进度为100%,进度条此时填充满界面缩略图的四周,并且可以在界面缩略图中显示“已到达”的提示信息。Exemplarily, please refer to Figure 11 again. When the camera is not rotated to the target position, the progress bar does not fill the entire circumference of the interface thumbnail, and the prompt message "Rotating" can be displayed in the interface thumbnail; Referring to FIG. 12 , after the camera rotates to the target position, the real-time rotation progress is 100%, the progress bar fills the periphery of the interface thumbnail, and the prompt message “Arrived” can be displayed in the interface thumbnail.
在一些实施方式中,摄像头可以在发生转动异常时,例如,转动时卡死等,可以向服务器发送异常信息,服务器可以根据异常信息生成异常指示信息,该异常指示信息可以携带有转动异常的异常类型等,电子设备在接收到服务器发送的异常指示信息后,可以根据异常指示信息,生成相应的第一提示信息,并将该第一提示信息进行展示,以提示摄像头转动异常以及转动异常的类型等。In some embodiments, the camera can send abnormal information to the server when abnormal rotation occurs, for example, the camera is stuck during rotation, and the server can generate abnormal indication information according to the abnormal information, and the abnormal indication information can carry the abnormal rotation abnormality. type, etc. After receiving the abnormality indication information sent by the server, the electronic device can generate corresponding first prompt information according to the abnormality indication information, and display the first prompt information to remind the camera of abnormal rotation and the type of abnormal rotation Wait.
在该实施方式中,若实时转动进度未达到100%时,则电子设备可以在接收到异常指示信息时,可以停止对以上实时转动进度进行更新。例如,停止对进度条中的进度的更新,以便用户知晓摄像头未转动至目标位置。In this embodiment, if the real-time rotation progress does not reach 100%, the electronic device may stop updating the above real-time rotation progress when receiving abnormal indication information. For example, stop updating the progress in the progress bar so the user knows that the camera is not moving to the target position.
在一些实施方式中,由于以上实时转动进度可以是电子设备根据摄像头的转动速度进行计算,因此可能存在摄像头实际的转动进度与电子设备计算的转动进度不一致的情况,或者摄像头实际转动时并未转动至目标位置的情况。针对该问题,电子设备可以在实时转动进度达到100%之后,可以获取当前摄像头拍摄的图像作为当前拍摄图像,将当前拍摄图像与目标位置的历史监控图像进行图像特征的匹配,得到匹配度;在当前拍摄图像与历史监控图像的匹配度大于或等于预设匹配度时,确定摄像头已转 动至目标位置;在当前拍摄图像与目标位置的历史监控图像的匹配度小于预设匹配度时,则确定摄像头未转动至目标位置,可以输出第二提示信息,该第二提示信息用于指示摄像头转动异常,以及未转动至目标位置。In some embodiments, since the above real-time rotation progress may be calculated by the electronic device according to the rotation speed of the camera, there may be situations where the actual rotation progress of the camera is inconsistent with the rotation progress calculated by the electronic device, or the camera does not rotate when it actually rotates to the target position. In response to this problem, after the real-time rotation progress reaches 100%, the electronic device can obtain the image captured by the current camera as the current captured image, and match the image features between the current captured image and the historical monitoring image of the target location to obtain the matching degree; When the matching degree between the currently captured image and the historical monitoring image is greater than or equal to the preset matching degree, it is determined that the camera has been rotated to the target position; when the matching degree between the currently captured image and the historical monitoring image of the target position is less than the preset matching degree, it is determined that If the camera does not rotate to the target position, second prompt information may be output, and the second prompt information is used to indicate that the camera rotates abnormally and does not rotate to the target position.
在该实施方式中,由于摄像头是对室内的图像进行拍摄,因此也可能存在室内的人物在摄像头的视野范围内占据较大范围,而导致当前拍摄的图像与目标位置的历史监控图像的匹配度小于预设匹配度的情况。因此,电子设备在将当前摄像头拍摄的图像,与目标位置的历史监控图像进行图像特征的匹配之前,还可以确定当前摄像头拍摄的图像中的人像区域,并计算人像区域占据拍摄的图像的比例,如果该比例不大于指定比例,则可以将当前摄像头拍摄的图像,与目标位置的历史监控图像进行图像特征的匹配,并且执行后续的步骤;如果该比例大于指定比例,电子设备可以间隔预设时长后再次获取摄像头拍摄的图像,并再次复执行当前摄像头拍摄的图像中的人像区域,并计算人像区域占据拍摄的图像的比例,如果该比例不大于指定比例,则可以将当前摄像头拍摄的图像,与目标位置的历史监控图像进行图像特征的匹配,并且执行后续的步骤。其中,预设时长可以为3秒,5秒等,在此不做限定;指定比例可以为40%,50%等,具体数值可以不做限定。In this implementation manner, since the camera shoots indoor images, there may also be indoor characters occupying a large area within the camera's field of view, resulting in the match between the currently captured image and the historical monitoring image of the target location. Less than the preset matching degree. Therefore, before the electronic device matches the image captured by the current camera with the historical monitoring image of the target location, it can also determine the portrait area in the image captured by the current camera, and calculate the proportion of the portrait area in the captured image. If the ratio is not greater than the specified ratio, the image captured by the current camera can be matched with the historical monitoring image of the target location, and the subsequent steps can be performed; if the ratio is greater than the specified ratio, the electronic device can be separated by a preset period of time Then obtain the image captured by the camera again, and execute the portrait area in the image captured by the current camera again, and calculate the proportion of the portrait area in the captured image. If the ratio is not greater than the specified ratio, the image captured by the current camera can be Image features are matched with historical surveillance images of the target location, and subsequent steps are performed. The preset duration may be 3 seconds, 5 seconds, etc., which is not limited here; the specified ratio may be 40%, 50%, etc., and the specific value may not be limited.
进一步地,如果电子设备连续N次检测到人像区域占据拍摄的图像的比例大于指定比例,则可以确认摄像头已转动至目标位置,结束流程,其中,N为大于指定数值的正整数,指定数值可以为4、6等。Further, if the electronic device detects for N consecutive times that the proportion of the image area occupied by the portrait area is greater than the specified proportion, it can be confirmed that the camera has been rotated to the target position, and the process is ended, wherein N is a positive integer greater than the specified value, and the specified value can be for 4, 6, etc.
本申请实施例提供的摄像头的控制方法,通过展示摄像头的控制界面,在控制界面中可以展示监控图像,且控制界面中包括历史查看位置对应的界面缩略图,响应针对目标位置对应的界面缩略图的选取操作,向摄像头发送转动指令,该转动指令用于控制该摄像头转动至目标位置,获取摄像头的实时转动进度,该实时转动进度用于表征摄像头转动至目标位置的进度,然后将实时转动进度以进度条的方式于界面缩略图的四周进行展示,从而用户可以在查看监控图像区域的同时,可以通过显示的进度条,了解到摄像头的实时转动进度,并且,进度条于控制界面中除以上监控图像区域以外的其他区域进行展示,可以不影响监控图像区域的显示,提升用户体验。另外,通过对历史查看位置对应的界面缩略图进行展示,可以使用户对历史查看位置进行选取,即可控制摄像头移动至相应的历史查看位置,方便了用户对摄像头的拍摄位置的控制。In the camera control method provided by the embodiment of the present application, by displaying the control interface of the camera, the monitoring image can be displayed in the control interface, and the control interface includes the interface thumbnail corresponding to the historical viewing position, and responds to the interface thumbnail corresponding to the target position. select operation, send a rotation instruction to the camera, the rotation instruction is used to control the camera to rotate to the target position, and obtain the real-time rotation progress of the camera, the real-time rotation progress is used to represent the progress of the camera rotation to the target position, and then the real-time rotation progress The progress bar is displayed around the thumbnail of the interface, so that the user can view the monitoring image area and know the real-time rotation progress of the camera through the displayed progress bar, and the progress bar is in the control interface except the above Displaying in areas other than the monitoring image area does not affect the display of the monitoring image area and improves user experience. In addition, by displaying the interface thumbnails corresponding to the historical viewing positions, the user can select the historical viewing positions and control the camera to move to the corresponding historical viewing positions, which facilitates the user to control the shooting position of the camera.
请参阅图15,其示出了本申请实施例提供的一种摄像头的控制装置400的结构框图。该摄像头的控制装置400应用上述的电子设备,该摄像头的控制装置400包括:界面展示模块410、转动控制模块420、进度获取模块430以及进度展示模块440。其中,所述界面展示模块410用于展示所述摄像头的控制界面;所述转动控制模块420用于响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置;所述进度获取模块430用于获取所述摄像头的实时转动进度;所述进度展示模块440用于将所述实时转动进度于所述控制界面中进行展示。Please refer to FIG. 15 , which shows a structural block diagram of a camera control apparatus 400 provided by an embodiment of the present application. The camera control apparatus 400 applies the above-mentioned electronic equipment. The camera control apparatus 400 includes an interface display module 410 , a rotation control module 420 , a progress acquisition module 430 and a progress display module 440 . Wherein, the interface display module 410 is used to display the control interface of the camera; the rotation control module 420 is used to respond to the control operation for controlling the rotation of the camera, and send a rotation instruction to the camera, the rotation instruction Used to control the camera to rotate to the target position; the progress acquisition module 430 is used to acquire the real-time rotation progress of the camera; the progress display module 440 is used to display the real-time rotation progress in the control interface .
在一些实施方式中,所述控制界面包括第一指定区域,所述第一指定区域用于显示所述摄像头实时采集的监控图像。进度展示模块440可以具体用于:在所述控制界面中的第二指定区域以进度条的形式展示所述实时转动进度,其中,所述第二指定区域位于所述控制界面中除所述第一指定区域以外的区域。In some embodiments, the control interface includes a first designated area, and the first designated area is used to display the monitoring image collected by the camera in real time. The progress display module 440 may be specifically configured to: display the real-time rotation progress in the form of a progress bar in a second designated area in the control interface, wherein the second designated area is located in the control interface except for the first designated area. an area outside the designated area.
作为一种实施方式,所述第二指定区域包括所述目标位置对应的监控图像的界面缩略图。进度展示模块440可以具体用于:在所述界面缩略图的四周展示进度条,所述进度条中用于表征所述实时转动进度。As an implementation manner, the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position. The progress display module 440 may be specifically configured to: display a progress bar around the interface thumbnail, where the progress bar is used to represent the real-time rotation progress.
作为一种实施方式,所述第二指定区域包括所述目标位置对应的监控图像的界面缩略图。进度展示模块440可以具体用于:在所述界面缩略图中展示进度条,所述进度条用于表征所述实时转动进度。As an implementation manner, the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position. The progress display module 440 may be specifically configured to: display a progress bar in the interface thumbnail, where the progress bar is used to represent the real-time rotation progress.
在一些实施方式中,进度获取模块430可以包括:位置获取单元以及进度确定单元。其中,位置获取单元用于获取响应所述控制操作时所述摄像头的位置,作为初始位置;进度确定单元用于基于所述初始位置、所述目标位置以及所述摄像头的转动速度,确定所述摄像头的实时转动进度。In some embodiments, the progress obtaining module 430 may include: a position obtaining unit and a progress determining unit. Wherein, the position acquisition unit is used to acquire the position of the camera in response to the control operation as the initial position; the progress determination unit is used to determine the position of the camera based on the initial position, the target position and the rotation speed of the camera The real-time rotation progress of the camera.
在该实施方式下,进度获取单元可以具体用于:基于所述初始位置以及所述目标位置,确定所述摄像头需转动的转动角度;基于所述转动角度以及所述转动速度,确定所述摄像头需转动的总时长;基于所述摄像头在当前时刻的已转动时长与所述总时长的比值,确定所述摄像头的实时转动进度。In this implementation manner, the progress acquisition unit may be specifically configured to: determine the rotation angle of the camera to be rotated based on the initial position and the target position; determine the rotation angle of the camera based on the rotation angle and the rotation speed The total duration of rotation; the real-time rotation progress of the camera is determined based on the ratio of the rotation duration of the camera at the current moment to the total duration.
在该实施方式下,位置获取单元可以具体用于:向管理智能家居设备的服务器发送摄像头位置获取请求;接收所述服务器返回的所述摄像头的位置。In this implementation manner, the location acquiring unit may be specifically configured to: send a request for acquiring the location of the camera to a server that manages smart home devices; and receive the location of the camera returned by the server.
在一些实施方式中,所述控制界面包括多个历史查看位置对应的多个监控图像的界面缩略图。转动控制模块420可以具体用于:响应针对目标位置对应的界面缩略图的选取操作,向所述摄像头发送转动指令,其中,所述目标位置为所述多个历史查看位置中的任一位置。In some embodiments, the control interface includes interface thumbnails of multiple monitoring images corresponding to multiple historical viewing positions. The rotation control module 420 may be specifically configured to send a rotation instruction to the camera in response to a selection operation of an interface thumbnail corresponding to a target position, where the target position is any position among the multiple historical viewing positions.
在一些实施方式中,该摄像头的控制装置400还可以包括:信息生成模块以及信息提示模块。信息生成模块用于基于所述实时转动进度,生成文本提示信息,所述文本提示信息用于提示用户所述摄像头的实时转动进度;信息提示模块用于在所述控制界面中展示所述文本提示信息。In some embodiments, the camera control apparatus 400 may further include: an information generating module and an information prompting module. The information generation module is used to generate text prompt information based on the real-time rotation progress, and the text prompt information is used to prompt the user of the real-time rotation progress of the camera; the information prompt module is used to display the text prompt in the control interface information.
在一些实施方式中,转动控制模块420可以具体用于:响应用于控制所述摄像头转动的控制操作,向管理智能家居设备的服务器发送转动指令,所述服务器用于将所述转动指令发送至所述摄像头。In some embodiments, the rotation control module 420 may be specifically configured to: in response to a control operation for controlling the rotation of the camera, send a rotation instruction to a server that manages smart home devices, and the server is configured to send the rotation instruction to the camera.
所属领域的技术人员可以清楚地了解到,为描述的方便和简洁,上述描述装置和模块的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that, for the convenience and brevity of description, for the specific working process of the above-described devices and modules, reference may be made to the corresponding processes in the foregoing method embodiments, which will not be repeated here.
在本申请所提供的几个实施例中,模块相互之间的耦合可以是电性,机械或其它形式的耦合。In several embodiments provided in this application, the coupling between the modules may be electrical, mechanical or other forms of coupling.
另外,在本申请各个实施例中的各功能模块可以集成在一个处理模块中,也可以是各个模块单独物理存在,也可以两个或两个以上模块集成在一个模块中。上述集成的模块既可以采用硬件的形式实现,也可以采用软件功能模块的形式实现。In addition, each functional module in each embodiment of the present application may be integrated into one processing module, or each module may exist physically alone, or two or more modules may be integrated into one module. The above-mentioned integrated modules can be implemented in the form of hardware, and can also be implemented in the form of software function modules.
综上所述,本申请提供的方案,通过展示摄像头的控制界面,响应用于控制摄像头转动的控制操作,向摄像头发送转动指令,该转动指令用于控制该摄像头转动至目标位置,并获取摄像头的实时转动进度,该实时转动进度用于表征摄像头转动至目标位置的进度,然后将实时转动进度于控制界面中进行展示,从而可以实现在控制摄像头转动时,展示摄像头转动过程中的进度,使用户了解到摄像头转动时的状态,提升用户体验。To sum up, in the solution provided by this application, by displaying the control interface of the camera, in response to the control operation for controlling the rotation of the camera, a rotation instruction is sent to the camera, and the rotation instruction is used to control the camera to rotate to the target position, and obtain the camera. The real-time rotation progress is used to represent the progress of the camera rotating to the target position, and then the real-time rotation progress is displayed in the control interface, so that when the camera is controlled to rotate, the progress in the process of the camera rotation can be displayed, so that the The user understands the state of the camera when it is rotated, which improves the user experience.
请参考图16,其示出了本申请实施例提供的一种电子设备的结构框图。其示出了本申请实施例提供的一种电子设备的结构框图。该电子设备100可以是智能手机、平板电脑、智能手表、笔记本电脑等能够运行应用程序的电子设备。本申请中的电子设备100可以包括一个或多个如下部件:处理器110、存储器120、显示屏130以及一个或多个应用程序,其中一个或多个应用程序可以被存储在存储器120中并被配置为由一个或多个处理器110执行,一个或多个程序配置用于执行如前述方法实施例所描述的方法。Please refer to FIG. 16 , which shows a structural block diagram of an electronic device provided by an embodiment of the present application. It shows a structural block diagram of an electronic device provided by an embodiment of the present application. The electronic device 100 may be an electronic device capable of running an application program, such as a smart phone, a tablet computer, a smart watch, and a notebook computer. The electronic device 100 in the present application may include one or more of the following components: a processor 110, a memory 120, a display screen 130, and one or more application programs, wherein the one or more application programs may be stored in the memory 120 and accessed by Configured to be executed by one or more processors 110, the one or more programs are configured to execute the methods described in the foregoing method embodiments.
处理器110可以包括一个或者多个处理核。处理器110利用各种接口和线路连接整个电子设备100内的各个部分,通过运行或执行存储在存储器120内的指令、程序、代码集或指令集,以及调用存储在存储器120内的数据,执行电子设备100的各种功能和处理数据。可选地,处理器110可以采用数字信号处理(Digital Signal Processing,DSP)、现场可编程门阵列(Field-Programmable Gate Array,FPGA)、可编程逻辑 阵列(Programmable Logic Array,PLA)中的至少一种硬件形式来实现。处理器110可集成中央处理器(Central Processing Unit,CPU)、图像处理器(Graphics Processing Unit,GPU)和调制解调器等中的一种或几种的组合。其中,CPU主要处理操作***、用户界面和应用程序等;GPU用于负责显示内容的渲染和绘制;调制解调器用于处理无线通信。可以理解的是,上述调制解调器也可以不集成到处理器110中,单独通过一块通信芯片进行实现。The processor 110 may include one or more processing cores. The processor 110 uses various interfaces and lines to connect various parts of the entire electronic device 100, and executes by running or executing the instructions, programs, code sets or instruction sets stored in the memory 120, and calling the data stored in the memory 120. Various functions of the electronic device 100 and processing data. Optionally, the processor 110 may adopt at least one of a digital signal processing (Digital Signal Processing, DSP), a Field-Programmable Gate Array (Field-Programmable Gate Array, FPGA), and a Programmable Logic Array (Programmable Logic Array, PLA). A hardware form is implemented. The processor 110 may integrate one or a combination of a central processing unit (Central Processing Unit, CPU), a graphics processing unit (Graphics Processing Unit, GPU), a modem, and the like. Among them, the CPU mainly handles the operating system, user interface and application programs, etc.; the GPU is used for rendering and drawing of the display content; the modem is used to handle wireless communication. It can be understood that, the above-mentioned modem may also not be integrated into the processor 110, and is implemented by a communication chip alone.
存储器120可以包括随机存储器(Random Access Memory,RAM),也可以包括只读存储器(Read-Only Memory)。存储器120可用于存储指令、程序、代码、代码集或指令集。存储器120可包括存储程序区和存储数据区,其中,存储程序区可存储用于实现操作***的指令、用于实现至少一个功能的指令(比如触控功能、声音播放功能、图像播放功能等)、用于实现下述各个方法实施例的指令等。存储数据区还可以存储电子设备100在使用中所创建的数据(比如电话本、音视频数据、聊天记录数据)等。The memory 120 may include random access memory (Random Access Memory, RAM), or may include read-only memory (Read-Only Memory). Memory 120 may be used to store instructions, programs, codes, sets of codes, or sets of instructions. The memory 120 may include a stored program area and a stored data area, wherein the stored program area may store instructions for implementing an operating system, instructions for implementing at least one function (such as a touch function, a sound playback function, an image playback function, etc.) , instructions for implementing the following method embodiments, and the like. The storage data area may also store data (such as phone book, audio and video data, chat record data) created by the electronic device 100 during use.
显示屏130用于显示由用户输入的信息、提供给用户的信息以及所述电子设备100的各种图形用户接口,这些图形用户接口可以由图形、文本、图标、数字、视频和其任意组合来构成,在一个实例中,该显示屏130可以为液晶显示器(Liquid Crystal Display,LCD),也可以为有机发光二极管(Organic Light-Emitting Diode,OLED),在此不做限定。The display screen 130 is used to display information input by the user, information provided to the user, and various graphical user interfaces of the electronic device 100, which may be composed of graphics, text, icons, numbers, videos, and any combination thereof. In one example, the display screen 130 may be a liquid crystal display (Liquid Crystal Display, LCD) or an organic light-emitting diode (Organic Light-Emitting Diode, OLED), which is not limited herein.
请参考图17,其示出了本申请实施例提供的一种计算机可读存储介质的结构框图。该计算机可读介质800中存储有程序代码,所述程序代码可被处理器调用执行上述方法实施例中所描述的方法。Please refer to FIG. 17 , which shows a structural block diagram of a computer-readable storage medium provided by an embodiment of the present application. The computer-readable medium 800 stores program codes, and the program codes can be invoked by the processor to execute the methods described in the above method embodiments.
计算机可读存储介质800可以是诸如闪存、EEPROM(电可擦除可编程只读存储器)、EPROM、硬盘或者ROM之类的电子存储器。可选地,计算机可读存储介质800包括非易失性计算机可读介质(non-transitory computer-readable storage medium)。计算机可读存储介质800具有执行上述方法中的任何方法步骤的程序代码810的存储空间。这些程序代码可以从一个或者多个计算机程序产品中读出或者写入到这一个或者多个计算机程序产品中。程序代码810可以例如以适当形式进行压缩。The computer readable storage medium 800 may be an electronic memory such as flash memory, EEPROM (Electrically Erasable Programmable Read Only Memory), EPROM, hard disk, or ROM. Optionally, the computer-readable storage medium 800 includes a non-transitory computer-readable storage medium. Computer readable storage medium 800 has storage space for program code 810 to perform any of the method steps in the above-described methods. These program codes can be read from or written to one or more computer program products. Program code 810 may be compressed, for example, in a suitable form.
最后应说明的是:以上实施例仅用以说明本申请的技术方案,而非对其限制;尽管参照前述实施例对本申请进行了详细的说明,本领域的普通技术人员当理解:其依然可以对前述各实施例所记载的技术方案进行修改,或者对其中部分技术特征进行等同替换;而这些修改或者替换,并不驱使相应技术方案的本质脱离本申请各实施例技术方案的精神和范围。Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, but not to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand: it can still be Modifications are made to the technical solutions described in the foregoing embodiments, or some technical features thereof are equivalently replaced; and these modifications or replacements do not drive the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions in the embodiments of the present application.

Claims (20)

  1. 一种摄像头的控制方法,应用于电子设备,其特征在于,所述方法包括:A method for controlling a camera, applied to electronic equipment, characterized in that the method comprises:
    展示所述摄像头的控制界面;Display the control interface of the camera;
    响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置;In response to a control operation for controlling the rotation of the camera, a rotation instruction is sent to the camera, where the rotation instruction is used to control the camera to rotate to a target position;
    获取所述摄像头的实时转动进度,所述实时转动进度用于表征所述摄像头转动至所述目标位置的进度;Obtain the real-time rotation progress of the camera, where the real-time rotation progress is used to represent the progress of the camera's rotation to the target position;
    将所述实时转动进度于所述控制界面中进行展示。The real-time rotation progress is displayed in the control interface.
  2. 根据权利要求1所述的方法,其特征在于,所述控制界面包括第一指定区域,所述第一指定区域用于显示所述摄像头实时采集的监控图像,所述将所述实时转动进度于所述控制界面中进行展示,包括:The method according to claim 1, wherein the control interface includes a first designated area, and the first designated area is used to display the monitoring images collected by the camera in real time, and the real-time rotation progress is Displayed in the control interface, including:
    在所述控制界面中的第二指定区域以进度条的形式展示所述实时转动进度,其中,所述第二指定区域位于所述控制界面中除所述第一指定区域以外的区域。A second designated area in the control interface displays the real-time rotation progress in the form of a progress bar, wherein the second designated area is located in an area other than the first designated area in the control interface.
  3. 根据权利要求2所述的方法,其特征在于,所述第二指定区域包括所述目标位置对应的监控图像的界面缩略图,所述在所述控制界面中的第二指定区域以进度条的形式展示所述实时转动进度,包括:The method according to claim 2, wherein the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position, and the second designated area in the control interface is displayed in the form of a progress bar. The real-time rotation progress is displayed in the form of:
    在所述界面缩略图的四周展示进度条,所述进度条用于表征所述实时转动进度。A progress bar is displayed around the interface thumbnail, and the progress bar is used to represent the real-time rotation progress.
  4. 根据权利要求2所述的方法,其特征在于,所述第二指定区域包括所述目标位置对应的监控图像的界面缩略图,所述在所述控制界面中的指定区域以进度条的形式展示所述实时转动进度,包括:The method according to claim 2, wherein the second designated area includes an interface thumbnail of the monitoring image corresponding to the target position, and the designated area in the control interface is displayed in the form of a progress bar The real-time rotation progress includes:
    在所述界面缩略图中展示进度条,所述进度条用于表征所述实时转动进度。A progress bar is displayed in the interface thumbnail, and the progress bar is used to represent the real-time rotation progress.
  5. 根据权利要求1-4任一项所述的方法,其特征在于,所述获取所述摄像头的实时转动进度,包括:The method according to any one of claims 1-4, wherein the acquiring the real-time rotation progress of the camera comprises:
    获取响应所述控制操作时所述摄像头的位置,作为初始位置;Obtain the position of the camera in response to the control operation as the initial position;
    基于所述初始位置、所述目标位置以及所述摄像头的转动速度,确定所述摄像头的实时转动进度。Based on the initial position, the target position and the rotation speed of the camera, the real-time rotation progress of the camera is determined.
  6. 根据权利要求5所述的方法,其特征在于,所述基于所述初始位置、所述目标位置以及所述摄像头的转动速度,确定所述摄像头的实时转动进度,包括:The method according to claim 5, wherein determining the real-time rotation progress of the camera based on the initial position, the target position and the rotation speed of the camera comprises:
    基于所述初始位置以及所述目标位置,确定所述摄像头需转动的转动角度;Based on the initial position and the target position, determine the rotation angle of the camera to be rotated;
    基于所述转动角度以及所述转动速度,确定所述摄像头需转动的总时长;Based on the rotation angle and the rotation speed, determine the total duration for which the camera needs to be rotated;
    基于所述摄像头在当前时刻的已转动时长与所述总时长的比值,确定所述摄像头的实时转动进度。The real-time rotation progress of the camera is determined based on the ratio of the rotation duration of the camera at the current moment to the total duration.
  7. 根据权利要求5所述的方法,其特征在于,所述基于所述初始位置、所述目标位置以及所述摄像头的转动速度,确定所述摄像头的实时转动进度,包括:The method according to claim 5, wherein determining the real-time rotation progress of the camera based on the initial position, the target position and the rotation speed of the camera comprises:
    基于所述初始位置以及所述目标位置,确定所述摄像头需转动的转动角度作为待转动角度;Based on the initial position and the target position, determine the rotation angle of the camera to be rotated as the to-be-rotated angle;
    基于所述转动速度以及在当前时刻的已转动的时长,确定已转动角度;determining the rotated angle based on the rotation speed and the rotated duration at the current moment;
    基于所述已转动角度与所述待转动角度比值,确定所述摄像头的实时转动进度。Based on the ratio of the rotated angle to the to-be-rotated angle, the real-time rotation progress of the camera is determined.
  8. 根据权利要求1-4任一项所述的方法,其特征在于,所述获取所述摄像头的实时转动进度,包括:The method according to any one of claims 1-4, wherein the acquiring the real-time rotation progress of the camera comprises:
    获取响应所述控制操作时所述摄像头的位置,作为初始位置;Obtain the position of the camera in response to the control operation as the initial position;
    基于所述初始位置以及所述目标位置,确定所述摄像头需转动的转动角度作为待转动角度;Based on the initial position and the target position, determine the rotation angle of the camera to be rotated as the to-be-rotated angle;
    根据实时从服务器获取的所述摄像头已转动的角度,与所述待转动角度的比值,确定所述摄像头的实时转动进度。The real-time rotation progress of the camera is determined according to the ratio of the angle of the camera that has been rotated obtained from the server in real time to the angle to be rotated.
  9. 根据权利要求5-8任一项所述的方法,其特征在于,所述获取响应所述控制操作时所述摄像头的位置,包括:The method according to any one of claims 5-8, wherein the acquiring the position of the camera in response to the control operation comprises:
    向管理智能家居设备的服务器发送摄像头位置获取请求;Send a request for camera location acquisition to a server that manages smart home devices;
    接收所述服务器返回的所述摄像头的位置。The location of the camera returned by the server is received.
  10. 根据权利要求1-9任一项所述的方法,其特征在于,所述控制界面包括多个历史查看位置对应的多个监控图像的界面缩略图,所述响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,包括:The method according to any one of claims 1-9, wherein the control interface includes interface thumbnails of multiple monitoring images corresponding to multiple historical viewing positions, and the response is used to control the rotation of the camera. Control operations, sending rotation instructions to the camera, including:
    响应针对目标位置对应的界面缩略图的选取操作,向所述摄像头发送转动指令,其中,所述目标位置为所述多个历史查看位置中的任一位置。In response to the selection operation for the interface thumbnail corresponding to the target position, a rotation instruction is sent to the camera, wherein the target position is any position in the multiple historical viewing positions.
  11. 根据权利要求1-10任一项所述的方法,其特征在于,所述响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,包括:The method according to any one of claims 1-10, wherein the sending a rotation instruction to the camera in response to a control operation for controlling the rotation of the camera comprises:
    响应用于控制所述摄像头转动的控制操作,获取待拍摄的目标位置;Acquire the target position to be photographed in response to the control operation for controlling the rotation of the camera;
    基于预先存储的拍摄位置与位置角度对应的对应关系,获取与所述目标位置对应的位置角度;Obtaining the position angle corresponding to the target position based on the pre-stored correspondence between the shooting position and the position angle;
    基于所述目标位置对应的位置角度,生成转动指令,所述转动指令用于控制所述摄像头转动至目标位置对应的位置角度。Based on the position angle corresponding to the target position, a rotation instruction is generated, and the rotation instruction is used to control the camera to rotate to the position angle corresponding to the target position.
  12. 根据权利要求11所述的方法,其特征在于,在所述响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令之前,所述方法还包括:The method according to claim 11, wherein before sending a rotation instruction to the camera in response to the control operation for controlling the rotation of the camera, the method further comprises:
    根据每次调整后的所述摄像头的位置角度,以及每次调整时用户输入的对应的拍摄位置,生成拍摄位置与位置角度的对应关系,并将所述对应关系进行存储。According to the position angle of the camera after each adjustment, and the corresponding shooting position input by the user during each adjustment, the corresponding relationship between the shooting position and the position angle is generated, and the corresponding relationship is stored.
  13. 根据权利要求1-12任一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1-12, wherein the method further comprises:
    基于所述实时转动进度,生成文本提示信息,所述文本提示信息用于提示用户所述摄像头的实时转动进度;generating text prompt information based on the real-time rotation progress, where the text prompt information is used to prompt the user of the real-time rotation progress of the camera;
    在所述控制界面中展示所述文本提示信息。The text prompt information is displayed in the control interface.
  14. 根据权利要求1-13任一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1-13, wherein the method further comprises:
    接收服务器发送的异常指示信息,所述异常指示信息用于指示所述摄像头转动异常;Receive abnormal indication information sent by the server, where the abnormal indication information is used to indicate that the camera rotates abnormally;
    基于所述异常指示信息,生成对应的第一提示信息;generating corresponding first prompt information based on the abnormal indication information;
    将所述第一提示信息进行展示,所述第一提示信息用于提示所述摄像头转动异常。The first prompt information is displayed, and the first prompt information is used to prompt that the camera rotates abnormally.
  15. 根据权利要求14所述的方法,其特征在于,所述方法还包括:The method of claim 14, wherein the method further comprises:
    在所述实时转动进度未达到100%时,若接收到所述异常提示信息,停止对所述转动进度进行更新。When the real-time rotation progress does not reach 100%, if the abnormal prompt information is received, the update of the rotation progress is stopped.
  16. 根据权利要求1-15任一项所述的方法,其特征在于,所述方法还包括:The method according to any one of claims 1-15, wherein the method further comprises:
    在所述实时转动进度达到100%时,获取当前所述摄像头拍摄的图像作为当前拍摄图像;When the real-time rotation progress reaches 100%, acquire the current image captured by the camera as the current captured image;
    将所述当前拍摄图像与所述目标位置的历史监控图像进行图像特征的匹配,得到匹配度;Matching the image features between the current captured image and the historical monitoring image of the target position to obtain a matching degree;
    若所述匹配度小于预设匹配度,输出第二提示信息,所述第二提示信息用于提示所述摄像头转动异常,且未转动至所述目标位置。If the matching degree is less than the preset matching degree, second prompt information is output, and the second prompt information is used to prompt that the camera rotates abnormally and does not rotate to the target position.
  17. 根据权利要求1-16任一项所述的方法,其特征在于,所述响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,包括:The method according to any one of claims 1-16, wherein the sending a rotation instruction to the camera in response to a control operation for controlling rotation of the camera comprises:
    响应用于控制所述摄像头转动的控制操作,向管理智能家居设备的服务器发送转动指令,所述服务器用于将所述转动指令发送至所述摄像头。In response to the control operation for controlling the rotation of the camera, a rotation instruction is sent to a server that manages smart home devices, and the server is configured to send the rotation instruction to the camera.
  18. 一种摄像头的控制装置,应用于电子设备,其特征在于,所述装置包括:界面 展示模块、转动控制模块、进度获取模块以及进度展示模块,其中,A control device for a camera, applied to electronic equipment, wherein the device comprises: an interface display module, a rotation control module, a progress acquisition module and a progress display module, wherein,
    所述界面展示模块用于展示所述摄像头的控制界面;The interface display module is used to display the control interface of the camera;
    所述转动控制模块用于响应用于控制所述摄像头转动的控制操作,向所述摄像头发送转动指令,所述转动指令用于控制所述摄像头转动至目标位置;The rotation control module is configured to send a rotation instruction to the camera in response to a control operation for controlling the rotation of the camera, where the rotation instruction is used to control the camera to rotate to a target position;
    所述进度获取模块用于获取所述摄像头的实时转动进度;The progress obtaining module is used to obtain the real-time rotation progress of the camera;
    所述进度展示模块用于将所述实时转动进度于所述控制界面中进行展示。The progress display module is used for displaying the real-time rotation progress in the control interface.
  19. 一种电子设备,其特征在于,包括:An electronic device, comprising:
    一个或多个处理器;one or more processors;
    存储器;memory;
    一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并被配置为由所述一个或多个处理器执行,所述一个或多个程序配置用于执行如权利要求1-17任一项所述的方法。One or more application programs, wherein the one or more application programs are stored in the memory and configured to be executed by the one or more processors, the one or more programs are configured to perform such as The method of any one of claims 1-17.
  20. 一种计算机可读取存储介质,其特征在于,所述计算机可读取存储介质中存储有程序代码,所述程序代码可被处理器调用执行如权利要求1-17任一项所述的方法。A computer-readable storage medium, wherein a program code is stored in the computer-readable storage medium, and the program code can be invoked by a processor to execute the method according to any one of claims 1-17 .
PCT/CN2021/105304 2020-09-14 2021-07-08 Camera control method and apparatus, electronic device, and storage medium WO2022052613A1 (en)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202010962150.6A CN112118390A (en) 2020-09-14 2020-09-14 Camera control method and device, electronic equipment and storage medium
CN202010962150.6 2020-09-14

Publications (1)

Publication Number Publication Date
WO2022052613A1 true WO2022052613A1 (en) 2022-03-17

Family

ID=73802700

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/105304 WO2022052613A1 (en) 2020-09-14 2021-07-08 Camera control method and apparatus, electronic device, and storage medium

Country Status (2)

Country Link
CN (1) CN112118390A (en)
WO (1) WO2022052613A1 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112118390A (en) * 2020-09-14 2020-12-22 Oppo广东移动通信有限公司 Camera control method and device, electronic equipment and storage medium
CN113014894B (en) * 2021-05-25 2021-08-13 长沙鹏阳信息技术有限公司 Petroleum underground operation safety staring control method based on artificial intelligence

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140300688A1 (en) * 2013-04-08 2014-10-09 Samsung Electronics Co., Ltd. Imaging apparatus and method of controlling the same
CN108549245A (en) * 2018-05-09 2018-09-18 东莞维升电子制品有限公司 Smart home method for managing and monitoring and its system
CN109246358A (en) * 2018-10-30 2019-01-18 广州小鹏汽车科技有限公司 A kind of control method and system of roof camera head
CN109255821A (en) * 2018-09-03 2019-01-22 上海商汤智能科技有限公司 A kind of image display method, equipment and computer readable storage medium
CN110196557A (en) * 2019-05-05 2019-09-03 深圳绿米联创科技有限公司 Apparatus control method, device, mobile terminal and storage medium
CN112118390A (en) * 2020-09-14 2020-12-22 Oppo广东移动通信有限公司 Camera control method and device, electronic equipment and storage medium

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN104735355B (en) * 2015-03-13 2018-01-19 广东欧珀移动通信有限公司 The image capture method and device of a kind of intelligent terminal
CN111800601A (en) * 2017-05-11 2020-10-20 华为技术有限公司 Method and device for determining prompt information in video monitoring

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140300688A1 (en) * 2013-04-08 2014-10-09 Samsung Electronics Co., Ltd. Imaging apparatus and method of controlling the same
CN108549245A (en) * 2018-05-09 2018-09-18 东莞维升电子制品有限公司 Smart home method for managing and monitoring and its system
CN109255821A (en) * 2018-09-03 2019-01-22 上海商汤智能科技有限公司 A kind of image display method, equipment and computer readable storage medium
CN109246358A (en) * 2018-10-30 2019-01-18 广州小鹏汽车科技有限公司 A kind of control method and system of roof camera head
CN110196557A (en) * 2019-05-05 2019-09-03 深圳绿米联创科技有限公司 Apparatus control method, device, mobile terminal and storage medium
CN112118390A (en) * 2020-09-14 2020-12-22 Oppo广东移动通信有限公司 Camera control method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN112118390A (en) 2020-12-22

Similar Documents

Publication Publication Date Title
US11947780B2 (en) Timeline-video relationship processing for alert events
US11238290B2 (en) Timeline-video relationship processing for alert events
JP6030808B2 (en) Intelligent remote control method, router, terminal, device, program, and recording medium
EP2944078B1 (en) Wireless video camera
WO2022052613A1 (en) Camera control method and apparatus, electronic device, and storage medium
US10270959B1 (en) Creating preview images for controlling pan and tilt cameras
US9854206B1 (en) Privacy-aware indoor drone exploration and communication framework
WO2020168571A1 (en) Device control method, apparatus, system, electronic device and cloud server
CN110196557B (en) Equipment control method, device, mobile terminal and storage medium
US20110234820A1 (en) Electronic device and method for controlling cameras using the same
US10666768B1 (en) Augmented home network visualization
EP3593050B1 (en) Cooker hood and video surveillance method based on cooker hood
US20200007925A1 (en) Sharing Video Footage from Audio/Video Recording and Communication Devices to Smart TV Devices
WO2023098287A1 (en) Message pushing method and apparatus, storage medium and electronic apparatus
CN112820014A (en) Intelligent access control system control method, device, equipment and medium
TWI439134B (en) 3d digital image monitor system and method
CN108846899B (en) Method and system for improving area perception of user for each function in house source
JP2004505514A (en) Method and apparatus for mode switching in a camera-based system
CN109977260B (en) Video acquisition method, device, system, electronic equipment and storage medium
WO2022052604A1 (en) Information prompt method and apparatus, electronic device, and storage medium
JP4350389B2 (en) Communication network system, portable terminal device, and computer program
CN107230240B (en) Shooting method and mobile terminal
WO2023236848A1 (en) Device control method, apparatus and system, and electronic device and readable storage medium
TWI527000B (en) Infrared contral system and operation method thereof
CN114285687B (en) Intelligent control method and intelligent control device of environment monitoring equipment and electronic equipment

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21865669

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21865669

Country of ref document: EP

Kind code of ref document: A1