Movatterモバイル変換


[0]ホーム

URL:


CN110636225A - Photographing method and electronic equipment - Google Patents

Photographing method and electronic equipment
Download PDF

Info

Publication number
CN110636225A
CN110636225ACN201911013771.3ACN201911013771ACN110636225ACN 110636225 ACN110636225 ACN 110636225ACN 201911013771 ACN201911013771 ACN 201911013771ACN 110636225 ACN110636225 ACN 110636225A
Authority
CN
China
Prior art keywords
screen
area
picture
camera
content
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Granted
Application number
CN201911013771.3A
Other languages
Chinese (zh)
Other versions
CN110636225B (en
Inventor
朱冰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Vivo Mobile Communication Co Ltd
Original Assignee
Vivo Mobile Communication Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Vivo Mobile Communication Co LtdfiledCriticalVivo Mobile Communication Co Ltd
Priority to CN201911013771.3ApriorityCriticalpatent/CN110636225B/en
Publication of CN110636225ApublicationCriticalpatent/CN110636225A/en
Application grantedgrantedCritical
Publication of CN110636225BpublicationCriticalpatent/CN110636225B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Images

Classifications

Landscapes

Abstract

Translated fromChinese

本发明公开了一种拍照方法及电子设备,该电子设备包括:屏幕和摄像头,摄像头设置在屏幕的下方,并且可在屏幕的下方移动,该方法包括:在摄像头已启动的情况下获取屏幕上显示的内容画面;根据内容画面确定屏幕中的第一屏幕区域,其中,第一屏幕区域为内容画面中的第一画面区域对应的屏幕区域,第一画面区域为内容画面中尺寸不小于摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;控制摄像头移动至第一屏幕区域的下方。实施上述方法,通过对电子设备屏幕上显示的内容进行分析,来选择屏下适合摄像头拍摄的位置,指示摄像头移动至该位置,无需在屏幕上开孔即可以实现全面屏电子设备的拍摄功能,增加了电子设备屏幕的可视空间。

The invention discloses a photographing method and electronic equipment. The electronic equipment comprises: a screen and a camera. The camera is arranged below the screen and can move below the screen. The displayed content picture; determine the first screen area in the screen according to the content picture, wherein the first screen area is the screen area corresponding to the first picture area in the content picture, and the first picture area is the size of the content picture not smaller than the camera The image area where the lens size and the pixel color parameter are lower than the preset parameter threshold; control the camera to move to the bottom of the first screen area. Implement the above method, by analyzing the content displayed on the screen of the electronic device, select a suitable position for the camera to shoot under the screen, instruct the camera to move to this position, and realize the shooting function of the full-screen electronic device without opening holes on the screen. Increases the viewing space of the electronic device screen.

Description

Translated fromChinese
拍照方法及电子设备Photographing method and electronic equipment

技术领域technical field

本发明实施例涉及电子设备技术领域,尤其涉及一种拍照方法及电子设备。Embodiments of the present invention relate to the technical field of electronic equipment, and in particular, to a photographing method and electronic equipment.

背景技术Background technique

随着电子设备越来越普及,用户对全面屏的需要越来越强烈。为实现全面屏电子设备的前置拍摄功能,现有技术中,通常会在电子设备屏幕上开孔,将前置摄像头安置在这个孔内。然而,虽然开孔方案可以实现全面屏电子设备的前置拍摄功能,但是屏幕上的开孔区域不具备显示功能,导致屏幕的可视空间降低。As electronic devices become more and more popular, users' needs for full screens are becoming stronger and stronger. In order to realize the front camera function of the full-screen electronic device, in the prior art, a hole is usually opened on the screen of the electronic device, and the front camera is placed in the hole. However, although the opening solution can realize the front-facing shooting function of the full-screen electronic device, the opening area on the screen does not have a display function, resulting in a reduction in the visual space of the screen.

发明内容Contents of the invention

本发明实施例提供一种拍照方法及电子设备,以解决现有技术中存在的屏幕的可视空间降低的技术问题。Embodiments of the present invention provide a photographing method and an electronic device to solve the technical problem in the prior art that the visual space of a screen is reduced.

为解决上述技术问题,本发明实施例是这样实现的:In order to solve the above-mentioned technical problems, the embodiment of the present invention is implemented as follows:

第一方面,本发明实施例提供了一种拍照方法,应用于电子设备,所述电子设备包括:屏幕和摄像头,所述摄像头设置在所述屏幕的下方,并且可在所述屏幕的下方移动,所述方法包括:In the first aspect, an embodiment of the present invention provides a method for taking pictures, which is applied to electronic equipment, and the electronic equipment includes: a screen and a camera, and the camera is arranged below the screen and can move below the screen , the method includes:

在所述摄像头已启动的情况下,获取所述屏幕上显示的内容画面;In the case that the camera is started, acquire the content picture displayed on the screen;

根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;According to the content picture, determine a first screen area in the screen, wherein the first screen area is a screen area corresponding to the first screen area in the content picture, and the first screen area is the A picture area in the content picture whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than the preset parameter threshold;

控制所述摄像头移动至所述第一屏幕区域的下方。controlling the camera to move to the bottom of the first screen area.

可选地,作为一个实施例,在所述控制所述摄像头移动至所述第一屏幕区域的下方的步骤之后,还包括:Optionally, as an embodiment, after the step of controlling the camera to move below the first screen area, the method further includes:

控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。controlling the camera to capture images under the first screen area to obtain a first image.

可选地,作为一个实施例,在所述控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像的步骤之后,还包括:Optionally, as an embodiment, after the step of controlling the camera to capture images under the first screen area to obtain the first image, the method further includes:

确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;Determining a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter is lower than that of the first screen The screen area corresponding to the screen area of the pixel color parameter of the area;

控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。Controlling the camera to move from below the first screen area to below the second screen area to capture images to obtain a second image.

可选地,作为一个实施例,所述像素色彩参数为:画面区域内所有像素的RGB平均值。Optionally, as an embodiment, the pixel color parameter is: an RGB average value of all pixels in the picture area.

可选地,作为一个实施例,在根据所述内容画面,确定所述屏幕中的第一屏幕区域的步骤之前,还包括:确定所述内容画面中的第一画面区域,其中,Optionally, as an embodiment, before the step of determining the first screen area in the screen according to the content screen, the method further includes: determining the first screen area in the content screen, wherein,

所述确定所述内容画面中的第一画面区域,包括:The determining the first picture area in the content picture includes:

确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;Determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;

若所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域,则将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;If the content picture includes: a picture area with a size of S and an average value of RGB of T, then the picture area with a size of S and an average value of RGB of T is determined as the first picture area;

若所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域,则执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;If the content picture does not include: a picture area with a size of S and an average value of RGB of T, then execute the T++ operation, and determine whether the T obtained by the operation is greater than M, wherein the M is the camera through the screen. The critical value of the RGB average value of the photo;

若所述运算得到的T不大于M,则确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;If the T obtained by the operation is not greater than M, then determine whether the content screen includes: a picture area whose size is S and whose RGB average value is T obtained by the operation;

若所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;If the content picture includes: a picture area whose size is S and the average value of RGB is T obtained by the calculation, then the picture area whose size is S and the average value of RGB is T obtained by the calculation is determined as First screen area;

若所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。If the content picture does not include a picture area whose size is S and whose RGB average value is T obtained by the calculation, repeat the above picture area determination operation until a picture area satisfying the condition is found.

第二方面,本发明实施例还提供了一种电子设备,所述电子设备包括:屏幕和摄像头,所述摄像头设置在所述屏幕的下方,并且可在所述屏幕的下方移动,所述电子设备包括:In the second aspect, the embodiment of the present invention also provides an electronic device, the electronic device includes: a screen and a camera, the camera is arranged below the screen and can move below the screen, the electronic Equipment includes:

获取单元,用于在所述摄像头已启动的情况下,获取所述屏幕上显示的内容画面;An acquisition unit, configured to acquire the content picture displayed on the screen when the camera is activated;

第一确定单元,用于根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;The first determining unit is configured to determine a first screen area in the screen according to the content picture, wherein the first screen area is a screen area corresponding to the first picture area in the content picture, and the The first picture area is a picture area in the content picture whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than a preset parameter threshold;

第一控制单元,用于控制所述摄像头移动至所述第一屏幕区域的下方。A first control unit, configured to control the camera to move to the bottom of the first screen area.

可选地,作为一个实施例,所述电子设备还包括:Optionally, as an embodiment, the electronic device further includes:

第二控制单元,用于控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。The second control unit is configured to control the camera to capture images under the first screen area to obtain a first image.

可选地,作为一个实施例,所述电子设备还包括:Optionally, as an embodiment, the electronic device further includes:

第二确定单元,用于确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;The second determination unit is configured to determine a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter A screen area corresponding to a picture area lower than the pixel color parameter of the first picture area;

第二控制单元,用于控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。The second control unit is configured to control the camera to move from below the first screen area to below the second screen area to capture images and obtain a second image.

可选地,作为一个实施例,所述像素色彩参数为:画面区域内所有像素的RGB平均值。Optionally, as an embodiment, the pixel color parameter is: an RGB average value of all pixels in the picture area.

可选地,作为一个实施例,所述电子设备还包括:第三确定单元,其中,所述第三确定单元包括:Optionally, as an embodiment, the electronic device further includes: a third determining unit, wherein the third determining unit includes:

第一确定子单元,用于确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;The first determination subunit is used to determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;

第二确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域的情况下,将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;The second determining subunit is used to determine the picture area whose size is S and whose RGB average value is T when the content picture includes: a picture area whose size is S and whose RGB average value is T, as First screen area;

第三确定子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域的情况下,执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;The third determining subunit is used to execute T++ operation and determine whether the T obtained by the operation is greater than M when the content image does not include: an image area whose size is S and the average value of RGB is T, wherein, Said M is the critical value of the RGB mean value that said camera takes pictures through the screen;

第四确定子单元,用于在所述运算得到的T不大于M的情况下,确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;The fourth determining subunit is used to determine whether the content picture includes: a picture area whose size is S and whose RGB average value is T obtained by the calculation, when the T obtained by the calculation is not greater than M;

第五确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;The fifth determining subunit is used to set the size as S and the average value of RGB to the picture area whose size is S and the average value of RGB is The picture area of T obtained by the calculation is determined as the first picture area;

处理子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。The processing subunit is used to repeat the above-mentioned picture area determination operation until a picture meeting the condition is found in the case that the content picture does not include: a picture area whose size is S and whose RGB average value is T obtained by the calculation area so far.

第三方面,本发明实施例还提供了一种电子设备,包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现上述任一拍照方法的步骤。In the third aspect, the embodiment of the present invention also provides an electronic device, including a processor, a memory, and a computer program stored on the memory and operable on the processor, and the computer program is executed by the processor During execution, the steps of any one of the above-mentioned photographing methods are realized.

第四方面,本发明实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质上存储计算机程序,所述计算机程序被处理器执行时实现上述任一拍照方法的步骤。In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and when the computer program is executed by a processor, the steps of any one of the above-mentioned photographing methods are implemented.

本发明实施例中,对电子设备的结构进行改进,在电子设备的屏幕下方设置可移动的摄像头,在该电子设备检测到该摄像头已启动的情况下,获取屏幕上显示的内容画面,根据屏幕上显示的内容画面,确定屏幕中用作摄像位置的第一屏幕区域,并控制摄像头移动至第一屏幕区域下方。可见,本发明实施例中,可以通过对电子设备屏幕上显示的内容进行分析,来选择屏下适合摄像头拍摄的位置,指示摄像头移动至该位置,与现有技术相比,无需在屏幕上开孔即可以实现全面屏电子设备的拍摄功能,增加了电子设备屏幕的可视空间。In the embodiment of the present invention, the structure of the electronic device is improved, and a movable camera is set under the screen of the electronic device. The content screen displayed on the screen, determine the first screen area used as the camera position in the screen, and control the camera to move to the bottom of the first screen area. It can be seen that in the embodiment of the present invention, by analyzing the content displayed on the screen of the electronic device, it is possible to select a suitable position for the camera under the screen and instruct the camera to move to this position. The hole can realize the shooting function of the full-screen electronic device, increasing the visual space of the screen of the electronic device.

附图说明Description of drawings

图1是本发明实施例提供的一种拍照方法的流程图;Fig. 1 is a flowchart of a photographing method provided by an embodiment of the present invention;

图2是本发明实施例提供的确定内容画面中第一画面区域步骤流程图;Fig. 2 is a flow chart of steps for determining the first screen area in the content screen provided by an embodiment of the present invention;

图3是本发明实施例提供的一种拍照方法的示例图;Fig. 3 is an example diagram of a photographing method provided by an embodiment of the present invention;

图4是本发明实施例提供的另一种拍照方法的流程图;Fig. 4 is a flowchart of another photographing method provided by an embodiment of the present invention;

图5是本发明实施例提供的另一种拍照方法的示例图;Fig. 5 is an example diagram of another photographing method provided by an embodiment of the present invention;

图6是本发明实施例提供的一种电子设备的结构示意图;FIG. 6 is a schematic structural diagram of an electronic device provided by an embodiment of the present invention;

图7是实现本发明各个实施例的一种电子设备的硬件结构示意图。Fig. 7 is a schematic diagram of a hardware structure of an electronic device implementing various embodiments of the present invention.

具体实施方式Detailed ways

下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都属于本发明保护的范围。The following will clearly and completely describe the technical solutions in the embodiments of the present invention with reference to the accompanying drawings in the embodiments of the present invention. Obviously, the described embodiments are some of the embodiments of the present invention, but not all of them. Based on the embodiments of the present invention, all other embodiments obtained by persons of ordinary skill in the art without making creative efforts belong to the protection scope of the present invention.

随着电子设备的越来越普及,用户对全面屏的需要越来越强烈,目前为实现全面屏,摄像头被设置在了屏下,由于拍摄受屏幕显示内容的影响,往往会在摄像头对应屏幕上方开孔来达到摄像头的拍摄功能。虽然挖孔的方案可以实现全面屏,但是这种水滴、刘海等方案,挖孔区域是没有显示功能的,导致屏幕的可视空间降低,给用户带来了视觉以及体验上的不佳。With the increasing popularity of electronic devices, users have increasingly strong needs for a full screen. Currently, in order to achieve a full screen, the camera is set under the screen. There is a hole on the top to achieve the shooting function of the camera. Although the hole-digging solution can realize a full screen, the water droplet, notch and other solutions have no display function in the hole-digging area, which reduces the visual space of the screen and brings poor visual and experience to users.

为了解决上述技术问题,本发明实施例提供了一种拍照方法及电子设备。In order to solve the above technical problem, embodiments of the present invention provide a photographing method and an electronic device.

下面首先对本发明实施例提供的拍照方法进行介绍。Firstly, the photographing method provided by the embodiment of the present invention will be introduced below.

需要说明的是,本发明实施例提供的方法适用于电子设备,该电子设备在结构上包括:屏幕和摄像头,该屏幕上未设置用于承载摄像头的开孔,该摄像头设置在屏幕的下方,并且可在屏幕的下方移动。在实际应用中,该屏幕可以为全面屏,该摄像头可以为前置摄像头,该电子设备可以包括:智能手机、平板电脑、个人数字助理等等,本发明实施例对此不作限定。It should be noted that the method provided by the embodiment of the present invention is applicable to electronic equipment, and the electronic equipment structurally includes: a screen and a camera, the screen is not provided with an opening for carrying the camera, and the camera is provided below the screen, And can be moved at the bottom of the screen. In practical applications, the screen may be a full screen, the camera may be a front camera, and the electronic device may include: a smart phone, a tablet computer, a personal digital assistant, etc., which are not limited in this embodiment of the present invention.

图1是本发明实施例提供的一种拍照方法的流程图,如图1所示,该方法可以包括以下步骤:步骤101、步骤102和步骤103,其中,Fig. 1 is a flowchart of a photographing method provided by an embodiment of the present invention. As shown in Fig. 1, the method may include the following steps:step 101,step 102 and step 103, wherein,

在步骤101中,在电子设备的摄像头已启动的情况下,获取该电子设备的屏幕上显示的内容画面。Instep 101, when the camera of the electronic device is started, the content picture displayed on the screen of the electronic device is acquired.

本发明实施例中,可以由电子设备用户触发该电子设备的摄像头启动,也可以由电子设备自动触发该电子设备的摄像头启动,例如,定时触发电子设备的摄像头启动。In the embodiment of the present invention, the user of the electronic device may trigger the start of the camera of the electronic device, or the electronic device may automatically trigger the start of the camera of the electronic device, for example, trigger the start of the camera of the electronic device periodically.

在步骤102中,根据屏幕上显示的内容画面,确定屏幕中的第一屏幕区域;其中,第一屏幕区域为内容画面中的第一画面区域对应的屏幕区域,第一画面区域为内容画面中尺寸不小于摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域。Instep 102, the first screen area in the screen is determined according to the content picture displayed on the screen; wherein, the first screen area is the screen area corresponding to the first picture area in the content picture, and the first picture area is the screen area in the content picture. The image area whose size is not smaller than the lens size of the camera and whose pixel color parameters are lower than the preset parameter threshold.

本发明实施例中,第一屏幕区域的尺寸大于或等于摄像头的镜头尺寸,以保证摄像头在移动到第一屏幕区域下方的屏下位置时,能够进行正常的图像采集。In the embodiment of the present invention, the size of the first screen area is greater than or equal to the lens size of the camera, so as to ensure that the camera can perform normal image acquisition when it moves to an off-screen position below the first screen area.

优选地,第一屏幕区域的尺寸等于摄像头的镜头尺寸,以提高在屏幕上找到适合摄像头拍摄的屏下拍摄位置的几率。Preferably, the size of the first screen area is equal to the lens size of the camera, so as to increase the probability of finding an off-screen shooting position on the screen suitable for shooting by the camera.

本发明实施例中,像素色彩参数是影响摄像头拍照效果的重要因素,在通常情况下,屏幕显示内容的像素色彩参数越小,屏幕能透过的像素越多,摄像头的拍照效果越好;屏幕显示内容的像素色彩参数越大,屏幕能透过的像素越少,摄像头的拍照效果越差;当屏幕显示内容的像素色彩参数达到一定值(即预设参数阈值)时,屏幕透过的像素非常少,少到无法保证摄像头进行正常的图像采集。In the embodiment of the present invention, the pixel color parameter is an important factor affecting the photographing effect of the camera. Under normal circumstances, the smaller the pixel color parameter of the screen display content, the more pixels the screen can see through, and the better the photographing effect of the camera; The larger the pixel color parameter of the displayed content, the fewer pixels the screen can see through, and the poorer the camera's photographing effect; Very few, too few to guarantee normal image acquisition by the camera.

考虑到摄像头拍摄过程,由于在屏幕下方,受当前摄像头上方屏幕显示内容的影响,屏幕上显示的每个像素均由RGB三原色组成、且一般RGB三原色的取值在[0,255]之间,其中,0表示最弱,255表示最强,并且RGB的强弱程度直接影响屏幕传递像素的多少。Considering the camera shooting process, due to the influence of the content displayed on the screen above the current camera at the bottom of the screen, each pixel displayed on the screen is composed of three primary colors of RGB, and the values of the three primary colors of RGB are generally between [0, 255]. Among them, 0 means the weakest, 255 means the strongest, and the strength of RGB directly affects the number of pixels transmitted by the screen.

基于上述分析,本发明实施例中,像素色彩参数可以为:画面区域内所有像素的RGB平均值。具体的,屏幕显示内容的RGB平均值越小,屏幕能透过的像素越多,摄像头的拍照效果越好(例如,RGB=000为摄像头的最佳拍摄位置);屏幕显示内容的RGB平均值越大,屏幕能透过的像素越少,摄像头的拍照效果越差;当屏幕显示内容的RGB平均值达到一定值(即预设RGB均值阈值)时,屏幕透过的像素非常少,少到无法保证摄像头进行正常的图像采集。Based on the above analysis, in the embodiment of the present invention, the pixel color parameter may be: the RGB average value of all pixels in the picture area. Specifically, the smaller the RGB average value of the screen display content, the more pixels the screen can see through, and the better the camera's photographing effect (for example, RGB=000 is the best shooting position of the camera); the RGB average value of the screen display content The larger the size, the fewer pixels the screen can see through, and the worse the camera's photo effect will be; when the RGB average value of the content displayed on the screen reaches a certain value (that is, the preset RGB average value threshold), the screen will see through very few pixels, as few as Normal image acquisition by the camera cannot be guaranteed.

在本发明提供的一个实施例中,可以首先确定内容画面中的第一画面区域,基于第一画面区域,来确定屏幕中的第一屏幕区域,在确定内容画面中的第一画面区域时,可以通过循环查找的方式来确定第一画面区域,此时,如图2所示,上述确定内容画面中的第一画面区域的步骤具体可以包括以下步骤:步骤1041、步骤1042和步骤1043,其中,In an embodiment provided by the present invention, first determine the first screen area in the content screen, and determine the first screen area in the screen based on the first screen area. When determining the first screen area in the content screen, The first screen area may be determined by means of cyclic search. At this time, as shown in FIG. 2, the above-mentioned step of determining the first screen area in the content screen may specifically include the following steps:Step 1041,Step 1042, andStep 1043, wherein ,

在步骤1041中,确定内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,若是,则将该尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;其中,S不小于摄像头的镜头尺寸,T的初始值为0。Instep 1041, determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, and if so, determine the picture area with a size of S and an average value of RGB of T as the first picture area; Wherein, S is not smaller than the lens size of the camera, and the initial value of T is 0.

本发明实施例中,S可以等于摄像头的镜头尺寸,也可以大于摄像头的镜头尺寸。优选地,S等于摄像头的镜头尺寸。In the embodiment of the present invention, S may be equal to or larger than the lens size of the camera. Preferably, S is equal to the lens size of the camera.

在步骤1042中,若内容画面中不包括:尺寸为S且RGB平均值为T的画面区域,则执行T++运算,并确定运算得到的T是否大于M,若运算得到的T不大于M、且内容画面中包括:尺寸为S且RGB平均值为运算得到的T的画面区域,则将该尺寸为S且RGB平均值为运算得到的T的画面区域,确定为第一画面区域;其中,M为摄像头透过屏幕进行拍照的RGB平均值的临界值。Instep 1042, if the content screen does not include: a screen area whose size is S and the average value of RGB is T, then perform T++ operation, and determine whether the T obtained by the operation is greater than M, if the T obtained by the operation is not greater than M, and The content picture includes: a picture area whose size is S and whose RGB average value is T obtained by calculation, then the picture area whose size is S and whose RGB average value is T obtained by calculation is determined as the first picture area; among them, M The threshold value of the RGB average value for the camera to take pictures through the screen.

在步骤1043中,若运算得到的T不大于M、且内容画面中不包括:尺寸为S且RGB平均值为运算得到的T的画面区域,则重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。Instep 1043, if the computed T is not greater than M, and the content screen does not include: a screen area whose size is S and whose RGB average value is the computed T, then repeat the above-mentioned screen area determination operation until it finds an image that satisfies the condition screen area.

本发明实施例中,首先可以进行一系列前置设置操作:选定摄像头的镜头尺寸大小S为显示内容分析单位,设定显示内容的RGB均值T取值目标在[0,M],0最佳,M最差,初始化T为0;在完成前置设置之后,对当前屏幕显示内容按照以S为单位,寻找是否存在满足T的位置P;如果存在,则将满足T的位置P确定第一画面区域;如果不存在,则将T++,且满足T<M时,继续寻找满足的位置P。In the embodiment of the present invention, a series of presetting operations can be performed first: the lens size S of the selected camera is the display content analysis unit, and the RGB mean T value target of the display content is set at [0, M], and 0 is the most is the best, M is the worst, and initialize T to 0; after completing the pre-settings, find whether there is a position P that satisfies T for the current screen display content in units of S; if it exists, determine the position P that satisfies T A screen area; if it does not exist, T++ will be set, and when T<M is satisfied, continue to search for a satisfactory position P.

可见,本发明实施例中,通过循环渐进寻找的方式,来寻找摄像头的最佳屏下拍摄位置,可以最大程度地提升拍照效果。It can be seen that, in the embodiment of the present invention, the best off-screen shooting position of the camera is found through a cyclic and progressive search method, which can maximize the photographing effect.

在步骤103中,控制摄像头移动至第一屏幕区域的下方。Instep 103, the camera is controlled to move below the first screen area.

本发明实施例中,在控制摄像头移动至第一屏幕区域的下方之后,可以进一步控制该摄像头在第一屏幕区域的下方进行图像拍摄,得到第一图像。In the embodiment of the present invention, after the camera is controlled to move below the first screen area, the camera may be further controlled to capture images under the first screen area to obtain the first image.

为了便于理解,结合图3所示的场景图进行描述,如图3所示,在电子设备检测到摄像头已启动的情况下,获取屏幕上显示的内容画面,之后根据该内容画面确定屏幕中用于屏下拍摄的第一屏幕区域,最后指示摄像头在屏下移动至第一屏幕区域的下方进行拍摄,从而实现电子设备的前置拍摄功能。For ease of understanding, the description will be made in conjunction with the scene diagram shown in Figure 3. As shown in Figure 3, when the electronic device detects that the camera has been activated, it acquires the content picture displayed on the screen, and then determines the content picture used in the screen according to the content picture. Take the first screen area under the screen, and finally instruct the camera to move to the bottom of the first screen area under the screen to shoot, so as to realize the front-facing shooting function of the electronic device.

由上述实施例可见,该实施例中,对电子设备的结构进行改进,在电子设备的屏幕下方设置可移动的摄像头,在该电子设备检测到该摄像头已启动的情况下,获取屏幕上显示的内容画面,根据屏幕上显示的内容画面,确定屏幕中用作摄像位置的第一屏幕区域,并控制摄像头移动至第一屏幕区域下方。可见,本发明实施例中,可以通过对电子设备屏幕上显示的内容进行分析,来选择屏下适合摄像头拍摄的位置,指示摄像头移动至该位置,与现有技术相比,无需在屏幕上开孔即可以实现全面屏电子设备的拍摄功能,增加了电子设备屏幕的可视空间。It can be seen from the above-mentioned embodiment that in this embodiment, the structure of the electronic device is improved, and a movable camera is set under the screen of the electronic device, and when the electronic device detects that the camera has been activated, it obtains the information displayed on the screen. The content picture, according to the content picture displayed on the screen, determines the first screen area used as the camera position in the screen, and controls the camera to move to the bottom of the first screen area. It can be seen that in the embodiment of the present invention, by analyzing the content displayed on the screen of the electronic device, it is possible to select a suitable position for the camera under the screen and instruct the camera to move to this position. The hole can realize the shooting function of the full-screen electronic device, increasing the visual space of the screen of the electronic device.

图4是本发明实施例提供的另一种拍照方法的流程图,本发明实施例中,当需要拍摄多张图像时,如图4所示,该方法可以包括以下步骤:步骤401、步骤402、步骤403、步骤404和步骤405,其中,Fig. 4 is a flowchart of another photographing method provided by an embodiment of the present invention. In an embodiment of the present invention, when multiple images need to be photographed, as shown in Fig. 4, the method may include the following steps: Step 401,Step 402 ,step 403,step 404 and step 405, wherein,

在步骤401中,在电子设备的摄像头已启动的情况下,获取该电子设备的屏幕上显示的内容画面。Instep 401, when the camera of the electronic device is started, the content picture displayed on the screen of the electronic device is acquired.

在步骤402中,根据屏幕上显示的内容画面,确定屏幕中的第一屏幕区域;其中,第一屏幕区域为内容画面中的第一画面区域对应的屏幕区域,第一画面区域为内容画面中尺寸不小于摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域。Instep 402, the first screen area in the screen is determined according to the content picture displayed on the screen; wherein, the first screen area is the screen area corresponding to the first picture area in the content picture, and the first picture area is the screen area in the content picture. The image area whose size is not smaller than the lens size of the camera and whose pixel color parameters are lower than the preset parameter threshold.

在步骤403中,控制摄像头移动至第一屏幕区域的下方,控制该摄像头在第一屏幕区域的下方进行图像拍摄,得到第一图像。Instep 403, the camera is controlled to move below the first screen area, and the camera is controlled to capture images under the first screen area to obtain a first image.

本发明实施例中的步骤401~步骤403,与图1所示实施例中的步骤101~103类似,在此不再赘述,详细内容参见图1所示实施例中的内容。Steps 401 to 403 in the embodiment of the present invention are similar tosteps 101 to 103 in the embodiment shown in FIG. 1 , and will not be repeated here. For details, refer to the content in the embodiment shown in FIG. 1 .

在步骤404中,确定屏幕中的第二屏幕区域;其中,第二屏幕区域为屏幕上显示的内容画面中尺寸不小于摄像头的镜头尺寸、且像素色彩参数低于第一画面区域的像素色彩参数的画面区域所对应的屏幕区域。Instep 404, determine the second screen area in the screen; wherein, the second screen area is the pixel color parameter of the content picture displayed on the screen whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than that of the first picture area The screen area corresponding to the screen area of .

本发明实施例中,在拍摄完第一图像后,如果需要拍摄第二图像,则继续在屏幕上查找第二屏幕区域,具体查找方式与第一屏幕区域的查找方式类似,其中,摄像头在第二屏幕区域的拍摄效果优于在第一屏幕区域的拍摄效果。In the embodiment of the present invention, after the first image is taken, if the second image needs to be taken, continue to search for the second screen area on the screen. The specific search method is similar to that of the first screen area. The shooting effect in the second screen area is better than that in the first screen area.

在步骤405中,控制摄像头由第一屏幕区域的下方移动至第二屏幕区域的下方进行图像拍摄,得到第二图像。Instep 405, the camera is controlled to move from the bottom of the first screen area to the bottom of the second screen area to capture images to obtain a second image.

同理,在拍摄完第二图像后,如果需要拍摄第三图像,则查找第三图像的屏下拍摄位置“第三屏幕区域”,之后控制摄像头由第二屏幕区域的下方移动至第三屏幕区域的下方进行图像拍摄,得到第三图像。Similarly, after the second image is taken, if the third image needs to be taken, search for the off-screen shooting position "third screen area" of the third image, and then control the camera to move from the bottom of the second screen area to the third screen The image is captured below the area to obtain the third image.

为了便于理解,结合图5所示的示例图进行描述,根据拍摄效果影响因素分析,选择以摄像头的镜头尺寸大小为分析单位,计算分析单位的所有像素的RGB平均值,RGB平均值越小(越接近纯黑色),拍摄效果越好。In order to facilitate understanding, it is described in conjunction with the example diagram shown in Figure 5. According to the analysis of the factors affecting the shooting effect, the lens size of the camera is selected as the analysis unit, and the RGB average value of all pixels in the analysis unit is calculated. The smaller the RGB average value ( The closer to pure black), the better the shooting effect.

图5中的左图表示拍摄第一图像时选择了位置1,图5中的中间图表示表示拍摄第二图像时,原来位置1显示内容已经没有位置2好(位置2的RGB平均值更小),则选择位置2进行拍摄,图5中的右图表示拍摄第三图像时,位置3相对位置1、2更好(位置3的RGB平均值最低),则选择位置3进行拍摄。The left picture in Figure 5 shows thatposition 1 was selected when taking the first image, and the middle picture in Figure 5 shows that when the second picture is taken, the original display content ofposition 1 is not as good as that of position 2 (the RGB average value ofposition 2 is smaller ),select position 2 for shooting, and the right figure in Figure 5 indicates thatposition 3 is better thanposition 1 and 2 (the average RGB value ofposition 3 is the lowest) when shooting the third image, then selectposition 3 for shooting.

由上述实施例可见,该实施例中,当需要拍摄多个图像时,可以针对每个图像确定屏下拍摄位置,并将所确定的屏下拍摄位置与上一屏下拍摄位置进行比较,选取拍摄效果更佳的拍摄位置作为最终的屏下拍摄位置,从而提高拍摄效果。It can be seen from the above embodiment that in this embodiment, when multiple images need to be captured, the off-screen shooting position can be determined for each image, and the determined off-screen shooting position can be compared with the previous off-screen shooting position, and selected The shooting position with better shooting effect is used as the final off-screen shooting position, thereby improving the shooting effect.

图6是本发明实施例提供的一种电子设备的结构示意图,该电子设备包括:屏幕和摄像头,摄像头设置在屏幕的下方,并且可在屏幕的下方移动,如图6所示,电子设备600,可以包括:获取单元601、第一确定单元602和第一控制单元603,其中,FIG. 6 is a schematic structural diagram of an electronic device provided by an embodiment of the present invention. The electronic device includes: a screen and a camera. The camera is arranged below the screen and can move below the screen. As shown in FIG. 6 , the electronic device 600 , may include: an acquisition unit 601, a first determination unit 602, and a first control unit 603, wherein,

获取单元601,用于在所述摄像头已启动的情况下,获取所述屏幕上显示的内容画面;An acquisition unit 601, configured to acquire the content picture displayed on the screen when the camera is started;

第一确定单元602,用于根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;The first determining unit 602 is configured to determine a first screen area in the screen according to the content screen, where the first screen area is a screen area corresponding to the first screen area in the content screen, and The first picture area is a picture area in the content picture whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than the preset parameter threshold;

第一控制单元603,用于控制所述摄像头移动至所述第一屏幕区域的下方。The first control unit 603 is configured to control the camera to move below the first screen area.

由上述实施例可见,该实施例中,对电子设备的结构进行改进,在电子设备的屏幕下方设置可移动的摄像头,在该电子设备检测到该摄像头已启动的情况下,获取屏幕上显示的内容画面,根据屏幕上显示的内容画面,确定屏幕中用作摄像位置的第一屏幕区域,并控制摄像头移动至第一屏幕区域下方。可见,本发明实施例中,可以通过对电子设备屏幕上显示的内容进行分析,来选择屏下适合摄像头拍摄的位置,指示摄像头移动至该位置,与现有技术相比,无需在屏幕上开孔即可以实现全面屏电子设备的拍摄功能,增加了电子设备屏幕的可视空间。It can be seen from the above-mentioned embodiment that in this embodiment, the structure of the electronic device is improved, and a movable camera is set under the screen of the electronic device, and when the electronic device detects that the camera has been activated, it obtains the information displayed on the screen. The content picture, according to the content picture displayed on the screen, determines the first screen area used as the camera position in the screen, and controls the camera to move to the bottom of the first screen area. It can be seen that in the embodiment of the present invention, by analyzing the content displayed on the screen of the electronic device, it is possible to select a suitable position for the camera under the screen and instruct the camera to move to this position. The hole can realize the shooting function of the full-screen electronic device, increasing the visual space of the screen of the electronic device.

可选地,作为一个实施例,所述电子设备600,还可以包括:Optionally, as an embodiment, the electronic device 600 may further include:

第二控制单元,用于控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。The second control unit is configured to control the camera to capture images under the first screen area to obtain a first image.

可选地,作为一个实施例,所述电子设备600,还可以包括:Optionally, as an embodiment, the electronic device 600 may further include:

第二确定单元,用于确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;The second determination unit is configured to determine a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter A screen area corresponding to a picture area lower than the pixel color parameter of the first picture area;

第二控制单元,用于控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。The second control unit is configured to control the camera to move from below the first screen area to below the second screen area to capture images and obtain a second image.

可选地,作为一个实施例,所述像素色彩参数可以为:画面区域内所有像素的RGB平均值。Optionally, as an embodiment, the pixel color parameter may be: an RGB average value of all pixels in the picture area.

可选地,作为一个实施例,所述电子设备600,还可以包括:Optionally, as an embodiment, the electronic device 600 may further include:

第三确定单元,其中,所述第三确定单元,可以包括:The third determining unit, wherein the third determining unit may include:

第一确定子单元,用于确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;The first determination subunit is used to determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;

第二确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域的情况下,将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;The second determining subunit is used to determine the picture area whose size is S and whose RGB average value is T when the content picture includes: a picture area whose size is S and whose RGB average value is T, as First screen area;

第三确定子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域的情况下,执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;The third determining subunit is used to execute T++ operation and determine whether the T obtained by the operation is greater than M when the content image does not include: an image area whose size is S and the average value of RGB is T, wherein, Said M is the critical value of the RGB mean value that said camera takes pictures through the screen;

第四确定子单元,用于在所述运算得到的T不大于M的情况下,确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;The fourth determining subunit is used to determine whether the content picture includes: a picture area whose size is S and whose RGB average value is T obtained by the calculation, when the T obtained by the calculation is not greater than M;

第五确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;The fifth determining subunit is used to set the size as S and the average value of RGB to the picture area whose size is S and the average value of RGB is The picture area of T obtained by the calculation is determined as the first picture area;

处理子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。The processing subunit is used to repeat the above-mentioned picture area determination operation until a picture meeting the condition is found in the case that the content picture does not include: a picture area whose size is S and whose RGB average value is T obtained by the calculation area so far.

图7是实现本发明各个实施例的一种电子设备的硬件结构示意图,如图7所示,该电子设备700包括但不限于:射频单元701、网络模块702、音频输出单元703、输入单元704、传感器705、显示单元706、用户输入单元707、接口单元708、存储器709、处理器710、以及电源711等部件。本领域技术人员可以理解,图7中示出的电子设备结构并不构成对电子设备的限定,电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。在本发明实施例中,电子设备包括但不限于手机、平板电脑、笔记本电脑、掌上电脑、车载终端、可穿戴设备、以及计步器等。FIG. 7 is a schematic diagram of the hardware structure of an electronic device implementing various embodiments of the present invention. As shown in FIG. 7, theelectronic device 700 includes but is not limited to: aradio frequency unit 701, anetwork module 702, anaudio output unit 703, and aninput unit 704 ,sensor 705,display unit 706,user input unit 707,interface unit 708,memory 709,processor 710,power supply 711 and other components. Those skilled in the art can understand that the structure of the electronic device shown in Figure 7 does not constitute a limitation on the electronic device, and the electronic device may include more or less components than shown in the illustration, or combine some components, or different components layout. In the embodiment of the present invention, electronic devices include but are not limited to mobile phones, tablet computers, notebook computers, palmtop computers, vehicle-mounted terminals, wearable devices, and pedometers.

其中,处理器710,用于在电子设备的摄像头已启动的情况下,获取该电子设备的屏幕上显示的内容画面;根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;控制所述摄像头移动至所述第一屏幕区域的下方。Wherein, theprocessor 710 is configured to acquire the content picture displayed on the screen of the electronic device when the camera of the electronic device is started; determine the first screen area in the screen according to the content picture, wherein, The first screen area is the screen area corresponding to the first screen area in the content picture, and the first picture area is the size of the content picture not smaller than the lens size of the camera, and the pixel color parameter is lower than A screen area of a preset parameter threshold; controlling the camera to move below the first screen area.

本发明实施例中,对电子设备的结构进行改进,在电子设备的屏幕下方设置可移动的摄像头,在该电子设备检测到该摄像头已启动的情况下,获取屏幕上显示的内容画面,根据屏幕上显示的内容画面,确定屏幕中用作摄像位置的第一屏幕区域,并控制摄像头移动至第一屏幕区域下方。可见,本发明实施例中,可以通过对电子设备屏幕上显示的内容进行分析,来选择屏下适合摄像头拍摄的位置,指示摄像头移动至该位置,与现有技术相比,无需在屏幕上开孔即可以实现全面屏电子设备的拍摄功能,增加了电子设备屏幕的可视空间。In the embodiment of the present invention, the structure of the electronic device is improved, and a movable camera is set under the screen of the electronic device. The content screen displayed on the screen, determine the first screen area used as the camera position in the screen, and control the camera to move to the bottom of the first screen area. It can be seen that in the embodiment of the present invention, by analyzing the content displayed on the screen of the electronic device, it is possible to select a suitable position for the camera under the screen and instruct the camera to move to this position. The hole can realize the shooting function of the full-screen electronic device, increasing the visual space of the screen of the electronic device.

可选地,作为一个实施例,在所述控制所述摄像头移动至所述第一屏幕区域的下方的步骤之后,还包括:Optionally, as an embodiment, after the step of controlling the camera to move below the first screen area, the method further includes:

控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。controlling the camera to capture images under the first screen area to obtain a first image.

可选地,作为一个实施例,在所述控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像的步骤之后,还包括:Optionally, as an embodiment, after the step of controlling the camera to capture images under the first screen area to obtain the first image, the method further includes:

确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;Determining a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter is lower than that of the first screen The screen area corresponding to the screen area of the pixel color parameter of the area;

控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。Controlling the camera to move from below the first screen area to below the second screen area to capture images to obtain a second image.

可选地,作为一个实施例,所述像素色彩参数为:画面区域内所有像素的RGB平均值。Optionally, as an embodiment, the pixel color parameter is: an RGB average value of all pixels in the picture area.

可选地,作为一个实施例,在根据所述内容画面,确定所述屏幕中的第一屏幕区域的步骤之前,还包括:确定所述内容画面中的第一画面区域,其中,所述确定所述内容画面中的第一画面区域,包括:Optionally, as an embodiment, before the step of determining the first screen area in the screen according to the content screen, it further includes: determining the first screen area in the content screen, wherein the determining The first picture area in the content picture includes:

确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;Determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;

若所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域,则将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;If the content picture includes: a picture area with a size of S and an average value of RGB of T, then the picture area with a size of S and an average value of RGB of T is determined as the first picture area;

若所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域,则执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;If the content picture does not include: a picture area with a size of S and an average value of RGB of T, then execute the T++ operation, and determine whether the T obtained by the operation is greater than M, wherein the M is the camera through the screen. The critical value of the RGB average value of the photo;

若所述运算得到的T不大于M,则确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;If the T obtained by the operation is not greater than M, then determine whether the content screen includes: a picture area whose size is S and whose RGB average value is T obtained by the operation;

若所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;If the content picture includes: a picture area whose size is S and the average value of RGB is T obtained by the calculation, then the picture area whose size is S and the average value of RGB is T obtained by the calculation is determined as First screen area;

若所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。If the content picture does not include a picture area whose size is S and whose RGB average value is T obtained by the calculation, repeat the above picture area determination operation until a picture area satisfying the condition is found.

应理解的是,本发明实施例中,射频单元701可用于收发信息或通话过程中,信号的接收和发送,具体的,将来自基站的下行数据接收后,给处理器710处理;另外,将上行的数据发送给基站。通常,射频单元701包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器、双工器等。此外,射频单元701还可以通过无线通信系统与网络和其他设备通信。It should be understood that, in the embodiment of the present invention, theradio frequency unit 701 can be used to receive and send signals during sending and receiving information or during a call. Specifically, the downlink data from the base station is received and processed by theprocessor 710; in addition, the Uplink data is sent to the base station. Generally, theradio frequency unit 701 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier, a duplexer, and the like. In addition, theradio frequency unit 701 can also communicate with the network and other devices through a wireless communication system.

电子设备通过网络模块702为用户提供了无线的宽带互联网访问,如帮助用户收发电子邮件、浏览网页和访问流式媒体等。The electronic device provides users with wireless broadband Internet access through thenetwork module 702, such as helping users send and receive emails, browse web pages, and access streaming media.

音频输出单元703可以将射频单元701或网络模块702接收的或者在存储器709中存储的音频数据转换成音频信号并且输出为声音。而且,音频输出单元703还可以提供与电子设备700执行的特定功能相关的音频输出(例如,呼叫信号接收声音、消息接收声音等等)。音频输出单元703包括扬声器、蜂鸣器以及受话器等。Theaudio output unit 703 may convert audio data received by theradio frequency unit 701 or thenetwork module 702 or stored in thememory 709 into an audio signal and output as sound. Also, theaudio output unit 703 can also provide audio output related to a specific function performed by the electronic device 700 (for example, a call signal reception sound, a message reception sound, etc.). Theaudio output unit 703 includes a speaker, a buzzer, a receiver, and the like.

输入单元704用于接收音频或视频信号。输入单元704可以包括图形处理器(Graphics Processing Unit,GPU)7041和麦克风7042,图形处理器7041对在视频捕获模式或图像捕获模式中由图像捕获装置(如摄像头)获得的静态图片或视频的图像数据进行处理。处理后的图像可以显示在显示单元706上。经图形处理器7041处理后的图像可以存储在存储器709(或其它存储介质)中或者经由射频单元701或网络模块702进行发送。麦克风7042可以接收声音,并且能够将这样的声音处理为音频数据。处理后的音频数据可以在电话通话模式的情况下转换为可经由射频单元701发送到移动通信基站的格式输出。Theinput unit 704 is used to receive audio or video signals. Theinput unit 704 may include a graphics processing unit (Graphics Processing Unit, GPU) 7041 and amicrophone 7042, and thegraphics processor 7041 is used for still pictures or video images obtained by an image capture device (such as a camera) in a video capture mode or an image capture mode. The data is processed. The processed image can be displayed on thedisplay unit 706 . The images processed by thegraphics processor 7041 may be stored in the memory 709 (or other storage media) or sent via theradio frequency unit 701 or thenetwork module 702 . Themicrophone 7042 can receive sound, and can process such sound into audio data. The processed audio data can be converted into a format that can be sent to a mobile communication base station via theradio frequency unit 701 for output in the case of a phone call mode.

电子设备700还包括至少一种传感器705,比如光传感器、运动传感器以及其他传感器。具体地,光传感器包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板7061的亮度,接近传感器可在电子设备700移动到耳边时,关闭显示面板7061和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别电子设备姿态(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;传感器705还可以包括指纹传感器、压力传感器、虹膜传感器、分子传感器、陀螺仪、气压计、湿度计、温度计、红外线传感器等,在此不再赘述。Theelectronic device 700 also includes at least onesensor 705, such as a light sensor, a motion sensor, and other sensors. Specifically, the light sensor includes an ambient light sensor and a proximity sensor, wherein the ambient light sensor can adjust the brightness of thedisplay panel 7061 according to the brightness of the ambient light, and the proximity sensor can turn off thedisplay panel 7061 and 7061 when theelectronic device 700 moves to the ear. / or backlighting. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in various directions (generally three axes), and can detect the magnitude and direction of gravity when it is still, and can be used to identify the posture of electronic equipment (such as horizontal and vertical screen switching, related games) , magnetometer posture calibration), vibration recognition-related functions (such as pedometer, knocking), etc.; thesensor 705 can also include fingerprint sensors, pressure sensors, iris sensors, molecular sensors, gyroscopes, barometers, hygrometers, thermometers, Infrared sensors, etc., will not be repeated here.

显示单元706用于显示由用户输入的信息或提供给用户的信息。显示单元706可包括显示面板7061,可以采用液晶显示器(Liquid Crystal Display,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板7061。Thedisplay unit 706 is used to display information input by the user or information provided to the user. Thedisplay unit 706 may include adisplay panel 7061, and thedisplay panel 7061 may be configured in the form of a liquid crystal display (Liquid Crystal Display, LCD), an organic light-emitting diode (Organic Light-Emitting Diode, OLED), or the like.

用户输入单元707可用于接收输入的数字或字符信息,以及产生与电子设备的用户设置以及功能控制有关的键信号输入。具体地,用户输入单元707包括触控面板7071以及其他输入设备7072。触控面板7071,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板7071上或在触控面板7071附近的操作)。触控面板7071可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器710,接收处理器710发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板7071。除了触控面板7071,用户输入单元707还可以包括其他输入设备7072。具体地,其他输入设备7072可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆,在此不再赘述。Theuser input unit 707 can be used to receive input numbers or character information, and generate key signal input related to user settings and function control of the electronic device. Specifically, theuser input unit 707 includes atouch panel 7071 andother input devices 7072 . Thetouch panel 7071, also referred to as a touch screen, can collect touch operations of the user on or near it (for example, the user uses any suitable object or accessory such as a finger or a stylus on thetouch panel 7071 or near the touch panel 7071). operate). Thetouch panel 7071 may include two parts, a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, and detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and sends it to the For theprocessor 710, receive the command sent by theprocessor 710 and execute it. In addition, thetouch panel 7071 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to thetouch panel 7071 , theuser input unit 707 may also includeother input devices 7072 . Specifically,other input devices 7072 may include, but are not limited to, physical keyboards, function keys (such as volume control keys, switch keys, etc.), trackballs, mice, and joysticks, which will not be repeated here.

