WO2018040174A1 - 一种设置预览分辨率的方法、装置及终端 - Google Patents

一种设置预览分辨率的方法、装置及终端 Download PDF

Info

Publication number
WO2018040174A1
WO2018040174A1 PCT/CN2016/100682 CN2016100682W WO2018040174A1 WO 2018040174 A1 WO2018040174 A1 WO 2018040174A1 CN 2016100682 W CN2016100682 W CN 2016100682W WO 2018040174 A1 WO2018040174 A1 WO 2018040174A1
Authority
WO
WIPO (PCT)
Prior art keywords
resolution
preview
initial
ratio
pixels
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.)
Ceased
Application number
PCT/CN2016/100682
Other languages
English (en)
French (fr)
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.)
Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Original Assignee
Yulong Computer Telecommunication Scientific Shenzhen 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 Yulong Computer Telecommunication Scientific Shenzhen Co Ltd filed Critical Yulong Computer Telecommunication Scientific Shenzhen Co Ltd
Publication of WO2018040174A1 publication Critical patent/WO2018040174A1/zh
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/1407General aspects irrespective of display type, e.g. determination of decimal point position, display with fixed or driving decimal point, suppression of non-significant zeros
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/14Digital output to display device ; Cooperation and interconnection of the display device with other functional units
    • G06F3/1415Digital output to display device ; Cooperation and interconnection of the display device with other functional units with means for detecting differences between the image stored in the host and the images displayed on the displays

