Movatterモバイル変換


[0]ホーム

URL:


CN108024079A - Record screen method, apparatus, terminal and storage medium - Google Patents

Record screen method, apparatus, terminal and storage medium
Download PDF

Info

Publication number
CN108024079A
CN108024079ACN201711226853.7ACN201711226853ACN108024079ACN 108024079 ACN108024079 ACN 108024079ACN 201711226853 ACN201711226853 ACN 201711226853ACN 108024079 ACN108024079 ACN 108024079A
Authority
CN
China
Prior art keywords
screen recording
screen
target storage
terminal
parameter
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
CN201711226853.7A
Other languages
Chinese (zh)
Other versions
CN108024079B (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.)
Guangdong Oppo Mobile Telecommunications Corp Ltd
Original Assignee
Guangdong Oppo Mobile Telecommunications Corp 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 Guangdong Oppo Mobile Telecommunications Corp LtdfiledCriticalGuangdong Oppo Mobile Telecommunications Corp Ltd
Priority to CN201711226853.7ApriorityCriticalpatent/CN108024079B/en
Publication of CN108024079ApublicationCriticalpatent/CN108024079A/en
Application grantedgrantedCritical
Publication of CN108024079BpublicationCriticalpatent/CN108024079B/en
Activelegal-statusCriticalCurrent
Anticipated expirationlegal-statusCritical

Links

Classifications

Landscapes

Abstract

Translated fromChinese

本申请实施例公开了一种录屏方法、装置、终端及存储介质,属于计算机技术领域,所述方法包括:根据第一录屏参数进行录屏,监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录屏数据;当所述目标存储余量不大于预设阈值时,获取第二录屏参数;根据所述第二录屏参数进行录屏;其中,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量。本申请实施例通过监控目标存储空间容量,在容量不足时采用相比于第一录屏参数节省存储空间的第二录屏参数录屏,延长了终端录屏的时长,提高了终端进行长时间屏幕录制的成功率。

The embodiment of the present application discloses a screen recording method, device, terminal, and storage medium, which belong to the field of computer technology. The method includes: recording the screen according to the first screen recording parameters, monitoring the target storage margin, and the target storage margin The amount is the remaining capacity of the target storage space, and the target storage space is used to store screen recording data; when the target storage margin is not greater than the preset threshold, obtain the second screen recording parameter; according to the second screen recording parameter Perform screen recording; wherein, the amount of screen recording data generated according to the second screen recording parameter per unit time is smaller than the amount of screen recording data generated according to the first screen recording parameter. In the embodiment of the present application, by monitoring the capacity of the target storage space, when the capacity is insufficient, the second screen recording parameter saves storage space compared with the first screen recording parameter to record the screen, which prolongs the duration of terminal screen recording and improves the long-term performance of the terminal. Screen recording success rate.

Description

Translated fromChinese
录屏方法、装置、终端及存储介质Screen recording method, device, terminal and storage medium

技术领域technical field

本申请实施例涉及计算机技术领域,特别涉及一种录屏方法、装置、终端及存储介质。The embodiments of the present application relate to the field of computer technology, and in particular to a screen recording method, device, terminal and storage medium.

背景技术Background technique

录屏,也称为屏幕录像或屏幕录制,是指采集屏幕的整个区域或部分指定区域的图像数据,将图像数据编码得到视频文件的技术。Screen recording, also known as screen recording or screen recording, refers to the technology of collecting image data of the entire area or a part of the designated area of the screen, and encoding the image data to obtain a video file.

相关技术中,当用户需要录屏时,用户可以开启终端的录屏功能。终端在录屏功能开启后,将持续录制屏幕中的显示画面,并将录制画面存储在终端中。In related technologies, when a user needs to record a screen, the user may enable the screen recording function of the terminal. After the screen recording function is turned on, the terminal will continuously record the displayed images on the screen and store the recorded images in the terminal.

由于录制画面将持续写入到终端的存储空间内,当存储空间的容量不足时,容易导致录屏失败。Since the recorded screen will continue to be written into the storage space of the terminal, when the capacity of the storage space is insufficient, it is easy to cause screen recording failure.

发明内容Contents of the invention

本申请实施例提供了一种录屏方法、装置、终端及存储介质,可以解决由于录制画面将持续写入到终端的存储空间内,当存储空间的容量不足时,容易导致录屏失败的问题。所述技术方案如下:The embodiment of the present application provides a screen recording method, device, terminal and storage medium, which can solve the problem that the recording screen will fail when the capacity of the storage space is insufficient because the recording screen will be continuously written into the storage space of the terminal . Described technical scheme is as follows:

根据本申请的第一方面,提供了一种录屏方法,所述方法包括:According to the first aspect of the present application, a screen recording method is provided, the method comprising:

根据第一录屏参数进行录屏;Record the screen according to the first screen recording parameters;

监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录屏数据;Monitoring the target storage margin, the target storage margin is the remaining capacity of the target storage space, and the target storage space is used to store screen recording data;

当所述目标存储余量不大于预设阈值时,获取第二录屏参数;When the target storage margin is not greater than a preset threshold, acquire a second screen recording parameter;

根据所述第二录屏参数进行录屏;performing screen recording according to the second screen recording parameters;

其中,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量。Wherein, the amount of screen recording data generated according to the second screen recording parameter per unit time is smaller than the amount of screen recording data generated according to the first screen recording parameter.

根据本申请的第二方面,提供了一种录屏装置,所述装置包括:According to a second aspect of the present application, a screen recording device is provided, the device comprising:

第一录屏模块,被配置为根据第一录屏参数进行录屏;The first screen recording module is configured to perform screen recording according to the first screen recording parameters;

余量监控模块,被配置为监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录幕数据;The residual monitoring module is configured to monitor the target storage residual, the target storage residual is the remaining capacity of the target storage space, and the target storage space is used to store recording data;

参数获取模块,被配置为当所述目标存储余量不大于预设阈值时,获取第二录屏参数,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量;The parameter acquisition module is configured to acquire a second screen recording parameter when the target storage margin is not greater than a preset threshold, and the amount of screen recording data generated according to the second screen recording parameter within a unit time is less than according to the The amount of screen recording data generated by the first screen recording parameter;

第二录屏模块,被配置为根据所述第二录屏参数录屏。The second screen recording module is configured to record a screen according to the second screen recording parameters.

根据本申请的第三方面,提供了一种终端,所述终端包括处理器和存储器,所述存储器中存储有至少一条指令,所述指令由所述处理器加载并执行以实现如第一方面所述的录屏方法。According to a third aspect of the present application, a terminal is provided, the terminal includes a processor and a memory, at least one instruction is stored in the memory, and the instruction is loaded and executed by the processor to implement the first aspect The screen recording method described above.

根据本申请的第四方面,提供了一种计算机可读存储介质,所述存储介质中存储有至少一条指令,所述指令由处理器加载并执行以实现如第一方面所述的录屏方法。According to a fourth aspect of the present application, a computer-readable storage medium is provided, wherein at least one instruction is stored in the storage medium, and the instruction is loaded and executed by a processor to implement the screen recording method as described in the first aspect .

本申请实施例提供的技术方案带来的有益效果是:The beneficial effects brought by the technical solutions provided by the embodiments of the present application are:

由于本申请实施例的方案在执行时,根据第一参数录屏,对用于存储录屏数据的存储空间的剩余容量进行实时监控,并对该目标存储余量进行判断,当该目标存储余量不大于预设阈值时,终端将获取该预设阈值对应的第二录屏参数,并在启用该第二录屏参数录屏,其中,启用第二录屏参数前的终端根据第一录屏参数录屏,在单位时间内根据第二录屏参数产生的录屏数据量不大于根据第一录屏参数产生的录屏数据量。可见,根据本申请实施例录屏方法能够在目标存储余量不足的情况下,自动启用在单位时间内产生录屏数据量较小的第二录屏参数来录屏,延长了终端录屏的时长,提高了终端进行长时间屏幕录制的成功率。When the solution of the embodiment of the present application is executed, the remaining capacity of the storage space used to store the screen recording data is monitored in real time according to the first parameter of screen recording, and the remaining capacity of the target storage is judged. When the amount is not greater than the preset threshold, the terminal will obtain the second screen recording parameter corresponding to the preset threshold, and record the screen after enabling the second screen recording parameter, wherein, the terminal before enabling the second screen recording parameter is based on the first recording parameter For screen recording with screen parameters, the amount of screen recording data generated according to the second screen recording parameter within a unit time is not greater than the amount of screen recording data generated according to the first screen recording parameter. It can be seen that according to the embodiment of the present application, the screen recording method can automatically enable the second screen recording parameter that generates a small amount of screen recording data per unit time to record the screen when the target storage margin is insufficient, which prolongs the terminal screen recording time. Duration, which improves the success rate of terminal for long-term screen recording.

附图说明Description of drawings

为了更清楚地说明本申请实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings that need to be used in the description of the embodiments will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application. For those skilled in the art, other drawings can also be obtained based on these drawings without creative effort.

图1是本申请一个示例性实施例提供的录屏方法的流程图;FIG. 1 is a flowchart of a screen recording method provided in an exemplary embodiment of the present application;

图2是本申请另一个示例性实施例提供的录屏方法流程图;FIG. 2 is a flowchart of a screen recording method provided by another exemplary embodiment of the present application;

图3是基于图2所示的录屏方法所提供的录屏的界面图;Fig. 3 is the interface diagram of the screen recording provided based on the screen recording method shown in Fig. 2;

图4是基于图2所示的录屏方法提供的部分步骤的流程图;Fig. 4 is a flowchart of some steps provided based on the screen recording method shown in Fig. 2;

图5是基于图2所示的录屏方法提供的一种展示提醒信息的界面图;FIG. 5 is an interface diagram showing reminder information provided based on the screen recording method shown in FIG. 2;

图6是基于图2所示的录屏方法提供的一种界面示意图;Fig. 6 is a schematic diagram of an interface provided based on the screen recording method shown in Fig. 2;

图7是本申请一个示例性实施例提供的录屏装置的结构框图;Fig. 7 is a structural block diagram of a screen recording device provided by an exemplary embodiment of the present application;

图8是本申请一个示例性实施例提供的终端的结构框图。Fig. 8 is a structural block diagram of a terminal provided by an exemplary embodiment of the present application.

具体实施方式Detailed ways

为使本申请的目的、技术方案和优点更加清楚,下面将结合附图对本申请实施方式作进一步地详细描述。In order to make the purpose, technical solution and advantages of the present application clearer, the implementation manners of the present application will be further described in detail below in conjunction with the accompanying drawings.

为了本申请实施例所示方案易于理解,下面将对本申请实施例中出现的若干名词进行解释。In order to make the solutions shown in the embodiments of the present application easy to understand, some terms appearing in the embodiments of the present application will be explained below.

目标存储余量:是指目标存储空间的剩余容量,可以指存储介质的数据存储容量,是具有确定单位的常量。例如,1.34GByte、529MByte或800Kbyte等数值。Target storage margin: refers to the remaining capacity of the target storage space, may refer to the data storage capacity of the storage medium, and is a constant with a definite unit. For example, values such as 1.34GByte, 529MByte, or 800Kbyte.

