CN118075125A - Node management method, electronic equipment and medium - Google Patents
Node management method, electronic equipment and medium Download PDFInfo
- Publication number
- CN118075125A CN118075125A CN202211467858.XA CN202211467858A CN118075125A CN 118075125 A CN118075125 A CN 118075125A CN 202211467858 A CN202211467858 A CN 202211467858A CN 118075125 A CN118075125 A CN 118075125A
- Authority
- CN
- China
- Prior art keywords
- node
- post
- target
- electronic device
- processing
- 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.)
- Pending
Links
Classifications
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/0803—Configuration setting
- H04L41/084—Configuration by using pre-existing information, e.g. using templates or copying from other elements
- H04L41/0843—Configuration by using pre-existing information, e.g. using templates or copying from other elements based on generic templates
-
- H—ELECTRICITY
- H04—ELECTRIC COMMUNICATION TECHNIQUE
- H04L—TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
- H04L41/00—Arrangements for maintenance, administration or management of data switching networks, e.g. of packet switching networks
- H04L41/08—Configuration management of networks or network elements
- H04L41/085—Retrieval of network configuration; Tracking network configuration history
- H04L41/0853—Retrieval of network configuration; Tracking network configuration history by actively collecting configuration information or by backing up configuration information
Landscapes
- Engineering & Computer Science (AREA)
- Computer Networks & Wireless Communication (AREA)
- Signal Processing (AREA)
- Stored Programmes (AREA)
Abstract
本申请提供了一种节点管理方法、电子设备及介质,涉及终端技术领域。该方法包括:对与目标应用关联的目标节点进行查询,目标节点用于表征在电子设备上目标应用所支持的功能;若未查询到目标节点,则获取目标应用提供的目标节点的配置信息;根据节点配置模板以及目标节点的配置信息,对目标节点进行配置。由此,若目标应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。
The present application provides a node management method, electronic device and medium, and relates to the field of terminal technology. The method includes: querying a target node associated with a target application, the target node is used to characterize the functions supported by the target application on the electronic device; if the target node is not queried, obtaining the configuration information of the target node provided by the target application; configuring the target node according to the node configuration template and the configuration information of the target node. Thus, if the special function of the target application is not supported by the electronic device, the post-processing management module of the electronic device can display the function control corresponding to the custom node in the relevant interface of the built-in application by adding a custom node, so that the special function of the application is adapted to the electronic device, and the customization capability of the target application is provided to the user.
Description
技术领域Technical Field
本申请涉及终端技术领域,尤其涉及一种节点管理方法、电子设备及介质。The present application relates to the field of terminal technology, and in particular to a node management method, electronic equipment and medium.
背景技术Background technique
随着终端技术的发展,电子设备如手机的功能也越来越丰富,性能也越来越强大。电子设备可以呈现丰富多彩的图形用户界面(GraphicalUserInterface,GUI),在图形用户界面中呈现多种功能控件,以供用户使用。With the development of terminal technology, electronic devices such as mobile phones have become more and more functional and powerful. Electronic devices can present a colorful graphical user interface (GUI), in which a variety of functional controls are presented for users to use.
目前,电子设备可以通过对节点能力的查询,得到电子设备在目标应用上所支持的功能,进而决定在目标应用的用户界面中展示支持的节点的功能控件。然而,某些应用具有特殊的功能,但电子设备并不支持该特殊的功能,无法与目标应用适配,需重新设计电子设备的软件逻辑,改造周期较长且成本高。Currently, electronic devices can query node capabilities to obtain the functions supported by the electronic device on the target application, and then decide to display the function controls of the supported nodes in the user interface of the target application. However, some applications have special functions, but the electronic device does not support the special functions and cannot adapt to the target application. The software logic of the electronic device needs to be redesigned, which takes a long time and is costly.
发明内容Summary of the invention
本申请的目的在于:提供一种节点管理方法、电子设备及介质,能够使应用的特殊功能与电子设备适配。The purpose of the present application is to provide a node management method, an electronic device and a medium, which can adapt the special functions of an application to the electronic device.
第一方面,本申请公开了一种节点管理方法,应用于手机、PAD、大屏等电子设备,该方法包括:对与目标应用关联的目标节点进行查询,该目标节点用于表征在该电子设备上该目标应用所支持的功能;若未查询到该目标节点,则获取该目标应用提供的该目标节点的配置信息;根据节点配置模板以及该目标节点的配置信息,对该目标节点进行配置。In the first aspect, the present application discloses a node management method, which is applied to electronic devices such as mobile phones, PADs, and large screens. The method includes: querying a target node associated with a target application, where the target node is used to characterize the functions supported by the target application on the electronic device; if the target node is not found, obtaining the configuration information of the target node provided by the target application; and configuring the target node according to a node configuration template and the configuration information of the target node.
由此,若目标应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。Therefore, if the special functions of the target application are not supported by the electronic device, the post-processing management module of the electronic device can add a custom node and display the function controls corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide users with customization capabilities of the target application.
在一些可能的实现方式中,根据节点配置模板以及目标节点的配置信息,对目标节点进行配置,包括:将目标节点的配置信息,写入到节点配置模板中对应的字段,生成目标节点的配置文件,以完成对目标节点的配置。In some possible implementations, the target node is configured according to the node configuration template and the configuration information of the target node, including: writing the configuration information of the target node into the corresponding field in the node configuration template, generating a configuration file of the target node, so as to complete the configuration of the target node.
在一些可能的实现方式中,节点配置模板中对应的字段包括:节点标识字段、节点所在插件路径字段、节点支持能力名称字段、节点支持能力参数字段、节点输入数据类型字段、节点输出数据类型字段、节点约束条件字段、节点开放信息字段中的一种或多种的组合。In some possible implementations, the corresponding fields in the node configuration template include: a node identification field, a node plug-in path field, a node support capability name field, a node support capability parameter field, a node input data type field, a node output data type field, a node constraint condition field, and a combination of one or more of the node open information fields.
由此,通过将目标节点的配置信息直接写入配置模板中的方法,可以方便快捷地生成目标节点的配置文件,向用户提供目标应用的定制能力。Therefore, by directly writing the configuration information of the target node into the configuration template, the configuration file of the target node can be generated conveniently and quickly, providing the user with the customization capability of the target application.
在一些可能的实现方式中,该方法还包括:在目标应用的用户界面中,展示目标节点对应的功能控件。由此,电子设备可以直接向用户提供目标应用的定制能力。In some possible implementations, the method further includes: displaying a function control corresponding to the target node in a user interface of the target application. Thus, the electronic device can directly provide the user with the customization capability of the target application.
在一些可能的实现方式中,该方法还包括:响应于针对目标节点对应的功能控件的触发操作,加载目标节点的配置文件。In some possible implementations, the method further includes: in response to a trigger operation on a function control corresponding to the target node, loading a configuration file of the target node.
在一些可能的实现方式中,该电子设备包括应用层和媒体中台后处理框架层;应用层包括目标应用,媒体中台后处理框架层包括后处理管理模块,对与目标应用关联的目标节点进行查询,包括:目标应用向后处理管理模块发送针对目标节点的节点查询指令;后处理管理模块接收到节点查询指令后,对目标节点进行查询。In some possible implementations, the electronic device includes an application layer and a media middle station post-processing framework layer; the application layer includes a target application, and the media middle station post-processing framework layer includes a post-processing management module, which queries a target node associated with the target application, including: the target application sends a node query instruction for the target node to the post-processing management module; after receiving the node query instruction, the post-processing management module queries the target node.
在一些可能的实现方式中,根据节点配置模板以及目标节点的配置信息,对目标节点进行配置,包括:后处理管理模块根据节点配置模板以及目标节点的配置信息,对目标节点进行配置。In some possible implementations, the target node is configured according to the node configuration template and the configuration information of the target node, including: a post-processing management module configures the target node according to the node configuration template and the configuration information of the target node.
在一些可能的实现方式中,媒体中台后处理框架层还包括:后处理管线模块、后处理节点构建模块;响应于针对目标节点对应的功能控件的触发操作,加载目标节点的配置文件,包括:目标应用获取针对目标节点对应的功能控件的触发操作;目标应用根据触发操作,通过后处理管理模块向后处理管线模块发送管线的创建指令;后处理管线模块基于创建管线的指令,向后处理节点构建模块发送目标节点的构建指令;后处理节点构建模块基于目标节点的构建指令,加载目标节点的配置文件。In some possible implementations, the post-processing framework layer of the media middle station also includes: a post-processing pipeline module, a post-processing node construction module; in response to a trigger operation on a function control corresponding to a target node, loading a configuration file of the target node, including: the target application obtains a trigger operation on a function control corresponding to the target node; the target application sends a pipeline creation instruction to the post-processing pipeline module through the post-processing management module according to the trigger operation; the post-processing pipeline module sends a target node construction instruction to the post-processing node construction module based on the pipeline creation instruction; the post-processing node construction module loads the configuration file of the target node based on the target node construction instruction.
由此,若目标应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。Therefore, if the special functions of the target application are not supported by the electronic device, the post-processing management module of the electronic device can add a custom node and display the function controls corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide users with customization capabilities of the target application.
第二方面,本申请公开了一种电子设备,包括处理器和存储器;存储器用于存储计算机执行命令;处理器用于执行存储器存储的计算机执行命令,使得处理器执行如第一方面中的方法。In a second aspect, the present application discloses an electronic device, comprising a processor and a memory; the memory is used to store computer execution commands; the processor is used to execute the computer execution commands stored in the memory, so that the processor executes the method in the first aspect.
第三方面,本申请公开了一种计算机可读存储介质,计算机可读存储介质中存储有计算机程序或指令,当计算机程序或指令被运行时,实现如第一方面中的方法。In a third aspect, the present application discloses a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed, the method in the first aspect is implemented.
第四方面,本申请提供了一种计算机程序产品,当计算机程序产品在计算机上运行时,使得计算机执行如第一方面中任意一项的节点管理方法。In a fourth aspect, the present application provides a computer program product. When the computer program product is run on a computer, the computer executes a node management method as described in any one of the first aspects.
附图说明BRIEF DESCRIPTION OF THE DRAWINGS
图1为本申请实施例提供的一种电子设备的硬件结构示意图;FIG1 is a schematic diagram of the hardware structure of an electronic device provided in an embodiment of the present application;
图2为本申请实施例提供的一种电子设备的软件结构示意图;FIG2 is a schematic diagram of a software structure of an electronic device provided in an embodiment of the present application;
图3为本申请实施例提供的一种电子设备的桌面示意图;FIG3 is a desktop schematic diagram of an electronic device provided in an embodiment of the present application;
图4为本申请实施例提供的一种电子设备的相机页面示意图;FIG4 is a schematic diagram of a camera page of an electronic device provided in an embodiment of the present application;
图5为本申请实施例提供的一种电子设备的图库页面示意图;FIG5 is a schematic diagram of a gallery page of an electronic device provided in an embodiment of the present application;
图6为本申请实施例提供的一种电子设备的编辑页面示意图;FIG6 is a schematic diagram of an editing page of an electronic device provided in an embodiment of the present application;
图7为本申请实施例提供的一种节点管理方法的时序图;FIG7 is a timing diagram of a node management method provided in an embodiment of the present application;
图8为本申请实施例提供的一种管线示意图。FIG8 is a schematic diagram of a pipeline provided in an embodiment of the present application.
具体实施方式Detailed ways
本申请说明书和权利要求书及附图说明中的术语“第一”、“第二”和“第三”等是用于区别不同对象,而不是用于限定特定顺序。The terms "first", "second", "third", etc. in the specification, claims and drawings of this application are used to distinguish different objects rather than to limit a specific order.
在本申请实施例中,“示例性的”或者“例如”等词用于表示作例子、例证或说明。本申请实施例中被描述为“示例性的”或者“例如”的任何实施例或设计方案不应被解释为比其它实施例或设计方案更优选或更具优势。确切而言,使用“示例性的”或者“例如”等词旨在以具体方式呈现相关概念。In the embodiments of the present application, words such as "exemplary" or "for example" are used to indicate examples, illustrations or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of the present application should not be interpreted as being more preferred or more advantageous than other embodiments or designs. Specifically, the use of words such as "exemplary" or "for example" is intended to present related concepts in a specific way.
为了下述各实施例的描述清楚简洁,首先给出相关技术的简要介绍:In order to make the description of the following embodiments clear and concise, a brief introduction to the related technology is first given:
媒体中台后处理框架是指集成了多种针对媒体数据处理功能的框架,不同的功能可以通过不同的节点体现,也就是说,不同的节点,所体现的功能不同。在一些示例中,不同的电子设备,媒体中台后处理框架的节点能力不同。应用层的应用可以通过媒体中台后处理框架进行查询电子设备所支持的能力,并对相关的能力进行调用,从而实现各种各样的功能,例如,视频剪辑、拍摄图像等。在一些示例中,电子设备可以动态显示功能控件,因此,针对不同的电子设备而言,不同的用户体验到的功能不同。The media middle station post-processing framework refers to a framework that integrates multiple functions for media data processing. Different functions can be reflected through different nodes, that is, different nodes reflect different functions. In some examples, different electronic devices have different node capabilities of the media middle station post-processing framework. Applications at the application layer can query the capabilities supported by electronic devices through the media middle station post-processing framework and call related capabilities to achieve various functions, such as video editing, image capture, etc. In some examples, electronic devices can dynamically display function controls. Therefore, for different electronic devices, different users experience different functions.
随着终端技术的发展,电子设备如手机的功能也越来越丰富,性能也越来越强大。电子设备可以呈现丰富多彩的图形用户界面(Graphical User Interface,GUI),在图形用户界面中呈现多种功能控件,以供用户使用。With the development of terminal technology, electronic devices such as mobile phones have become more and more functional and powerful. Electronic devices can present a colorful graphical user interface (GUI), in which a variety of functional controls are presented for users to use.
目前,电子设备可以通过对节点能力的查询,得到电子设备在目标应用上所支持的功能,进而决定在目标应用的用户界面中展示支持的节点的功能控件。然而,某些应用具有特殊的功能,但电子设备并不支持该特殊的功能,无法与目标应用适配,需重新设计电子设备的软件逻辑,改造周期较长且成本高。Currently, electronic devices can query node capabilities to obtain the functions supported by the electronic device on the target application, and then decide to display the function controls of the supported nodes in the user interface of the target application. However, some applications have special functions, but the electronic device does not support the special functions and cannot adapt to the target application. The software logic of the electronic device needs to be redesigned, which takes a long time and is costly.
有鉴于此,本申请实施例提供的一种节点管理方法、电子设备及介质,在该方法中,若目标应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。In view of this, an embodiment of the present application provides a node management method, an electronic device and a medium. In the method, if the special functions of the target application are not supported by the electronic device, the post-processing management module of the electronic device can add a custom node and display the function control corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide the user with customization capabilities of the target application.
首先,介绍本申请实施例中提供的示例性电子设备100。在一些实施例中,电子设备100可以是手机、平板电脑、桌面型计算机、膝上型计算机、手持计算机、笔记本电脑、超级移动个人计算机(ultra-mobile personal computer,UMPC)、上网本、以及蜂窝电话、个人数字助理(personal digital assistant,PDA)、增强现实(augmented reality,AR)设备、虚拟现实(virtual reality,VR)设备、人工智能(artificial intelligence,AI)设备、可穿戴式设备、车载设备、智能家居设备和/或智慧城市设备,本申请实施例对该电子设备100的具体类型不作特殊限制。参见图1,该图为本申请实施例提供的一种电子设备100的硬件结构示意图。First, an exemplary electronic device 100 provided in an embodiment of the present application is introduced. In some embodiments, the electronic device 100 may be a mobile phone, a tablet computer, a desktop computer, a laptop computer, a handheld computer, a notebook computer, an ultra-mobile personal computer (UMPC), a netbook, and a cellular phone, a personal digital assistant (PDA), an augmented reality (AR) device, a virtual reality (VR) device, an artificial intelligence (AI) device, a wearable device, a vehicle-mounted device, a smart home device and/or a smart city device. The embodiment of the present application does not impose any special restrictions on the specific type of the electronic device 100. Referring to FIG. 1 , the figure is a schematic diagram of the hardware structure of an electronic device 100 provided in an embodiment of the present application.
如图1所示,电子设备可以包括处理器110,内部存储器121,天线1,天线2,移动通信模块150,无线通信模块160,传感器模块180,显示屏194等。其中传感器模块180可以包括触摸传感器180K等。As shown in FIG1 , the electronic device may include a processor 110, an internal memory 121, an antenna 1, an antenna 2, a mobile communication module 150, a wireless communication module 160, a sensor module 180, a display screen 194, etc. The sensor module 180 may include a touch sensor 180K, etc.
可以理解的是,本实施例示意的结构并不构成对电子设备的具体限定。在另一些实施例中,电子设备可以包括比图示更多或更少的部件,或者组合某些部件,或者拆分某些部件,或者不同的部件布置。图示的部件可以以硬件,软件,软件和硬件的组合实现。It is to be understood that the structure illustrated in this embodiment does not constitute a specific limitation on the electronic device. In other embodiments, the electronic device may include more or fewer components than shown in the figure, or combine some components, or split some components, or arrange the components differently. The components shown in the figure may be implemented in hardware, software, or a combination of software and hardware.
处理器110可以包括一个或多个处理单元,例如:处理器110可以包括应用处理器(application processor,AP),调制解调处理器,图形处理器(graphics processingunit,GPU),图像信号处理器(image signal processor,ISP),控制器,视频编解码器,数字信号处理器(digital signal processor,DSP),基带处理器,和/或神经网络处理器(neural-network processing unit,NPU)等。其中,不同的处理单元可以是独立的器件,也可以集成在一个或多个处理器中。例如,在本申请中,处理器110可以对与目标应用关联的目标节点进行查询,该目标节点用于表征在该电子设备上该目标应用所支持的功能;若未查询到该目标节点,则获取该目标应用提供的该目标节点的配置信息;根据节点配置模板以及该目标节点的配置信息,对该目标节点进行配置。由此,若目标应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。The processor 110 may include one or more processing units, for example: the processor 110 may include an application processor (application processor, AP), a modem processor, a graphics processor (graphics processing unit, GPU), an image signal processor (image signal processor, ISP), a controller, a video codec, a digital signal processor (digital signal processor, DSP), a baseband processor, and/or a neural-network processing unit (neural-network processing unit, NPU), etc. Among them, different processing units can be independent devices or integrated in one or more processors. For example, in the present application, the processor 110 can query the target node associated with the target application, and the target node is used to characterize the functions supported by the target application on the electronic device; if the target node is not queried, the configuration information of the target node provided by the target application is obtained; according to the node configuration template and the configuration information of the target node, the target node is configured. Therefore, if the special function of the target application is not supported by the electronic device, the post-processing management module of the electronic device can display the function control corresponding to the custom node in the relevant interface of the built-in application by adding a custom node, so that the special function of the application is adapted to the electronic device, and the customization capability of the target application is provided to the user.
其中,控制器可以是电子设备的神经中枢和指挥中心。控制器可以根据指令操作码和时序信号,产生操作控制信号,完成取指令和执行指令的控制。The controller can be the nerve center and command center of the electronic device. The controller can generate operation control signals according to the instruction operation code and timing signal to complete the control of fetching and executing instructions.
处理器110中还可以设置存储器,用于存储指令和数据。在一些实施例中,处理器110中的存储器为高速缓冲存储器。该存储器可以保存处理器110刚用过或循环使用的指令或数据。如果处理器110需要再次使用该指令或数据,可从所述存储器中直接调用。避免了重复存取,减少了处理器110的等待时间,因而提高了系统的效率。The processor 110 may also be provided with a memory for storing instructions and data. In some embodiments, the memory in the processor 110 is a cache memory. The memory may store instructions or data that the processor 110 has just used or cyclically used. If the processor 110 needs to use the instruction or data again, it may be directly called from the memory. This avoids repeated access, reduces the waiting time of the processor 110, and thus improves the efficiency of the system.
在一些实施例中,处理器110可以包括一个或多个接口。接口可以包括集成电路(inter-integrated circuit,I2C)接口,集成电路内置音频(inter-integrated circuitsound,I2S)接口,脉冲编码调制(pulse code modulation,PCM)接口,通用异步收发传输器(universal asynchronous receiver/transmitter,UART)接口,移动产业处理器接口(mobile industry processor interface,MIPI),通用输入输出(general-purposeinput/output,GPIO)接口,用户标识模块(subscriber identity module,SIM)接口,和/或通用串行总线(universal serial bus,USB)接口等。In some embodiments, the processor 110 may include one or more interfaces. The interface may include an inter-integrated circuit (I2C) interface, an inter-integrated circuit sound (I2S) interface, a pulse code modulation (PCM) interface, a universal asynchronous receiver/transmitter (UART) interface, a mobile industry processor interface (MIPI), a general-purpose input/output (GPIO) interface, a subscriber identity module (SIM) interface, and/or a universal serial bus (USB) interface, etc.
I2C接口是一种双向同步串行总线,包括一根串行数据线(serial data line,SDA)和一根串行时钟线(derail clock line,SCL)。在一些实施例中,处理器110可以包含多组I2C总线。处理器110可以通过不同的I2C总线接口分别耦合触摸传感器180K等。例如:处理器110可以通过I2C接口耦合触摸传感器180K,使处理器110与触摸传感器180K通过I2C总线接口通信,实现电子设备的触摸功能。基于电子设备的触摸功能,在用户触摸电子设备所显示的应用图标后,电子设备可以启动该应用。The I2C interface is a bidirectional synchronous serial bus, including a serial data line (SDA) and a serial clock line (SCL). In some embodiments, the processor 110 may include multiple groups of I2C buses. The processor 110 may be coupled to the touch sensor 180K and the like through different I2C bus interfaces. For example: the processor 110 may be coupled to the touch sensor 180K through the I2C interface, so that the processor 110 communicates with the touch sensor 180K through the I2C bus interface to realize the touch function of the electronic device. Based on the touch function of the electronic device, after the user touches the application icon displayed by the electronic device, the electronic device can start the application.
UART接口是一种通用串行数据总线,用于异步通信。该总线可以为双向通信总线。它将要传输的数据在串行通信与并行通信之间转换。在一些实施例中,UART接口通常被用于连接处理器110与无线通信模块160。The UART interface is a universal serial data bus for asynchronous communication. The bus can be a bidirectional communication bus. It converts the data to be transmitted between serial communication and parallel communication. In some embodiments, the UART interface is generally used to connect the processor 110 and the wireless communication module 160.
MIPI接口可以被用于连接处理器110与显示屏194等外围器件。MIPI接口包括摄像头串行接口(camera serial interface,CSI),显示屏串行接口(display serialinterface,DSI)等。在一些实施例中,处理器110和摄像头通过CSI接口通信,实现电子设备的拍摄功能。处理器110和显示屏194通过DSI接口通信,实现电子设备的显示功能。例如,电子设备基于显示功能,能够显示相关界面。The MIPI interface can be used to connect the processor 110 to peripheral devices such as the display screen 194. The MIPI interface includes a camera serial interface (CSI), a display serial interface (DSI), etc. In some embodiments, the processor 110 and the camera communicate via the CSI interface to implement the shooting function of the electronic device. The processor 110 and the display screen 194 communicate via the DSI interface to implement the display function of the electronic device. For example, the electronic device can display a related interface based on the display function.
GPIO接口可以通过软件配置。GPIO接口可以被配置为控制信号,也可被配置为数据信号。在一些实施例中,GPIO接口可以用于连接处理器110与摄像头,显示屏194,无线通信模块160,传感器模块180等。GPIO接口还可以被配置为I2C接口,I2S接口,UART接口,MIPI接口等。The GPIO interface can be configured by software. The GPIO interface can be configured as a control signal or as a data signal. In some embodiments, the GPIO interface can be used to connect the processor 110 with a camera, a display screen 194, a wireless communication module 160, a sensor module 180, etc. The GPIO interface can also be configured as an I2C interface, an I2S interface, a UART interface, a MIPI interface, etc.
可以理解的是,本实施例示意的各模块间的接口连接关系,只是示意性说明,并不构成对电子设备的结构限定。在本申请另一些实施例中,电子设备也可以采用上述实施例中不同的接口连接方式,或多种接口连接方式的组合。It is understandable that the interface connection relationship between the modules illustrated in this embodiment is only a schematic illustration and does not constitute a structural limitation of the electronic device. In other embodiments of the present application, the electronic device may also adopt different interface connection methods in the above embodiments, or a combination of multiple interface connection methods.
电子设备的无线通信功能可以通过天线1,天线2,移动通信模块150,无线通信模块160,调制解调处理器以及基带处理器等实现。The wireless communication function of the electronic device can be implemented through antenna 1, antenna 2, mobile communication module 150, wireless communication module 160, modem processor and baseband processor.
天线1和天线2用于发射和接收电磁波信号。电子设备中的每个天线可用于覆盖单个或多个通信频带。不同的天线还可以复用,以提高天线的利用率。例如:可以将天线1复用为无线局域网的分集天线。在另外一些实施例中,天线可以和调谐开关结合使用。Antenna 1 and antenna 2 are used to transmit and receive electromagnetic wave signals. Each antenna in the electronic device can be used to cover a single or multiple communication frequency bands. Different antennas can also be reused to improve the utilization of the antennas. For example, antenna 1 can be reused as a diversity antenna for a wireless local area network. In some other embodiments, the antenna can be used in combination with a tuning switch.
移动通信模块150可以提供应用在电子设备上的包括2G/3G/4G/5G等无线通信的解决方案。移动通信模块150可以包括至少一个滤波器,开关,功率放大器,低噪声放大器(low noise amplifier,LNA)等。移动通信模块150可以由天线1接收电磁波,并对接收的电磁波进行滤波,放大等处理,传送至调制解调处理器进行解调。移动通信模块150还可以对经调制解调处理器调制后的信号放大,经天线1转为电磁波辐射出去。在一些实施例中,移动通信模块150的至少部分功能模块可以被设置于处理器110中。在一些实施例中,移动通信模块150的至少部分功能模块可以与处理器110的至少部分模块被设置在同一个器件中。The mobile communication module 150 can provide solutions for wireless communications including 2G/3G/4G/5G, etc., applied to electronic devices. The mobile communication module 150 may include at least one filter, a switch, a power amplifier, a low noise amplifier (LNA), etc. The mobile communication module 150 can receive electromagnetic waves from the antenna 1, and filter, amplify, and process the received electromagnetic waves, and transmit them to the modulation and demodulation processor for demodulation. The mobile communication module 150 can also amplify the signal modulated by the modulation and demodulation processor, and convert it into electromagnetic waves for radiation through the antenna 1. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the processor 110. In some embodiments, at least some of the functional modules of the mobile communication module 150 can be set in the same device as at least some of the modules of the processor 110.
调制解调处理器可以包括调制器和解调器。其中,调制器用于将待发送的低频基带信号调制成中高频信号。解调器用于将接收的电磁波信号解调为低频基带信号。随后解调器将解调得到的低频基带信号传送至基带处理器处理。低频基带信号经基带处理器处理后,被传递给应用处理器。应用处理器通过显示屏194显示图像或视频。在一些实施例中,调制解调处理器可以是独立的器件。在另一些实施例中,调制解调处理器可以独立于处理器110,与移动通信模块150或其他功能模块设置在同一个器件中。The modem processor may include a modulator and a demodulator. The modulator is used to modulate the low-frequency baseband signal to be sent into a medium-high frequency signal. The demodulator is used to demodulate the received electromagnetic wave signal into a low-frequency baseband signal. The demodulator then transmits the demodulated low-frequency baseband signal to the baseband processor for processing. After the low-frequency baseband signal is processed by the baseband processor, it is passed to the application processor. The application processor displays an image or video through the display screen 194. In some embodiments, the modem processor may be an independent device. In other embodiments, the modem processor may be independent of the processor 110 and be set in the same device as the mobile communication module 150 or other functional modules.
无线通信模块160可以提供应用在电子设备上的包括无线局域网(wirelesslocal area networks,WLAN)(如无线保真(wireless fidelity,Wi-Fi)网络),蓝牙(bluetooth,BT),全球导航卫星系统(global navigation satellite system,GNSS),调频(frequency modulation,FM),近距离无线通信技术(near field communication,NFC),红外技术(infrared,IR)等无线通信的解决方案。无线通信模块160可以是集成至少一个通信处理模块的一个或多个器件。无线通信模块160经由天线2接收电磁波,将电磁波信号调频以及滤波处理,将处理后的信号发送到处理器110。无线通信模块160还可以从处理器110接收待发送的信号,对其进行调频,放大,经天线2转为电磁波辐射出去。The wireless communication module 160 can provide wireless communication solutions including wireless local area networks (WLAN) (such as wireless fidelity (Wi-Fi) networks), bluetooth (BT), global navigation satellite system (GNSS), frequency modulation (FM), near field communication (NFC), infrared (IR), etc., which are applied to electronic devices. The wireless communication module 160 can be one or more devices integrating at least one communication processing module. The wireless communication module 160 receives electromagnetic waves via the antenna 2, modulates the frequency of the electromagnetic wave signal and performs filtering, and sends the processed signal to the processor 110. The wireless communication module 160 can also receive the signal to be sent from the processor 110, modulate the frequency of it, amplify it, and convert it into electromagnetic waves for radiation through the antenna 2.
在一些实施例中,电子设备的天线1和移动通信模块150耦合,天线2和无线通信模块160耦合,使得电子设备可以通过无线通信技术与网络以及其他设备通信。所述无线通信技术可以包括全球移动通讯系统(global system for mobile communications,GSM),通用分组无线服务(general packet radio service,GPRS),码分多址接入(code divisionmultiple access,CDMA),宽带码分多址(wideband code division multiple access,WCDMA),时分码分多址(time-division code division multiple access,TD-SCDMA),长期演进(long term evolution,LTE),BT,GNSS,WLAN,NFC,FM,和/或IR技术等。所述GNSS可以包括全球卫星定位系统(global positioning system,GPS),全球导航卫星系统(globalnavigation satellite system,GLONASS),北斗卫星导航系统(beidou navigationsatellite system,BDS),准天顶卫星系统(quasi-zenith satellite system,QZSS)和/或星基增强系统(satellite based augmentation systems,SBAS)。In some embodiments, the antenna 1 of the electronic device is coupled to the mobile communication module 150, and the antenna 2 is coupled to the wireless communication module 160, so that the electronic device can communicate with the network and other devices through wireless communication technology. The wireless communication technology may include global system for mobile communications (GSM), general packet radio service (GPRS), code division multiple access (CDMA), wideband code division multiple access (WCDMA), time division code division multiple access (TD-SCDMA), long term evolution (LTE), BT, GNSS, WLAN, NFC, FM, and/or IR technology. The GNSS may include global positioning system (GPS), global navigation satellite system (GLONASS), Beidou navigation satellite system (BDS), quasi-zenith satellite system (QZSS) and/or satellite based augmentation system (SBAS).
在一些示例中,基于电子设备的无线通信技术,电子设备可以从云端下载相应的文件,例如云配置文件等。In some examples, based on the wireless communication technology of the electronic device, the electronic device can download corresponding files, such as cloud configuration files, from the cloud.
电子设备通过GPU,显示屏194,以及应用处理器等实现显示功能。GPU为图像处理的微处理器,连接显示屏194和应用处理器。GPU用于执行数学和几何计算,用于图形渲染。处理器110可包括一个或多个GPU,其执行程序指令以生成或改变显示信息。The electronic device implements the display function through a GPU, a display screen 194, and an application processor. The GPU is a microprocessor for image processing, which connects the display screen 194 and the application processor. The GPU is used to perform mathematical and geometric calculations for graphics rendering. The processor 110 may include one or more GPUs that execute program instructions to generate or change display information.
显示屏194用于显示图像,视频等。显示屏194包括显示面板。显示面板可以采用液晶显示屏(liquid crystal display,LCD),有机发光二极管(organic light-emittingdiode,OLED),有源矩阵有机发光二极体或主动矩阵有机发光二极体(active-matrixorganic light emitting diode的,AMOLED),柔性发光二极管(flex light-emittingdiode,FLED),Miniled,MicroLed,Micro-oled,量子点发光二极管(quantum dot lightemitting diodes,QLED)等。在一些实施例中,电子设备可以包括1个或N个显示屏194,N为大于1的正整数。The display screen 194 is used to display images, videos, etc. The display screen 194 includes a display panel. The display panel can be a liquid crystal display (LCD), an organic light-emitting diode (OLED), an active-matrix organic light-emitting diode or an active-matrix organic light-emitting diode (AMOLED), a flexible light-emitting diode (FLED), Miniled, MicroLed, Micro-oled, a quantum dot light-emitting diode (QLED), etc. In some embodiments, the electronic device may include 1 or N display screens 194, where N is a positive integer greater than 1.
电子设备的显示屏194上可以显示一系列图形用户界面(graphical userinterface,GUI),这些GUI都是该电子设备的主屏幕。一般来说,电子设备的显示屏194的尺寸是固定的,只能在该电子设备的显示屏194中显示有限的控件。控件是一种GUI元素,它是一种软件组件,包含在应用程序中,控制着该应用程序处理的所有数据以及关于这些数据的交互操作,用户可以通过直接操作(direct manipulation)来与控件交互,从而对应用程序的有关信息进行读取或者编辑。一般而言,控件可以包括图标、按钮、菜单、选项卡、文本框、对话框、状态栏、导航栏、Widget等可视的界面元素。在一些示例中,当电子设备所支持的功能不同时,电子设备所展示的功能控件会存在不同。A series of graphical user interfaces (GUIs) can be displayed on the display screen 194 of the electronic device, and these GUIs are the main screens of the electronic device. Generally speaking, the size of the display screen 194 of the electronic device is fixed, and only limited controls can be displayed on the display screen 194 of the electronic device. A control is a GUI element, which is a software component included in an application program, and controls all data processed by the application program and interactive operations on these data. Users can interact with the control through direct manipulation to read or edit relevant information of the application program. Generally speaking, controls can include visual interface elements such as icons, buttons, menus, tabs, text boxes, dialog boxes, status bars, navigation bars, widgets, etc. In some examples, when the functions supported by the electronic device are different, the functional controls displayed by the electronic device will be different.
内部存储器121可以用于存储计算机可执行程序代码,所述可执行程序代码包括指令。处理器110通过运行存储在内部存储器121的指令,从而执行电子设备的各种功能应用以及数据处理。例如,在本实施例中,处理器110可以通过执行存储在内部存储器121中的指令,查询自身所支持的节点,然后在目标应用的相关界面,展示自身所支持的节点相对应的功能控件。内部存储器121可以包括存储程序区和存储数据区。其中,存储程序区可存储操作系统,至少一个功能所需的应用程序(比如声音播放功能,图像播放功能等)等。存储数据区可存储电子设备使用过程中所创建的数据(比如音频数据,电话本等)等。此外,内部存储器121可以包括高速随机存取存储器,还可以包括非易失性存储器,例如至少一个磁盘存储器件,闪存器件,通用闪存存储器(universal flash storage,UFS)等。处理器110通过运行存储在内部存储器121的指令,和/或存储在设置于处理器中的存储器的指令,执行电子设备的各种功能应用以及数据处理。The internal memory 121 can be used to store computer executable program codes, which include instructions. The processor 110 executes various functional applications and data processing of the electronic device by running the instructions stored in the internal memory 121. For example, in this embodiment, the processor 110 can query the nodes supported by itself by executing the instructions stored in the internal memory 121, and then display the functional controls corresponding to the nodes supported by itself in the relevant interface of the target application. The internal memory 121 may include a storage program area and a storage data area. Among them, the storage program area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.). The storage data area may store data created during the use of the electronic device (such as audio data, a phone book, etc.). In addition, the internal memory 121 may include a high-speed random access memory, and may also include a non-volatile memory, such as at least one disk storage device, a flash memory device, a universal flash storage (UFS), etc. The processor 110 executes various functional applications and data processing of the electronic device by running the instructions stored in the internal memory 121, and/or the instructions stored in the memory provided in the processor.
另外,在上述部件之上,运行有操作系统。例如苹果公司所开发的iOS操作系统,谷歌公司所开发的Android开源操作系统,微软公司所开发的Windows操作系统等。在该操作系统上可以安装运行应用程序。In addition, an operating system is running on the above components, such as the iOS operating system developed by Apple, the Android open source operating system developed by Google, and the Windows operating system developed by Microsoft. Application programs can be installed and run on the operating system.
电子设备的操作系统可以采用分层架构,事件驱动架构,微核架构,微服务架构,或云架构。本申请实施例以分层架构的Android系统为例,示例性说明电子设备的软件结构。The operating system of the electronic device may adopt a layered architecture, an event-driven architecture, a micro-core architecture, a micro-service architecture, or a cloud architecture. The embodiment of the present application takes the Android system of the layered architecture as an example to exemplify the software structure of the electronic device.
参见图2,该图为本申请实施例提供的一种电子设备的软件结构示意图。本申请实施例以分层架构的Android系统为例,示例性说明电子设备100的软件结构。See Fig. 2, which is a schematic diagram of the software structure of an electronic device provided in an embodiment of the present application. The present application embodiment takes the Android system with a layered architecture as an example to exemplarily illustrate the software structure of the electronic device 100.
分层架构将软件分成若干个层,每一层都有清晰的角色和分工。层与层之间通过软件接口通信。在一些实施例中,将Android系统分为四层,从上至下分别为应用层(Applications,APP)、框架层(Framework,FWK)、硬件抽象层(Hardware AbstractionLayer,HAL)和内核层(Kernel)。The layered architecture divides the software into several layers, each with clear roles and division of labor. The layers communicate with each other through software interfaces. In some embodiments, the Android system is divided into four layers, from top to bottom: application layer (Applications, APP), framework layer (Framework, FWK), hardware abstraction layer (HAL) and kernel layer (Kernel).
其中,应用程序层可以包括一系列应用程序包。在一些实施例中,应用程序层可以包括视频编辑,预览播放器等应用程序。框架层为应用层的应用程序提供应用编程接口(application programming interface,API)和编程框架,在该框架层可以包括一些预先定义的函数。在一些实施例中,框架层可以包括媒体中台后处理框架(HnMediaGraph)等,媒体中台后处理框架又可以包括管理模块、图生成模块、管线模块、节点构建模块等。媒体中台后处理框架是指集成了多种针对媒体数据处理功能的框架,不同的功能可以通过不同的节点体现,也就是说,不同的节点,所体现的功能不同。在一些示例中,不同的电子设备,媒体中台后处理框架的节点能力不同。应用层的应用可以通过媒体中台后处理框架进行查询电子设备所支持的能力,并对相关的能力进行调用,从而实现各种各样的功能,例如,视频剪辑、拍摄图像等。硬件抽象层定义硬件“驱动”的接口,降低安卓操作系统与硬件的耦合度。在一些实施例中,硬件抽象层可以包括滤镜算法、动画算法、文字算法等。内核层负责管理系统的进程、内存、设备驱动程序、文件和网络系统,决定着系统的性能和稳定性。Among them, the application layer may include a series of application packages. In some embodiments, the application layer may include applications such as video editing and preview players. The framework layer provides an application programming interface (API) and a programming framework for the application layer, and the framework layer may include some predefined functions. In some embodiments, the framework layer may include a media middle station post-processing framework (HnMediaGraph), etc., and the media middle station post-processing framework may include a management module, a graph generation module, a pipeline module, a node construction module, etc. The media middle station post-processing framework refers to a framework that integrates a variety of media data processing functions. Different functions can be embodied through different nodes, that is, different nodes have different functions. In some examples, different electronic devices have different node capabilities of the media middle station post-processing framework. The application layer application can query the capabilities supported by the electronic device through the media middle station post-processing framework, and call the relevant capabilities to achieve a variety of functions, such as video editing, shooting images, etc. The hardware abstraction layer defines the interface of the hardware "driver" to reduce the coupling degree between the Android operating system and the hardware. In some embodiments, the hardware abstraction layer may include filter algorithms, animation algorithms, text algorithms, etc. The kernel layer is responsible for managing the system's processes, memory, device drivers, files, and network systems, and determines the system's performance and stability.
在一些实施例中,用户打开应用程序视频编辑APP后,可以在视频编辑APP上基于后处理管理模块中的管线(pipeline)增删滤镜效果,根据辅助滤镜算法操作增删滤镜效果后,再将该视频帧数据传送至视频编辑APP的预览播放器中。In some embodiments, after the user opens the application video editing APP, the user can add or delete filter effects based on the pipeline in the post-processing management module on the video editing APP, and after adding or deleting filter effects according to the auxiliary filter algorithm, the video frame data is transmitted to the preview player of the video editing APP.
需要说明的是,本申请实施例虽然以Android系统为例进行说明,但是其基本原理同样适用于基于iOS、Windows等操作系统的电子设备100。It should be noted that although the embodiment of the present application is described using the Android system as an example, its basic principles are also applicable to electronic devices 100 based on operating systems such as iOS and Windows.
参见图3,该图为本申请实施例提供的一种电子设备的桌面示意图。该场景中包括电子设备100,以电子设备100为智能手机为例进行说明,电子设备100可以呈现人机交互界面。用户为电子设备100解锁后,电子设备100可以向用户呈现桌面300。该桌面300可以包括多种应用程序的图标,例如,相机的图标301、图库的图标302、音乐的图标等。用户可以利用手指或触控笔等多种方式对应用的图标进行触控操作,对于触控操作的方式,本申请不做限定。Refer to Figure 3, which is a schematic diagram of the desktop of an electronic device provided in an embodiment of the present application. The scene includes an electronic device 100, and the electronic device 100 is described as a smart phone. The electronic device 100 can present a human-computer interaction interface. After the user unlocks the electronic device 100, the electronic device 100 can present a desktop 300 to the user. The desktop 300 may include icons of multiple applications, for example, a camera icon 301, a gallery icon 302, a music icon, and the like. The user can use a finger or a stylus to perform touch operations on the application icons in a variety of ways, and the present application does not limit the touch operation method.
在一些实施例中,当用户点击桌面300中相机的图标301后,电子设备100可以向用户呈现相机页面400。参见图4,该图为本申请实施例提供的一种电子设备的相机页面示意图。该相机页面400包括图库按键401、镜头翻转按键、拍摄按键等。用户可以点击相机页面400中的图库按键401,进入图库页面500。参见图5,该图为本申请实施例提供的一种电子设备的图库页面示意图。该图库页面500包括编辑按键501、收藏按键、分享按键等。用户可以进一步点击编辑按键501,进入编辑页面600。参见图6,该图为本申请实施例提供的一种电子设备的编辑页面示意图。该编辑页面600包括文字按键、滤镜按键、调节按键、更多按键等,其中,滤镜按键中还可以包括原图按键、晨光按键、黄昏按键、光晕按键、童年按键等,通过对按键的点击可以对图片或视频进行编辑增加或删除等操作。In some embodiments, when the user clicks the camera icon 301 in the desktop 300, the electronic device 100 can present a camera page 400 to the user. Referring to FIG. 4, the figure is a schematic diagram of a camera page of an electronic device provided in an embodiment of the present application. The camera page 400 includes a gallery button 401, a lens flip button, a shooting button, etc. The user can click the gallery button 401 in the camera page 400 to enter the gallery page 500. Referring to FIG. 5, the figure is a schematic diagram of a gallery page of an electronic device provided in an embodiment of the present application. The gallery page 500 includes an edit button 501, a favorite button, a share button, etc. The user can further click the edit button 501 to enter the edit page 600. Referring to FIG. 6, the figure is a schematic diagram of an edit page of an electronic device provided in an embodiment of the present application. The edit page 600 includes a text button, a filter button, an adjustment button, a more button, etc., wherein the filter button can also include an original picture button, a morning light button, a dusk button, a halo button, a childhood button, etc., and by clicking on the button, operations such as editing, adding or deleting pictures or videos can be performed.
在另一些实施例中,用户还可以点击桌面300中的图库图标302。在电子设备100向用户呈现图库页面后,用户可以点击需要进行编辑的图片或视频并对其进行编辑操作。需要说明的是,对于选取待编辑视频的方法,本申请不做限定。In other embodiments, the user can also click on the gallery icon 302 in the desktop 300. After the electronic device 100 presents the gallery page to the user, the user can click on the picture or video to be edited and perform an editing operation on it. It should be noted that the present application does not limit the method for selecting the video to be edited.
参见图7,该图为本申请实施例提供的一种节点管理方法的时序图。该方法包括:See Figure 7, which is a timing diagram of a node management method provided in an embodiment of the present application. The method includes:
S701:电子设备启动目标应用。S701: The electronic device starts a target application.
目标应用可以是上述应用层中的任一个应用,例如可以是图库应用,也可以是相机应用,该目标应用可以对照片或视频起到编辑效果。需要说明的是,除编辑应用外,还可以是其他应用,例如游戏应用等。对于具体的应用,本申请不做限定。为了便于理解,下文以电子设备为手机、目标应用为图库应用为例,对本申请的技术方案进行介绍。The target application can be any application in the above application layer, for example, it can be a gallery application or a camera application, and the target application can edit photos or videos. It should be noted that in addition to editing applications, it can also be other applications, such as game applications. This application does not limit the specific application. For ease of understanding, the following takes the electronic device as a mobile phone and the target application as a gallery application as an example to introduce the technical solution of this application.
在一些具体的实施方式中,电子设备可以接收用户对主界面中目标应用的图标的触摸操作,启动目标应用。手机的触摸传感器180K可以接收到用户在手机主界面中目标应用的图标的触摸操作,并上报给处理器110,处理器110可以响应于该触摸操作,在显示屏194中显示该目标应用的用户界面。此外,本申请实施例中还可以通过其它方式使得手机启动图库应用,并在显示屏194上图库应用的用户界面。例如,手机处于黑屏、锁屏或者某一应用的用户界面时,处理器110可以响应于用户的语音指令或者快捷操作等,启动图库应用,并在显示屏194中显示图库应用的用户界面。In some specific implementations, the electronic device can receive a user's touch operation on the icon of the target application in the main interface and start the target application. The touch sensor 180K of the mobile phone can receive the user's touch operation on the icon of the target application in the main interface of the mobile phone and report it to the processor 110. The processor 110 can respond to the touch operation and display the user interface of the target application on the display screen 194. In addition, in the embodiment of the present application, other methods can be used to enable the mobile phone to start the gallery application and display the user interface of the gallery application on the display screen 194. For example, when the mobile phone is in a black screen, a lock screen, or the user interface of a certain application, the processor 110 can respond to the user's voice command or shortcut operation, etc., to start the gallery application and display the user interface of the gallery application on the display screen 194.
S702:目标应用向后处理管理模块发送版本查询指令。S702: The target application sends a version query instruction to the post-processing management module.
版本查询指令用于查询电子设备的媒体中台后处理框架的当前版本号,通过媒体中台后处理框架的当前版本的版本号可以进一步查询该版本所支持的节点的能力。节点是指电子设备所支持的功能或者是电子设备所具有的能力。例如若电子设备支持滤镜功能,则在电子设备中存在与滤镜功能对应的滤镜节点,若电子设备不支持滤镜功能,则在电子设备中不存在与滤镜功能对应的滤镜节点。也就是说,目标应用可以通过接口查询电子设备的媒体中台后处理框架的版本号,进而查询该版本的媒体中台后处理框架所支持的当前可用的媒体节点,以及节点可以支持的媒体能力描述,从而进一步使得用户体验这些不同的能力。由此,通过设置不同电子设备的媒体中台后处理框架的版本号的方式,可以确保向前兼容,增加版本标识,以便于后续接口的扩展。The version query instruction is used to query the current version number of the media middle station post-processing framework of the electronic device. The capabilities of the nodes supported by the version number of the current version of the media middle station post-processing framework can be further queried. A node refers to a function supported by an electronic device or a capability possessed by an electronic device. For example, if the electronic device supports a filter function, a filter node corresponding to the filter function exists in the electronic device. If the electronic device does not support the filter function, a filter node corresponding to the filter function does not exist in the electronic device. In other words, the target application can query the version number of the media middle station post-processing framework of the electronic device through the interface, and then query the currently available media nodes supported by the version of the media middle station post-processing framework, as well as the media capability description that the node can support, thereby further allowing the user to experience these different capabilities. Therefore, by setting the version number of the media middle station post-processing framework of different electronic devices, forward compatibility can be ensured, and version identification can be added to facilitate subsequent interface expansion.
需要说明的是,以上仅仅是以版本号为例进行查询,在其他实施例中,还可以是其他能够用于唯一表示版本的标识,例如编号等。It should be noted that the above query is only performed using the version number as an example. In other embodiments, it may be other identifiers that can be used to uniquely indicate the version, such as a serial number.
在一些具体的实施方式中,在目标应用即图库启动后,图库会向后处理管理模块发送版本查询指令,通过当前版本的版本号可以进一步查询该版本所支持的节点的能力。In some specific implementations, after the target application, ie, the gallery, is started, the gallery will send a version query instruction to the post-processing management module, and the capabilities of the nodes supported by the version can be further queried through the version number of the current version.
S703:后处理管理模块查询版本号。S703: The post-processing management module queries the version number.
后处理管理模块接收到目标应用发出的版本查询指令后,可以查询当前媒体中台后处理框架的版本的版本号,进而查询该媒体中台后处理框架的版本所支持的节点的能力。After receiving the version query instruction issued by the target application, the post-processing management module can query the version number of the current media middle station post-processing framework, and then query the capabilities of the nodes supported by the version of the media middle station post-processing framework.
需要说明的是,当后处理管理模块查询该媒体中台后处理框架的版本所支持的节点的能力时,需要首先加载节点能力的配置文件(例如XML文件)。该配置文件中至少包括节点名称、节点的插件库路径等字段信息。在配置文件加载时,后处理管理模块可以通过对该配置文件进行节点能力的解析,从而生成合适的数据结构并进行缓存,以用于业务的查询。It should be noted that when the post-processing management module queries the capabilities of the nodes supported by the version of the post-processing framework of the media center, it is necessary to first load the configuration file (such as an XML file) of the node capabilities. The configuration file includes at least field information such as the node name and the node's plug-in library path. When the configuration file is loaded, the post-processing management module can parse the node capabilities of the configuration file to generate a suitable data structure and cache it for business queries.
可以理解的是,当配置文件支持某一节点能力时,则表明电子设备支持该节点对应的功能;当配置文件不支持某一节点能力时,则表明电子设备不支持该节点对应的功能。It is understandable that when the configuration file supports a certain node capability, it indicates that the electronic device supports the function corresponding to the node; when the configuration file does not support a certain node capability, it indicates that the electronic device does not support the function corresponding to the node.
S704:后处理管理模块向目标应用返回版本号。S704: The post-processing management module returns the version number to the target application.
当后处理管理模块查询到当前版本的版本号后,向目标应用返回版本号。在一种可能的实施方式中,后处理管理模块将“版本号1”这一版本号返回至目标应用。After the post-processing management module queries the version number of the current version, it returns the version number to the target application. In a possible implementation, the post-processing management module returns the version number "version number 1" to the target application.
S705:后处理管理模块对当前版本号对应的节点的配置文件进行解析。S705: The post-processing management module parses the configuration file of the node corresponding to the current version number.
配置文件中携带有节点的节点名称、节点的插件库路径等信息,后处理管理模块获取到节点的配置文件后,可以对该配置文件进行节点能力的解析,进而得到节点名称以及插件库路径。在一种具体的实施方式中,后处理管理模块可以对滤镜节点的配置文件进行节点能力的解析,得到滤镜节点的节点名称和滤镜节点的插件库路径。The configuration file carries information such as the node name of the node, the node's plug-in library path, etc. After the post-processing management module obtains the node configuration file, it can parse the configuration file for node capabilities to obtain the node name and the plug-in library path. In a specific implementation, the post-processing management module can parse the configuration file of the filter node for node capabilities to obtain the node name of the filter node and the plug-in library path of the filter node.
在一些示例中,滤镜节点的节点名称可以包括滤镜1(晨光)、滤镜2(黄昏)和滤镜3(光晕),插件库路径可以包括滤镜1插件库路径、滤镜2插件库路径以及滤镜3插件库路径。滤镜1插件库路径、滤镜2地插件库路径以及滤镜3插件库路径可以相同,也可以不同。通过滤镜节点的节点名称可知,电子设备可能支持上述晨光、黄昏和光晕等滤镜功能。In some examples, the node names of the filter nodes may include filter 1 (morning light), filter 2 (dusk), and filter 3 (halo), and the plug-in library path may include filter 1 plug-in library path, filter 2 plug-in library path, and filter 3 plug-in library path. The filter 1 plug-in library path, the filter 2 plug-in library path, and the filter 3 plug-in library path may be the same or different. It can be seen from the node names of the filter nodes that the electronic device may support the above-mentioned filter functions such as morning light, dusk, and halo.
S706:后处理管理模块获取节点的插件库。S706: The post-processing management module obtains the plug-in library of the node.
后处理管理模块完成对配置文件的节点能力的解析后,即可获取节点名称以及节点的插件库路径,并基于上述插件库路径获取插件库。After the post-processing management module completes parsing of the node capabilities of the configuration file, it can obtain the node name and the plug-in library path of the node, and obtain the plug-in library based on the plug-in library path.
在一种具体的实施方式中,以节点名称为晨光,插件库路径为晨光插件库路径为例,后处理管理模块能够基于该晨光插件库路径,得到晨光插件库。In a specific implementation, taking the node name as Chenguang and the plug-in library path as the Chenguang plug-in library path as an example, the post-processing management module can obtain the Chenguang plug-in library based on the Chenguang plug-in library path.
S707:后处理管理模块对节点的插件库进行加载并解析。S707: The post-processing management module loads and parses the plug-in library of the node.
加载是指将插件库加载到目标应用的进程中,后处理管理模块可以将节点的插件库进行加载,加载到目标应用的进程中。Loading refers to loading the plug-in library into the process of the target application. The post-processing management module can load the plug-in library of the node into the process of the target application.
解析是指对节点的插件库进行解析,以获取到查询节点是否存在的接口,例如可以是createMediaNodeByName(std::stringnodeName)。后处理管理模块可以对插件库进行解析,以获取到查询节点是否存在的接口。接着,后处理管理模块可以向该查询节点是否存在的接口传入目标节点的节点名称,以在该插件库中查询是否存在该目标节点。Parsing refers to parsing the node's plug-in library to obtain an interface to query whether the node exists, such as createMediaNodeByName(std::stringnodeName). The post-processing management module can parse the plug-in library to obtain an interface to query whether the node exists. Then, the post-processing management module can pass the node name of the target node to the interface to query whether the node exists, so as to query whether the target node exists in the plug-in library.
在一些实施例中,后处理管理模块对插件库进行解析后,可以得到节点查询函数,该节点查询函数用于查询插件库中是否存在相应节点,例如可以调用该节点查询函数,将节点的节点名称在节点的插件库中对节点进行查询,进而得到插件库是否包括节点的查询结果。需要说明的是,上述用于查询节点是否存在的接口可以是节点查询函数的一种具体形式。In some embodiments, after the post-processing management module parses the plug-in library, a node query function can be obtained, and the node query function is used to query whether a corresponding node exists in the plug-in library. For example, the node query function can be called to query the node in the plug-in library of the node with the node name, and then obtain a query result of whether the plug-in library includes the node. It should be noted that the above interface for querying whether a node exists can be a specific form of the node query function.
在查询过程中,插件库中维护有包括多个节点的集合,将节点名称传入到该插件库的接口后,将该节点名称与集合中的节点名称进行比对。若集合中存在该节点名称,则表明该插件库中包括该节点,也即电子设备支持该节点所对应的功能;若集合中不存在该节点名称,则表明该插件库中不包括该节点,也即电子设备不支持该节点所对应的功能。During the query process, a set including multiple nodes is maintained in the plug-in library. After the node name is passed to the interface of the plug-in library, the node name is compared with the node name in the set. If the node name exists in the set, it means that the plug-in library includes the node, that is, the electronic device supports the function corresponding to the node; if the node name does not exist in the set, it means that the plug-in library does not include the node, that is, the electronic device does not support the function corresponding to the node.
需要说明的是,查询过程中所比对的节点名称仅仅是举例介绍,本领域技术人员可以基于实际需要,选择合适的内容进行比对,以确定插件库中是否包括目标节点。It should be noted that the node names compared during the query process are only examples, and those skilled in the art can select appropriate content for comparison based on actual needs to determine whether the target node is included in the plug-in library.
在一些示例中,后处理管理模块可以将晨光插件库加载到图库的进程中,然后对晨光插件库进行解析,得到该晨光插件库的用于查询节点是否存在的接口。在得到该晨光插件库的用于查询节点是否存在的接口后,后处理管理模块将上述节点名称如晨光传给用于查询节点是否存在的接口,然后得到晨光插件库中是否存在该晨光节点的结果。In some examples, the post-processing management module can load the Chenguang plug-in library into the process of the library, and then parse the Chenguang plug-in library to obtain the interface of the Chenguang plug-in library for querying whether a node exists. After obtaining the interface of the Chenguang plug-in library for querying whether a node exists, the post-processing management module passes the above node name such as Chenguang to the interface for querying whether a node exists, and then obtains the result of whether the Chenguang node exists in the Chenguang plug-in library.
在另一些示例中,后处理管理模块可以将黄昏插件库加载到图库的进程中,然后对黄昏插件库进行解析,得到该黄昏插件库的用于查询节点是否存在的接口。在得到该黄昏插件库的用于查询节点是否存在的接口后,后处理管理模块将上述节点名称如黄昏传给用于查询节点是否存在的接口,然后得到黄昏插件库中是否存在该黄昏节点的结果。In other examples, the post-processing management module can load the dusk plug-in library into the process of the library, and then parse the dusk plug-in library to obtain the interface of the dusk plug-in library for querying whether a node exists. After obtaining the interface of the dusk plug-in library for querying whether a node exists, the post-processing management module passes the above node name such as dusk to the interface for querying whether a node exists, and then obtains the result of whether the dusk node exists in the dusk plug-in library.
其中,上述晨光插件库和黄昏插件库可以是同一个插件库,即晨光插件库的路径与黄昏插件库的路径相同,当然,上述晨光插件库和黄昏插件库也可以是不同的插件库,即晨光插件库的路径与黄昏插件库的路径不相同。Among them, the above-mentioned Morning Light plug-in library and Dusk plug-in library can be the same plug-in library, that is, the path of the Morning Light plug-in library is the same as the path of the Dusk plug-in library. Of course, the above-mentioned Morning Light plug-in library and Dusk plug-in library can also be different plug-in libraries, that is, the path of the Morning Light plug-in library is different from the path of the Dusk plug-in library.
后处理管理模块在得到插件库中是否存在节点的结果后,可以将插件库中存在的节点记录在节点能力信息表中。在一些示例中,节点能力信息表可以如下表1所示:After obtaining the result of whether the node exists in the plug-in library, the post-processing management module can record the nodes existing in the plug-in library in the node capability information table. In some examples, the node capability information table can be shown in Table 1 below:
S708:后处理管理模块判断当前版本号对应的节点中是否包含所需节点。S708: The post-processing management module determines whether the nodes corresponding to the current version number include the required nodes.
所需节点,指目标应用提供的、可以达成一定效果的节点。例如,文字节点、动画节点等均可以是所需节点。由于现有技术中,存在某些应用具有特殊的功能,但电子设备并不支持该特殊的功能的问题,即电子设备无法与目标应用适配,因此,后处理管理模块可以先判断当前框架的版本号对应的节点中是否包含所需节点。Required nodes refer to nodes provided by the target application that can achieve a certain effect. For example, text nodes, animation nodes, etc. can all be required nodes. In the prior art, there is a problem that some applications have special functions, but the electronic device does not support the special functions, that is, the electronic device cannot adapt to the target application. Therefore, the post-processing management module can first determine whether the nodes corresponding to the version number of the current framework contain the required nodes.
由于后处理管理模块已经完成了对当前版本号对应的节点的配置文件的解析,因此,后处理管理模块已经得到了当前版本号对应的节点的节点名称以及插件库。在一种具体的实施方式中,可以通过调用节点查询函数,将节点名称在节点的插件库中对节点进行查询,进而得到插件库是否包括节点的查询结果。Since the post-processing management module has completed the parsing of the configuration file of the node corresponding to the current version number, the post-processing management module has obtained the node name and the plug-in library of the node corresponding to the current version number. In a specific implementation, the node name can be queried in the plug-in library of the node by calling the node query function, and then the query result of whether the plug-in library includes the node can be obtained.
倘若后处理管理模块判断当前版本号对应的节点中未包含所需节点,则执行S709及后续操作。倘若后处理管理模块判断当前版本号对应的节点中已包含所需节点,则继续判断当前版本号对应的节点中是否包含下一个所需节点。If the post-processing management module determines that the node corresponding to the current version number does not contain the required node, S709 and subsequent operations are executed. If the post-processing management module determines that the node corresponding to the current version number already contains the required node, it continues to determine whether the node corresponding to the current version number contains the next required node.
S709:后处理管理模块新增自定义节点。S709: Add a custom node to the post-processing management module.
新增自定义节点,即扩展当前版本号对应的节点中不包含的所需节点。后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。Adding a custom node means expanding the required nodes that are not included in the nodes corresponding to the current version number. The post-processing management module can add a custom node and display the function controls corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide users with the customization capability of the target application.
在一种具体的实施方式中,目标应用要提供在视频文件中插入文字的功能时,而电子设备的媒体中台后处理框架并不支持该在视频文件中插入文字的功能,则后处理管理模块可以新增文字节点作为自定义节点,以定制满足需求的文字定制能力。为了便于理解,下文以自定义节点为文字节点展开说明。In a specific implementation, when the target application needs to provide a function of inserting text into a video file, and the media middle platform post-processing framework of the electronic device does not support the function of inserting text into a video file, the post-processing management module can add a text node as a custom node to customize the text customization capability that meets the requirements. For ease of understanding, the following description will be based on the custom node as the text node.
在一些实例中,后处理管理模块可以通过将目标节点的配置信息,写入到节点配置模板中对应的字段,从而生成目标节点的配置文件,以完成对目标节点的配置。该节点配置模板中,可以包括节点标识字段、节点所在插件路径字段、节点支持能力名称字段、节点支持能力参数字段、节点输入数据类型字段、节点输出数据类型字段、节点约束条件字段、节点开放信息字段等字段。该配置信息可以是待写入上述字段的字段值。具体的,节点配置模板可以如下所示:In some instances, the post-processing management module can generate a configuration file for the target node by writing the configuration information of the target node into the corresponding field in the node configuration template to complete the configuration of the target node. The node configuration template may include fields such as the node identification field, the node plug-in path field, the node support capability name field, the node support capability parameter field, the node input data type field, the node output data type field, the node constraint condition field, and the node open information field. The configuration information may be the field value to be written into the above fields. Specifically, the node configuration template may be as follows:
<?xmlverson=“1.0”encoding=“utf-8”?><? xmlverson="1.0"encoding="utf-8"? >
<MediaNodes><MediaNodes>
<!--节点配置属性--><!--Node Configuration Properties-->
<!--name,节点名称和标识--><!--name, node name and ID -->
<!--path,节点所在插件路径--><! --path, the plugin path where the node is located -->
<Nodename=“xxx”,path=“xxx/xx/xx.so”><Nodename="xxx", path="xxx/xx/xx.so">
<!--节点支持的能力,可以设置的参数,以及参数取值--><! --Capabilities supported by the node, parameters that can be set, and parameter values -->
<Capsname=“xxx”value=“xxx”/><Capsname="xxx"value="xxx"/>
<Capsname=“xxx”value=“xxx”/><Capsname="xxx"value="xxx"/>
<!--节点输入和数据类型,支持多个--><!--Node input and data type, supports multiple -->
<Inputname=“xxx”type=“xxx”/><Input name="xxx" type="xxx"/>
<!--节点输出和数据类型,支持多个--><!--Node output and data type, supports multiple -->
<Outputname=“xxx”type=“xxx”/><Outputname="xxx"type="xxx"/>
<!--使用约束,节点对平台的依赖,对应用不可见--><! -- Usage constraints, node dependence on the platform, invisible to the application -->
<Limitname=“deps”value=“system|chip”/><Limitname="deps"value="system|chip"/>
<!--是否对外部开放--><! --Is it open to the outside world? -->
<Limitname=“opens”value=“true|false”/><Limitname="opens"value="true|false"/>
</Node></Node>
<Nodename=“xxx”><Nodename="xxx">
<!--节点属性和能力--><!--Node attributes and capabilities-->
</Node></Node>
<MediaNodes><MediaNodes>
需要说明的是,还可以有其他形式的节点配置模板,对于具体的节点配置模板内容,本申请不做限定。It should be noted that there may be other forms of node configuration templates, and this application does not limit the specific content of the node configuration templates.
S710:后处理管理模块加载自定义节点的配置文件。S710: The post-processing management module loads the configuration file of the custom node.
与S703类似的,后处理管理模块可以加载自定义节点的配置文件(例如XML文件)。该配置文件中至少包括节点名称、节点的插件库路径等字段信息。在配置文件加载时,后处理管理模块可以通过对该配置文件进行节点能力的解析,从而生成合适的数据结构并进行缓存,以用于业务的查询。Similar to S703, the post-processing management module can load a configuration file (e.g., an XML file) of a custom node. The configuration file includes at least field information such as the node name and the node's plug-in library path. When the configuration file is loaded, the post-processing management module can parse the configuration file for node capabilities, thereby generating a suitable data structure and caching it for business queries.
S711:后处理管理模块对自定义节点的配置文件进行解析。S711: The post-processing management module parses the configuration file of the custom node.
与S705类似的,自定义节点的配置文件中携带有自定义节点的节点名称、自定义节点的插件库路径等信息。后处理管理模块获取到自定义节点的配置文件后,可以对该配置文件进行节点能力的解析,进而得到自定义节点名称以及插件库路径。Similar to S705, the configuration file of the custom node carries information such as the node name of the custom node, the plug-in library path of the custom node, etc. After the post-processing management module obtains the configuration file of the custom node, it can parse the configuration file for node capabilities to obtain the custom node name and the plug-in library path.
在一些示例中,自定义节点的节点名称可以包括文字1(宋体)和文字2(楷体)等,插件库路径可以包括文字1插件库路径以及文字2插件库路径。文字1插件库路径、文字2地插件库路径可以相同,也可以不同。通过文字节点的节点名称可知,电子设备可能支持上述宋体、楷体等文字功能。In some examples, the node name of the custom node may include text 1 (Songti) and text 2 (Kaiti), etc., and the plug-in library path may include text 1 plug-in library path and text 2 plug-in library path. The text 1 plug-in library path and the text 2 plug-in library path may be the same or different. It can be known from the node name of the text node that the electronic device may support the above-mentioned text functions such as Songti and Kaiti.
S712:后处理管理模块获取自定义节点的插件库。S712: The post-processing management module obtains a plug-in library of the custom node.
与S706类似的,后处理管理模块完成对自定义节点的配置文件的节点能力的解析后,即可获取自定义节点名称以及自定义节点的插件库路径,并基于上述插件库路径获取插件库。Similar to S706, after the post-processing management module completes parsing the node capability of the configuration file of the custom node, it can obtain the custom node name and the plug-in library path of the custom node, and obtain the plug-in library based on the plug-in library path.
在一种具体的实施方式中,以节点名称为宋体,插件库路径为宋体插件库路径为例,后处理管理模块能够基于该宋体插件库路径,得到宋体插件库。In a specific implementation, taking the node name as Songti and the plug-in library path as the Songti plug-in library path as an example, the post-processing management module can obtain the Songti plug-in library based on the Songti plug-in library path.
S713:后处理管理模块对自定义节点的插件库进行加载。S713: The post-processing management module loads the plug-in library of the custom node.
后处理管理模块可以将自定义节点的插件库进行加载,加载到目标应用的进程中,从而生成对应的节点信息和能力。The post-processing management module can load the plug-in library of the custom node into the process of the target application, thereby generating the corresponding node information and capabilities.
由此,若应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。Therefore, if the special functions of the application are not supported by the electronic device, the post-processing management module of the electronic device can add a custom node and display the function controls corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide users with customization capabilities of the target application.
S714:目标应用获取待处理的文件,以及编辑页面的效果的选择操作。S714: The target application obtains the file to be processed and a selection operation of the effect of the editing page.
用户选取的待处理文件可以是图片文件,也可以是视频文件。电子设备100可以通过获取用户选取的待处理的文件在电子设备100中的存储位置,获取用户选取的待处理的文件。为了便于理解,下文将以待处理文件为视频文件展开说明。The file to be processed selected by the user may be a picture file or a video file. The electronic device 100 may obtain the file to be processed selected by the user by obtaining the storage location of the file to be processed selected by the user in the electronic device 100. For ease of understanding, the following description will be based on the file to be processed being a video file.
电子设备100的目标应用可以获取用户选择的待加入至待处理文件的效果。具体的,用户进入电子设备100所展示的编辑界面。该编辑页面包括文字、滤镜、调节等效果。此时的编辑界面已经显示自定义能力,即文字效果。为了便于理解,下文将以选择的效果为滤镜效果及文字效果展开说明。The target application of the electronic device 100 can obtain the effect selected by the user to be added to the file to be processed. Specifically, the user enters the editing interface displayed by the electronic device 100. The editing page includes effects such as text, filters, and adjustments. At this time, the editing interface has displayed the customization capability, that is, the text effect. For ease of understanding, the following will be explained with the selected effects as filter effects and text effects.
在一些实施例中,用户可以点击滤镜按键,并选择滤镜种类,如晨光、黄昏、光晕等滤镜,从而将滤镜效果添加进相应的图片或视频中。在另一些实施例中,用户可以点击文字按键,从而在图片或视频文件中添加文字效果;在另一些实施例中,用户可以点击调节按键,从而调节该图片或视频的显示参数。In some embodiments, the user can click on the filter button and select the filter type, such as morning light, dusk, halo, etc., to add the filter effect to the corresponding picture or video. In other embodiments, the user can click on the text button to add text effects to the picture or video file; in other embodiments, the user can click on the adjustment button to adjust the display parameters of the picture or video.
S715:目标应用向后处理管理模块调用版本号接口。S715: The target application calls the version number interface to the post-processing management module.
目标应用在拿到后处理管理模块的版本号之后,会调用该版本支持的后处理接口。在一种可能的实施方式中,若S704中,后处理管理模块将“版本号1”这一版本号返回至目标应用,则目标应用向后处理管理模块调用的版本号接口为版本号1的接口。After obtaining the version number of the post-processing management module, the target application will call the post-processing interface supported by the version. In a possible implementation, if in S704, the post-processing management module returns the version number "version 1" to the target application, the version number interface called by the target application to the post-processing management module is the interface of version 1.
S716:目标应用向后处理管线模块发送文件,并下发创建管线的指令。S716: The target application sends the file to the post-processing pipeline module and issues an instruction to create a pipeline.
管线是一种线性通信模型,可视作流水线。简单来说就是一套系统的综合解决方案,为获取结果提供一条龙服务。A pipeline is a linear communication model that can be viewed as an assembly line. In simple terms, it is a comprehensive solution for a system that provides a one-stop service for obtaining results.
在目标应用获取待处理的视频文件以及编辑页面的效果的选择操作后,目标应用将该视频文件发送至后处理管线模块,并下发创建视频分析管线的指令。After the target application obtains the video file to be processed and the selection operation of the effect of the editing page, the target application sends the video file to the post-processing pipeline module and issues an instruction to create a video analysis pipeline.
S717:后处理管线模块向后处理节点构建模块发送构建解码节点的指令。S717: The post-processing pipeline module sends an instruction to construct a decoding node to the post-processing node construction module.
解码节点是用于实现解码的功能节点。解码是一种用特定方法,把数码还原成它所代表的内容或将电脉冲信号、光信号、无线电波等转换成它所代表的信息、数据等的过程。解码是受传者将接受到的符号或代码还原为信息的过程,与编码过程相对应。例如,在本申请中,解码节点可以将格式为H264格式的视频流、格式为ACC的音频流解码,并进一步构建视频流控制节点和音频流控制节点。The decoding node is a functional node used to implement decoding. Decoding is a process of using a specific method to restore digital data to the content it represents or convert electrical pulse signals, optical signals, radio waves, etc. into the information, data, etc. it represents. Decoding is the process by which the recipient restores the received symbols or codes to information, corresponding to the encoding process. For example, in this application, the decoding node can decode a video stream in the H264 format and an audio stream in the ACC format, and further construct a video stream control node and an audio stream control node.
当后处理管线模块接收到目标应用发出的创建管线的指令后,向后处理节点构建模块发送构建解码节点的指令。When the post-processing pipeline module receives the instruction to create a pipeline from the target application, it sends an instruction to construct a decoding node to the post-processing node construction module.
S718:后处理节点构建模块构建解码节点。S718: The post-processing node construction module constructs a decoding node.
后处理节点构建模块基于获取到的构建解码节点的指令,构建解码节点。需要说明的是,此处的构建指的是加载在内存中。The post-processing node construction module constructs the decoding node based on the acquired instruction for constructing the decoding node. It should be noted that the construction here refers to loading into the memory.
S719:后处理管线模块向后处理节点构建模块发送构建滤镜节点的指令。S719: The post-processing pipeline module sends an instruction to construct a filter node to the post-processing node construction module.
滤镜节点是用于添加滤镜的功能节点。在本申请中,例如滤镜节点可以是黄昏滤镜节点,通过构建黄昏滤镜节点,可以对视频文件添加黄昏滤镜,以使用户观看到添加了黄昏滤镜后的视频文件。The filter node is a functional node for adding a filter. In the present application, for example, the filter node may be a dusk filter node. By constructing the dusk filter node, a dusk filter may be added to a video file so that a user can watch the video file after the dusk filter is added.
当后处理管线模块接收到目标应用发出的创建管线的指令后,向后处理节点构建模块发送构建滤镜节点的指令。When the post-processing pipeline module receives the instruction to create a pipeline from the target application, it sends an instruction to construct a filter node to the post-processing node construction module.
S720:后处理节点构建模块构建滤镜节点。S720: The post-processing node construction module constructs a filter node.
后处理节点构建模块基于获取到的构建滤镜节点的指令,构建滤镜节点。需要说明的是,此处的构建指的是加载在内存中。The post-processing node construction module constructs the filter node based on the acquired instruction for constructing the filter node. It should be noted that the construction here refers to loading into the memory.
S721:后处理管线模块向后处理节点构建模块发送构建自定义节点的指令。S721: The post-processing pipeline module sends an instruction to construct a custom node to the post-processing node construction module.
当后处理管线模块接收到目标应用发出的创建管线的指令后,向后处理节点构建模块发送构建自定义节点的指令。在一些可能的实施方式中,若该应用具有在视频文件中添加文字的特殊功能,但电子设备并不支持该特殊的功能,则后处理管理模块可以新增文字节点作为自定义节点,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。此时,后处理管线模块向后处理节点构建模块发送构建自定义节点的指令为构建文字节点的指令。When the post-processing pipeline module receives the instruction to create a pipeline from the target application, it sends an instruction to build a custom node to the post-processing node construction module. In some possible implementations, if the application has a special function of adding text to a video file, but the electronic device does not support this special function, the post-processing management module can add a text node as a custom node to adapt the special function of the application to the electronic device and provide the user with the customization capability of the target application. At this time, the instruction to build a custom node sent by the post-processing pipeline module to the post-processing node construction module is an instruction to build a text node.
S722:后处理节点构建模块构建自定义节点。S722: The post-processing node construction module constructs a custom node.
后处理节点构建模块基于获取到的构建自定义节点的指令,构建自定义节点。需要说明的是,此处的构建指的是加载在内存中。The post-processing node construction module constructs the custom node based on the acquired instruction for constructing the custom node. It should be noted that the construction here refers to loading into the memory.
S723:后处理管线模块向后处理图生成模块发送构建管线的指令。S723: The post-processing pipeline module sends a pipeline construction instruction to the post-processing graph generation module.
在目标应用向后处理管线模块下发创建管线的指令后,后处理管线模块向后处理节点构建模块发送构建解码节点、滤镜节点、自定义节点的指令。当后处理节点构建模块构建完成解码节点、滤镜节点、自定义节点后,后处理管线模块向后处理图生成模块发送基于上述节点构建管线的指令。需要说明的是,构建的节点除解码节点、滤镜节点、自定义节点外,还可以包含其他节点,例如解封装节点、封装节点、动画节点等。对于具体的节点名称及其功能,本申请不做限定。After the target application sends an instruction to create a pipeline to the post-processing pipeline module, the post-processing pipeline module sends instructions to the post-processing node construction module to construct decoding nodes, filter nodes, and custom nodes. After the post-processing node construction module completes the construction of decoding nodes, filter nodes, and custom nodes, the post-processing pipeline module sends instructions to the post-processing graph generation module to build a pipeline based on the above nodes. It should be noted that in addition to decoding nodes, filter nodes, and custom nodes, the constructed nodes can also include other nodes, such as decapsulation nodes, encapsulation nodes, animation nodes, etc. This application does not limit the specific node names and their functions.
S724:后处理图生成模块构建管线。S724: The post-processing graph generation module constructs a pipeline.
后处理图生成模块可以基于解码节点、滤镜节点、自定义节点等节点等节点构建管线。参见图8,该图为本申请实施例提供的一种管线示意图。一个管线可以是视频文件顺序流向解码节点、文字A节点、滤镜B节点,从而使用户可以获取添加了文字A和滤镜B的视频文件。The post-processing graph generation module can construct a pipeline based on nodes such as decoding nodes, filter nodes, custom nodes, etc. See Figure 8, which is a schematic diagram of a pipeline provided by an embodiment of the present application. A pipeline can be a video file that flows sequentially to a decoding node, a text A node, and a filter B node, so that a user can obtain a video file with text A and filter B added.
在一些可能的实施方式中,在后处理图生成模块构建管线后,还可以对该管线进行参数的配置。在一些实施例中,可以在解码节点设置“解码为YUV格式”或“解码为RGB格式”。需要说明的是,不同节点的参数配置不同,对于参数的配置,本申请不做限定。In some possible implementations, after the post-processing graph generation module constructs the pipeline, the parameters of the pipeline can also be configured. In some embodiments, "decoding to YUV format" or "decoding to RGB format" can be set at the decoding node. It should be noted that the parameter configurations of different nodes are different, and this application does not limit the configuration of the parameters.
S725:后处理图生成模块将管线发送至后处理管线模块。S725: The post-processing graph generation module sends the pipeline to the post-processing pipeline module.
S726:后处理管线模块基于构建的管线运行文件。S726: The post-processing pipeline module runs the file based on the constructed pipeline.
后处理管线模块尝试运行启动构建的管线。在一些具体的实施方式中,可以在需要运行的管线的起始段点击start,从而运行该管线。通过运行该管线,对待处理视频进行处理,获得带有滤镜及文字效果的视频文件。The post-processing pipeline module attempts to run the pipeline that was started. In some specific implementations, you can click start at the beginning of the pipeline that needs to be run to run the pipeline. By running the pipeline, the video to be processed is processed to obtain a video file with filters and text effects.
需要说明的是,在启动管线后,可以通过变更节点能力,完成能力的重新配置。It should be noted that after starting the pipeline, the capacity can be reconfigured by changing the node capacity.
S727:后处理管线模块向目标应用发送文件。S727: The post-processing pipeline module sends the file to the target application.
后处理管线模块向电子设备100的目标应用输出带有效果的视频。此时,用户的电子设备100上即可预览到处理后得到的具有滤镜及文字效果的视频文件。The post-processing pipeline module outputs the video with effects to the target application of the electronic device 100. At this time, the user's electronic device 100 can preview the processed video file with filters and text effects.
本申请提供了一种节点管理方法,在该方法中,若应用的特殊功能是电子设备所不支持的,电子设备的后处理管理模块可以通过新增自定义节点,在该内置应用的相关界面展示与自定义节点相对应的功能控件,以使应用的特殊功能与电子设备适配,向用户提供目标应用的定制能力。The present application provides a node management method, in which, if the special functions of an application are not supported by an electronic device, a post-processing management module of the electronic device can add a custom node and display the function controls corresponding to the custom node in the relevant interface of the built-in application to adapt the special functions of the application to the electronic device and provide users with customization capabilities of the target application.
本申请实施例还提供一种计算机可读存储介质,所述计算机可读存储介质中存储有计算机程序或指令,当所述计算机程序或指令被运行时,实现上述方法实施例中电子设备100执行的各个功能或者步骤。An embodiment of the present application further provides a computer-readable storage medium, in which a computer program or instruction is stored. When the computer program or instruction is executed, each function or step performed by the electronic device 100 in the above method embodiment is implemented.
本申请另一实施例还提供了一种包含指令的计算机程序产品。当该计算机程序产品在计算机或处理器上运行时,使得计算机或处理器执行上述任一个方法中的一个或多个步骤。Another embodiment of the present application further provides a computer program product including instructions. When the computer program product is run on a computer or a processor, the computer or the processor executes one or more steps in any of the above methods.
Claims (10)
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211467858.XA CN118075125A (en) | 2022-11-22 | 2022-11-22 | Node management method, electronic equipment and medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202211467858.XA CN118075125A (en) | 2022-11-22 | 2022-11-22 | Node management method, electronic equipment and medium |
Publications (1)
Publication Number | Publication Date |
---|---|
CN118075125A true CN118075125A (en) | 2024-05-24 |
Family
ID=91097832
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202211467858.XA Pending CN118075125A (en) | 2022-11-22 | 2022-11-22 | Node management method, electronic equipment and medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN118075125A (en) |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070198586A1 (en) * | 2006-02-22 | 2007-08-23 | Hardy Mark D | Methods and apparatus for providing a configurable geospatial data provisioning framework |
CN103399792A (en) * | 2013-07-24 | 2013-11-20 | 佳都新太科技股份有限公司 | Implementation scheme of Android-based plug-in applications |
CN106055330A (en) * | 2016-05-31 | 2016-10-26 | 深圳卡尔拓客科技有限公司 | Management method and system of application program |
CN106878333A (en) * | 2017-03-28 | 2017-06-20 | 上海爱数信息技术股份有限公司 | A third-party authentication method, device and application system server |
CN110708202A (en) * | 2019-10-15 | 2020-01-17 | 深圳前海微众银行股份有限公司 | Configuration method, device and equipment of plug-in node and storage medium |
CN111638921A (en) * | 2020-06-01 | 2020-09-08 | 南京雷鲨信息科技有限公司 | Plug-in management system and method running in intelligent terminal |
CN112527248A (en) * | 2019-09-18 | 2021-03-19 | 阿里巴巴集团控股有限公司 | Request processing method and device and electronic equipment |
-
2022
- 2022-11-22 CN CN202211467858.XA patent/CN118075125A/en active Pending
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US20070198586A1 (en) * | 2006-02-22 | 2007-08-23 | Hardy Mark D | Methods and apparatus for providing a configurable geospatial data provisioning framework |
CN103399792A (en) * | 2013-07-24 | 2013-11-20 | 佳都新太科技股份有限公司 | Implementation scheme of Android-based plug-in applications |
CN106055330A (en) * | 2016-05-31 | 2016-10-26 | 深圳卡尔拓客科技有限公司 | Management method and system of application program |
CN106878333A (en) * | 2017-03-28 | 2017-06-20 | 上海爱数信息技术股份有限公司 | A third-party authentication method, device and application system server |
CN112527248A (en) * | 2019-09-18 | 2021-03-19 | 阿里巴巴集团控股有限公司 | Request processing method and device and electronic equipment |
CN110708202A (en) * | 2019-10-15 | 2020-01-17 | 深圳前海微众银行股份有限公司 | Configuration method, device and equipment of plug-in node and storage medium |
CN111638921A (en) * | 2020-06-01 | 2020-09-08 | 南京雷鲨信息科技有限公司 | Plug-in management system and method running in intelligent terminal |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2020244495A1 (en) | Screen projection display method and electronic device | |
US12019942B2 (en) | Multi-screen collaboration method and system, and electronic device | |
WO2020244492A1 (en) | Screen projection display method and electronic device | |
CN114741213B (en) | Notification processing method, chip, electronic device and computer-readable storage medium | |
CN115480834A (en) | Display method and electronic device | |
WO2023198196A1 (en) | Device control method and electronic device | |
WO2024179203A1 (en) | Voice control method and electronic device | |
CN116052236B (en) | Face detection processing engine, shooting method and equipment related to face detection | |
CN118075125A (en) | Node management method, electronic equipment and medium | |
CN117631935A (en) | Parameter synchronization method and electronic equipment | |
CN115700431A (en) | Desktop display method and electronic equipment | |
CN113835802A (en) | Device interaction method, system, device and computer readable storage medium | |
CN115344168B (en) | Message display method, terminal and computer readable storage medium | |
CN117707453B (en) | Method, equipment and storage medium for reading node information | |
WO2022188632A1 (en) | Theme display method and apparatus, terminal, and computer storage medium | |
CN117971335A (en) | Display method, electronic device and medium | |
CN118075407A (en) | Method, equipment and storage medium for creating piping diagram | |
CN117978907A (en) | Data processing method, electronic device and medium | |
WO2025118987A1 (en) | Layer synthesis method and electronic device | |
CN118625977A (en) | Wallpaper generation method and electronic device | |
CN117668350A (en) | Application recommended methods and related devices | |
WO2024125287A1 (en) | Data synchronization method and electronic device | |
WO2024109484A1 (en) | Application migration method and electronic device | |
CN118860973A (en) | Data migration method, system, electronic device and storage medium | |
CN117938559A (en) | Communication method and electronic device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
CB02 | Change of applicant information | ||
CB02 | Change of applicant information |
Country or region after: China Address after: Unit 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong 518040 Applicant after: Honor Terminal Co.,Ltd. Address before: 3401, unit a, building 6, Shenye Zhongcheng, No. 8089, Hongli West Road, Donghai community, Xiangmihu street, Futian District, Shenzhen, Guangdong Applicant before: Honor Device Co.,Ltd. Country or region before: China |