Definitions

  • the present invention relates to the field of communications technologies, and in particular, to a method, an apparatus, and a terminal for setting a preview resolution.
  • the camera function has become one of the basic functions of electronic products such as mobile phones. Users have become accustomed to taking photos of their mobile phones to record what is happening in their lives.
  • the preview interface can present the picture currently captured by the camera, so that the user can adjust the shooting position according to the content displayed on the preview interface.
  • the resolution of the preview interface is low, there may be a case where the preview effect is significantly different from the actual shooting effect.
  • the above implementation will result in a higher resolution of the preview interface.
  • the resolution of the preview interface reaches the maximum resolution that the display can support, the increase of the preview resolution does not improve the preview effect, and the higher preview resolution increases the real-time data generated during the user's shooting, thereby occupying A large amount of mobile phone memory and resources to increase mobile phone power consumption.
  • the invention provides a method, a device and a terminal for setting a preview resolution, which solves the problem that the terminal power consumption is large due to the high preview resolution.
  • the embodiment of the present invention adopts the following technical solutions:
  • the present invention provides a method for setting a preview resolution, the method comprising: acquiring a screen resolution of a terminal and an initial preview resolution during terminal shooting, the initial preview resolution and a camera resolution of the terminal The same; if the initial preview resolution is greater than the screen resolution, according to a ratio of the initial preview resolution to the number of vertical pixels of the screen resolution, and the initial preview resolution and the screen resolution The ratio of the number of horizontal pixels determines a preview ratio; according to the preview ratio, the preview resolution during the shooting of the terminal is adjusted from the initial resolution to the current preview resolution, and the current preview resolution is smaller than the initial Preview resolution.
  • the present invention provides an apparatus for setting a preview resolution, the apparatus comprising: an acquisition module configured to acquire a screen resolution of the terminal and an initial preview resolution during terminal shooting, the initial preview resolution and The camera has the same resolution; the determining module is configured to: when the initial preview resolution acquired by the acquiring module is greater than the screen resolution acquired by the acquiring module, according to the initial preview resolution and the screen resolution a ratio of the number of pixels, and a ratio of the initial preview resolution to the number of horizontal pixels of the screen resolution determines a preview ratio; the adjustment module is configured to follow the preview ratio determined by the determining module, and the terminal is in the process of shooting The preview resolution is adjusted by the acquisition module to an initial resolution, and the current preview resolution is smaller than the initial preview resolution.
  • the present invention provides a terminal, the terminal comprising at least the apparatus for setting a preview resolution according to the second aspect.
  • the method, device and terminal for setting preview resolution provided by the present invention, if the initial preview resolution obtained is greater than the screen resolution, the ratio of the vertical pixels according to the initial preview resolution and the screen resolution, and the horizontal pixels of the two The ratio of the number determines the preview ratio, and the preview resolution during the terminal shooting is adjusted from the initial preview resolution to the current preview resolution according to the preview ratio; otherwise, the initial preview resolution is still used as the preview resolution during the terminal shooting.
  • the preview resolution and the camera resolution are set to the same resolution.
  • the initial adjustment resolution can be adjusted according to the ratio of the initial preview resolution to the screen resolution. Preview the resolution to get the current preview resolution that is less than the initial preview resolution.
  • the present invention can solve the problem of large power consumption of the terminal due to excessive preview resolution.
  • FIG. 1 is a flowchart of a method for setting a preview resolution according to an embodiment of the present invention
  • FIG. 2 is a flowchart of another method for setting a preview resolution according to an embodiment of the present invention.
  • FIG. 3 is a flowchart of another method for setting a preview resolution according to an embodiment of the present invention.
  • FIG. 4 is a flowchart of another method for setting a preview resolution according to an embodiment of the present invention.
  • FIG. 5 is a schematic diagram of an apparatus for setting a preview resolution according to an embodiment of the present invention.
  • FIG. 6 is a schematic block diagram of a structure of a terminal according to an embodiment of the present invention.
  • the embodiment of the invention provides a method for setting a preview resolution, which can be applied to terminals such as mobile phones and tablet computers. As shown in FIG. 1 , the method process specifically includes:
  • the initial preview resolution is the same as the camera resolution of the terminal.
  • the user's shooting process involves three resolution parameters, including: camera resolution, screen resolution and preview resolution.
  • camera resolution In order to obtain pictures of different quality, you can select cameras with different resolutions to complete the image acquisition process.
  • the resolution of the camera with the size of 8M corresponds to 3264*2448
  • the resolution of the camera with the size of 13M corresponds to 4208*. 3120.
  • the resolution of the screen is determined by the hardware structure of the screen, such as the screen resolution of the FHD (English: Full High Definition) screen with a screen resolution of 1920*1080 and HD (English: High Definition) screen.
  • the resolution is 1280*720.
  • the camera resolution is usually used as the preview resolution.
  • preview and “photographing” can be separately processed, that is, the preview uses a set of parameters, the camera uses another set of parameters, the parameters used in the preview process and the parameters used in the photographing process. Do not affect each other. Therefore, the change in preview resolution does not affect the quality of the image.
  • the user can select different camera resolutions according to his own needs, but when the camera of the terminal is fixed, the maximum resolution of the camera is the full-size resolution of the camera.
  • steps 103 and 104 are performed; otherwise, step 105 is performed.
  • the initial preview resolution When the initial preview resolution is greater than the screen resolution, the screen resolution becomes the main factor limiting the preview effect. At this time, the initial preview resolution is adjusted without affecting the preview effect. Therefore, the initial preview resolution can be reduced by the preview ratio.
  • the preview ratio can be determined by the ratio of the initial preview resolution to the number of vertical pixels of the screen resolution, and the ratio of the initial preview resolution to the number of horizontal pixels of the screen resolution.
  • the initial preview resolution is 3264*2448
  • the screen resolution is 1920*1080
  • the ratio of the initial preview resolution to the vertical resolution of the screen resolution is 3264/1920
  • the initial preview resolution and the screen resolution are the number of horizontal pixels.
  • the ratio is 2448/1080
  • the preview ratio can be determined according to the ratio of the number of vertical pixels to 3264/1920 and the ratio of the horizontal pixels to 2448/1080. The specific determination method will be proposed later, and will not be described here.
  • the preview resolution during the terminal shooting is adjusted from the initial resolution to the current preview resolution.
  • the current preview resolution is smaller than the initial preview resolution, which means that the initial preview resolution is reduced according to the preview ratio, and a current preview resolution smaller than the initial preview resolution can be obtained.
  • the initial preview resolution is the main factor determining the preview effect. Adjusting the initial preview resolution may affect the preview effect. Therefore, in order to avoid the influence on the preview effect, the initial preview resolution is set to the current preview resolution, that is, the preview resolution during the terminal shooting is not adjusted.
  • a method for setting a preview resolution provided by an embodiment of the present invention, if the obtained initial preview resolution is greater than the screen resolution, the ratio of the vertical pixels according to the initial preview resolution and the screen resolution, and the number of horizontal pixels of the two Compared with determining the preview ratio, the preview resolution during terminal shooting is adjusted from the initial preview resolution to the current preview resolution according to the preview ratio; otherwise, the initial preview resolution is still used as the preview resolution during the terminal shooting.
  • the preview resolution and the camera resolution are set to the same resolution.
  • the present invention can adjust the terminal according to the ratio of the initial preview resolution to the screen resolution. The preview ratio during shooting.
  • the present invention can solve the problem of large power consumption of the terminal due to excessive preview resolution.
  • the number of vertical pixels of the initial preview resolution is greater than the number of vertical pixels of the screen resolution, and the horizontal pixels of the initial preview resolution are used to reduce the influence of the preview resolution.
  • the preview resolution needs to be adjusted. Therefore, on the basis of the implementation shown in FIG. 1, an implementation as shown in FIG. 2 can also be implemented.
  • the step 102 determines whether the initial resolution is greater than the screen resolution, and may be specifically implemented as steps 1021 to 1024:
  • step 1022 is performed; otherwise, step 1024 is performed.
  • step 1023 If the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution, step 1023 is performed; otherwise, step 1024 is performed.
  • adjusting the initial preview resolution may affect the preview effect. If the number of vertical pixels of the initial preview resolution is less than or equal to the number of vertical pixels of the screen resolution, indicating that the initial preview resolution is the main factor affecting the preview effect in the vertical direction, adjusting the initial preview resolution may affect the preview effect. . If the number of horizontal pixels of the initial preview resolution is less than the number of horizontal pixels of the screen resolution, indicating that the initial preview resolution is the main factor affecting the preview effect in the horizontal direction, adjusting the initial preview resolution at this time may affect the preview effect.
  • the initial preview resolution in order to reduce the influence on the preview effect, when the number of vertical pixels of the initial preview resolution is less than or equal to the number of vertical pixels of the screen resolution or the number of horizontal pixels of the initial preview resolution is less than or the screen resolution
  • the number of horizontal pixels is the rate
  • the initial pixel number of the initial preview resolution is greater than the number of vertical pixels of the screen resolution
  • the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution
  • the initial preview resolution is 3264*2448 and the screen resolution is 1920*1080
  • the initial preview resolution is 1280*960 and the screen resolution is 1920*1080
  • the present invention is not limited to the order of comparison of the number of vertical pixels and the comparison process of the number of horizontal pixels.
  • the method for setting a preview resolution provided by the embodiment of the present invention, if the number of vertical pixels of the initial preview resolution is greater than the number of vertical pixels of the screen resolution, and the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution, then Determine that the initial preview resolution is greater than the screen resolution; otherwise determine that the initial preview resolution is less than or equal to the screen resolution.
  • the preview resolution and the camera resolution are set to the same resolution, and the present invention solves the problem of large power consumption of the terminal due to excessive preview resolution, only when the initial preview resolution is When the number of vertical pixels is greater than the number of vertical pixels of the screen resolution, and the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution, it is determined that the initial preview resolution is greater than the screen resolution, thereby avoiding the initial preview resolution adjustment.
  • Reasonable the impact on the preview effect.
  • the step 103 determines the preview ratio according to the ratio of the initial preview resolution to the vertical pixel number of the screen resolution and the ratio of the initial preview resolution to the horizontal pixel number of the screen resolution, which may be specifically implemented as steps 1031 to 1033:
  • step 1032 is performed; otherwise, step 1033 is performed.
  • the smaller of the ratio of the horizontal pixel number to the vertical pixel number is determined as the preview ratio.
  • the initial preview resolution is 3264*2448
  • the screen resolution is 1920*1080
  • the ratio of vertical pixels is 3264/1920 is less than the ratio of horizontal pixels to 2448/1080
  • the ratio of the number of vertical pixels is determined as the preview ratio
  • initial preview The resolution is 3264*2448
  • the screen resolution is 1280*1024
  • the ratio of vertical pixels is 3264/1280 is greater than the ratio of horizontal pixels to 2448/1024
  • the ratio of the number of horizontal pixels is determined as the preview ratio.
  • the method for setting the preview resolution provided by the embodiment of the present invention the ratio of the preview resolution to the vertical pixel number of the screen resolution, and the smaller one of the ratio of the preview resolution to the horizontal pixel number of the screen resolution is used as the preview ratio.
  • the preview resolution and the camera resolution are set to the same resolution, and the present invention solves the problem that the terminal power consumption is large due to the excessive preview resolution, by using the preview resolution and The ratio of the vertical pixel count of the screen resolution and the smaller of the ratio of the preview resolution to the horizontal pixel number of the screen resolution as the preview ratio ensures that the adjusted initial preview resolution is still greater than the screen resolution, thereby The initial preview resolution is adjusted without affecting the preview.
  • the number of vertical pixels and the number of vertical pixels of the initial resolution are respectively adjusted according to a certain ratio in order to ensure that the preview interface is not deformed after the preview resolution is adjusted. Therefore, on the basis of the implementation shown in FIG. 1, an implementation as shown in FIG. 4 can also be implemented.
  • the step 104 adjusts the preview resolution during the terminal shooting from the initial resolution to the current preview resolution according to the preview ratio, which may be specifically implemented as steps 1041 to 1043:
  • the initial preview resolution is 3264*2448
  • the screen resolution is 1920*1080
  • the number of horizontal pixels of the initial preview resolution is 2448, adjusted according to the preview ratio 3264/1920
  • the resolution is 1920*1440.
  • the preview resolution during terminal shooting can be adjusted from 3264*2448 to 1920*1440.
  • the preview ratio is determined to be 2448/1080
  • the number of vertical pixels of the current preview resolution is 1440
  • the number of horizontal pixels is 1080
  • the method for setting the preview resolution provided by the embodiment of the present invention adjusts the number of vertical pixels and the number of horizontal pixels of the initial preview resolution according to the preview ratio, and distinguishes the number of vertical pixels and the number of horizontal pixels of the current preview resolution, and shoots the terminal.
  • the preview resolution in the process is adjusted to the current preview resolution.
  • the preview resolution and the camera resolution are set to the same resolution, and the present invention solves the problem of large power consumption of the terminal due to excessive preview resolution, and the initial preview resolution.
  • the number of vertical pixels and the number of horizontal pixels are adjusted in the same proportion to ensure that the preview interface does not deform relative to the image captured by the camera.
  • the embodiment of the present invention further provides an apparatus 20 for setting a preview resolution.
  • the apparatus 20 is configured to perform any method flow as shown in FIG. 1 to FIG.
  • the obtaining module 21 is configured to acquire the screen resolution of the terminal and the initial preview resolution during the terminal shooting, and the initial preview resolution is the same as the camera resolution of the terminal.
  • the determining module 22 is configured to, when the initial preview resolution acquired by the obtaining module 21 is greater than the screen resolution acquired by the obtaining module 21, the ratio of the initial preview resolution to the vertical pixel number of the screen resolution, and the initial preview resolution and the screen The ratio of the number of horizontal pixels of the resolution determines the preview ratio.
  • the adjustment module 23 is configured to adjust the initial resolution acquired by the acquisition module 21 to the current preview resolution according to the preview ratio determined by the determination module 22, and the current preview resolution is smaller than the initial preview resolution.
  • the device 20 further includes:
  • the determining module 24 is configured to determine whether the number of vertical pixels of the initial preview resolution acquired by the obtaining module 21 is greater than the number of vertical pixels of the screen resolution acquired by the acquiring module 21; and when the number of vertical pixels of the initial preview resolution is greater than the screen resolution When the number of vertical pixels is used, it is judged whether the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution.
  • the determining module 22 is further configured to determine that the initial preview resolution is greater than the screen resolution when the determining module 24 determines that the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution.
  • the determining module 22 is specifically configured to determine, when the ratio of the number of vertical pixels is greater than the ratio of the number of horizontal pixels, the ratio of the number of horizontal pixels is determined as a preview ratio; when the ratio of the number of vertical pixels is less than Or equal to the ratio of the number of horizontal pixels, the ratio of the number of vertical pixels is determined as the preview ratio.
  • the adjusting module 23 is specifically configured to reduce the number of vertical pixels and the number of horizontal pixels of the initial preview resolution according to the preview ratio; the number of vertical pixels of the reduced initial preview resolution and The number of horizontal pixels, set to the number of vertical pixels and horizontal pixels of the current preview resolution; adjust the preview resolution during terminal shooting to the current preview resolution.
  • the determining module 22 is further configured to set the initial resolution to the current preview resolution when the initial resolution is less than or equal to the screen resolution.
  • the apparatus for setting a preview resolution provided by the embodiment of the present invention, if the obtained initial preview resolution is greater than the screen resolution, the ratio of the vertical pixels according to the initial preview resolution and the screen resolution, and the number of horizontal pixels of the two Compared with determining the preview ratio, the preview resolution during terminal shooting is adjusted from the initial preview resolution to the current preview resolution according to the preview ratio; otherwise, the initial preview resolution is still used as the preview resolution during the terminal shooting.
  • the preview resolution and the camera resolution are set to the same resolution.
  • the present invention can adjust the terminal according to the ratio of the initial preview resolution to the screen resolution. The preview ratio during shooting.
  • the present invention can solve the problem of large power consumption of the terminal due to excessive preview resolution.
  • the embodiment of the present invention further provides a terminal, where the terminal is configured to execute the method flow shown in FIG. 1 to FIG. 4, and the terminal at least includes the apparatus for setting a preview resolution as shown in FIG. 5.
  • the terminal provided by the embodiment of the present invention determines the preview ratio according to the ratio of the initial preview resolution to the vertical pixel number of the screen resolution and the ratio of the horizontal pixels of the two, if the obtained initial preview resolution is greater than the screen resolution.
  • the preview resolution during terminal shooting is adjusted from the initial preview resolution to the current preview resolution according to the preview ratio; otherwise, the initial preview resolution is still used as the preview resolution during the terminal shooting.
  • the preview resolution and the camera resolution are set to the same resolution.
  • the present invention can adjust the terminal according to the ratio of the initial preview resolution to the screen resolution.
  • the preview ratio during shooting Since the current preview resolution obtained after the adjustment is smaller than the initial preview resolution, the number of pixels of the current preview resolution is smaller than the number of pixels of the initial preview resolution. Therefore, in the process of previewing the terminal using the current preview resolution, the number of pixels that the terminal needs to update in real time is reduced, which reduces the power consumption of the terminal. Therefore, the present invention can solve the problem of large power consumption of the terminal due to excessive preview resolution.
  • the terminal 30 in the embodiment of the present invention may be different types of electronic devices, such as: smart phones, tablet computers, palmtop computers, and mobile internet devices, personal digital assistants, media players, smart televisions, smart watches, smart glasses, smart hands. Ring and so on.
  • the terminal 30 in the embodiment of the present invention includes at least one processor 31, such as a CPU, at least one receiver 33, at least one memory 34, at least one transmitter 35, and at least one communication bus 32.
  • the communication bus 32 is used to implement connection communication between these components.
  • the receiver 33 and the transmitter 35 may be wired transmission ports or wireless devices, for example, including antenna devices for data communication with other devices.
  • the memory 34 may be a high speed RAM memory or a non-volatile memory such as at least one disk memory.
  • the processor 31 can execute the operating system of the terminal 30 and various installed application programs, program codes, and the like.
  • each module described above includes the acquiring module 21, the determining module 22, and the like.
  • Program code is stored in the memory 34, and the processor 31 can call the program code stored in the memory 34 via the communication bus 32 to perform related functions.
  • the various modules e.g., the acquisition module 21, the determination module 22, etc.
  • FIG. 5 are program codes stored in the memory 34, and are executed by the processor 31, thereby implementing The functions of the various modules are implemented to implement a method of setting a preview resolution.
  • the memory 34 stores a plurality of instructions that are executed by the processor 31 to implement a method of setting a preview resolution.
  • the performing, by the processor 31, the execution of the multiple instructions includes: acquiring a screen resolution of the terminal and an initial preview resolution during the terminal shooting, where the initial preview resolution is the same as the camera resolution of the terminal; If the initial preview resolution is greater than the screen resolution, a ratio of the initial preview resolution to the number of vertical pixels of the screen resolution, and a level of the initial preview resolution and the screen resolution The ratio of the number of pixels determines a preview ratio; according to the preview ratio, the preview resolution during the shooting of the terminal is adjusted from the initial resolution to a current preview resolution, and the current preview resolution is smaller than the initial preview resolution. rate.
  • the processor 31 further: determining whether the vertical pixel number of the initial preview resolution is greater than the vertical of the screen resolution. a number of pixels; if the number of vertical pixels of the initial preview resolution is greater than the number of vertical pixels of the screen resolution, determining whether the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution; If the number of horizontal pixels of the initial preview resolution is greater than the number of horizontal pixels of the screen resolution, it is determined that the initial preview resolution is greater than the screen resolution.
  • the ratio of the initial preview resolution to the number of vertical pixels of the screen resolution, and the ratio of the initial preview resolution to the horizontal pixel number of the screen resolution determine a preview The ratio includes: if a ratio of the number of vertical pixels is greater than a ratio of the number of horizontal pixels, determining a ratio of the number of horizontal pixels as the preview ratio; if a ratio of the number of vertical pixels is less than or equal to the ratio The ratio of the number of horizontal pixels determines the ratio of the number of vertical pixels as the preview ratio.
  • the adjusting the initial preview resolution of the terminal to the current preview resolution according to the preview ratio comprises: reducing a vertical pixel number of the initial preview resolution according to the preview ratio The number of horizontal pixels; the number of vertical pixels and horizontal pixels of the reduced initial preview resolution, the number of vertical pixels and the number of horizontal pixels of the current preview resolution; and the preview resolution during the shooting of the terminal Adjust to the current preview resolution.
  • the processor 31 sets the initial resolution if the initial resolution is less than or equal to the screen resolution.
  • the current preview resolution is set.
  • the storage medium may be a magnetic disk, an optical disk, a read-only memory (English: Read-Only Memory, ROM for short) or a random access memory (English: Random Access Memory, RAM for short).

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Studio Devices (AREA)