目标存储空间:是用于存储录屏所产生的数据的存储空间。在本申请实施例提供的方案中,终端在录屏的过程中将采集终端屏幕中显示的画面,即在录屏时生成用于存储该采集的画面的数据,用于存储该数据的存储空间即为目标存储空间。Target storage space: It is the storage space used to store the data generated by the screen recording. In the solution provided by the embodiment of this application, the terminal will collect the picture displayed on the terminal screen during the screen recording process, that is, generate the data used to store the captured picture during the screen recording, and use the storage space for storing the data That is the target storage space.

可选地,该目标存储空间可以是进行屏幕录制的终端上的存储介质的存储空间,包括但不限于该终端的内存储器和外存储器。Optionally, the target storage space may be a storage space of a storage medium on a terminal performing screen recording, including but not limited to an internal memory and an external memory of the terminal.

可选地,该目标存储空间也可以是与进行屏幕录制的终端相连的若干个存储设备提供的存储空间,该存储设备包括但不限于其它终端、局域网主机、工作站或存储服务器等。Optionally, the target storage space may also be a storage space provided by several storage devices connected to the terminal performing screen recording, including but not limited to other terminals, LAN hosts, workstations or storage servers.

第一录屏参数:可以包括分辨率、编码格式、码率和帧率中的至少一种。该参数可以是分辨率、编码格式、码率或帧率中的一种参数,也可以是包括分辨率、编码格式、码率和帧率中的至少两种的参数集合。该参数用于在终端录屏时使用。可选地,该参数可以是终端内置的用户不可更改的参数,也可以是终端提供给用户进行设置的参数。当参数是不可更改的参数时,该参数的数据类型和数值均不可被更改。The first screen recording parameter: may include at least one of resolution, encoding format, bit rate and frame rate. The parameter may be one of resolution, coding format, code rate or frame rate, or a parameter set including at least two of resolution, coding format, code rate and frame rate. This parameter is used for terminal screen recording. Optionally, the parameter may be a parameter built into the terminal that cannot be changed by the user, or a parameter provided by the terminal for the user to set. When the parameter is an unchangeable parameter, neither the data type nor the value of the parameter can be changed.

第二录屏参数:类似于第一录屏参数,同样可以分辨率、编码格式、码率和帧率中的至少一种。该参数可以是分辨率、编码格式、码率或帧率中的一种参数,也可以是包括分辨率、编码格式、码率和帧率中的至少两种的参数集合。也用于在终端进行屏幕录制时使用。相比于第一录屏参数,终端在单位时间内根据第二录屏参数录屏所产生的数据量小于根据第一录屏参数录屏所产生的数据量。可选地,第二录屏参数可以是终端内置的用户不可更改的参数,也可以是终端提供给用户进行自主设置的参数。The second screen recording parameter: similar to the first screen recording parameter, it can also be at least one of resolution, encoding format, bit rate and frame rate. The parameter may be one of resolution, coding format, code rate or frame rate, or a parameter set including at least two of resolution, coding format, code rate and frame rate. Also used for screen recording in terminal. Compared with the first screen recording parameter, the amount of data generated by the terminal according to the second screen recording parameter per unit time is smaller than the data amount generated according to the first screen recording parameter. Optionally, the second screen recording parameter may be a parameter built into the terminal that cannot be changed by the user, or a parameter provided by the terminal for the user to set independently.

信息输出组件:包括屏幕、扬声器、振动组件和提示灯等组件中的至少一种,可以令信息通过视觉信息、听觉信息或者体感信息被用户感知。Information output component: including at least one of components such as a screen, a speaker, a vibration component, and a reminder light, which can make information perceived by the user through visual information, auditory information, or somatosensory information.

示例性地,本申请实施例所示的录屏方法,可以应用在终端中,该终端具备显示屏且具备录屏的功能。终端可以包括手机、平板电脑、膝上型电脑、台式电脑、电脑一体机、服务器、工作站、电视、机顶盒、智能眼镜、智能手表、数码相机、MP4播放终端、MP5播放终端、学习机、点读机、电纸书、电子词典、车载终端、虚拟现实(Virtual Reality,VR)播放终端或增强现实(AugmentedReality,AR)播放终端等。Exemplarily, the screen recording method shown in the embodiment of the present application can be applied in a terminal, and the terminal has a display screen and a screen recording function. Terminals can include mobile phones, tablet computers, laptop computers, desktop computers, all-in-one computers, servers, workstations, TVs, set-top boxes, smart glasses, smart watches, digital cameras, MP4 playback terminals, MP5 playback terminals, learning machines, point-to-read computer, electronic paper book, electronic dictionary, vehicle-mounted terminal, virtual reality (Virtual Reality, VR) playback terminal or augmented reality (Augmented Reality, AR) playback terminal, etc.

可选地,终端实现屏幕录制的功能至少可以通过具备录屏进程的操作系统、具备录屏功能的应用程序或者能够运行录屏进程的应用程序中至少一种来实现。Optionally, the screen recording function of the terminal can be realized by at least one of an operating system with a screen recording process, an application program with a screen recording function, or an application program capable of running a screen recording process.

(1)当终端是通过具备录屏进程的操作系统来实现录屏功能时,录屏进程可以是操作系统中自带的系统进程,该系统进程可以在终端的通知栏或者屏幕悬浮窗中显示相应的录屏控件。用户通过控制该录屏控件,来控制屏幕录制进行开始、暂停以及结束等操作。(1) When the terminal realizes the screen recording function through an operating system with a screen recording process, the screen recording process can be a system process that comes with the operating system, and the system process can be displayed in the notification bar of the terminal or the floating window on the screen Corresponding screen recording controls. By controlling the screen recording control, the user controls the screen recording to perform operations such as start, pause, and end.

(2)当终端是通过具备录屏功能的应用程序来实现屏幕录制功能时,该应用程序既可以是在用户的操作下安装的第三方应用程序,也可以是终端出厂时自带的应用程序。当该应用程序运行时,其提供有屏幕录制功能,使得终端能够录屏。(2) When the terminal realizes the screen recording function through an application program with the screen recording function, the application program can be a third-party application program installed under the operation of the user, or an application program that comes with the terminal when it leaves the factory . When the application is running, it provides a screen recording function, enabling the terminal to record the screen.

(3)当终端是通过能够运行录屏进程的应用程序来实现录屏功能时,该录屏进程可以通过一个插件或者控件来执行。例如,一个应用程序可以原本不具备录屏功能,但是其可以运行录屏插件或者录屏控件。当该应用程序安装了该录屏插件或者录屏控件后,该终端在运行该录屏插件或者录屏控件时即可录屏。例如,终端中运行有应用程序A,应用程序A原本不具有录屏的功能,当终端下载了录屏进程a后,且当录屏进程a被录屏应用A运行时,终端能够录屏。(3) When the terminal realizes the screen recording function through an application program capable of running a screen recording process, the screen recording process can be executed through a plug-in or a control. For example, an application may not originally have a screen recording function, but it may run a screen recording plug-in or a screen recording control. After the screen recording plug-in or screen recording control is installed in the application program, the terminal can record the screen when running the screen recording plug-in or screen recording control. For example, there is an application program A running in the terminal, and the application program A does not have the screen recording function originally. After the terminal downloads the screen recording process a, and when the screen recording process a is run by the screen recording application A, the terminal can record the screen.

请参考图1,其是本申请一个示例性实施例提供的录屏方法的流程图。该录屏方法可以应用在上述所示的终端中。在图1中,录屏方法包括:Please refer to FIG. 1 , which is a flowchart of a screen recording method provided by an exemplary embodiment of the present application. The screen recording method can be applied to the terminals shown above. In Figure 1, the screen recording methods include:

步骤110,根据第一录屏参数进行录屏。Step 110, perform screen recording according to the first screen recording parameter.

在本申请实施例中,终端具备录屏功能,能够根据第一录屏参数进行录屏。其中,终端在录屏时,将先获取到显示在屏幕中的各个单位时间内的画面。其中,单位时间内的画面可以称为一帧画面。当终端获取到各帧画面后,终端可以将各帧画面进行编码,得到对应的录屏文件。该录屏文件是能够被视频播放器播放的文件。In the embodiment of the present application, the terminal has a screen recording function, and can perform screen recording according to the first screen recording parameter. Wherein, when the terminal is recording the screen, it will first obtain the screens displayed on the screen in each unit of time. Wherein, a picture in a unit time may be referred to as a frame of picture. After the terminal obtains each frame of picture, the terminal can encode each frame of picture to obtain a corresponding screen recording file. The screen recording file is a file that can be played by a video player.

步骤120,监控目标存储余量,目标存储余量是目标存储空间的剩余容量,目标存储空间用于存储录屏数据。Step 120, monitor the remaining capacity of the target storage, where the target storage capacity is the remaining capacity of the target storage space, and the target storage space is used to store screen recording data.

以终端是手机为例,当手机根据第一录屏参数录屏时,手机将监控目标存储余量。可选地,当目标存储空间是手机中指定的存储空间时,终端将调用相关函数确定指定的存储空间的剩余容量。Taking the terminal as a mobile phone as an example, when the mobile phone records the screen according to the first screen recording parameter, the mobile phone will monitor the target storage balance. Optionally, when the target storage space is the specified storage space in the mobile phone, the terminal will call related functions to determine the remaining capacity of the specified storage space.

例如,终端中的搭载的操作系统是安卓(Android)操作系统,当目标存储空间是存储卡时,终端可以调用getAvailaleSize()函数来确定存储卡中剩余的存储容量。当目标存储空间是手机的内部存储时,终端可以通过读取配置文件(如“/proc/meminfo”)中的数据来确定内部存储中剩余的存储容量。For example, the operating system installed in the terminal is an Android operating system, and when the target storage space is a memory card, the terminal can call the getAvailaleSize() function to determine the remaining storage capacity in the memory card. When the target storage space is the internal storage of the mobile phone, the terminal can determine the remaining storage capacity in the internal storage by reading the data in the configuration file (such as "/proc/meminfo").

再例如,终端中的搭载的操作系统是iOS操作系统,当目标存储空间是外部存储时,终端可以调用getAvailableDiskSize()函数来确定外部存储的剩余容量。当目标存储空间是手机的内部存储时,终端可以通过调用getAvailableMemorySize()函数来确定内部存储的剩余容量。For another example, the operating system installed in the terminal is an iOS operating system, and when the target storage space is an external storage, the terminal may call a getAvailableDiskSize() function to determine the remaining capacity of the external storage. When the target storage space is the internal storage of the mobile phone, the terminal can determine the remaining capacity of the internal storage by calling the getAvailableMemorySize() function.

可选地,若目标存储空间包括至少两个不同存储空间的存储空间时,终端将对获取的至少两个存储空间各自的剩余容量求和,将该和值确定为目标存储余量。Optionally, if the target storage space includes storage spaces of at least two different storage spaces, the terminal sums the obtained remaining capacities of the at least two storage spaces, and determines the sum value as the target storage remaining amount.