进一步的,触控面板7071可覆盖在显示面板7061上,当触控面板7071检测到在其上或附近的触摸操作后,传送给处理器710以确定触摸事件的类型,随后处理器710根据触摸事件的类型在显示面板7061上提供相应的视觉输出。虽然在图7中,触控面板7071与显示面板7061是作为两个独立的部件来实现电子设备的输入和输出功能,但是在某些实施例中,可以将触控面板7071与显示面板7061集成而实现电子设备的输入和输出功能,具体此处不做限定。Furthermore, thetouch panel 7071 can be covered on thedisplay panel 7061. When thetouch panel 7071 detects a touch operation on or near it, it will be sent to theprocessor 710 to determine the type of the touch event. The type of event provides a corresponding visual output on thedisplay panel 7061. Although in FIG. 7, thetouch panel 7071 and thedisplay panel 7061 are used as two independent components to realize the input and output functions of the electronic device, in some embodiments, thetouch panel 7071 and thedisplay panel 7061 can be integrated. The implementation of the input and output functions of the electronic device is not specifically limited here.

接口单元708为外部装置与电子设备700连接的接口。例如,外部装置可以包括有线或无线头戴式耳机端口、外部电源(或电池充电器)端口、有线或无线数据端口、存储卡端口、用于连接具有识别模块的装置的端口、音频输入/输出(I/O)端口、视频I/O端口、耳机端口等等。接口单元708可以用于接收来自外部装置的输入(例如,数据信息、电力等等)并且将接收到的输入传输到电子设备700内的一个或多个元件或者可以用于在电子设备700和外部装置之间传输数据。Theinterface unit 708 is an interface for connecting an external device to theelectronic device 700 . For example, an external device may include a wired or wireless headset port, an external power (or battery charger) port, a wired or wireless data port, a memory card port, a port for connecting a device with an identification module, audio input/output (I/O) ports, video I/O ports, headphone ports, and more. Theinterface unit 708 can be used to receive input from an external device (for example, data information, power, etc.) transfer data between devices.