Abstract

一种设置预览分辨率的方法、装置及终端,涉及通信技术领域,能够解决因预览分辨率过高,而造成的手机功耗大的问题。所述方法包括:获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率(101),所述初始预览分辨率与终端的摄像头分辨率相同;如果所述初始预览分辨率大于所述屏幕分辨率(102),则根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例(103);按照所述预览比例,将所述终端拍摄过程中的预览分辨率由所述初始分辨率调整为当前预览分辨率(104),所述当前预览分辨率小于所述初始预览分辨率。该方法适用于设置预览分辨率的过程。

Description

一种设置预览分辨率的方法、装置及终端
本申请要求于2016年8月31日提交中国专利局,申请号为201610790518.9、发明名称为“一种设置预览分辨率的方法、装置及终端”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本发明涉及通信技术领域,尤其涉及一种设置预览分辨率的方法、装置及终端。
背景技术
目前,拍照功能已经成为手机等电子产品的基本功能之一,用户已经习惯于随时随地通过手机拍照来记录生活中发生的事情。在实际使用过程中,预览界面能够呈现摄像头当前拍摄的画面,使用户可以根据预览界面所显示的内容来调整拍摄位置。
如果预览界面的分辨率较低,则可能会出现预览效果与实际拍摄效果差别较大的情况。为了使预览效果贴近实际拍摄效果,可以将手机中预览界面的分辨率和摄像头的分辨率设置为相同的分辨率。对于分辨率较高的摄像头而言,采用上述实现方式会造成预览界面的分辨率也处于较高的状态。然而,当预览界面的分辨率达到显示屏能够支持的最大分辨率后,预览分辨率的增加并不能提高预览效果,且较高的预览分辨率会增加用户拍摄过程中产生的实时数据,从而占用大量手机内存和资源,增加手机功耗。
发明内容
本发明提供一种设置预览分辨率的方法、装置及终端,解决了因预览分辨率过高,而造成的终端功耗大的问题。
为达到上述目的,本发明实施例采用如下技术方案:
第一方面,本发明提供一种设置预览分辨率的方法,所述方法包括:获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,所述初始预览分辨率与终端的摄像头分辨率相同;如果所述初始预览分辨率大于所述屏幕分辨率,则根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例;按照所述预览比例,将所述终端拍摄过程中的预览分辨率由所述初始分辨率调整为当前预览分辨率,所述当前预览分辨率小于所述初始预览分辨率。
第二方面,本发明提供一种设置预览分辨率的装置,所述装置包括:获取模块,设置为获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,所述初始预览分辨率与终端的摄像头分辨率相同;确定模块,设置为当所述获取模块获取的初始预览分辨率大于所述获取模块获取的屏幕分辨率时,根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例;调整模块,设置为按照所述确定模块确定的预览比例,将所述终端拍摄过程中的预览分辨率由所述获取模块获取的初始分辨率调整为当前预览分辨率,所述当前预览分辨率小于所述初始预览分辨率。
第三方面,本发明提供一种终端,所述终端至少包括第二方面所述的设置预览分辨率的装置。
本发明提供的设置预览分辨率的方法、装置及终端,如果获取的初始预览分辨率大于屏幕分辨率,则根据初始预览分辨率和屏幕分辨率的垂直像素数之比,以及二者的水平像素数之比确定预览比例,按照预览比例将终端拍摄过程中的预览分辨率由初始预览分辨率调整为当前预览分辨率;否则,仍然使用初始预览分辨率作为终端拍摄过程中的预览分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在初始预览分辨率大于屏幕分辨率时,可以根据初始预览分辨率与屏幕分辨率的比例关系调整初始预览分辨率,得到小于初始预览分辨率的当前预览分辨率。由于当前预览分辨率小于初始预览分辨率,当前预览分辨率的像素点数量也就少于初始预览分辨率的像素点数量。因此,在终端使用当前预览分辨率进行预览的过程中,终端需要实时更新的像素点数量变少,降低了终端的功耗。因此,本发明能解决因预览分辨率过高造成的终端功耗大的问题。
附图说明
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其它的附图。
图1为本发明实施例提供的一种设置预览分辨率的方法流程图;
图2为本发明实施例提供的另一种设置预览分辨率的方法流程图;
图3为本发明实施例提供的另一种设置预览分辨率的方法流程图;
图4为本发明实施例提供的另一种设置预览分辨率的方法流程图;
图5为本发明实施例提供的一种设置预览分辨率的装置示意图;
图6为本发明实施例提供的一种终端的结构示意框图。
具体实施方式
下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本发明一部分实施例,而不是全部的实施例。基于本发明中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其它实施例,都属于本发明保护的范围。
本发明实施例提供一种设置预览分辨率的方法,该方法可以应用于手机、平板电脑等终端。如图1所示,该方法流程具体包括:
101、获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率。
其中,初始预览分辨率与终端的摄像头分辨率相同。
在实际应用中,用户的拍摄过程涉及三个分辨率参数,具体包括:摄像头分辨率、屏幕分辨率和预览分辨率。为了得到不同质量的图片,可以选择不同分辨率的摄像头来完成图像的采集过程,如大小为8M的图片对应的摄像头分辨率为3264*2448,大小为13M的图片对应的摄像头分辨率为4208*3120。屏幕分辨率的大小由屏幕的硬件结构决定,如FHD(英文:Full High Definition,中文:全高清)屏的屏幕分辨率为1920*1080,HD(英文:High Definition,中文:高清)屏的屏幕分辨率为1280*720。而为了保证预览效果,通常使用摄像头分辨率作为预览分辨率。
目前,由于终端中实现照相功能的软件部分,可实现“预览”及“拍照”分开处理,即预览用一组参数,拍照用另一组参数,预览过程使用的参数与拍照过程使用的参数之间互不影响。因此,预览分辨率的改变并不会影响图片的质量。
需要说明的是,用户可以根据自身需求选择不同的摄像头分辨率,但当终端的摄像头固定,则摄像头分辨率的最大值为摄像头的全尺寸分辨率。
102、确定初始分辨率是否大于屏幕分辨率。
如果初始预览分辨率大于屏幕分辨率,则执行步骤103和步骤104;否则,执行步骤105。
103、根据初始预览分辨率与屏幕分辨率的垂直像素数之比,以及初始预览分辨率与屏幕分辨率的水平像素数之比确定预览比例。
当初始预览分辨率大于屏幕分辨率时,屏幕分辨率成为限制预览效果的主要因素,此时对初始预览分辨率进行调整,不会影响预览效果。因此,可以按照预览比例缩小初始预览分辨率。
预览比例可以根据初始预览分辨率与屏幕分辨率的垂直像素数之比,以及初始预览分辨率与屏幕分辨率的水平像素数之比确定。例如,初始预览分辨率为3264*2448,屏幕分辨率为1920*1080,初始预览分辨率与屏幕分辨率的垂直像素数之比为3264/1920,初始预览分辨率与屏幕分辨率的水平像素数之比为2448/1080,预览比例可以根据垂直像素数之比为3264/1920和水平像素数之比为2448/1080确定,具体确定方式会在后文提出,在此不做赘述。
104、按照预览比例,将终端拍摄过程中的预览分辨率由初始分辨率调整为当前预览分辨率。
在本发明实施例中,当前预览分辨率小于初始预览分辨率,也就意味着,将初始预览分辨率按照预览比例减小,可以得到小于初始预览分辨率的当前预览分辨率。
105、将初始分辨率设置为当前预览分辨率。
当初始预览分辨率小于或等于屏幕分辨率时,初始预览分辨率是决定预览效果的主要因素,此时对初始预览分辨率进行调整,可能会影响预览效果。因此,为了避免对预览效果的影响,将初始预览分辨率设置为当前预览分辨率,即不对终端拍摄过程中的预览分辨率进行调整。
本发明实施例提供的设置预览分辨率的方法,如果获取的初始预览分辨率大于屏幕分辨率,则根据初始预览分辨率和屏幕分辨率的垂直像素数之比,以及二者的水平像素数之比确定预览比例,按照预览比例将终端拍摄过程中的预览分辨率由初始预览分辨率调整为当前预览分辨率;否则,仍然使用初始预览分辨率作为终端拍摄过程中的预览分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在初始预览分辨率大于屏幕分辨率时,可以根据初始预览分辨率与屏幕分辨率的比例关系调整终端拍摄过程中的预览比例。由于调整后得到的当前预览分辨率小于初始预览分辨率,当前预览分辨率的像素点数量也就少于初始预览分辨率的像素点数量。因此,在终端使用当前预览分辨率进行预览的过程中,终端需要实时更新的像素点数量变少,降低了终端的功耗。因此,本发明能解决因预览分辨率过高造成的终端功耗大的问题。
为了减少预览分辨率的调整对预览效果的影响,在本发明实施例的一个实现方式中,当初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数,且初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数时,需要对预览分辨率进行调整。因此,在如图1所示的实现方式的基础上,还可以实现为如图2所示的实现方式。其中,步骤102确定初始分辨率是否大于屏幕分辨率,可以具体实现为步骤1021至步骤1024:
1021、判断初始预览分辨率的垂直像素数是否大于屏幕分辨率的垂直像素数。
如果初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数,则执行步骤1022;否则,执行步骤1024。
1022、判断初始预览分辨率的水平像素数是否大于屏幕分辨率的水平像素数。
如果初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数,则执行步骤1023;否则,执行步骤1024。
如果初始预览分辨率的垂直像素数小于或等于屏幕分辨率的垂直像素数,表明垂直方向上,初始预览分辨率是影响预览效果的主要因素,此时调整初始预览分辨率易对预览效果造成影响。如果初始预览分辨率的水平像素数小于或屏幕分辨率的水平像素数,表明水平方向上,初始预览分辨率是影响预览效果的主要因素,此时调整初始预览分辨率易对预览效果造成影响。因此,在本发明实施例中,为了减小对预览效果的影响,当初始预览分辨率的垂直像素数小于或等于屏幕分辨率的垂直像素数或初始预览分辨率的水平像素数小于或屏幕分辨率的水平像素数时,确定初始预览分辨率小于或等于屏幕分辨率。当初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数,且初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数时,确定初始预览分辨率大于屏幕分辨率。例如,当初始预览分辨率为3264*2448,屏幕分辨率为1920*1080时,确定初始预览分辨率大于屏幕分辨率;当初始预览分辨率为1280*960,屏幕分辨率为1920*1080时,确定初始分辨率小于或等于屏幕分辨率。
1023、确定初始预览分辨率大于屏幕分辨率。
1024、确定初始预览分辨率小于或等于屏幕分辨率。
需要说明的是,对于垂直像素数的比较和水平像素数的比较过程的先后顺序,本发明不做限定。
本发明实施例提供的设置预览分辨率的方法,如果初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数,且初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数,则确定初始预览分辨率大于屏幕分辨率;否则确定初始预览分辨率小于或等于屏幕分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在解决因预览分辨率过高造成的终端功耗大的问题的基础上,仅当初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数,且初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数时,确定初始预览分辨率大于屏幕分辨率,从而避免初始预览分辨率调整不合理,对预览效果的影响。
为了保证调整预览分辨率后的预览效果,在本发明实施例的一个实现方式中,将垂直像素数之比与水平像素数之比中较小的值作为预览比例。因此,在如图1所示的实现方式的基础上,还可以实现为如图3所示的实现方式。其中,步骤103根据初始预览分辨率与屏幕分辨率的垂直像素数之比,以及初始预览分辨率与屏幕分辨率的水平像素数之比确定预览比例,可以具体实现为步骤1031至1033:
1031、确定垂直像素数之比是否大于水平像素数之比。
如果垂直像素数之比大于水平像素数之比,则执行步骤1032;否则,执行步骤1033。
为了避免调整后的初始预览分辨率小于屏幕分辨率,从而影响预览效果,将水平像素数之比和垂直像素数之比中较小的一个,确定为预览比例。例如,初始预览分辨率为3264*2448,屏幕分辨率为1920*1080,垂直像素数之比3264/1920小于水平像素数之比2448/1080,将垂直像素数之比确定为预览比例;初始预览分辨率为3264*2448,屏幕分辨率为1280*1024,垂直像素数之比3264/1280大于水平像素数之比2448/1024,将水平像素数之比确定为预览比例。
1032、将水平像素数之比确定为预览比例。
1033、将垂直像素数之比确定为预览比例。
本发明实施例提供的设置预览分辨率的方法,预览分辨率与屏幕分辨率的垂直像素数之比,以及预览分辨率与屏幕分辨率的水平像素数之比中较小的一个作为预览比例。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在解决因预览分辨率过高造成的终端功耗大的问题的基础上,通过将预览分辨率与屏幕分辨率的垂直像素数之比,以及预览分辨率与屏幕分辨率的水平像素数之比中较小的一个作为预览比例,保证了调整后的初始预览分辨率仍然大于屏幕分辨率,从而使初始预览分辨率的调整,不影响预览效果。
为了保证调整预览分辨率后的预览界面不会发生形变,在本发明实施例的一个实现方式中,按照一定比例分别调整初始分辨率的垂直像素数和垂直像素数。因此,在如图1所示的实现方式的基础上,还可以实现为如图4所示的实现方式。其中,步骤104按照预览比例,将终端拍摄过程中的预览分辨率由初始分辨率调整为当前预览分辨率,可以具体实现为步骤1041至步骤1043:
1041、按照预览比例减小初始预览分辨率的垂直像素数和水平像素数。
1042、将减小后的初始预览分辨率的垂直像素数和水平像素数,设置为当前预览分辨率的垂直像素数和水平像素数。
1043、将终端拍摄过程中的预览分辨率调整为当前预览分辨率。
例如,初始预览分辨率为3264*2448,屏幕分辨率为1920*1080,将初始预览分辨率的垂直像素数3264,根据预览比例3264/1920调整,得到当前预览分辨率的垂直像素数为3264/(3264/1920)=1920;将初始预览分辨率的水平像素数2448,根据预览比例3264/1920调整,得到当前预览分辨率的水平分辨率为2448/(3264/1920)=1440,即当前预览分辨率为1920*1440。此时,可以将终端拍摄过程中的预览分辨率由3264*2448调整为1920*1440。
需要说明的是,初始预览分辨率为3264*2448,屏幕分辨率为1920*1080时,如果将预览比例确定为2448/1080,得到的当前预览分辨率的垂直像素数为1440,水平像素数为1080,可以看出,当前预览分辨率的垂直像素数1440小于屏幕分辨率的垂直像素数1920,会影响预览效果。
本发明实施例提供的设置预览分辨率的方法,将初始预览分辨率的垂直像素数和水平像素数均按照预览比例调整,分辨得到当前预览分辨率的垂直像素数和水平像素数,将终端拍摄过程中的预览分辨率调整为当前预览分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在解决因预览分辨率过高造成的终端功耗大的问题的基础上,对初始预览分辨率的垂直像素数和水平像素数按照相同比例进行调整,可以保证预览界面相对于摄像头捕捉的画面不会发生形变。
本发明实施例还提供一种设置预览分辨率的装置20,如图5所示,该装置20用于执行如图1至图4所示的任意一种方法流程,该装置20包括:
获取模块21,设置为获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,初始预览分辨率与终端的摄像头分辨率相同。
确定模块22,设置为当获取模块21获取的初始预览分辨率大于获取模块21获取的屏幕分辨率时,根据初始预览分辨率与屏幕分辨率的垂直像素数之比,以及初始预览分辨率与屏幕分辨率的水平像素数之比确定预览比例。
调整模块23,设置为按照确定模块22确定的预览比例,将终端拍摄过程中的预览分辨率由获取模块21获取的初始分辨率调整为当前预览分辨率,当前预览分辨率小于初始预览分辨率。
在本发明实施例的一个实现方式中,装置20还包括:
判断模块24,设置为判断获取模块21获取的初始预览分辨率的垂直像素数是否大于获取模块21获取的屏幕分辨率的垂直像素数;以及当初始预览分辨率的垂直像素数大于屏幕分辨率的垂直像素数时,判断初始预览分辨率的水平像素数是否大于屏幕分辨率的水平像素数。
确定模块22,还设置为当判断模块24确定初始预览分辨率的水平像素数大于屏幕分辨率的水平像素数时,确定初始预览分辨率大于屏幕分辨率。
在本发明实施例的一个实现方式中,确定模块22,具体设置为当垂直像素数之比大于水平像素数之比时,将水平像素数之比确定为预览比例;当垂直像素数之比小于或等于水平像素数之比时,则将垂直像素数之比确定为预览比例。
在本发明实施例的一个实现方式中,调整模块23,具体设置为按照预览比例减小初始预览分辨率的垂直像素数和水平像素数;将减小后的初始预览分辨率的垂直像素数和水平像素数,设置为当前预览分辨率的垂直像素数和水平像素数;将终端拍摄过程中的预览分辨率调整为当前预览分辨率。
确定模块22,还设置为当初始分辨率小于或等于屏幕分辨率时,将初始分辨率设置为当前预览分辨率。
本发明实施例提供的设置预览分辨率的装置,如果获取的初始预览分辨率大于屏幕分辨率,则根据初始预览分辨率和屏幕分辨率的垂直像素数之比,以及二者的水平像素数之比确定预览比例,按照预览比例将终端拍摄过程中的预览分辨率由初始预览分辨率调整为当前预览分辨率;否则,仍然使用初始预览分辨率作为终端拍摄过程中的预览分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在初始预览分辨率大于屏幕分辨率时,可以根据初始预览分辨率与屏幕分辨率的比例关系调整终端拍摄过程中的预览比例。由于调整后得到的当前预览分辨率小于初始预览分辨率,当前预览分辨率的像素点数量也就少于初始预览分辨率的像素点数量。因此,在终端使用当前预览分辨率进行预览的过程中,终端需要实时更新的像素点数量变少,降低了终端的功耗。因此,本发明能解决因预览分辨率过高造成的终端功耗大的问题。
本发明实施例还提供一种终端,该终端用于执行如图1至图4所示的方法流程,该终端至少包括如图5所示的设置预览分辨率的装置。本发明实施例提供的终端,如果获取的初始预览分辨率大于屏幕分辨率,则根据初始预览分辨率和屏幕分辨率的垂直像素数之比,以及二者的水平像素数之比确定预览比例,按照预览比例将终端拍摄过程中的预览分辨率由初始预览分辨率调整为当前预览分辨率;否则,仍然使用初始预览分辨率作为终端拍摄过程中的预览分辨率。相比较于现有技术中将预览分辨率和摄像头分辨率设置为相同的分辨率,本发明在初始预览分辨率大于屏幕分辨率时,可以根据初始预览分辨率与屏幕分辨率的比例关系调整终端拍摄过程中的预览比例。由于调整后得到的当前预览分辨率小于初始预览分辨率,当前预览分辨率的像素点数量也就少于初始预览分辨率的像素点数量。因此,在终端使用当前预览分辨率进行预览的过程中,终端需要实时更新的像素点数量变少,降低了终端的功耗。因此,本发明能解决因预览分辨率过高造成的终端功耗大的问题。
具体而言,参考图6所示,为本发明实施例提供的一种终端30的结构示意框图。本发明实施例中的终端30可以是不同类型的电子设备,例如:智能手机、平板电脑、掌上电脑以及移动互联网设备、个人数字助理、媒体播放器、智能电视、智能手表、智能眼镜、智能手环等。如图7所示,本发明实施例中的终端30包括:至少一个处理器31,例如CPU,至少一个接收器33,至少一个存储器34,至少一个发送器35,至少一个通信总线32。其中,所述通信总线32用于实现这些组件之间的连接通信。其中,所述接收器33和所述发送器35可以是有线发送端口,也可以为无线设备,例如包括天线装置,用于与其他设备进行数据通信。所述存储器34可以是高速RAM存储器,也可以是非不稳定的存储器(non-volatile memory),例如至少一个磁盘存储器。
所述处理器31可执行所述终端30的操作系统以及安装的各类应用程序、程序代码等,例如,上述的各个模块,包括所述获取模块21、所述确定模块22等。
所述存储器34中存储有程序代码,且所述处理器31可通过通信总线32,调用所述存储器34中存储的程序代码以执行相关的功能。例如,图5中所述的各个模块(例如,所述获取模块21、所述确定模块22等)是存储在所述存储器34中的程序代码,并由所述处理器31所执行,从而实现所述各个模块的功能以实现设置预览分辨率的方法。
在本发明的一个实施例中,所述存储器34存储多个指令,所述多个指令被所述处理器31所执行以实现设置预览分辨率的方法。具体而言,所述处理器31对所述多个指令的执行包括:获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,所述初始预览分辨率与终端的摄像头分辨率相同;如果所述初始预览分辨率大于所述屏幕分辨率,则根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例;按照所述预览比例,将所述终端拍摄过程中的预览分辨率由所述初始分辨率调整为当前预览分辨率,所述当前预览分辨率小于所述初始预览分辨率。
在进一步的实施例中,在所述获取终端的初始预览分辨率和屏幕分辨率之后,所述处理器31进一步:判断所述初始预览分辨率的垂直像素数是否大于所述屏幕分辨率的垂直像素数;如果所述初始预览分辨率的垂直像素数大于所述屏幕分辨率的垂直像素数,则判断所述初始预览分辨率的水平像素数是否大于所述屏幕分辨率的水平像素数;如果所述初始预览分辨率的水平像素数大于所述屏幕分辨率的水平像素数,则确定所述初始预览分辨率大于所述屏幕分辨率。
在进一步的实施例中,所述根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例,包括:如果所述垂直像素数之比大于所述水平像素数之比,则将所述水平像素数之比确定为所述预览比例;如果所述垂直像素数之比小于或等于所述水平像素数之比,则将所述垂直像素数之比确定为所述预览比例。
在进一步的实施例中,所述按照所述预览比例将所述终端的初始预览分辨率调整为当前预览分辨率,包括:按照所述预览比例减小所述初始预览分辨率的垂直像素数和水平像素数;将减小后的初始预览分辨率的垂直像素数和水平像素数,设置为所述当前预览分辨率的垂直像素数和水平像素数;将所述终端拍摄过程中的预览分辨率调整为当前预览分辨率。
在进一步的实施例中,在所述获取终端的初始预览分辨率和屏幕分辨率之后,如果所述初始分辨率小于或等于所述屏幕分辨率,所述处理器31将所述初始分辨率设置为当前预览分辨率。
具体地,所述处理器31对上述指令的具体实现方法可参考图1-4对应实施例中相关步骤的描述,在此不赘述。
本说明书中的各个实施例均采用递进的方式描述,各个实施例之间相同相似的部分互相参见即可,每个实施例重点说明的都是与其他实施例的不同之处。尤其,对于装置实施例而言,由于其基本相似于方法实施例,所以描述得比较简单,相关之处参见方法实施例的部分说明即可。
本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,是可以通过计算机程序来指令相关的硬件来完成,所述的程序可存储于计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。其中,所述的存储介质可为磁碟、光盘、只读存储记忆体(英文:Read-Only Memory,简称:ROM)或随机存储记忆体(英文:Random Access Memory,简称:RAM)等。
以上所述,仅为本发明的具体实施方式,但本发明的保护范围并不局限于此,任何熟悉本技术领域的技术人员在本发明揭露的技术范围内,可轻易想到的变化或替换,都应涵盖在本发明的保护范围之内。因此,本发明的保护范围应该以权利要求的保护范围为准。