其中,终端在屏录时产生的录屏数据可以存储在临时文件中,该临时文件在终端录屏时暂时存储在目标存储空间中。当录屏过程结束后,终端将处理该临时文件,得到可以被播放器播放的录屏文件。该录屏文件中存储有终端录屏产生的多媒体数据。可选地,该多媒体数据可以是视频数据、音频数据和文本数据等中至少一种。例如,临时文件可以是文件后缀名为.avw的文件,该文件被终端处理后可以转变为后缀名为.avi的录屏文件。Wherein, the screen recording data generated by the terminal during screen recording may be stored in a temporary file, and the temporary file is temporarily stored in the target storage space during the terminal screen recording. When the screen recording process ends, the terminal will process the temporary file to obtain a screen recording file that can be played by the player. The screen recording file stores multimedia data generated by terminal screen recording. Optionally, the multimedia data may be at least one of video data, audio data, and text data. For example, the temporary file may be a file with a suffix of .avw, which can be converted into a screen recording file with a suffix of .avi after being processed by the terminal.

步骤130,当目标存储余量不大于预设阈值时,获取第二录屏参数。Step 130, when the target storage remaining amount is not greater than the preset threshold, acquire a second screen recording parameter.

在本申请实施例中,终端在确定出目标存储余量小于或者等于预设阈值时,获取第二录屏参数。需要说明的是,终端可以通过周期性的方式监控目标存储余量。因此,在一种可能的实现方式中,终端可能在一个监控周期中获取到目标存储余量大于预设阈值,在相邻的下一个监控周期获取到的目标存储余量小于预设阈值。在另一种可能的实现方式,终端可能直接监控到的目标存储余量等于预设阈值。在上述两种可能的实现方式中,终端都将获取到第二录屏参数。In the embodiment of the present application, when the terminal determines that the target storage remaining amount is less than or equal to the preset threshold, the terminal acquires the second screen recording parameter. It should be noted that the terminal may monitor the target storage balance in a periodic manner. Therefore, in a possible implementation manner, the terminal may acquire a target storage balance greater than a preset threshold in one monitoring period, and acquire a target storage balance smaller than a preset threshold in an adjacent next monitoring period. In another possible implementation manner, the target storage balance that may be directly monitored by the terminal is equal to a preset threshold. In the above two possible implementation manners, the terminal will obtain the second screen recording parameters.

其中,在单位时间内根据第二录屏参数产生的录屏数据量小于根据第一录屏参数产生的录屏数据量。例如,第一录屏参数包含1080p的分辨率和30fps的帧率,第二录屏参数可以是分辨率小于1080p但帧率保持30fps的参数,或者,第二录屏参数也可以是保持分辨为1080p但帧率小于30fps的参数,或者,第二录屏参数还可以是分辨率小于1080p同时帧率小于30fps的参数。需要说明的,本申请实施例并不对第一录屏参数和第二录屏参数具体包含的参数种类和数值大小进行限定。Wherein, the amount of screen recording data generated according to the second screen recording parameter per unit time is smaller than the amount of screen recording data generated according to the first screen recording parameter. For example, the first screen recording parameter includes a resolution of 1080p and a frame rate of 30fps, and the second screen recording parameter can be a parameter with a resolution lower than 1080p but a frame rate of 30fps, or the second screen recording parameter can also be a resolution of 1080p but the frame rate is less than 30fps, or, the second screen recording parameter can also be a parameter with a resolution less than 1080p and the frame rate is less than 30fps. It should be noted that the embodiment of the present application does not limit the types and values of parameters specifically included in the first screen recording parameter and the second screen recording parameter.

可选地,预设阈值可以是终端的操作系统或者具备录屏功能的应用程序设置的一个存储容量。在一些可能的实现方式中,该预设阈值可以被用户所修改。Optionally, the preset threshold may be a storage capacity set by an operating system of the terminal or an application program having a screen recording function. In some possible implementation manners, the preset threshold can be modified by the user.

步骤140,根据第二录屏参数进行录屏。Step 140, perform screen recording according to the second screen recording parameter.

在本申请实施例中,终端在获取到第二录屏参数后,将根据第二录屏参数录屏。并存储根据第二录屏参数录屏产生的录屏数据。In the embodiment of the present application, after acquiring the second screen recording parameter, the terminal will record the screen according to the second screen recording parameter. And store the screen recording data generated according to the screen recording of the second screen recording parameter.

在一种可能的实现方式中,终端根据第一录屏参数进行录屏产生的录屏数据可以和根据第二录屏参数进行录屏产生的录屏数据一同处理,处理后拼接成为一个录屏文件。该录屏文件中包含有根据第一录屏参数录制的多媒体文件片段,以及,以第二录屏参数录制的多媒体文件片段。在需要播放该录屏文件时,终端可以直接通过播放器播放该录屏文件。In a possible implementation, the screen recording data generated by the terminal according to the first screen recording parameter can be processed together with the screen recording data generated according to the second screen recording parameter, and then spliced into one screen recording after processing document. The screen recording file includes multimedia file segments recorded according to the first screen recording parameters, and multimedia file segments recorded according to the second screen recording parameters. When the screen recording file needs to be played, the terminal can directly play the screen recording file through the player.

在另一种可能的实现方式中,终端根据第一录屏参数进行录屏产生的录屏数据和根据第二录屏参数进行录屏产生的数据被终端分别处理,生成各自对应的录屏文件。其中,根据第一录屏参数进行录屏生成的录屏文件中,包含指向根据第二录屏参数进行录屏生成的录屏文件的标识。在实际应用中,当根据第一录屏参数进行录屏生成的录屏文件播放完成后,播放器将根据该标识自动获取到根据第二录屏参数进行录屏生成的录屏文件的文件路径,并播放该录屏文件,保证用户可以看到完整的录屏内容。In another possible implementation, the screen recording data generated by the terminal according to the first screen recording parameter and the data generated according to the second screen recording parameter are respectively processed by the terminal to generate corresponding screen recording files . Wherein, the screen recording file generated according to the first screen recording parameter includes an identifier pointing to the screen recording file generated according to the second screen recording parameter. In practical applications, after the screen recording file generated according to the first screen recording parameter is played, the player will automatically obtain the file path of the screen recording file generated according to the second screen recording parameter according to the identifier , and play the screen recording file to ensure that the user can see the complete screen recording content.

综上所述,本实施例提供的录屏方法,根据第一录屏参数进行录屏,监控目标存储余量,当目标存储余量不大于预设阈值时,获取第二录屏参数,根据第二录屏参数录屏。其中,由于在单位时间内根据第二录屏参数产生的录屏数据量小于根据第一录屏参数产生的录屏数据量,因此,相对于持续以第一录屏参数录屏的方案而言,本申请实施例提供的录屏方法能够在目标存储余量相同的情况下,得到更长的屏幕录制时间,提高了进行长时间屏幕录制的成功率。To sum up, the screen recording method provided by this embodiment records the screen according to the first screen recording parameter, monitors the target storage margin, and obtains the second screen recording parameter when the target storage margin is not greater than the preset threshold, and according to The second screen recording parameter screen recording. Among them, since the amount of screen recording data generated according to the second screen recording parameter per unit time is smaller than the amount of screen recording data generated according to the first screen recording parameter, therefore, compared to the scheme of continuously recording screens with the first screen recording parameters , the screen recording method provided by the embodiment of the present application can obtain a longer screen recording time under the condition that the target storage margin is the same, and improves the success rate of long-term screen recording.

与上一个实施例不同的是,终端还能够针对被录制的应用程序确定相应的录屏参数,请参考如下实施例。Different from the previous embodiment, the terminal can also determine corresponding screen recording parameters for the recorded application program, please refer to the following embodiment.

请参见图2,其是本申请另一个示例性实施例提供的录屏方法流程图。该录屏方法可以应用在上述所示的终端中。在图2中,该录屏方法包括:Please refer to FIG. 2 , which is a flowchart of a screen recording method provided by another exemplary embodiment of the present application. The screen recording method can be applied to the terminals shown above. In Figure 2, the screen recording method includes:

步骤201,根据录屏启动指令,开始进行录屏。Step 201, start recording screen according to the screen recording start instruction.

在本申请实施例中,终端可以根据录屏启动指令,开始进行录屏。其中,录屏启动指令可以实现为下列指令中的至少一种。In the embodiment of the present application, the terminal may start to record the screen according to the screen recording start instruction. Wherein, the screen recording start instruction can be implemented as at least one of the following instructions.

(1)当用于录屏的进程或者应用程序提供有录屏控件时,录屏启动指令可以是用户点击该用于指示开始录屏的录屏控件时生成的指令。(1) When the process or application program used for screen recording provides a screen recording control, the screen recording start instruction may be an instruction generated when the user clicks the screen recording control for instructing to start recording the screen.

(2)当用于录屏的进程或者应用程序是通过摇晃终端或改变终端姿态的方式开启录屏功能时,终端可以通过速度传感器、加速度传感器或者陀螺仪等传感器采集指定数据。录屏启动指令可以是根据指定数据生成的指令。(2) When the screen recording process or application starts the screen recording function by shaking the terminal or changing the posture of the terminal, the terminal can collect specified data through sensors such as speed sensors, acceleration sensors, or gyroscopes. The screen recording start instruction may be an instruction generated according to specified data.

(3)当用于录屏的进程或者应用程序是通过接收语音指令开启录屏功能时,终端可以采集和预设语音模版匹配的声音。录屏启动指令可以是根据和预设语音模版匹配的声音生成的指令。(3) When the screen recording process or application program starts the screen recording function by receiving a voice command, the terminal can collect the sound matching the preset voice template. The screen recording start instruction may be an instruction generated according to a voice matching a preset voice template.

(4)当用于录屏的进程或者应用程序是通过接收触控信号开启录屏功能时,终端可以采集指定触控信号,如短按触控信号、长按触控信号、轻压触控信号、重压触控信号、滑动触控信号或多点触控信号等信号。可选地,对于能够分辨指关节触控信号、手掌触控信号和手背触控信号的终端而言,终端还可以采集关节触控信号、手掌触控信号或手背触控信号等信号。可选地,对于能够识别悬浮触控(Floating Touch)信号的终端而言,终端也可以采集悬浮触控信号。可选地,对于折叠屏终端(包括但不限于外折叠屏终端和内折叠屏终端)而言,终端还可以采集折叠屏发生的折叠角度发生变化的信号,例如折叠屏终端的折叠屏由展开状态变化为折叠状态时产生的信号。可选地,对于全面屏终端而言,终端可以采集热感应器和/或光感器所采集的特定数据,该特定数据表示用户的手指在指定区域进行了指定触控动作。录屏启动指令是根据上述终端采集的信号生成的指令。(4) When the process or application program used for screen recording starts the screen recording function by receiving touch signals, the terminal can collect specified touch signals, such as short-press touch signals, long-press touch signals, and light-press touch signals signal, heavy touch signal, sliding touch signal or multi-touch signal and other signals. Optionally, for a terminal capable of distinguishing finger joint touch signals, palm touch signals, and back touch signals, the terminal may also collect signals such as joint touch signals, palm touch signals, or back touch signals. Optionally, for a terminal capable of recognizing a floating touch (Floating Touch) signal, the terminal may also collect the floating touch signal. Optionally, for folding screen terminals (including but not limited to outer folding screen terminals and inner folding screen terminals), the terminal can also collect signals that the folding angle of the folding screen changes. Signal generated when the state changes to the collapsed state. Optionally, for a full-screen terminal, the terminal may collect specific data collected by a thermal sensor and/or a light sensor, and the specific data indicates that a user's finger performs a specified touch action in a specified area. The screen recording start instruction is an instruction generated according to the signal collected by the above-mentioned terminal.