存储器709可用于存储软件程序以及各种数据。存储器709可主要包括存储程序区和存储数据区,其中,存储程序区可存储操作系统、至少一个功能所需的应用程序(比如声音播放功能、图像播放功能等)等;存储数据区可存储根据手机的使用所创建的数据(比如音频数据、电话本等)等。此外,存储器709可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件、闪存器件、或其他易失性固态存储器件。Thememory 709 can be used to store software programs as well as various data. Thememory 709 can mainly include a program storage area and a data storage area, wherein the program storage area can store an operating system, at least one application program required by a function (such as a sound playback function, an image playback function, etc.); Data created by the use of mobile phones (such as audio data, phonebook, etc.), etc. In addition, thememory 709 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one magnetic disk storage device, flash memory device, or other volatile solid-state storage devices.

处理器710是电子设备的控制中心,利用各种接口和线路连接整个电子设备的各个部分,通过运行或执行存储在存储器709内的软件程序和/或模块,以及调用存储在存储器709内的数据,执行电子设备的各种功能和处理数据,从而对电子设备进行整体监控。处理器710可包括一个或多个处理单元;优选地,处理器710可集成应用处理器和调制解调处理器,其中,应用处理器主要处理操作系统、用户界面和应用程序等,调制解调处理器主要处理无线通信。可以理解的是,上述调制解调处理器也可以不集成到处理器710中。Theprocessor 710 is the control center of the electronic device, and uses various interfaces and lines to connect various parts of the entire electronic device, by running or executing software programs and/or modules stored in thememory 709, and calling data stored in thememory 709 , to perform various functions of the electronic equipment and process data, so as to monitor the electronic equipment as a whole. Theprocessor 710 may include one or more processing units; preferably, theprocessor 710 may integrate an application processor and a modem processor, wherein the application processor mainly processes the operating system, user interface and application programs, etc., and the modem The processor mainly handles wireless communication. It can be understood that the foregoing modem processor may not be integrated into theprocessor 710 .