Claims (10)

  1. 一种设置预览分辨率的方法,其特征在于,所述方法包括:
    获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,所述初始预览分辨率与终端的摄像头分辨率相同;
    如果所述初始预览分辨率大于所述屏幕分辨率,则根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例;
    按照所述预览比例,将所述终端拍摄过程中的预览分辨率由所述初始分辨率调整为当前预览分辨率,所述当前预览分辨率小于所述初始预览分辨率。
  2. 根据权利要求1所述的方法,其特征在于,在所述获取终端的初始预览分辨率和屏幕分辨率之后,还包括:
    判断所述初始预览分辨率的垂直像素数是否大于所述屏幕分辨率的垂直像素数;
    如果所述初始预览分辨率的垂直像素数大于所述屏幕分辨率的垂直像素数,则判断所述初始预览分辨率的水平像素数是否大于所述屏幕分辨率的水平像素数;
    如果所述初始预览分辨率的水平像素数大于所述屏幕分辨率的水平像素数,则确定所述初始预览分辨率大于所述屏幕分辨率。
  3. 根据权利要求1所述的方法,其特征在于,所述根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例,包括:
    如果所述垂直像素数之比大于所述水平像素数之比,则将所述水平像素数之比确定为所述预览比例;
    如果所述垂直像素数之比小于或等于所述水平像素数之比,则将所述垂直像素数之比确定为所述预览比例。
  4. 根据权利要求1所述的方法,其特征在于,所述按照所述预览比例将所述终端的初始预览分辨率调整为当前预览分辨率,包括:
    按照所述预览比例减小所述初始预览分辨率的垂直像素数和水平像素数;
    将减小后的初始预览分辨率的垂直像素数和水平像素数,设置为所述当前预览分辨率的垂直像素数和水平像素数;
    将所述终端拍摄过程中的预览分辨率调整为当前预览分辨率。
  5. 根据权利要求1至4中任意一项所述的方法,其特征在于,在所述获取终端的初始预览分辨率和屏幕分辨率之后,还包括:
    如果所述初始分辨率小于或等于所述屏幕分辨率,则将所述初始分辨率设置为当前预览分辨率。
  6. 一种设置预览分辨率的装置,其特征在于,所述装置包括:
    获取模块,设置为获取终端的屏幕分辨率和终端拍摄过程中的初始预览分辨率,所述初始预览分辨率与终端的摄像头分辨率相同;
    确定模块,设置为当所述获取模块获取的初始预览分辨率大于所述获取模块获取的屏幕分辨率时,根据所述初始预览分辨率与所述屏幕分辨率的垂直像素数之比,以及所述初始预览分辨率与所述屏幕分辨率的水平像素数之比确定预览比例;
    调整模块,设置为按照所述确定模块确定的预览比例,将所述终端拍摄过程中的预览分辨率由所述获取模块获取的初始分辨率调整为当前预览分辨率,所述当前预览分辨率小于所述初始预览分辨率。
  7. 根据权利要求6所述的装置,其特征在于,所述装置还包括:
    判断模块,设置为判断所述获取模块获取的初始预览分辨率的垂直像素数是否大于所述获取模块获取的屏幕分辨率的垂直像素数;以及当所述初始预览分辨率的垂直像素数大于所述屏幕分辨率的垂直像素数时,判断所述初始预览分辨率的水平像素数是否大于所述屏幕分辨率的水平像素数;
    所述确定模块,还设置为当所述判断模块确定初始预览分辨率的水平像素数大于所述屏幕分辨率的水平像素数时,确定所述初始预览分辨率大于所述屏幕分辨率。
  8. 根据权利要求6所述的装置,其特征在于,所述确定模块,具体设置为当所述垂直像素数之比大于所述水平像素数之比时,将所述水平像素数之比确定为所述预览比例;
    当所述垂直像素数之比小于或等于所述水平像素数之比时,则将所述垂直像素数之比确定为所述预览比例。
  9. 根据权利要求6所述的装置,其特征在于,所述调整模块,具体设置为按照所述预览比例减小所述初始预览分辨率的垂直像素数和水平像素数;将减小后的初始预览分辨率的垂直像素数和水平像素数,设置为所述当前预览分辨率的垂直像素数和水平像素数;将所述终端拍摄过程中的预览分辨率调整为当前预览分辨率;
    所述确定模块,还设置为当所述初始分辨率小于或等于所述屏幕分辨率时,将所述初始分辨率设置为当前预览分辨率。
  10. 一种终端,其特征在于,所述终端至少包括如权利要求6至9中任意一项所述的设置预览分辨率的装置。