(5)当用于录屏的进程或者应用程序是通过图像识别开启录屏功能时,终端可以通过摄像头采集用户的所做出的手势、姿势或表情。该录屏启动指令可以是根据指定的手势、姿势或者表情等中至少一种图像,经过识别后生成的指令。(5) When the process or application program used for screen recording starts the screen recording function through image recognition, the terminal can collect the user's gestures, postures or expressions through the camera. The screen recording start instruction may be an instruction generated after recognition according to at least one image of a specified gesture, posture, or expression.

步骤202,确定位于前台运行的第一应用程序的标识。Step 202, determine the identity of the first application running in the foreground.

在本申请实施例中,终端能够获取位于前台运行的第一应用程序的标识。若终端中搭载的操作系统是安卓操作系统,则终端可以通过获取活动栈(activitystack)栈顶的活动(activity)的标识来确定在前台运行的第一应用程序。其中,该活动的标识即为第一应用程序的标识。In the embodiment of the present application, the terminal can acquire the identifier of the first application running in the foreground. If the operating system carried in the terminal is an Android operating system, the terminal may determine the first application program running in the foreground by obtaining the identifier of the activity at the top of the activity stack (activity stack). Wherein, the identifier of the activity is the identifier of the first application program.

步骤203,根据第一应用程序的标识,确定第一录屏参数。Step 203: Determine a first screen recording parameter according to the identifier of the first application program.

在本申请实施例中,终端可以根据第一应用程序的标识,确定第一录屏参数。请参见图3,其是基于图2所示的录屏方法所提供的录屏的界面图。在图3中,终端正在对屏幕进行录制,在屏幕中的用户界面中显示有悬浮窗31,该悬浮窗31中显示有当前已录制的时长(24秒)。终端确定用户界面32所属的应用程序的标识,该标识可以是应用程序的名称,也可以是应用程序的安装包名。In this embodiment of the present application, the terminal may determine the first screen recording parameter according to the identifier of the first application program. Please refer to FIG. 3 , which is an interface diagram of screen recording provided based on the screen recording method shown in FIG. 2 . In FIG. 3 , the terminal is recording the screen, and a floating window 31 is displayed in the user interface on the screen, and the floating window 31 displays the currently recorded duration (24 seconds). The terminal determines the identifier of the application to which the user interface 32 belongs, and the identifier may be the name of the application or the name of the installation package of the application.

可选地,终端中预设有两类应用程序的标识,一类标识对应高画质录屏参数,另一类对应低画质录屏参数。终端将根据应用程序的标识来确定对应的录屏参数。如识别出应用程序是幻灯片播放应用程序、图文编辑应用程序、图文展示应用程序或视频编辑应用程序等时,终端将低画质录屏参数确定为第一录屏参数。如识别出应用程序是游戏应用程序、视频播放应用程序或直播应用程序等时,终端将高画质录屏参数确定为第一录屏参数。在一种应用场景中,终端可以预先设定低画质录屏参数和高画质录屏参数,其中,两种参数的数值可以如表一所示。Optionally, two types of application identifications are preset in the terminal, one type of identification corresponds to high-quality screen recording parameters, and the other type corresponds to low-quality screen recording parameters. The terminal will determine the corresponding screen recording parameters according to the identification of the application program. If it is recognized that the application program is a slide show application program, an image-text editing application program, an image-text display application program, or a video editing application program, etc., the terminal determines the low-quality screen recording parameter as the first screen recording parameter. If it is recognized that the application program is a game application program, a video playback application program, or a live broadcast application program, the terminal determines the high-quality screen recording parameter as the first screen recording parameter. In an application scenario, the terminal may preset low-quality screen recording parameters and high-quality screen recording parameters, where the values of the two parameters may be as shown in Table 1.

表一Table I

参数parameter分辨率resolution编码格式Encoding format码率code rate帧率frame rate低画质录屏参数Low quality screen recording parameters480p480pH.264H.264512Kbps512Kbps24fps24fps高画质录屏参数High-quality screen recording parameters1080p1080pH.264H.2642048Kbps2048Kbps30fps30fps

可选地,除了如图3所示的手机类终端确定录屏时显示的用户界面对应的应用程序的标识外,终端的屏幕中还可以展示多个应用程序的用户界面(例如终端是膝上型电脑、台式电脑或电脑一体机等设备)。在终端的屏幕中展示多个应用的用户界面时,终端可以分别确定在屏幕中展示用户界面的应用程序,分别根据展示出用户界面的应用程序,获取对应的第一录屏参数。Optionally, in addition to the identification of the application program corresponding to the user interface displayed when the mobile phone terminal determines the screen recording as shown in Figure 3, the user interface of multiple application programs can also be displayed on the screen of the terminal (for example, the terminal is a laptop laptops, desktops, or all-in-one computers). When displaying user interfaces of multiple applications on the screen of the terminal, the terminal may respectively determine the application programs displaying the user interfaces on the screen, and acquire corresponding first screen recording parameters according to the application programs displaying the user interfaces.

例如,当终端是手机时,终端在录屏时显示的界面如图3所示。该用户界面32对应的应用程序的名称是“绘图小助手”,安装包的名称是“huituxiaozhushou.apk”。本申请实施例中,可以预先生成应用程序对应的标识。比如终端可以根据“绘图小助手”或者“huituxiaozhushou.apk”确定该应用程序对应的标识是图文编辑应用程序标识,后续再根据该图文编辑应用程序标识确定对应的第一录屏参数。由于该图文编辑应用程序对画质要求不高,终端可以将低画质录屏参数确定该第一录屏参数。For example, when the terminal is a mobile phone, the interface displayed by the terminal during screen recording is shown in FIG. 3 . The name of the application program corresponding to the user interface 32 is "Drawing Assistant", and the name of the installation package is "huituxiaozhushou.apk". In this embodiment of the application, the identifier corresponding to the application program may be generated in advance. For example, the terminal can determine according to the "drawing assistant" or "huituxiaozhushou.apk" that the identifier corresponding to the application is the identifier of the graphic editing application, and then determine the corresponding first screen recording parameter according to the identifier of the graphic editing application. Since the image-text editing application program does not have high requirements on image quality, the terminal may determine the first screen recording parameter based on the low-quality screen recording parameters.

再例如,当终端是台式电脑时,该台式电脑在录屏时同时显示有体育比赛直播播放器A的窗口、即时通讯应用程序B的窗口和网页浏览器C的窗口。该台式电脑可以分别获取比赛直播播放器A、即时通讯应用程序B和网页浏览器C各自的标识,再根据上述三个标识分别确定各自对应的第一录屏参数。此时,终端可以根据三个标识分别确定三个窗口各自对应的第一录屏参数,从而保证屏幕录制所生成的录屏文件的观看效果。如比赛直播播放器A的窗口使用的分辨率是720p,即时通讯应用程序B的窗口和网页浏览器C的窗口使用的分辨率是240p。For another example, when the terminal is a desktop computer, the desktop computer simultaneously displays the window of the sports game live broadcast player A, the window of the instant messaging application program B and the window of the web browser C while recording the screen. The desktop computer can respectively obtain the respective identifications of the game live broadcast player A, the instant messaging application program B and the web browser C, and then respectively determine the corresponding first screen recording parameters according to the above three identifications. At this time, the terminal can respectively determine the first screen recording parameters corresponding to the three windows according to the three identifiers, so as to ensure the viewing effect of the screen recording file generated by the screen recording. For example, the resolution of the window of the game live player A is 720p, the resolution of the window of the instant messaging application B and the window of the web browser C is 240p.

步骤204,根据第一录屏参数进行录屏。Step 204, perform screen recording according to the first screen recording parameter.

步骤204的执行过程步骤110的执行过程相同,此处不再赘述。The execution process of step 204 is the same as the execution process of step 110, and will not be repeated here.

步骤205,监控目标存储余量,目标存储余量是目标存储空间的剩余容量,目标存储空间用于存储录屏数据。Step 205, monitor the remaining capacity of the target storage, where the target storage capacity is the remaining capacity of the target storage space, and the target storage space is used to store screen recording data.

步骤205的执行过程和步骤120的执行过程相同,此处不再赘述。The execution process of step 205 is the same as the execution process of step 120, and will not be repeated here.

作为一种替代的实现方式,步骤205可由下列步骤1)、步骤2)和步骤3)来替换,以实现监控目标存储余量的功能。As an alternative implementation manner, step 205 may be replaced by the following steps 1), 2) and 3), so as to realize the function of monitoring the target storage balance.

步骤1)确定用于存放录屏文件的存储空间,录屏文件是根据录屏数据生成的文件。Step 1) Determine the storage space for storing the screen recording file, and the screen recording file is a file generated according to the screen recording data.

针对录屏文件而言,存放该录屏文件的存储空间通常由终端的操作系统或者具有录屏功能的应用程序指定。例如,手机中操作系统将存放该录屏文件的存储空间指定在数据卡中。For the screen recording file, the storage space for storing the screen recording file is usually specified by the operating system of the terminal or an application program with a screen recording function. For example, the operating system in the mobile phone designates the storage space for storing the screen recording file in the data card.

步骤2)确定存储空间的剩余存储容量和录屏文件的指定剩余容量,指定剩余容量等于录屏文件被允许占用的最大存储容量减去录屏文件已占用的存储容量。Step 2) Determine the remaining storage capacity of the storage space and the specified remaining capacity of the screen recording file, and the specified remaining capacity is equal to the maximum storage capacity allowed to be occupied by the screen recording file minus the occupied storage capacity of the screen recording file.

在本申请实施例中,终端将确定存储空间的剩余存储容量和录屏文件的指定剩余容量。需要说明的是,该指定剩余容量等于录屏文件被允许占用的最大存储容量减去录屏文件已经占用的存储容量。In the embodiment of the present application, the terminal will determine the remaining storage capacity of the storage space and the specified remaining capacity of the screen recording file. It should be noted that the specified remaining capacity is equal to the maximum storage capacity allowed to be occupied by the screen recording file minus the storage capacity already occupied by the screen recording file.

例如,在终端中录屏文件被允许占用的最大存储容量是200MByte,存储录屏文件的存储空间是存储卡,目前录屏文件已经占用了80MByte的存储容量,则确定出指定剩余容量是120MByte。For example, the maximum storage capacity that screen recording files are allowed to occupy in the terminal is 200MByte, and the storage space for storing screen recording files is a memory card. Currently, the screen recording files have occupied 80MByte of storage capacity, so it is determined that the specified remaining capacity is 120MByte.

步骤3)将剩余存储容量和录屏文件的指定剩余容量中的较小值,确定为目标存储余量。Step 3) Determine the smaller value of the remaining storage capacity and the designated remaining capacity of the screen recording file as the target storage remaining capacity.