电子设备700还可以包括给各个部件供电的电源711(比如电池),优选地,电源711可以通过电源管理系统与处理器710逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。Theelectronic device 700 can also include a power supply 711 (such as a battery) for supplying power to various components. Preferably, thepower supply 711 can be logically connected to theprocessor 710 through a power management system, so as to manage charging, discharging, and power consumption through the power management system. and other functions.

另外,电子设备700包括一些未示出的功能模块,在此不再赘述。In addition, theelectronic device 700 includes some functional modules not shown, which will not be repeated here.

优选地,本发明实施例还提供一种电子设备,包括处理器710,存储器709,存储在存储器709上并可在所述处理器710上运行的计算机程序,该计算机程序被处理器710执行时实现上述拍照方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。Preferably, the embodiment of the present invention also provides an electronic device, including aprocessor 710, amemory 709, and a computer program stored in thememory 709 and operable on theprocessor 710. When the computer program is executed by theprocessor 710 Each process of the above embodiment of the photographing method can be realized, and the same technical effect can be achieved. In order to avoid repetition, details are not repeated here.

本发明实施例还提供一种计算机可读存储介质,计算机可读存储介质上存储有计算机程序,该计算机程序被处理器执行时实现上述拍照方法实施例的各个过程,且能达到相同的技术效果,为避免重复,这里不再赘述。其中,所述的计算机可读存储介质,如只读存储器(Read-Only Memory,简称ROM)、随机存取存储器(Random Access Memory,简称RAM)、磁碟或者光盘等。The embodiment of the present invention also provides a computer-readable storage medium. A computer program is stored on the computer-readable storage medium. When the computer program is executed by a processor, each process of the above-mentioned photographing method embodiment is realized, and the same technical effect can be achieved. , to avoid repetition, it will not be repeated here. Wherein, the computer-readable storage medium is, for example, a read-only memory (Read-Only Memory, ROM for short), a random access memory (Random Access Memory, RAM for short), a magnetic disk or an optical disk, and the like.