PCT/CN2016/100682 2016-08-31 2016-09-28 一种设置预览分辨率的方法、装置及终端 Ceased WO2018040174A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201610790518.9A CN106293589B (zh) 2016-08-31 2016-08-31 一种设置预览分辨率的方法、装置及终端
CN201610790518.9 2016-08-31

Publications (1)

Publication Number Publication Date
WO2018040174A1 true WO2018040174A1 (zh) 2018-03-08

Family

ID=57674113

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2016/100682 Ceased WO2018040174A1 (zh) 2016-08-31 2016-09-28 一种设置预览分辨率的方法、装置及终端

Country Status (2)

Country Link
CN (1) CN106293589B (zh)
WO (1) WO2018040174A1 (zh)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN114390199A (zh) * 2018-10-15 2022-04-22 华为技术有限公司 一种拍摄方法及电子设备
CN110636354A (zh) * 2019-06-10 2019-12-31 青岛海信电器股份有限公司 一种显示设备
CN110765799B (zh) * 2019-10-21 2023-05-02 高新兴科技集团股份有限公司 客户端扫码识别方法、装置、设备及存储介质
CN112019738B (zh) * 2020-07-31 2022-03-01 广东小天才科技有限公司 一种拍照方法及终端设备
CN112055244B (zh) * 2020-09-04 2022-06-21 维沃移动通信有限公司 图像获取方法、装置、服务器和电子设备
CN112153293A (zh) * 2020-09-28 2020-12-29 广东小天才科技有限公司 一种图像数据的显示方法及电子设备、存储介质
CN114422694B (zh) * 2022-01-18 2024-03-26 杭州逗酷软件科技有限公司 预览分辨率适配方法和装置、电子设备

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100315543A1 (en) * 2009-06-12 2010-12-16 Samsung Electronics Co., Ltd. Method for converting a resolution and image sensor thereof
CN103139473A (zh) * 2011-11-28 2013-06-05 三星电子株式会社 消除快门迟滞的方法、照相机模块和具有其的移动设备
CN103546689A (zh) * 2013-10-11 2014-01-29 Tcl集团股份有限公司 android系统外接摄像头的分辨率获取方法及装置

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103019537B (zh) * 2012-11-19 2016-04-13 广东欧珀移动通信有限公司 一种图像预览方法及装置
KR102182160B1 (ko) * 2013-07-16 2020-11-24 엘지전자 주식회사 휴대 단말기 및 그 제어 방법

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20100315543A1 (en) * 2009-06-12 2010-12-16 Samsung Electronics Co., Ltd. Method for converting a resolution and image sensor thereof
CN103139473A (zh) * 2011-11-28 2013-06-05 三星电子株式会社 消除快门迟滞的方法、照相机模块和具有其的移动设备
CN103546689A (zh) * 2013-10-11 2014-01-29 Tcl集团股份有限公司 android系统外接摄像头的分辨率获取方法及装置