基于步骤2)所举的例子,当该存储卡的剩余存储容量是350MByte时,终端将比较上述350MByte和指定剩余容量120MByte的大小,将两者中的较小者120MByte确定为目标存储余量。Based on the example given in step 2), when the remaining storage capacity of the memory card is 350MByte, the terminal will compare the above-mentioned 350MByte with the specified remaining capacity of 120MByte, and determine the smaller of the two, 120MByte, as the target storage margin.

需要说明的是,步骤205执行完成之后,终端可以执行步骤2061、步骤2062和步骤208,或者执行步骤2071、步骤2072和步骤208。It should be noted that after step 205 is executed, the terminal may execute step 2061, step 2062, and step 208, or execute step 2071, step 2072, and step 208.

步骤2061,当目标存储余量不大于预设阈值时,查询预设阈值与第二录屏参数之间的对应关系。Step 2061, when the target storage remaining amount is not greater than the preset threshold, query the correspondence between the preset threshold and the second screen recording parameter.

在本申请实施例中,终端在目标存储余量不大于预设阈值时,从终端中查询预设阈值和第二录屏参数之间的对应关系。该对应关系可以是一张对应表格,也可以是用于表示对应关系的其它数据。比如,请参见表二,表二示出了一种预设阈值和第二录屏参数之间的对应关系。In the embodiment of the present application, when the target storage remaining amount is not greater than the preset threshold, the terminal queries the correspondence between the preset threshold and the second screen recording parameter from the terminal. The corresponding relationship may be a corresponding table, or other data used to represent the corresponding relationship. For example, please refer to Table 2, which shows a correspondence between a preset threshold and the second screen recording parameter.

表二Table II

预设阈值(MByte)Preset Threshold (MByte)100100300300500500第二录屏参数Parameters of the second screen recording分辨率480pResolution 480p分辨率720pResolution 720p分辨率1080pResolution 1080p

在表二中,第二录屏参数以单独的一种参数(分辨率)为例来说明,当预设阈值分别是100MByte、300MByte或500MByte时,对应的第二录屏参数的值也将对应确定。In Table 2, the second screen recording parameter is illustrated by taking a single parameter (resolution) as an example. When the preset thresholds are 100MByte, 300MByte or 500MByte, the corresponding second screen recording parameter value will also correspond to Sure.

步骤2062,根据对应关系,确定预设阈值对应的第二录屏参数。Step 2062, according to the corresponding relationship, determine the second screen recording parameter corresponding to the preset threshold.

步骤2071,当目标存储余量不大于预设阈值时,确定位于前台运行的第二应用程序的标识。Step 2071, when the target storage remaining amount is not greater than the preset threshold, determine the identity of the second application running in the foreground.

在本申请实施例中,当目标存储余量不大于预设阈值时,终端可以确定位于前台运行的第二应用程序的标识。终端能够使用其搭载的操作系统的系统工具,来获取第二应用程序的标识。In the embodiment of the present application, when the target storage remaining amount is not greater than the preset threshold, the terminal may determine the identity of the second application running in the foreground. The terminal can use the system tool of the operating system carried by it to acquire the identifier of the second application program.

步骤2072,当第二应用程序的标识和预设标识匹配时,获取第二录屏参数。Step 2072, when the identifier of the second application program matches the preset identifier, acquire second screen recording parameters.

在本申请实施例中,当第二应用程序的标识和预设标识匹配时,终端获取第二录屏参数。其中,预设标识可以是终端的操作系统或者具有屏幕录制功能的应用程序预先设置的标识。该预设标识可以包括如下标识中的至少一种:社交通讯应用程序标识、网页浏览器标识、图文编辑应用程序标识、图文展示应用程序标识、视频编辑应用程序标识、音频编辑应用程序标识、拍照摄影应用程序标识、地图导航应用程序标识、安全杀毒应用程序标识或理财支付应用程序标识等。In the embodiment of the present application, when the identifier of the second application program matches the preset identifier, the terminal acquires the second screen recording parameter. Wherein, the preset identifier may be an identifier preset by an operating system of the terminal or an application program having a screen recording function. The preset identification may include at least one of the following identifications: social communication application identification, web browser identification, graphic editing application identification, graphic display application identification, video editing application identification, audio editing application identification , a camera and photography application program identification, a map navigation application program identification, a security antivirus application program identification, or a wealth management payment application program identification, etc.

需要说明的是,由于本申请实施例中的预设标识对应的是对录屏的视频的画质要求不高的应用程序。因此,在终端确定第二应用程序的标识和预设标识匹配时,终端可以获取第二录屏参数。It should be noted that, since the preset identifier in the embodiment of the present application corresponds to an application program that does not have high requirements on the image quality of the screen-recorded video. Therefore, when the terminal determines that the identifier of the second application program matches the preset identifier, the terminal may acquire the second screen recording parameter.

可选地,作为步骤2072的一种替换方式,当应用程序的标识和预设标识不匹配时,终端可以保持使用第一录屏参数录屏。例如,应用程序的标识是游戏应用程序标识、视频播放应用程序标识、直播应用程序标识或短视频播放应用程序标识等时,终端可以保持使用第一录屏参数录屏。Optionally, as an alternative to step 2072, when the identifier of the application program does not match the preset identifier, the terminal may keep using the first screen recording parameter to record the screen. For example, when the application identifier is a game application identifier, a video playback application identifier, a live broadcast application identifier, or a short video playback application identifier, etc., the terminal may keep using the first screen recording parameter to record the screen.

步骤208,根据第二录屏参数录屏。Step 208, record the screen according to the second screen recording parameter.

在终端确定第二录屏参数后,终端将根据第二录屏参数录屏。After the terminal determines the second screen recording parameters, the terminal will record the screen according to the second screen recording parameters.

综上所述,本实施例根据录屏启动指令开始进行录屏,根据运行在前台的第一应用程序的标识,获取第一录屏参数,能够使得终端根据第一应用程序的标识获取和应用程序相适应的第一录屏参数,使得录屏所生成的录屏文件中的视频画质能够满足用户需要且不占用过多的存储空间,提高了录屏时的存储空间的利用效率。To sum up, in this embodiment, screen recording is started according to the screen recording start command, and the first screen recording parameters are acquired according to the identification of the first application program running in the foreground, so that the terminal can acquire and apply the parameters according to the identification of the first application program The first screen recording parameter adapted to the program enables the video quality in the screen recording file generated by the screen recording to meet the user's needs without taking up too much storage space, and improves the utilization efficiency of the storage space during screen recording.

本实施例提供的录屏方法,还能够当目标存储余量不大于预设阈值时,令终端获取位于前台运行的第二应用程序的标识,当第二应用程序的标识和预设标识匹配时,获取第二录屏参数,根据第二录屏参数录屏,令终端在第二应用程序是预设的程序时,且目标存储余量不大于预设阈值时使用第二录屏参数录屏。在保证录屏文件能够提供给第二应用程序相应的视频画质的前提下,延长了屏幕录制的时长。The screen recording method provided in this embodiment can also enable the terminal to obtain the identification of the second application program running in the foreground when the target storage margin is not greater than the preset threshold, and when the identification of the second application program matches the preset identification , obtain the second screen recording parameter, and record the screen according to the second screen recording parameter, so that the terminal uses the second screen recording parameter to record the screen when the second application program is a preset program and the target storage margin is not greater than the preset threshold . On the premise of ensuring that the screen recording file can provide the corresponding video quality for the second application program, the duration of the screen recording is extended.

本实施例提供的录屏方法,还能够当终端录屏时,通过终端确定用于存放录屏文件的存储空间,确定存储空间的剩余存储容量和录屏文件的指定剩余容量,将剩余存储容量和录屏文件的指定剩余容量中的较小值,确定为目标存储余量,提高了确定可以用于存储录屏文件的剩余容量的准确度。The screen recording method provided by this embodiment can also determine the storage space used to store the screen recording file through the terminal when the terminal is recording the screen, determine the remaining storage capacity of the storage space and the specified remaining capacity of the screen recording file, and use the remaining storage capacity The smaller value of the specified remaining capacity of the screen recording file and the screen recording file is determined as the target storage remaining capacity, which improves the accuracy of determining the remaining capacity that can be used to store the screen recording file.

不同于上述实施例,本申请实施例还提供一种录屏方法,能够在延长屏幕录制的时间的同时令用户知晓终端改变了录屏参数,请参考如下实施例。Different from the above embodiments, the embodiments of the present application also provide a screen recording method, which can prolong the screen recording time and at the same time let the user know that the terminal has changed the screen recording parameters, please refer to the following embodiments.

图4是基于图2所示的录屏方法提供的部分步骤的流程图,在图4中,终端在执行完成步骤205后,可以执行包括步骤2061和步骤2062的流程一,或者,也可以执行包括步骤2071和步骤2072的流程二。在终端执行流程一或者流程二的同时,终端可以同步执行包括步骤2091、步骤2092和步骤2094的流程三。或者,终端在执行完成步骤205后,可以直接执行包括步骤2091、步骤2092和步骤2093的流程四。其中,步骤2091至步骤2094的执行过程分述如下:Fig. 4 is a flow chart of some steps provided based on the screen recording method shown in Fig. 2. In Fig. 4, after completing step 205, the terminal may execute the first process including step 2061 and step 2062, or may execute Process 2 including step 2071 and step 2072. While the terminal executes the process 1 or the process 2, the terminal may synchronously execute the process 3 including step 2091 , step 2092 and step 2094 . Or, after completing step 205, the terminal may directly execute process 4 including step 2091, step 2092 and step 2093. Wherein, the execution process of step 2091 to step 2094 is described as follows:

步骤2091,当目标存储余量不大于预设阈值时,通过终端的信息输出组件展示提醒信息,提醒信息用于提醒用户目标存储余量不大于预设阈值。Step 2091, when the target storage remaining amount is not greater than the preset threshold, display reminder information through the information output component of the terminal, and the reminder information is used to remind the user that the target storage remaining amount is not greater than the preset threshold.

在本申请实施例中,终端在目标存储余量不大于预设阈值时,可以通过终端的信息输出组件展示提醒信息,该提醒信息用于提醒用户目标存储余量不大于预设阈值。需要说明的是,提醒信息可以根据信息输出组件的形态来确定展示方式。例如,若信息输出组件包括屏幕,则提醒信息的展示方式可以是图像展示,具体可以是文本信息、图片信息或动画信息。若信息输出组件包括扬声器,则提醒信息的展示方式可以是语音提醒或响铃提示。若信息输出组件包括是提示灯,则提醒信息的展示方式可以是提示灯的常亮、闪烁或变色等发光方式。In the embodiment of the present application, when the target storage remaining amount is not greater than the preset threshold, the terminal may display reminder information through the information output component of the terminal, and the reminder information is used to remind the user that the target storage remaining amount is not greater than the preset threshold. It should be noted that the reminder information can be displayed according to the form of the information output component. For example, if the information output component includes a screen, the reminder information may be displayed in an image display manner, specifically text information, picture information or animation information. If the information output component includes a loudspeaker, the display mode of the reminder information can be a voice reminder or a ringing reminder. If the information output component includes a reminder light, the display mode of the reminder information may be a light-emitting manner such as constant lighting, flickering or color change of the reminder light.