需要说明的是,在本说明书中,术语“包括”、“包含”或者其任何其他变体意在涵盖非排他性的包含,从而使得包括一系列要素的过程、方法、物品或者装置不仅包括那些要素,而且还包括没有明确列出的其他要素,或者是还包括为这种过程、方法、物品或者装置所固有的要素。在没有更多限制的情况下,由语句“包括一个……”限定的要素,并不排除在包括该要素的过程、方法、物品或者装置中还存在另外的相同要素。It should be noted that in this specification, the term "comprises", "comprises" or any other variation thereof is intended to cover a non-exclusive inclusion such that a process, method, article or apparatus comprising a set of elements includes not only those elements , but also includes other elements not expressly listed, or also includes elements inherent in such a process, method, article, or device. Without further limitations, an element defined by the phrase "comprising a ..." does not preclude the presence of additional identical elements in the process, method, article, or apparatus comprising that element.

通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到上述实施例方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本发明的技术方案本质上或者说对现有技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端(可以是手机,计算机,服务器,空调器,或者网络设备等)执行本发明各个实施例所述的方法。Through the description of the above embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus a necessary general-purpose hardware platform, and of course also by hardware, but in many cases the former is better implementation. Based on such an understanding, the essence of the technical solution of the present invention or the part that contributes to the prior art can be embodied in the form of software products, and the computer software products are stored in a storage medium (such as ROM/RAM, disk, CD) contains several instructions to make a terminal (which may be a mobile phone, a computer, a server, an air conditioner, or a network device, etc.) execute the methods described in various embodiments of the present invention.