Also Published As

Publication number Publication date
CN106293589B (zh) 2019-04-12
CN106293589A (zh) 2017-01-04

Similar Documents

Publication Publication Date Title
WO2018040174A1 (zh) 一种设置预览分辨率的方法、装置及终端
WO2010038970A2 (en) Method and system for managing an imaging device by an electronic device located remotely to the imaging device
WO2011059250A2 (en) Mobile terminal, display apparatus and control method thereof
WO2015026149A1 (en) System, apparatus, and method for sharing electronic device
WO2014157889A1 (en) Method and apparatus for improving quality of experience in sharing screen among devices, and recording medium thereof
WO2013118988A1 (en) Method and apparatus for interoperably performing services and system supporting the same
WO2015120673A1 (zh) 利用眼球跟踪技术控制拍照对焦的方法、系统及拍照设备
WO2014142557A1 (en) Electronic device and method for processing image
WO2017138728A1 (en) Method and apparatus for creating, streaming, and rendering hdr images
WO2014021627A1 (en) Apparatus and method for providing n-screen service in broadcast system
WO2018053909A1 (zh) 拍摄方法、拍摄装置和终端
WO2018053908A1 (zh) 一种双摄像头拍摄方法、系统及终端
WO2017128853A1 (zh) 摄制视频的处理方法、装置和设备
WO2022042753A1 (zh) 拍摄方法、装置及电子设备
WO2018090456A1 (zh) 一种基于终端流量的控制方法及装置
WO2021128545A1 (zh) 图片显示方法、装置、存储介质及智能设备
WO2014035171A1 (ko) 전자장치에서 영상통화중 파일 전송 방법 및 장치
JP7798452B2 (ja) 撮影モード決定方法、装置、電子機器、及び記憶媒体
WO2020116740A1 (ko) 실시간 방송 편집 시스템 및 편집 방법
WO2012144815A2 (en) Apparatus and method for adjusting resolution of application in wireless terminal
WO2024022391A1 (zh) 多媒体数据传输方法、装置、电子设备及存储介质
JP7594126B2 (ja) 画像処理方法、装置、電子機器、及び媒体
WO2012144816A2 (en) Apparatus and method of selecting resource of application in wireless terminal
WO2013113192A1 (zh) 图像传输的方法及系统
WO2012091526A2 (ko) 카메라를 구비한 휴대용 영상 통화 장치 및 그 방법

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: 16914737

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: 16914737

Country of ref document: EP

Kind code of ref document: A1