在提醒信息的一种可能实现的展示方式中,以终端是手机,信息输出组件是屏幕为例进行说明。请参照图5,其是基于图2所示的录屏方法提供的一种展示提醒信息的界面图。在图5中,当终端监控到目标存储余量不大于预设阈值时,终端将在屏幕中展示弹窗33,弹窗33中显示有提醒文本“存储容量不足,3秒后进行低容量录屏模式”。此时,用户可以通过该弹窗得知终端的存储容量不足的信息。In a possible display manner of reminder information, the terminal is a mobile phone and the information output component is a screen as an example for illustration. Please refer to FIG. 5 , which is an interface diagram showing reminder information provided based on the screen recording method shown in FIG. 2 . In FIG. 5, when the terminal monitors that the target storage margin is not greater than the preset threshold, the terminal will display a pop-up window 33 on the screen, and the pop-up window 33 displays a reminder text "Insufficient storage capacity, low-capacity recording after 3 seconds screen mode". At this time, the user can learn the information that the storage capacity of the terminal is insufficient through the pop-up window.

步骤2092,从提醒信息开始展示的时刻起,监控是否接收到预设操作,并设置定时器,预设操作是用于指示停止录屏、暂停录屏或以第一录屏参数录屏中任意一种操作。Step 2092, from the moment when the reminder information starts to be displayed, monitor whether a preset operation is received, and set a timer. The preset operation is used to instruct to stop recording the screen, pause the screen recording, or use any of the first screen recording parameters to record the screen. an operation.

终端将从提醒信息开始展示的时刻起,监控是否接收到预设操作,并设置定时器,该预设操作是用于指示停止录屏、暂停录屏或者以第一录屏参数录屏中任意一种操作。仍以图5所示的场景为例,当用户看到图5所示的界面后,用户可以停止录屏或者暂停录屏。若用户希望停止录制屏幕,则用户可以点击停止按钮311,若用户希望暂停录屏,用户可以点击暂停按钮312。或者,用户仍希望以第一录屏参数录屏,则用户可以点击拒绝按钮331。The terminal will monitor whether the preset operation is received from the moment when the reminder information starts to be displayed, and set a timer. The preset operation is used to instruct to stop recording, pause recording, or use any of the first screen recording parameters to record the screen. an operation. Still taking the scene shown in FIG. 5 as an example, when the user sees the interface shown in FIG. 5 , the user can stop or pause the screen recording. If the user wants to stop recording the screen, the user can click the stop button 311 , and if the user wants to pause the screen recording, the user can click the pause button 312 . Or, if the user still wants to record the screen with the first screen recording parameter, the user can click the reject button 331 .

步骤2093,若定时器未超时且接收到预设操作,则停止展示提醒信息。Step 2093, if the timer has not expired and the preset operation is received, stop displaying the reminder information.

在本申请实施例中,终端可以在定时器的超时时间内接收到用户操作时停止展示该提醒信息。比如,当超时时长是3秒时,当终端将在提醒信息开始展示的时刻09:49开始监控预设操作,若在09:52之前接收到预设操作,则停止展示提醒消息。例如,隐藏文本弹出框、停止提示铃声、停止振动或停止提示灯发光。In the embodiment of the present application, the terminal may stop displaying the reminder information when receiving a user operation within the timeout period of the timer. For example, when the timeout period is 3 seconds, the terminal will start monitoring the preset operation at 09:49 when the reminder information starts to be displayed, and stop displaying the reminder message if the preset operation is received before 09:52. For example, hide the text popover, stop the alert ringing, stop vibrating, or stop the alert light from glowing.

步骤2094,若定时器超时,则停止展示提醒信息。Step 2094, if the timer expires, stop displaying the reminder information.

在本申请实施例中,若定时器超时,则终端在提醒消息持续展示时长等于定时器超时时长后,将停止展示该提醒信息。例如,请参见图6,其是基于图2所示的录屏方法提供的一种界面示意图。图6可以是终端在定时器的超时时长内没有监控到预设操作后显示的界面。在图6中,终端的用户界面中显示有通知窗口34,该通知窗口用于通知用户终端以根据第二录屏参数录屏,如通知窗口34中显示的“录屏画质已由720p切换至480p”,表示终端已进入低容量录屏模式。In the embodiment of the present application, if the timer expires, the terminal will stop displaying the reminder information after the reminder message continues to be displayed for a duration equal to the timer expiration duration. For example, please refer to FIG. 6 , which is a schematic diagram of an interface provided based on the screen recording method shown in FIG. 2 . FIG. 6 may be an interface displayed after the terminal does not monitor a preset operation within the timeout period of the timer. In FIG. 6 , a notification window 34 is displayed on the user interface of the terminal, which is used to notify the user terminal to record the screen according to the second screen recording parameter, such as the "screen recording quality has been switched from 720p" displayed in the notification window 34 to 480p”, indicating that the terminal has entered the low-capacity screen recording mode.

综上所述,本实施例提供的录屏方法,当目标存储余量不大于预设阈值时,通过终端的信息输出组件展示提醒信息,从提醒信息开始展示的时刻起,监控是否接收到预设操作,并设置定时器,若定时器未超时且接收到预设操作,或者,定时器超时,则停止展示提醒信息。在能够提醒到用户目标存储余量不大于预设阈值的同时,避免对用户的干扰,提高了用户使用终端的工作效率。To sum up, in the screen recording method provided by this embodiment, when the target storage margin is not greater than the preset threshold, the reminder information is displayed through the information output component of the terminal. From the moment when the reminder information starts to be displayed, it is monitored whether the preset Set the operation and set the timer. If the timer does not expire and the preset operation is received, or if the timer expires, the display of the reminder message will stop. While the user can be reminded that the target storage margin is not greater than the preset threshold, interference to the user is avoided, and the work efficiency of the user using the terminal is improved.

下述为本申请装置实施例,可以用于执行本申请方法实施例。对于本申请装置实施例中未披露的细节,请参照本申请方法实施例。The following are device embodiments of the present application, which can be used to implement the method embodiments of the present application. For details not disclosed in the device embodiments of the present application, please refer to the method embodiments of the present application.

图7示出了本申请一个示例性实施例提供的录屏装置的结构框图。该录屏装置可以通过软件、硬件或者两者的结合实现成为终端的全部或一部分。该装置包括:Fig. 7 shows a structural block diagram of a screen recording device provided by an exemplary embodiment of the present application. The screen recording device can be implemented as all or a part of the terminal through software, hardware or a combination of the two. The unit includes:

第一录屏模块710,被配置为根据第一录屏参数进行录屏。The first screen recording module 710 is configured to perform screen recording according to the first screen recording parameter.

余量监控模块720,被配置为监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录幕数据;The residual monitoring module 720 is configured to monitor the target storage residual, the target storage residual is the remaining capacity of the target storage space, and the target storage space is used to store the recording data;

参数获取模块730,被配置为当所述目标存储余量不大于预设阈值时,获取第二录屏参数,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量;The parameter acquisition module 730 is configured to acquire a second screen recording parameter when the target storage margin is not greater than a preset threshold, and the amount of screen recording data generated according to the second screen recording parameter within a unit time is less than that according to the preset threshold. The amount of screen recording data generated by the first screen recording parameter;

第二录屏模块740,被配置为根据所述第二录屏参数录屏。The second screen recording module 740 is configured to record a screen according to the second screen recording parameter.

在一个可选的实施例中,所述装置工作时需要获取的第一录屏参数包括分辨率、编码格式、码率和帧率中的至少一种;需要获取的第二录屏参数包括分辨率、编码格式、码率和帧率中的至少一种。In an optional embodiment, the first screen recording parameters that need to be obtained when the device is working include at least one of resolution, encoding format, code rate, and frame rate; the second screen recording parameters that need to be obtained include resolution At least one of rate, encoding format, code rate and frame rate.

在一个可选的实施例中,所述参数获取模块730,被配置为当所述目标存储余量不大于预设阈值时,查询所述预设阈值与所述第二录屏参数之间的对应关系;根据所述对应关系,确定所述预设阈值对应的所述第二录屏参数。In an optional embodiment, the parameter obtaining module 730 is configured to query the distance between the preset threshold and the second screen recording parameter when the target storage margin is not greater than a preset threshold. Correspondence: according to the correspondence, determine the second screen recording parameter corresponding to the preset threshold.

在一个可选的实施例中,所述参数获取模块730,被配置为在根据第一录屏参数进行录屏之前,确定位于前台运行的第一应用程序的标识;根据所述第一应用程序的标识,确定所述第一录屏参数。In an optional embodiment, the parameter acquisition module 730 is configured to determine the identity of the first application program running in the foreground before recording the screen according to the first screen recording parameter; according to the first application program , to determine the first screen recording parameter.

在一个可选的实施例中,所述参数获取模块730,被配置为当所述目标存储余量不大于预设阈值时,确定位于前台运行的第二应用程序的标识;当所述第二应用程序的标识和预设标识匹配时,获取所述第二录屏参数。In an optional embodiment, the parameter acquisition module 730 is configured to determine the identity of the second application running in the foreground when the target storage balance is not greater than a preset threshold; when the second When the identifier of the application program matches the preset identifier, the second screen recording parameter is acquired.

在一个可选的实施例中,所述装置工作时需要获取的预设标识包括:社交通讯应用程序标识、网页浏览器标识、图文编辑应用程序标识、图文展示应用程序标识、视频编辑应用程序标识、音频编辑应用程序标识、拍照摄影应用程序标识、地图导航应用程序标识、安全杀毒应用程序标识或理财支付应用程序标识中至少一种。In an optional embodiment, the preset identifiers that need to be obtained when the device is working include: social communication application identifier, web browser identifier, image-text editing application identifier, image-text display application identifier, video editing application At least one of program identifiers, audio editing application identifiers, camera and photography application identifiers, map navigation application identifiers, security antivirus application identifiers, or financial payment application identifiers.

在一个可选的实施例中,所述余量监控模块720,被配置为当所述终端录屏时,确定用于存放录屏文件的存储空间,所述录屏文件是根据所述录屏数据生成的文件;确定所述存储空间的剩余存储容量和所述录屏文件的指定剩余容量,所述指定剩余容量等于所述录屏文件被允许占用的最大存储容量减去所述录屏文件已占用的存储容量;将所述剩余存储容量和所述录屏文件的指定剩余容量中的较小值,确定为所述目标存储余量。In an optional embodiment, the remaining monitoring module 720 is configured to determine a storage space for storing a screen recording file when the terminal is recording a screen, and the screen recording file is based on the screen recording file The file generated by the data; determine the remaining storage capacity of the storage space and the specified remaining capacity of the screen recording file, and the specified remaining capacity is equal to the maximum storage capacity that the screen recording file is allowed to occupy minus the screen recording file Occupied storage capacity; determining the smaller value of the remaining storage capacity and the designated remaining capacity of the screen recording file as the target storage remaining capacity.

在一个可选的实施例中,所述装置还包括信息展示模块,所述信息展示模块,被配置为当所述目标存储余量不大于预设阈值时,通过所述终端的信息输出组件展示提醒信息,所述提醒信息用于提醒所述目标存储余量不大于所述预设阈值。In an optional embodiment, the device further includes an information display module, and the information display module is configured to display through the information output component of the terminal when the target storage balance is not greater than a preset threshold reminder information, the reminder information is used to remind that the target storage remaining amount is not greater than the preset threshold.

在一个可选的实施例中,所述信息展示模块,被配置为从所述提醒信息开始展示的时刻起,监控是否接收到预设操作,并设置定时器,所述预设操作是用于指示停止录屏、暂停录屏或以所述第一录屏参数录屏中任意一种操作;若所述定时器未超时且接收到所述预设操作,则停止展示所述提醒信息;若所述定时器超时,则停止展示所述提醒信息。In an optional embodiment, the information display module is configured to monitor whether a preset operation is received and set a timer from the moment when the reminder information starts to be displayed, and the preset operation is for Instruct to stop screen recording, pause screen recording, or record screen with the first screen recording parameter; if the timer has not timed out and the preset operation is received, stop displaying the reminder message; if When the timer expires, the display of the reminder information is stopped.

图8是本申请一个示例性实施例提供的终端的结构框图,如图8所示,该终端包括处理器810和存储器820,所述存储器820中存储有至少一条指令,所述指令由所述处理器810加载并执行以实现如上各个实施例所述的录屏方法。Fig. 8 is a structural block diagram of a terminal provided by an exemplary embodiment of the present application. As shown in Fig. 8, the terminal includes a processor 810 and a memory 820, the memory 820 stores at least one instruction, and the instruction is executed by the The processor 810 is loaded and executed to implement the screen recording methods described in the above embodiments.

本申请实施例还提供了一种计算机可读介质,该计算机可读介质存储有至少一条指令,所述至少一条指令由所述处理器加载并执行以实现如上各个实施例所述的录屏方法。The embodiment of the present application also provides a computer-readable medium, the computer-readable medium stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement the screen recording method described in each of the above embodiments .

本申请实施例还提供了一种计算机程序产品,该计算机程序产品存储有至少一条指令,所述至少一条指令由所述处理器加载并执行以实现如上各个实施例所述的录屏方法。The embodiment of the present application also provides a computer program product, the computer program product stores at least one instruction, and the at least one instruction is loaded and executed by the processor to implement the screen recording method described in the above embodiments.

需要说明的是:上述实施例提供的录屏装置在执行录屏方法时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将设备的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的录屏装置与录屏方法实施例属于同一构思,其具体实现过程详见方法实施例,这里不再赘述。It should be noted that: when the screen recording device provided in the above embodiment executes the screen recording method, it only uses the division of the above-mentioned functional modules as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional modules according to needs. , which divides the internal structure of the device into different functional modules to complete all or part of the functions described above. In addition, the screen recording device and the screen recording method embodiment provided by the above embodiment belong to the same idea, and the specific implementation process thereof is detailed in the method embodiment, and will not be repeated here.

上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。The serial numbers of the above embodiments of the present application are for description only, and do not represent the advantages and disadvantages of the embodiments.

本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,所述的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps for implementing the above embodiments can be completed by hardware, and can also be completed by instructing related hardware through a program. The program can be stored in a computer-readable storage medium. The above-mentioned The storage medium mentioned may be a read-only memory, a magnetic disk or an optical disk, and the like.

以上所述仅为本申请的较佳实施例,并不用以限制本申请,凡在本申请的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本申请的保护范围之内。The above descriptions are only preferred embodiments of the application, and are not intended to limit the application. Any modifications, equivalent replacements, improvements, etc. made within the spirit and principles of the application shall be included in the protection of the application. within range.

Claims (12)

Translated fromChinese
1.一种录屏方法,其特征在于,所述方法包括:1. A screen recording method, characterized in that the method comprises:根据第一录屏参数进行录屏;Record the screen according to the first screen recording parameters;监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录屏数据;Monitoring the target storage margin, the target storage margin is the remaining capacity of the target storage space, and the target storage space is used to store screen recording data;当所述目标存储余量不大于预设阈值时,获取第二录屏参数;When the target storage margin is not greater than a preset threshold, acquire a second screen recording parameter;根据所述第二录屏参数进行录屏;performing screen recording according to the second screen recording parameters;其中,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量。Wherein, the amount of screen recording data generated according to the second screen recording parameter per unit time is smaller than the amount of screen recording data generated according to the first screen recording parameter.2.根据权利要求1所述的方法,其特征在于,2. The method of claim 1, wherein,所述第一录屏参数包括分辨率、编码格式、码率和帧率中的至少一种;The first screen recording parameters include at least one of resolution, encoding format, code rate and frame rate;所述第二录屏参数包括分辨率、编码格式、码率和帧率中的至少一种。The second screen recording parameter includes at least one of resolution, encoding format, code rate and frame rate.3.根据权利要求1所述的方法,其特征在于,所述当所述目标存储余量不大于预设阈值时,获取第二录屏参数,包括:3. The method according to claim 1, wherein said acquiring a second screen recording parameter when said target storage margin is not greater than a preset threshold comprises:当所述目标存储余量不大于预设阈值时,查询所述预设阈值与所述第二录屏参数之间的对应关系;When the target storage margin is not greater than a preset threshold, query the correspondence between the preset threshold and the second screen recording parameter;根据所述对应关系,确定所述预设阈值对应的所述第二录屏参数。According to the corresponding relationship, the second screen recording parameter corresponding to the preset threshold is determined.4.根据权利要求1所述的方法,其特征在于,所述根据第一录屏参数进行录屏之前,还包括:4. The method according to claim 1, wherein, before recording the screen according to the first screen recording parameter, further comprising:确定位于前台运行的第一应用程序的标识;determining an identity of a first application running in the foreground;根据所述第一应用程序的标识,确定所述第一录屏参数。Determine the first screen recording parameter according to the identifier of the first application program.5.根据权利要求1所述的方法,其特征在于,所述当所述目标存储余量不大于预设阈值时,获取第二录屏参数,包括:5. The method according to claim 1, wherein when the target storage margin is not greater than a preset threshold, acquiring a second screen recording parameter comprises:当所述目标存储余量不大于预设阈值时,确定位于前台运行的第二应用程序的标识;When the target storage balance is not greater than a preset threshold, determine the identity of the second application running in the foreground;当所述第二应用程序的标识和预设标识匹配时,获取所述第二录屏参数。When the identifier of the second application program matches the preset identifier, acquire the second screen recording parameters.6.根据权利要求5所述的方法,其特征在于,所述预设标识包括:社交通讯应用程序标识、网页浏览器标识、图文编辑应用程序标识、图文展示应用程序标识、视频编辑应用程序标识、音频编辑应用程序标识、拍照摄影应用程序标识、地图导航应用程序标识、安全杀毒应用程序标识或理财支付应用程序标识中至少一种。6. The method according to claim 5, wherein the preset identification includes: social communication application identification, web browser identification, graphic editing application identification, graphic display application identification, video editing application At least one of program identifiers, audio editing application identifiers, camera and photography application identifiers, map navigation application identifiers, security antivirus application identifiers, or financial payment application identifiers.7.根据权利要求1所述的方法,其特征在于,所述监控目标存储余量,包括:7. The method according to claim 1, wherein the monitoring target storage balance comprises:确定用于存放录屏文件的存储空间,所述录屏文件是根据所述录屏数据生成的文件;Determine the storage space used to store the screen recording file, the screen recording file is a file generated according to the screen recording data;确定所述存储空间的剩余存储容量和所述录屏文件的指定剩余容量,所述指定剩余容量等于所述录屏文件被允许占用的最大存储容量减去所述录屏文件已占用的存储容量;Determine the remaining storage capacity of the storage space and the specified remaining capacity of the screen recording file, the specified remaining capacity is equal to the maximum storage capacity allowed to be occupied by the screen recording file minus the occupied storage capacity of the screen recording file ;将所述剩余存储容量和所述录屏文件的指定剩余容量中的较小值,确定为所述目标存储余量。The smaller value of the remaining storage capacity and the specified remaining capacity of the screen recording file is determined as the target storage remaining capacity.8.根据权利要求1所述的方法,其特征在于,所述方法包括:8. The method of claim 1, wherein the method comprises:当所述目标存储余量不大于预设阈值时,通过所述终端的信息输出组件展示提醒信息,所述提醒信息用于提醒所述目标存储余量不大于所述预设阈值。When the target storage remaining amount is not greater than the preset threshold, the information output component of the terminal displays reminder information, and the reminder information is used to remind that the target storage remaining amount is not greater than the preset threshold.9.根据权利要求8所述的方法,其特征在于,所述方法还包括:9. The method of claim 8, further comprising:从所述提醒信息开始展示的时刻起,监控是否接收到预设操作,并设置定时器,所述预设操作是用于指示停止录屏、暂停录屏或以所述第一录屏参数录屏中任意一种操作;From the moment when the reminder information starts to be displayed, monitor whether a preset operation is received, and set a timer. The preset operation is used to indicate to stop recording the screen, pause the screen recording, or record with the first screen recording parameter Any operation on the screen;若所述定时器未超时且接收到所述预设操作,则停止展示所述提醒信息;If the timer has not expired and the preset operation is received, stop displaying the reminder message;若所述定时器超时,则停止展示所述提醒信息。If the timer expires, stop displaying the reminder information.10.一种录屏装置,其特征在于,所述装置包括:10. A screen recording device, characterized in that the device comprises:第一录屏模块,被配置为根据第一录屏参数进行录屏;The first screen recording module is configured to perform screen recording according to the first screen recording parameters;余量监控模块,被配置为监控目标存储余量,所述目标存储余量是目标存储空间的剩余容量,所述目标存储空间用于存储录幕数据;The residual monitoring module is configured to monitor the target storage residual, the target storage residual is the remaining capacity of the target storage space, and the target storage space is used to store recording data;参数获取模块,被配置为当所述目标存储余量不大于预设阈值时,获取第二录屏参数,在单位时间内根据所述第二录屏参数产生的录屏数据量小于根据所述第一录屏参数产生的录屏数据量;The parameter acquisition module is configured to acquire a second screen recording parameter when the target storage margin is not greater than a preset threshold, and the amount of screen recording data generated according to the second screen recording parameter within a unit time is less than according to the The amount of screen recording data generated by the first screen recording parameter;第二录屏模块,被配置为根据所述第二录屏参数录屏。The second screen recording module is configured to record a screen according to the second screen recording parameters.11.一种终端,其特征在于,所述终端包括处理器和存储器,所述存储器中存储有至少一条指令,所述指令由所述处理器加载并执行以实现如权利要求1至9任一所述的录屏方法。11. A terminal, characterized in that the terminal comprises a processor and a memory, at least one instruction is stored in the memory, and the instruction is loaded and executed by the processor to implement any one of claims 1 to 9. The screen recording method described above.12.一种计算机可读存储介质,其特征在于,所述存储介质中存储有至少一条指令,所述指令由处理器加载并执行以实现如权利要求1至9任一所述的录屏方法。12. A computer-readable storage medium, characterized in that at least one instruction is stored in the storage medium, and the instruction is loaded and executed by a processor to implement the screen recording method according to any one of claims 1 to 9 .
CN201711226853.7A2017-11-292017-11-29 Screen recording method, device, terminal and storage mediumActiveCN108024079B (en)

Priority Applications (1)