上面结合附图对本发明的实施例进行了描述,但是本发明并不局限于上述的具体实施方式,上述的具体实施方式仅仅是示意性的,而不是限制性的,本领域的普通技术人员在本发明的启示下,在不脱离本发明宗旨和权利要求所保护的范围情况下,还可做出很多形式,均属于本发明的保护之内。Embodiments of the present invention have been described above in conjunction with the accompanying drawings, but the present invention is not limited to the above-mentioned specific implementations, and the above-mentioned specific implementations are only illustrative, rather than restrictive, and those of ordinary skill in the art will Under the enlightenment of the present invention, without departing from the gist of the present invention and the protection scope of the claims, many forms can also be made, all of which belong to the protection of the present invention.

Claims (11)

Translated fromChinese
1.一种拍照方法,应用于电子设备,所述电子设备包括:屏幕和摄像头,所述摄像头设置在所述屏幕的下方,并且可在所述屏幕的下方移动,其特征在于,所述方法包括:1. A method for taking pictures, applied to an electronic device, the electronic device comprising: a screen and a camera, the camera is arranged below the screen and can move below the screen, it is characterized in that the method include:在所述摄像头已启动的情况下,获取所述屏幕上显示的内容画面;In the case that the camera is started, acquire the content picture displayed on the screen;根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;According to the content picture, determine a first screen area in the screen, wherein the first screen area is a screen area corresponding to the first screen area in the content picture, and the first screen area is the A picture area in the content picture whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than the preset parameter threshold;控制所述摄像头移动至所述第一屏幕区域的下方。controlling the camera to move to the bottom of the first screen area.2.根据权利要求1所述的方法,其特征在于,在所述控制所述摄像头移动至所述第一屏幕区域的下方的步骤之后,还包括:2. The method according to claim 1, further comprising: after the step of controlling the camera to move below the first screen area:控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。controlling the camera to capture images under the first screen area to obtain a first image.3.根据权利要求2所述的方法,其特征在于,在所述控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像的步骤之后,还包括:3. The method according to claim 2, characterized in that, after the step of controlling the camera to capture images under the first screen area to obtain the first image, further comprising:确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;Determining a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter is lower than that of the first screen The screen area corresponding to the screen area of the pixel color parameter of the area;控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。Controlling the camera to move from below the first screen area to below the second screen area to capture images to obtain a second image.4.根据权利要求1至3任一项所述的方法,其特征在于,所述像素色彩参数为:画面区域内所有像素的RGB平均值。4. The method according to any one of claims 1 to 3, wherein the pixel color parameter is: the RGB average value of all pixels in the picture area.5.根据权利要求4所述的方法,其特征在于,在根据所述内容画面,确定所述屏幕中的第一屏幕区域的步骤之前,还包括:确定所述内容画面中的第一画面区域,其中,5. The method according to claim 4, further comprising: determining the first screen area in the content screen before the step of determining the first screen area in the screen according to the content screen ,in,所述确定所述内容画面中的第一画面区域,包括:The determining the first picture area in the content picture includes:确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;Determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;若所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域,则将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;If the content picture includes: a picture area with a size of S and an average value of RGB of T, then the picture area with a size of S and an average value of RGB of T is determined as the first picture area;若所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域,则执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;If the content picture does not include: a picture area with a size of S and an average value of RGB of T, then execute the T++ operation, and determine whether the T obtained by the operation is greater than M, wherein the M is the camera through the screen. The critical value of the RGB average value of the photo;若所述运算得到的T不大于M,则确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;If the T obtained by the operation is not greater than M, then determine whether the content screen includes: a picture area whose size is S and whose RGB average value is T obtained by the operation;若所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;If the content picture includes: a picture area whose size is S and the average value of RGB is T obtained by the calculation, then the picture area whose size is S and the average value of RGB is T obtained by the calculation is determined as First screen area;若所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域,则重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。If the content picture does not include a picture area whose size is S and whose RGB average value is T obtained by the calculation, repeat the above picture area determination operation until a picture area satisfying the condition is found.6.一种电子设备,所述电子设备包括:屏幕和摄像头,所述摄像头设置在所述屏幕的下方,并且可在所述屏幕的下方移动,其特征在于,所述电子设备包括:6. An electronic device, the electronic device comprising: a screen and a camera, the camera is arranged below the screen and can move below the screen, characterized in that the electronic device comprises:获取单元,用于在所述摄像头已启动的情况下,获取所述屏幕上显示的内容画面;An acquisition unit, configured to acquire the content picture displayed on the screen when the camera is activated;第一确定单元,用于根据所述内容画面,确定所述屏幕中的第一屏幕区域,其中,所述第一屏幕区域为所述内容画面中的第一画面区域对应的屏幕区域,所述第一画面区域为所述内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于预设参数阈值的画面区域;The first determining unit is configured to determine a first screen area in the screen according to the content picture, wherein the first screen area is a screen area corresponding to the first picture area in the content picture, and the The first picture area is a picture area in the content picture whose size is not smaller than the lens size of the camera and whose pixel color parameter is lower than a preset parameter threshold;第一控制单元,用于控制所述摄像头移动至所述第一屏幕区域的下方。A first control unit, configured to control the camera to move to the bottom of the first screen area.7.根据权利要求6所述的电子设备,其特征在于,所述电子设备还包括:7. The electronic device according to claim 6, further comprising:第二控制单元,用于控制所述摄像头在所述第一屏幕区域的下方进行图像拍摄,得到第一图像。The second control unit is configured to control the camera to capture images under the first screen area to obtain a first image.8.根据权利要求7所述的电子设备,其特征在于,所述电子设备还包括:8. The electronic device according to claim 7, further comprising:第二确定单元,用于确定所述屏幕中的第二屏幕区域,其中,所述第二屏幕区域为所述屏幕上显示的内容画面中尺寸不小于所述摄像头的镜头尺寸、且像素色彩参数低于所述第一画面区域的像素色彩参数的画面区域所对应的屏幕区域;The second determination unit is configured to determine a second screen area in the screen, wherein the second screen area is the size of the content screen displayed on the screen is not smaller than the lens size of the camera, and the pixel color parameter A screen area corresponding to a picture area lower than the pixel color parameter of the first picture area;第二控制单元,用于控制所述摄像头由所述第一屏幕区域的下方移动至所述第二屏幕区域的下方进行图像拍摄,得到第二图像。The second control unit is configured to control the camera to move from below the first screen area to below the second screen area to capture images and obtain a second image.9.根据权利要求6至8任一项所述的电子设备,其特征在于,所述像素色彩参数为:画面区域内所有像素的RGB平均值。9. The electronic device according to any one of claims 6 to 8, wherein the pixel color parameter is: an RGB average value of all pixels in the picture area.10.根据权利要求9所述的电子设备,其特征在于,所述电子设备还包括:第三确定单元,其中,所述第三确定单元包括:10. The electronic device according to claim 9, further comprising: a third determining unit, wherein the third determining unit comprises:第一确定子单元,用于确定所述内容画面中是否包括:尺寸为S且RGB平均值为T的画面区域,其中,所述S不小于所述摄像头的镜头尺寸,所述T的初始值为0;The first determination subunit is used to determine whether the content picture includes: a picture area with a size of S and an average value of RGB of T, wherein the S is not smaller than the lens size of the camera, and the initial value of T is 0;第二确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为T的画面区域的情况下,将所述尺寸为S且RGB平均值为T的画面区域,确定为第一画面区域;The second determining subunit is used to determine the picture area whose size is S and whose RGB average value is T when the content picture includes: a picture area whose size is S and whose RGB average value is T, as First screen area;第三确定子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为T的画面区域的情况下,执行T++运算,并确定运算得到的T是否大于M,其中,所述M为所述摄像头透过屏幕进行拍照的RGB平均值的临界值;The third determining subunit is used to execute T++ operation and determine whether the T obtained by the operation is greater than M when the content image does not include: an image area whose size is S and the average value of RGB is T, wherein, Said M is the critical value of the RGB mean value that said camera takes pictures through the screen;第四确定子单元,用于在所述运算得到的T不大于M的情况下,确定所述内容画面中是否包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域;The fourth determining subunit is used to determine whether the content picture includes: a picture area whose size is S and whose RGB average value is T obtained by the calculation, when the T obtained by the calculation is not greater than M;第五确定子单元,用于在所述内容画面中包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,将所述尺寸为S且RGB平均值为所述运算得到的T的画面区域,确定为第一画面区域;The fifth determining subunit is used to set the size as S and the average value of RGB to the picture area whose size is S and the average value of RGB is The picture area of T obtained by the calculation is determined as the first picture area;处理子单元,用于在所述内容画面中不包括:尺寸为S且RGB平均值为所述运算得到的T的画面区域的情况下,重复上述画面区域确定操作,直至查找到满足条件的画面区域为止。The processing subunit is used to repeat the above-mentioned picture area determination operation until a picture meeting the condition is found in the case that the content picture does not include: a picture area whose size is S and whose RGB average value is T obtained by the calculation area so far.11.一种电子设备,其特征在于,包括处理器、存储器及存储在所述存储器上并可在所述处理器上运行的计算机程序,所述计算机程序被所述处理器执行时实现如权利要求1至5任一项所述的拍照方法的步骤。11. An electronic device, characterized by comprising a processor, a memory, and a computer program stored on the memory and operable on the processor, when the computer program is executed by the processor, the The steps of the photographing method described in any one of 1 to 5 are required.
CN201911013771.3A2019-10-232019-10-23 Photographing method and electronic deviceActiveCN110636225B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201911013771.3ACN110636225B (en)2019-10-232019-10-23 Photographing method and electronic device

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201911013771.3ACN110636225B (en)2019-10-232019-10-23 Photographing method and electronic device