Application NumberPriority DateFiling DateTitle
CN201711226853.7ACN108024079B (en)2017-11-292017-11-29 Screen recording method, device, terminal and storage medium

Applications Claiming Priority (1)

Application NumberPriority DateFiling DateTitle
CN201711226853.7ACN108024079B (en)2017-11-292017-11-29 Screen recording method, device, terminal and storage medium

Publications (2)

Publication NumberPublication Date
CN108024079Atrue CN108024079A (en)2018-05-11
CN108024079B CN108024079B (en)2021-08-03

Family

ID=62077435

Family Applications (1)

Application NumberTitlePriority DateFiling Date
CN201711226853.7AActiveCN108024079B (en)2017-11-292017-11-29 Screen recording method, device, terminal and storage medium

Country Status (1)

CountryLink
CN (1)CN108024079B (en)

Cited By (16)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN108777812A (en)*2018-06-252018-11-09乐蜜有限公司A kind of record screen live broadcasting method, device, electronic equipment and storage medium
CN110401870A (en)*2019-07-302019-11-01努比亚技术有限公司Method of adjustment, terminal and the computer readable storage medium of record screen frame per second
CN110753201A (en)*2019-11-122020-02-04维沃移动通信有限公司Video recording method and device, electronic equipment and storage medium
CN111199172A (en)*2018-11-192020-05-26中移动信息技术有限公司 Terminal-based screen recording processing method and device, and storage medium
CN111294658A (en)*2018-12-072020-06-16北京字节跳动网络技术有限公司Information processing method and device
CN111294321A (en)*2018-12-072020-06-16北京字节跳动网络技术有限公司Information processing method and device
CN111857914A (en)*2020-07-062020-10-30上海意略明数字科技股份有限公司Method and device for acquiring operation information of application program on terminal, storage medium and terminal
CN112543348A (en)*2020-11-272021-03-23深圳市慧为智能科技股份有限公司Remote screen recording method, device, equipment and computer readable storage medium
CN112584210A (en)*2020-12-072021-03-30海信视像科技股份有限公司Display device, video recording method and recorded file display method
CN112667357A (en)*2020-12-312021-04-16中电长城网际安全技术研究院(北京)有限公司Data processing method and device based on virtual machine, network equipment and storage medium
CN113655887A (en)*2021-01-182021-11-16海信视像科技股份有限公司Virtual reality equipment and static screen recording method
CN114428596A (en)*2022-01-302022-05-03深圳创维-Rgb电子有限公司 Screen projection display method, electronic device and readable storage medium
CN114489547A (en)*2022-01-302022-05-13深圳创维-Rgb电子有限公司Screen projection method and device, electronic equipment and readable storage medium
CN114727011A (en)*2022-03-072022-07-08深圳创维-Rgb电子有限公司Camera optimization method and device, electronic equipment and readable storage medium
US12088871B2 (en)2020-12-072024-09-10Hisense Visual Technology Co., Ltd.Display apparatus, video recording method, and recorded file display method
CN119718513A (en)*2020-01-212025-03-28华为技术有限公司Control display method and electronic equipment

Citations (12)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20050204388A1 (en)*1998-06-112005-09-15Knudson Edward B.Series reminders and series recording from an interactive television program guide
EP1586193A1 (en)*2003-01-202005-10-19Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V.Camera and method for optically recording a screen
CN102881307A (en)*2012-09-052013-01-16北京得力天方信息科技有限公司Video and audio recording and playing system and method
CN103902721A (en)*2014-04-102014-07-02中央电视台Data front field processing method and system and data back field publishing method and system
CN104168445A (en)*2013-05-152014-11-26晶睿通讯股份有限公司dynamic video storage method and network security monitoring device
CN104834713A (en)*2015-05-082015-08-12武汉网幂科技有限公司Method and system for storing and transmitting image data of terminal equipment
CN104850487A (en)*2015-04-272015-08-19小米科技有限责任公司Information display method and device
US20160100033A1 (en)*2012-01-262016-04-07Zoom International S.R.O.System and method for zero-footprint screen capture
CN105812698A (en)*2016-03-102016-07-27深圳市元征科技股份有限公司Screen recording method and device for vehicle diagnosis terminal
CN107102694A (en)*2017-06-062017-08-29南京巨鲨显示科技有限公司A kind of display with kinescope recording function
CN107333168A (en)*2017-06-132017-11-07青岛海信电器股份有限公司The memory space for calculating recording disk realizes the method and device that displaying predetermined programme is recorded
CN107357617A (en)*2017-06-302017-11-17广东欧珀移动通信有限公司Using update method, device, storage medium and electronic equipment

Patent Citations (12)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
US20050204388A1 (en)*1998-06-112005-09-15Knudson Edward B.Series reminders and series recording from an interactive television program guide
EP1586193A1 (en)*2003-01-202005-10-19Fraunhofer-Gesellschaft zur Förderung der angewandten Forschung e.V.Camera and method for optically recording a screen
US20160100033A1 (en)*2012-01-262016-04-07Zoom International S.R.O.System and method for zero-footprint screen capture
CN102881307A (en)*2012-09-052013-01-16北京得力天方信息科技有限公司Video and audio recording and playing system and method
CN104168445A (en)*2013-05-152014-11-26晶睿通讯股份有限公司dynamic video storage method and network security monitoring device
CN103902721A (en)*2014-04-102014-07-02中央电视台Data front field processing method and system and data back field publishing method and system
CN104850487A (en)*2015-04-272015-08-19小米科技有限责任公司Information display method and device
CN104834713A (en)*2015-05-082015-08-12武汉网幂科技有限公司Method and system for storing and transmitting image data of terminal equipment
CN105812698A (en)*2016-03-102016-07-27深圳市元征科技股份有限公司Screen recording method and device for vehicle diagnosis terminal
CN107102694A (en)*2017-06-062017-08-29南京巨鲨显示科技有限公司A kind of display with kinescope recording function
CN107333168A (en)*2017-06-132017-11-07青岛海信电器股份有限公司The memory space for calculating recording disk realizes the method and device that displaying predetermined programme is recorded
CN107357617A (en)*2017-06-302017-11-17广东欧珀移动通信有限公司Using update method, device, storage medium and electronic equipment

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
金磊 等: "基于H.264的屏幕视频实时编码器优化", 《计算机工程》*

Cited By (18)

* Cited by examiner, † Cited by third party
Publication numberPriority datePublication dateAssigneeTitle
CN108777812A (en)*2018-06-252018-11-09乐蜜有限公司A kind of record screen live broadcasting method, device, electronic equipment and storage medium
CN111199172A (en)*2018-11-192020-05-26中移动信息技术有限公司 Terminal-based screen recording processing method and device, and storage medium
CN111294658A (en)*2018-12-072020-06-16北京字节跳动网络技术有限公司Information processing method and device
CN111294321A (en)*2018-12-072020-06-16北京字节跳动网络技术有限公司Information processing method and device
CN110401870A (en)*2019-07-302019-11-01努比亚技术有限公司Method of adjustment, terminal and the computer readable storage medium of record screen frame per second
CN110753201B (en)*2019-11-122022-02-08维沃移动通信有限公司Video recording method and device, electronic equipment and storage medium
CN110753201A (en)*2019-11-122020-02-04维沃移动通信有限公司Video recording method and device, electronic equipment and storage medium
CN119718513A (en)*2020-01-212025-03-28华为技术有限公司Control display method and electronic equipment
CN111857914A (en)*2020-07-062020-10-30上海意略明数字科技股份有限公司Method and device for acquiring operation information of application program on terminal, storage medium and terminal
CN112543348A (en)*2020-11-272021-03-23深圳市慧为智能科技股份有限公司Remote screen recording method, device, equipment and computer readable storage medium
CN112584210A (en)*2020-12-072021-03-30海信视像科技股份有限公司Display device, video recording method and recorded file display method
US12088871B2 (en)2020-12-072024-09-10Hisense Visual Technology Co., Ltd.Display apparatus, video recording method, and recorded file display method
CN112667357A (en)*2020-12-312021-04-16中电长城网际安全技术研究院(北京)有限公司Data processing method and device based on virtual machine, network equipment and storage medium
CN113655887A (en)*2021-01-182021-11-16海信视像科技股份有限公司Virtual reality equipment and static screen recording method
CN114428596A (en)*2022-01-302022-05-03深圳创维-Rgb电子有限公司 Screen projection display method, electronic device and readable storage medium
CN114489547A (en)*2022-01-302022-05-13深圳创维-Rgb电子有限公司Screen projection method and device, electronic equipment and readable storage medium
CN114727011A (en)*2022-03-072022-07-08深圳创维-Rgb电子有限公司Camera optimization method and device, electronic equipment and readable storage medium
CN114727011B (en)*2022-03-072024-06-11深圳创维-Rgb电子有限公司Image pickup optimization method, device, electronic equipment and readable storage medium

Also Published As

Publication numberPublication date
CN108024079B (en)2021-08-03

Similar Documents

PublicationPublication DateTitle
CN108024079B (en) Screen recording method, device, terminal and storage medium
US10425679B2 (en)Method and device for displaying information on video image
EP3693837A1 (en)Method and apparatus for processing multiple inputs
EP3547218A1 (en)File processing device and method, and graphical user interface
CN106161943A (en)A kind of kinescope method and mobile terminal
CN113411532B (en) Method, device, terminal and storage medium for recording content
CN106453864A (en) An image processing method, device and terminal
CN113238727B (en) Screen switching method and device, computer readable medium and electronic device
CN105100870B (en) Screen capture method and terminal device
CN114095776B (en)Screen recording method and electronic equipment
CN112995746B (en) Video processing method, device and terminal device
US12271415B2 (en)Method, apparatus, device, readable storage medium and product for media content processing
WO2020244553A1 (en)Subtitle border-crossing processing method and apparatus, and electronic device
CN105335198A (en)Font addition method and device
US20110110564A1 (en)Electronic apparatus and image display
CN112911147A (en)Display control method, display control device and electronic equipment
US20150341435A1 (en)Communication system, transfer control device, and communication method
CN117519538A (en)Interface interaction method, device, equipment and storage medium
CN108256071B (en)Method and device for generating screen recording file, terminal and storage medium
US11551452B2 (en)Apparatus and method for associating images from two image streams
CN108174270A (en)Data processing method, data processing device, storage medium and electronic equipment
CN118466769A (en) A writing acceleration method and device supporting transparency
CN105404464B (en)A kind of method and user terminal for controlling picture
US10248214B2 (en)Wearable device for writing and drawing
CN107707812B (en) Image processing method, mobile terminal and computer-readable storage medium

Legal Events

DateCodeTitleDescription
PB01Publication
PB01Publication
SE01Entry into force of request for substantive examination
SE01Entry into force of request for substantive examination
CB02Change of applicant information

Address after:Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant after:OPPO Guangdong Mobile Communications Co.,Ltd.

Address before:Changan town in Guangdong province Dongguan 523860 usha Beach Road No. 18

Applicant before:GUANGDONG OPPO MOBILE TELECOMMUNICATIONS Corp.,Ltd.

CB02Change of applicant information
GR01Patent grant
GR01Patent grant

[8]ページ先頭

©2009-2025 Movatter.jp