Publications (2)

Publication NumberPublication Date
CN110636225Atrue CN110636225A (en)2019-12-31
CN110636225B CN110636225B (en)2021-06-15

Family

ID=68977359

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201911013771.3AActiveCN110636225B (en)2019-10-232019-10-23 Photographing method and electronic device

Country Status (1)

CountryLink
CN (1)CN110636225B (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN111031253A (en)*2020-01-132020-04-17维沃移动通信有限公司Shooting method and electronic equipment
CN111327822A (en)*2020-02-272020-06-23维沃移动通信有限公司Method for controlling camera to move and electronic equipment
CN111953899A (en)*2020-08-042020-11-17深圳市锐尔觅移动通信有限公司 Image generation method, image generation device, storage medium and electronic device

Citations (11)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20150029167A1 (en)*2012-02-242015-01-29Sharp Kabushiki KaishaDisplay device, electronic device comprising same, and drive method for display device
CN108683757A (en)*2018-04-242018-10-19Oppo广东移动通信有限公司Electronic device and electronic apparatus
CN108810627A (en)*2018-07-052018-11-13京东方科技集团股份有限公司A kind of display device and its display methods
CN108881530A (en)*2018-06-042018-11-23Oppo广东移动通信有限公司Electronic device
CN108983872A (en)*2018-06-042018-12-11Oppo广东移动通信有限公司 Electronic device and control method thereof
CN109143670A (en)*2018-09-192019-01-04北京小米移动软件有限公司Display panel, mobile terminal and its control method
CN208384467U (en)*2018-06-042019-01-15Oppo广东移动通信有限公司Electronic device
CN109348123A (en)*2018-10-252019-02-15努比亚技术有限公司Photographic method, mobile terminal and computer readable storage medium
CN109979382A (en)*2019-04-232019-07-05清华大学Imaging system color correcting method and system under screen based on screen transmitted spectrum
CN209313871U (en)*2018-11-292019-08-27华为技术有限公司 a terminal
CN110232892A (en)*2019-05-162019-09-13武汉华星光电半导体显示技术有限公司Display panel and display device

Patent Citations (11)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20150029167A1 (en)*2012-02-242015-01-29Sharp Kabushiki KaishaDisplay device, electronic device comprising same, and drive method for display device
CN108683757A (en)*2018-04-242018-10-19Oppo广东移动通信有限公司Electronic device and electronic apparatus
CN108881530A (en)*2018-06-042018-11-23Oppo广东移动通信有限公司Electronic device
CN108983872A (en)*2018-06-042018-12-11Oppo广东移动通信有限公司 Electronic device and control method thereof
CN208384467U (en)*2018-06-042019-01-15Oppo广东移动通信有限公司Electronic device
CN108810627A (en)*2018-07-052018-11-13京东方科技集团股份有限公司A kind of display device and its display methods
CN109143670A (en)*2018-09-192019-01-04北京小米移动软件有限公司Display panel, mobile terminal and its control method
CN109348123A (en)*2018-10-252019-02-15努比亚技术有限公司Photographic method, mobile terminal and computer readable storage medium
CN209313871U (en)*2018-11-292019-08-27华为技术有限公司 a terminal
CN109979382A (en)*2019-04-232019-07-05清华大学Imaging system color correcting method and system under screen based on screen transmitted spectrum
CN110232892A (en)*2019-05-162019-09-13武汉华星光电半导体显示技术有限公司Display panel and display device

Cited By (5)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN111031253A (en)*2020-01-132020-04-17维沃移动通信有限公司Shooting method and electronic equipment
CN111327822A (en)*2020-02-272020-06-23维沃移动通信有限公司Method for controlling camera to move and electronic equipment
CN111327822B (en)*2020-02-272021-07-20维沃移动通信有限公司 A method and electronic device for controlling the movement of a camera
CN111953899A (en)*2020-08-042020-11-17深圳市锐尔觅移动通信有限公司 Image generation method, image generation device, storage medium and electronic device
CN111953899B (en)*2020-08-042021-12-17深圳市锐尔觅移动通信有限公司 Image generation method, image generation device, storage medium and electronic device

Also Published As

Publication numberPublication date
CN110636225B (en)2021-06-15

Similar Documents

PublicationPublication DateTitle
CN107580184B (en) A shooting method and mobile terminal
CN108924414B (en) A shooting method and terminal equipment
CN108492246B (en)Image processing method and device and mobile terminal
CN107566730B (en) A panoramic image shooting method and mobile terminal
CN107509038A (en)A kind of image pickup method and mobile terminal
CN107977652B (en)Method for extracting screen display content and mobile terminal
CN107908383A (en)A kind of screen color method of adjustment, device and mobile terminal
CN107566748A (en)A kind of image processing method, mobile terminal and computer-readable recording medium
CN108495029A (en)A kind of photographic method and mobile terminal
CN108111754A (en)A kind of method and mobile terminal of definite image acquisition modality
CN110933302B (en) A shooting method and electronic device
CN108040209B (en)Shooting method and mobile terminal
CN108881719B (en) A method and terminal equipment for switching shooting modes
CN107707825A (en)A kind of panorama shooting method, mobile terminal and computer-readable recording medium
CN108833709A (en) Method for starting camera and mobile terminal
CN110213485A (en)A kind of image processing method and terminal
CN107608606A (en)A kind of image display method, mobile terminal and computer-readable recording medium
CN110636225B (en) Photographing method and electronic device
CN107682637A (en) A shooting method, mobile terminal and computer-readable storage medium
CN108076294B (en) A shooting method and mobile terminal
CN107807488B (en)Camera assembly, aperture adjusting method and mobile terminal
CN109005355A (en)A kind of image pickup method and mobile terminal
WO2021147911A1 (en)Mobile terminal, method for detecting image capturing mode, and storage medium
CN110602387B (en) Shooting method and electronic device
CN107566738A (en)A kind of panorama shooting method, mobile terminal and computer-readable recording medium

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp