[go: up one dir, main page]

CN106873851A - Method, device and terminal that 3D regards the Widget imitated are created in interactive interface - Google Patents

Method, device and terminal that 3D regards the Widget imitated are created in interactive interface Download PDF

Info

Publication number
CN106873851A
CN106873851A CN201710023789.6A CN201710023789A CN106873851A CN 106873851 A CN106873851 A CN 106873851A CN 201710023789 A CN201710023789 A CN 201710023789A CN 106873851 A CN106873851 A CN 106873851A
Authority
CN
China
Prior art keywords
view
interactive interface
widget
control
view control
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
Application number
CN201710023789.6A
Other languages
Chinese (zh)
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.)
Beijing Anyun Century Technology Co Ltd
Original Assignee
Beijing Qihoo Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Qihoo Technology Co Ltd filed Critical Beijing Qihoo Technology Co Ltd
Priority to CN201710023789.6A priority Critical patent/CN106873851A/en
Publication of CN106873851A publication Critical patent/CN106873851A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0481Interaction techniques based on graphical user interfaces [GUI] based on specific properties of the displayed interaction object or a metaphor-based environment, e.g. interaction with desktop elements like windows or icons, or assisted by a cursor's changing behaviour or appearance
    • G06F3/04815Interaction with a metaphor-based environment or interaction object displayed as three-dimensional, e.g. changing the user viewpoint with respect to the environment or object
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F9/00Arrangements for program control, e.g. control units
    • G06F9/06Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
    • G06F9/44Arrangements for executing specific programs
    • G06F9/451Execution arrangements for user interfaces

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Software Systems (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Processing Or Creating Images (AREA)

Abstract

本发明公开了在交互界面中创建3D视效的Widget的方法、装置及终端,该方法包括以下步骤:在交互界面中创建视图控件;在所述视图控件中绘制3D视图;输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。通过本发明实现了在交互界面中利用自定义控件创建具有3D视效Widget的效果,增强了交互界面中Widget的立体感,丰富了交互界面的内容,增加了Widget可实现的功能,使Widget可实现的应用类型更广泛,优化了用户体验。

The invention discloses a method, a device and a terminal for creating a Widget with 3D visual effects in an interactive interface. The method includes the following steps: creating a view control in the interactive interface; drawing a 3D view in the view control; inputting the 3D view to the interactive interface, and combine it with the view of the interactive interface to form a Widget. Through the present invention, the effect of creating a Widget with 3D visual effect by using self-defined controls in the interactive interface is realized, the three-dimensional sense of the Widget in the interactive interface is enhanced, the content of the interactive interface is enriched, and the functions that the Widget can realize are increased, so that the Widget can be realized. The types of applications implemented are wider and the user experience is optimized.

Description

在交互界面中创建3D视效的Widget的方法、装置及终端Method, device and terminal for creating 3D visual effect Widget in interactive interface

【技术领域】【Technical field】

本发明涉及计算机软件领域,特别设计在交互界面中创建3D视效的Widget的方法、装置及终端。The invention relates to the field of computer software, in particular a method, a device and a terminal for creating a 3D visual effect Widget in an interactive interface.

【背景技术】【Background technique】

Widget是应用程序窗口小部件,是微型的应用程序视图,它可以被嵌入到其它应用程序中(比如系统桌面)并接收周期性的更新。如今Widget已经成为手机上非常流行的技术,基于移动终端的Widget的各种小应用也不断涌现,可以为用户带来良好的移动互联网体验,随时随地获取有用的资讯,如天气预报、股票信息、头条新闻等。但现有的安卓桌面中只能显示2D用户界面控件绘制而成的Widget,如何在安卓桌面中创建具有3D视效的Widget是一个技术难点。另外,现有的安卓桌面中Widget的绘制只能使用安卓提供的几种固定的视图控件(View)来进行,而不能采用自定义View进行绘制,但这些原生的View不足以满足用户对软件功能多样化的需求,使得Widget的应用范围受到限制。Widget is an application widget, which is a miniature application view, which can be embedded in other applications (such as the system desktop) and receive periodic updates. Nowadays, Widget has become a very popular technology on mobile phones, and various small applications based on Widget on mobile terminals are also emerging, which can bring users a good mobile Internet experience and obtain useful information anytime and anywhere, such as weather forecasts, stock information, headlines etc. However, existing Android desktops can only display Widgets drawn by 2D user interface controls. How to create Widgets with 3D visual effects on Android desktops is a technical difficulty. In addition, the drawing of Widgets in the existing Android desktop can only be carried out using several fixed view controls (View) provided by Android, instead of using custom Views for drawing, but these native Views are not enough to satisfy users' requirements for software functions. Diversified requirements limit the application scope of Widget.

【发明内容】【Content of invention】

本发明的目的在于提供一种在交互界面中3D视效的Widget的绘制方法及其相应的装置,以在交互界面中绘制出具有3D视效的Widget。The object of the present invention is to provide a method for drawing a Widget with 3D visual effects in an interactive interface and a corresponding device thereof, so as to draw a Widget with 3D visual effects in an interactive interface.

相应的,本发明的另一目的在于提供一种终端,以便运行前一目标所述的方法。Correspondingly, another object of the present invention is to provide a terminal for running the method described in the previous object.

为实现该目的,本发明采用如下技术方案:To achieve this goal, the present invention adopts following technical scheme:

在交互界面中创建3D视效的Widget的方法,该方法包括以下步骤:A method for creating a Widget with 3D visual effects in an interactive interface, the method includes the following steps:

在交互界面中创建视图控件;Create view controls in the interactive interface;

在所述视图控件中绘制3D视图;Draw a 3D view in the view control;

输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。Inputting the 3D view into the interactive interface, and merging it with the view of the interactive interface to form a Widget.

进一步的,所述在交互界面中创建视图控件,包括:Further, the creating a view control in the interactive interface includes:

读取视图控件的创建信息;Read the creation information of the view control;

基于所述创建信息通过反射生成视图控件;generating a view control through reflection based on the creation information;

将所述视图控件放置到交互界面的目标位置上。Place the view control on the target position of the interactive interface.

优选的,所述创建信息包含在Widget应用的代码中。Preferably, the creation information is included in the code of the Widget application.

具体的,所述读取视图控件的创建信息之后,还包括:Specifically, after reading the creation information of the view control, it also includes:

获取包含在所述创建信息中的所述视图控件的尺寸信息;Acquiring size information of the view control included in the creation information;

基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域。A display area of a corresponding size is divided at the target position of the interactive interface based on the size information.

进一步的,所述在所述视图控件中绘制3D视图之后,将所述3D视图显示到所述显示区域中。Further, after the 3D view is drawn in the view control, the 3D view is displayed in the display area.

可选的,所述将所述3D视图显示到所述显示区域中之后,还包括:在所述显示区域内布置触摸事件。Optionally, after displaying the 3D view in the display area, the method further includes: arranging a touch event in the display area.

进一步的,所述在所述视图控件中绘制3D视图,包括:Further, the drawing the 3D view in the view control includes:

接收Widget应用中用于绘制的视图数据;Receive view data for drawing in the Widget application;

调用视图绘制接口;Call the view drawing interface;

基于所述视图数据在所述视图控件中绘制出3D视图。A 3D view is drawn in the view control based on the view data.

可选的,所述视图绘制接口为OpenGL。Optionally, the view drawing interface is OpenGL.

具体的,在所述视图控件中绘制3D视图之后,把所述3D视图保存在显存中。Specifically, after the 3D view is drawn in the view control, the 3D view is saved in the video memory.

进一步的,所述输入所述3D视图至所述交互界面,包括:从所述显存中输入所述3D视图至所述交互界面。Further, the inputting the 3D view to the interactive interface includes: inputting the 3D view from the video memory to the interactive interface.

优选的,所述视图控件为Textureview。Preferably, the view control is Textureview.

进一步的,所述交互界面为安卓系统桌面。Further, the interactive interface is an Android system desktop.

在交互界面中创建3D视效的Widget的装置,其特征在于,包括以下单元:The device for creating the Widget of 3D visual effect in the interactive interface is characterized in that it comprises the following units:

创建单元,用于在交互界面中创建视图控件;Create a unit for creating view controls in the interactive interface;

绘制单元,用于在所述视图控件中绘制3D视图;a drawing unit, configured to draw a 3D view in the view control;

显示单元,用于输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。The display unit is configured to input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget.

进一步的,所述创建单元,包括:Further, the creation unit includes:

读取单元,用于读取视图控件的创建信息;The reading unit is used to read the creation information of the view control;

生成单元,用于基于所述创建信息通过反射生成视图控件;a generating unit, configured to generate a view control through reflection based on the creation information;

位置单元,用于将所述视图控件放置到交互界面的目标位置上。The position unit is used to place the view control on the target position of the interactive interface.

优选的,所述创建信息包含在Widget应用的代码中。Preferably, the creation information is included in the code of the Widget application.

具体的,还包括:获取单元,用于获取包含在所述创建信息中的所述视图控件的尺寸信息;Specifically, it also includes: an acquisition unit, configured to acquire the size information of the view control contained in the creation information;

划分单元,用于基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域。A division unit, configured to divide a display area of a corresponding size at the target position of the interactive interface based on the size information.

进一步的,还包括显存,所述3D视图绘制完成后,将所述3D视图显示到所述显示区域中。Further, a video memory is also included, and after the drawing of the 3D view is completed, the 3D view is displayed in the display area.

可选的,还包括:事件布置单元,用于在所述显示区域内布置触摸事件。Optionally, further comprising: an event arranging unit, configured to arrange touch events in the display area.

进一步的,所述在所述视图控件中绘制3D视图,包括:Further, the drawing the 3D view in the view control includes:

接收单元,用于接收Widget应用中用于绘制的视图数据;A receiving unit, configured to receive view data for drawing in the Widget application;

调用单元,用于调用视图绘制接口;The calling unit is used to call the view drawing interface;

渲染单元,用于将所述视图数据渲染成3D视图。A rendering unit, configured to render the view data into a 3D view.

可选的,所述视图绘制接口为OpenGL。Optionally, the view drawing interface is OpenGL.

具体的,还包括显存,用于保存所述3D视图。Specifically, it also includes a video memory for saving the 3D view.

进一步的,从所述显存中输入所述3D视图至所述交互界面。Further, the 3D view is input from the video memory to the interactive interface.

优选的,所述视图控件为Textureview。Preferably, the view control is Textureview.

进一步的,所述交互界面为安卓系统桌面。Further, the interactive interface is an Android system desktop.

一种在交互界面中创建3D视效的Widget的终端,其包括:显示器,用于显示用户交互界面;存储器;一个或多个处理器,用于执行所述存储器中存储的程序;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并由所述一个或多个处理器执行;所述一个或多个应用程序用于执行上述方法。A Widget terminal for creating 3D visual effects in an interactive interface, which includes: a display for displaying a user interactive interface; a memory; one or more processors for executing programs stored in the memory; one or more An application program, wherein the one or more application programs are stored in the memory and executed by the one or more processors; the one or more application programs are used to perform the above method.

与现有技术相比,本发明具备如下有益效果:本发明提供的在交互界面中创建3D视效的Widget的方法、装置及终端,首先在交互界面中创建视图控件,然后在所述视图控件中绘制3D视图,最后输入所述3D视图至所述交互界面,并将其与交互界面的视图合成。实现了在交互界面中利用自定义控件创建具有3D视效的Widget,增强了交互界面中Widget的立体感,丰富了用户交互界面的内容,增加了Widget可实现的功能,从而优化了用户体验,使Widget可实现的应用类型更广泛。Compared with the prior art, the present invention has the following beneficial effects: the method, device and terminal for creating a Widget with 3D visual effects in the interactive interface provided by the present invention first create a view control in the interactive interface, and then create a view control in the view control The 3D view is drawn in, and finally the 3D view is input to the interactive interface, and synthesized with the view of the interactive interface. Realized the use of custom controls to create Widgets with 3D visual effects in the interactive interface, enhanced the three-dimensional sense of the Widget in the interactive interface, enriched the content of the user interactive interface, and increased the functions that the Widget can realize, thereby optimizing the user experience. Wider range of application types that can be realized by Widget.

【附图说明】【Description of drawings】

图1为本发明在交互界面中创建3D视效的Widget的方法的实施例一流程示意图。FIG. 1 is a schematic flowchart of Embodiment 1 of a method for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图2为本发明在交互界面中创建3D视效的Widget的方法的实施例二流程示意图。FIG. 2 is a schematic flowchart of Embodiment 2 of the method for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图3为本发明在交互界面中创建3D视效的Widget的方法的实施例二进一步方案的流程示意图。FIG. 3 is a schematic flowchart of a further solution of Embodiment 2 of the method for creating a Widget with 3D visual effects in an interactive interface according to the present invention.

图4为本发明在交互界面中创建3D视效的Widget的方法的实施例三流程示意图Fig. 4 is a schematic flow chart of Embodiment 3 of the method for creating a Widget with 3D visual effects in an interactive interface according to the present invention

图5为本发明在交互界面中创建3D视效的Widget的方法的实施例四流程示意图,FIG. 5 is a schematic flowchart of Embodiment 4 of the method for creating a 3D visual effect Widget in an interactive interface according to the present invention,

图6为本发明在交互界面中创建3D视效的Widget的方法的实施例一中绘制步骤的流程示意图。FIG. 6 is a schematic flowchart of drawing steps in Embodiment 1 of the method for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图7为本发明在交互界面中创建3D视效的Widget的方法的实施例一中显示步骤的流程示意图。FIG. 7 is a schematic flowchart of display steps in Embodiment 1 of the method for creating a 3D visual effect Widget in an interactive interface of the present invention.

图8为本发明在交互界面中创建3D视效的Widget的方法的实施例五流程示意图,其示出了矩阵运算接口的使用步骤。FIG. 8 is a schematic flowchart of Embodiment 5 of the method for creating a 3D visual effect Widget in an interactive interface according to the present invention, which shows the steps of using the matrix operation interface.

图9为本发明在交互界面中创建3D视效的Widget的装置的实施例六的原理示意图。FIG. 9 is a schematic diagram of the principle of Embodiment 6 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图10为本发明在交互界面中创建3D视效的Widget的装置的实施例七的原理示意图。FIG. 10 is a schematic diagram of the principle of Embodiment 7 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图11为本发明使在交互界面中创建3D视效的Widget的装置的实施例七的又一原理示意图。FIG. 11 is another schematic schematic diagram of Embodiment 7 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图12为本发明在交互界面中创建3D视效的Widget的装置的实施例八的原理示意图。FIG. 12 is a schematic schematic diagram of Embodiment 8 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图13为本发明在交互界面中创建3D视效的Widget的装置的实施例九的原理示意图。FIG. 13 is a schematic diagram of the principle of Embodiment 9 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图14为本发明在交互界面中创建3D视效的Widget的装置的实施例六的又一原理示意图。FIG. 14 is another schematic diagram of the principle of Embodiment 6 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图15为本发明在交互界面中创建3D视效的Widget的装置的实施例十的原理示意图。FIG. 15 is a schematic schematic diagram of Embodiment 10 of the device for creating a 3D visual effect Widget in an interactive interface according to the present invention.

图16为本发明能够在交互界面中创建3D视效的Widget的终端的结构示意图。FIG. 16 is a schematic structural diagram of a Widget terminal capable of creating 3D visual effects in an interactive interface according to the present invention.

【具体实施方式】【detailed description】

为了使本技术领域的人员更好地理解本发明方案,下面将结合本发明实施例中的附图,对本发明实施例中的技术方案进行清楚、完整地描述。In order to enable those skilled in the art to better understand the solutions of the present invention, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention.

在本发明的说明书和权利要求书及上述附图中的描述的一些流程中,包含了按照特定顺序出现的多个操作,但是应该清楚了解,这些操作可以不按照其在本文中出现的顺序来执行或并行执行,操作的序号如S11、S12等,仅仅是用于区分开各个不同的操作,序号本身不代表任何的执行顺序。另外,这些流程可以包括更多或更少的操作,并且这些操作可以按顺序执行或并行执行。In some processes described in the specification and claims of the present invention and the above-mentioned drawings, a plurality of operations appearing in a specific order are contained, but it should be clearly understood that these operations may not be performed in the order in which they appear herein Execution or parallel execution, the sequence number of the operation, such as S11, S12, etc., is only used to distinguish different operations, and the sequence number itself does not represent any execution order. Additionally, these processes can include more or fewer operations, and these operations can be performed sequentially or in parallel.

本技术领域技术人员可以理解,这里所使用的“终端”、“终端设备”既包括无线信号接收器的设备,其仅具备无发射能力的无线信号接收器的设备,又包括接收和发射硬件的设备,其具有能够在双向通信链路上,进行双向通信的接收和发射硬件的设备。这种设备可以包括:蜂窝或其他通信设备,其具有单线路显示器或多线路显示器或没有多线路显示器的蜂窝或其他通信设备;PCS(Personal Communications Service,个人通信系统),其可以组合语音、数据处理、传真和/或数据通信能力;PDA(Personal Digital Assistant,个人数字助理),其可以包括射频接收器、寻呼机、互联网/内联网访问、网络浏览器、记事本、日历和/或GPS(Global Positioning System,全球定位系统)接收器;常规膝上型和/或掌上型计算机或其他设备,其具有和/或包括射频接收器的常规膝上型和/或掌上型计算机或其他设备。这里所使用的“终端”、“终端设备”可以是便携式、可运输、安装在交通工具(航空、海运和/或陆地)中的,或者适合于和/或配置为在本地运行,和/或以分布形式,运行在地球和/或空间的任何其他位置运行。这里所使用的“终端”、“终端设备”还可以是通信终端、上网终端、音乐/视频播放终端,例如可以是PDA、MID10(Mobile Internet Device,移动互联网设备)和/或具有音乐/视频播放功能的移动电话,也可以是智能电视、机顶盒等设备。Those skilled in the art can understand that the "terminal" and "terminal equipment" used here not only include wireless signal receiver equipment, which only has wireless signal receiver equipment without transmission capabilities, but also include receiving and transmitting hardware. A device having receive and transmit hardware capable of bi-directional communication over a bi-directional communication link. Such equipment may include: cellular or other communication equipment, which has a single-line display or a multi-line display or a cellular or other communication equipment without a multi-line display; PCS (Personal Communications Service, personal communication system), which can combine voice, data Processing, facsimile and/or data communication capabilities; PDA (Personal Digital Assistant, Personal Digital Assistant), which may include radio frequency receiver, pager, Internet/Intranet access, web browser, notepad, calendar and/or GPS (Global Positioning System (Global Positioning System) receiver; a conventional laptop and/or palmtop computer or other device having and/or including a radio frequency receiver. As used herein, a "terminal", "terminal device" may be portable, transportable, installed in a vehicle (air, sea, and/or land), or adapted and/or configured to operate locally, and/or In distributed form, the operation operates at any other location on Earth and/or in space. The "terminal" and "terminal equipment" used here can also be a communication terminal, an Internet terminal, a music/video player terminal, such as a PDA, MID10 (Mobile Internet Device, mobile Internet device) and/or a music/video player Functional mobile phones, smart TVs, set-top boxes and other devices.

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

本发明中所称的视图控件(View)是指Android中非常重要的一种类。View是用来构建用户界面组件(Button,Textfields等等)的基类,是应用程序界面的直观体现。ViewGroup相当于一个放置View的容器,其职责是给其中的View计算出建议的宽和高和测量模式,以及决定这些View的位置,而View的职责是根据测量模式和ViewGroup给出的建议的宽和高,计算出自己的宽和高,同时还有个更重要的职责是在ViewGroup为其指定的区域内绘制自己的形态。通常应用程序界面可以看作是由View组成的,一个View占用了屏幕上的一个矩形区域并且负责界面绘制和事件处理。安卓桌面即是一个ViewGroup,在这个ViewGroup中,布置了很多用于实现各种各样功能的View,其中,Widget应用也是其中的一种View。安卓系统自带许多原生View,以实现用户界面交互,但自带的View类型和功能有限,因此需要通过自定义view来扩展,通常情况下,Android实现自定义控件无非三种方式:继承现有控件,对其控件的功能进行拓展;将现有控件进行组合,实现功能更加强大控件;重写View实现全新的控件。其中,一般当原生控件无法满足用户现有的需求的时候,就需要重写View来实现一种全新的控件,创建一个全新View实现自定义控件的基本流程如下:Ⅰ、在OnMeasure()方法中,测量自定义控件的大小,使自定义控件能够自适应布局各种各样的需求。Ⅱ、在OnDraw()方法中,利用画布(Canvas)与画笔(Paint)来绘制要显示的内容。Ⅲ、在OnLayout()方法中来确定控件显示位置。Ⅳ、在OnTouchEvent()方法处理控件的触摸事件。The view control (View) referred to in the present invention refers to a very important class in Android. View is the base class used to build user interface components (Button, Textfields, etc.), and is an intuitive embodiment of the application interface. ViewGroup is equivalent to a container for placing View. Its responsibility is to calculate the recommended width, height and measurement mode for the View in it, and to determine the position of these Views. The responsibility of View is to calculate the recommended width according to the measurement mode and ViewGroup. And height, calculate your own width and height, and a more important responsibility is to draw your own shape in the area specified by ViewGroup. Generally, the application interface can be regarded as composed of Views. A View occupies a rectangular area on the screen and is responsible for interface drawing and event handling. The Android desktop is a ViewGroup. In this ViewGroup, many Views for implementing various functions are arranged, and the Widget application is also one of the Views. The Android system comes with many native Views to achieve user interface interaction, but the built-in View types and functions are limited, so it needs to be extended through custom views. Usually, Android implements custom controls in three ways: Inherit the existing Controls, to expand the functions of its controls; combine existing controls to achieve more powerful controls; rewrite View to achieve brand new controls. Among them, generally when the native control cannot meet the existing needs of the user, it is necessary to rewrite the View to implement a new control. The basic process of creating a new View to implement a custom control is as follows: Ⅰ. In the OnMeasure() method , to measure the size of the custom control, so that the custom control can adapt to various needs of the layout. Ⅱ. In the OnDraw() method, use the Canvas and Paint to draw the content to be displayed. Ⅲ. Determine the display position of the control in the OnLayout() method. Ⅳ. Handle the touch event of the control in the OnTouchEvent() method.

本发明中所称的OpenGL(全写Open Graphics Library)是指定义了一个跨编程语言、跨平台的编程接口规格的专业的图形程序接口。它用于三维图像(二维的亦可),是一个功能强大,调用方便的底层图形库。OpenGL命令最初就是用C语言函数来进行描述的。OpenGL独立于窗口系统和操作系统,以它为基础开发的应用程序可以十分方便地在各种平台间移植;OpenGL可以与Visual C++紧密接口,便于实现机械手的有关计算和图形算法,可保证算法的正确性和可靠性;OpenGL使用简便,效率高。它具有七大功能:(1)建模:OpenGL图形库除了提供基本的点、线、多边形的绘制函数外,还提供了复杂的三维物体(球、锥、多面体、茶壶等)以及复杂曲线和曲面绘制函数。(2)变换:OpenGL图形库的变换包括基本变换和投影变换。基本变换有平移、旋转、变比镜像四种变换,投影变换有平行投影(又称正射投影)和透视投影两种变换。其变换方法有利于减少算法的运行时间,提高三维图形的显示速度。(3)颜色模式设置:OpenGL颜色模式有两种,即RGBA模式和颜色索引(Color Index)。(4)光照和材质设置:OpenGL光有辐射光(Emitted Light)、环境光(Ambient Light)、漫反射光(Diffuse Light)和镜面光(Specular Light)。材质是用光反射率来表示。场景(Scene)中物体最终反映到人眼的颜色是光的红绿蓝分量与材质红绿蓝分量的反射率相乘后形成的颜色。(5)纹理映射(Texture Mapping)。利用OpenGL纹理映射功能可以十分逼真地表达物体表面细节。(6)位图显示和图象增强图象功能除了基本的拷贝和像素读写外,还提供融合(Blending)、反走样(Antialiasing)和雾(fog)的特殊图象效果处理。以上三条可使被仿真物更具真实感,增强图形显示的效果。(7)双缓存动画(Double Buffering)双缓存即前台缓存和后台缓存,简言之,后台缓存计算场景、生成画面,前台缓存显示后台缓存已画好的画面。此外,利用OpenGL还能实现深度暗示(Depth Cue)、运动模糊(Motion Blur)等特殊效果。OpenGL绘图的基本过程是:清除缓冲区,设置当前颜色,绘制几何图元,输出图形。The OpenGL (full-written Open Graphics Library) referred to in the present invention refers to a professional graphics program interface that defines a cross-programming language and cross-platform programming interface specification. It is used for three-dimensional images (two-dimensional ones are also acceptable), and it is a powerful and easy-to-call underlying graphics library. OpenGL commands were originally described using C language functions. OpenGL is independent of the window system and operating system, and the application program developed based on it can be easily transplanted among various platforms; OpenGL can be closely interfaced with Visual C++, which is convenient for realizing the calculation and graphics algorithms of the manipulator, and can ensure the accuracy of the algorithm. Correctness and reliability; OpenGL is easy to use and efficient. It has seven functions: (1) Modeling: In addition to providing basic point, line, and polygon drawing functions, the OpenGL graphics library also provides complex three-dimensional objects (balls, cones, polyhedrons, teapots, etc.) and complex curves and Surface drawing functions. (2) Transformation: The transformation of the OpenGL graphics library includes basic transformation and projection transformation. There are four basic transformations: translation, rotation, and ratio mirroring. Projective transformations include parallel projection (also known as orthographic projection) and perspective projection. The transformation method is beneficial to reduce the running time of the algorithm and improve the display speed of three-dimensional graphics. (3) Color mode setting: There are two OpenGL color modes, namely RGBA mode and color index (Color Index). (4) Lighting and material settings: OpenGL light includes Emitted Light, Ambient Light, Diffuse Light and Specular Light. Materials are represented by light reflectance. The color of the object in the scene (Scene) that is finally reflected to the human eye is the color formed by multiplying the red, green, and blue components of light and the reflectance of the red, green, and blue components of the material. (5) Texture Mapping. Using the OpenGL texture mapping function can express the details of the object surface very realistically. (6) Bitmap display and image enhancement In addition to basic copying and pixel reading and writing, the image function also provides special image processing such as blending, antialiasing and fog. The above three items can make the simulated object more realistic and enhance the effect of graphic display. (7) Double Buffering (Double Buffering) Double buffering refers to the front buffer and the background buffer. In short, the background buffer calculates the scene and generates the picture, and the front buffer displays the picture that the background buffer has drawn. In addition, special effects such as depth cue and motion blur can be realized by using OpenGL. The basic process of OpenGL drawing is: clear the buffer, set the current color, draw geometric primitives, and output graphics.

实施例一Embodiment one

请参阅图1,本发明所提供的桌面中3D视效的Widget的绘制方法,其包括以下步骤:Please refer to Fig. 1, the drawing method of the Widget of 3D visual effect in the desktop provided by the present invention, it comprises the following steps:

S10,在交互界面中创建视图控件;S10, create a view control in the interactive interface;

S20,在所述视图控件中绘制3D视图;S20, draw a 3D view in the view control;

S30,输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。S30. Input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget.

用户交互界面(UI)泛指用户的操作界面,UI设计主要指界面的样式,美观程度。而使用上,对软件的人机交互、操作逻辑、界面美观的整体设计则是同样重要的另一个门道。好的UI不仅是让软件变得有个性有品味,还要让软件的操作变得舒适、简单、自由,充分体现软件的定位和特点。通常交互界面可看做是Viewgroup,根据其功能需要,在其内部布置若干View。在安卓手机中,安卓系统桌面是使用最为频繁的交互界面之一。现有技术中,现有的安卓桌面中,Widget应用只可为2D的UI控件绘制而成的,其显示也仅为2D视效。User interaction interface (UI) generally refers to the user's operation interface, and UI design mainly refers to the style and aesthetics of the interface. In terms of use, the overall design of the human-computer interaction, operation logic, and beautiful interface of the software is another equally important approach. A good UI not only makes the software individual and tasteful, but also makes the operation of the software comfortable, simple, and free, fully reflecting the positioning and characteristics of the software. Generally, the interactive interface can be regarded as a Viewgroup, and several Views are arranged inside it according to its functional requirements. In an Android mobile phone, the Android system desktop is one of the most frequently used interactive interfaces. In the prior art, in the existing Android desktop, the Widget application can only be drawn for 2D UI controls, and its display is only for 2D visual effects.

步骤S10中,在交互界面中创建视图控件。交互界面中无法直接进行3D绘制,需要在交互界面中新建能够进行3D绘制的视图控件,借助所述视图控件,绘制3D视效的3D视图。因此在交互界面中创建视图控件是后续步骤的必要前提。In step S10, a view control is created in the interactive interface. 3D rendering cannot be performed directly in the interactive interface, and it is necessary to create a view control capable of 3D rendering in the interactive interface, and use the view control to draw a 3D view of 3D visual effects. Therefore, creating a view control in the interactive interface is a necessary prerequisite for the subsequent steps.

步骤S20中,在所述视图控件中绘制3D视图。视图控件创建完成后,即可通过调用绘制接口在所述视图控件中绘制3D视效的3D视图。In step S20, a 3D view is drawn in the view control. After the view control is created, the 3D view of the 3D visual effect can be drawn in the view control by calling the drawing interface.

步骤S30中,输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。在所述视图控件中完成3D视图绘制后,即以完成了对Widget显示视图的3D化,这时所需做的即是将绘制完成的3D视图输出到交互界面中,并将3D视图和交互界面的视图进行合并。所述合并是指视图之间的拼接、叠加、覆盖等处理方式。合并的目的在于将3D视图的Widget融入到交互界面视图中,使两者共同显示在交互界面中。至此,具有3D视效的Widget绘制完成。In step S30, the 3D view is input into the interactive interface, and combined with the view of the interactive interface to form a Widget. After the 3D view drawing is completed in the view control, the 3D rendering of the Widget display view is completed. At this time, all that needs to be done is to output the drawn 3D view to the interactive interface, and combine the 3D view with the interactive interface. Interface views are merged. The merging refers to processing methods such as splicing, overlaying, covering, etc. between views. The purpose of merging is to integrate the Widget of the 3D view into the view of the interactive interface, so that the two can be displayed together in the interactive interface. So far, the drawing of the Widget with 3D visual effect is completed.

本发明通过在交互界面中创建自定义视图控件,并在所述视图控件中绘制3D视图,最后将所述3D视图与交互界面的视图进行合并,从而实现在交互界面中创建具有3D视效的Widget。The present invention creates a custom view control in the interactive interface, draws a 3D view in the view control, and finally combines the 3D view with the view of the interactive interface, thereby creating a 3D visual effect in the interactive interface. Widget.

实施例二Embodiment two

请参阅图2,实施例一中的步骤S10读取视图控件的创建信息,其具体实现方式为:Please refer to FIG. 2, the step S10 in the first embodiment reads the creation information of the view control, and its specific implementation is as follows:

S11,读取视图控件的创建信息;S11, reading the creation information of the view control;

S12,基于所述创建信息通过反射创建视图控件;S12. Create a view control through reflection based on the creation information;

S13,将所述视图控件放置到交互界面的目标位置上。S13. Place the view control on the target position of the interactive interface.

步骤S11中,读取视图控件的创建信息。所述创建信息包括有视图控件的创建代码、创建函数、调用类以及控件的尺寸等信息,其作用在于提供创建控件所需的控件信息。In step S11, the creation information of the view control is read. The creation information includes information such as creation code, creation function, calling class, and size of the control of the view control, and its function is to provide control information required for creating the control.

进一步,所述创建信息包含在Widget应用的代码中。Widget所反映的是Widget应用的内容,其内容源于Widget应用的更新,Widget与Widget应用之间存在直接关系。因此,视图控件的创建信息存在于Widget应用的代码中,便于Widget直接调用所述创建信息。Further, the creation information is included in the code of the Widget application. What the Widget reflects is the content of the Widget application, the content of which is derived from the update of the Widget application, and there is a direct relationship between the Widget and the Widget application. Therefore, the creation information of the view control exists in the code of the Widget application, so that the Widget can directly call the creation information.

步骤S12中,基于所述创建信息通过反射创建视图控件。所述反射是指程序可以访问、检测和修改它本身状态或行为的一种能力,是使用另外一种方法来调用获取应用程序或者程序组件的一些信息,这个应用程序可以是正在运行的也可以是还没有运行的,只要是能够被.NET调用的文件都可以使用反射来获取文件的信息,如dll、exe、com组件等都可以使用反射来获取文件的信息,同时也可以使用反射来调用这些组件或者程序。简单的说,“反射”其实就是利用程序集的元数据信息。程序集包含模块,而模块包含类型,类型又包含成员。反射则提供了封装程序集、模块和类型的对象,通过反射动态地创建类型的实例,将类型绑定到现有对象,或从现有对象中获取类型,然后,可以调用类型的方法或访问其字段和属性。程序运行过程中,基于读取到的视图控件创建信息,反射创建视图控件,这时,视图控件的尺寸、边界、布局、属性等参数均定义完成。In step S12, the view control is created through reflection based on the creation information. The reflection refers to the ability of a program to access, detect and modify its own state or behavior. It uses another method to call to obtain some information about the application or program components. This application can be running or can be It is not running yet, as long as it is a file that can be called by .NET, you can use reflection to obtain file information, such as dll, exe, com components, etc. can use reflection to obtain file information, and you can also use reflection to call these components or programs. Simply put, "reflection" is actually using the metadata information of the assembly. Assemblies contain modules, and modules contain types, which in turn contain members. Reflection provides objects that encapsulate assemblies, modules, and types. Through reflection, dynamically create instances of types, bind types to existing objects, or obtain types from existing objects. Then, you can call methods of types or access its fields and properties. During the running of the program, based on the read view control creation information, the view control is created by reflection. At this time, the parameters such as the size, boundary, layout, and attributes of the view control are all defined.

在步骤S13中,将所述视图控件放置到交互界面的目标位置上。所述目标位置应参考所述视图控件的尺寸大小,并最终根据用户的设置进行确定。需要说明的是,放置过程中还应存在空间判断机制,以提示用户Widget的可摆放位置。例如,在桌面中摆放日历Widget时,首先需要根据日历Widget需占用界面空间的大小,判断当前桌面界面是否有足够的空间,若当前桌面界面剩余空间不足以放置所述日历Widget时,则应提示用户当前页面没有足够的空间摆放此Widget;当前桌面界面剩余的空间足以摆放所述日历Widget时,则等待用户进一步的指示,待指示位置确定后,创建所述日历Widget。此时,用户指定的Widget生成位置即为本发明中所称的视图控件的目标位置。In step S13, the view control is placed on the target position of the interactive interface. The target position should refer to the size of the view control, and finally be determined according to the settings of the user. It should be noted that there should also be a space judgment mechanism during the placing process to prompt the user where the Widget can be placed. For example, when placing a calendar widget on the desktop, it is first necessary to judge whether the current desktop interface has enough space according to the size of the interface space that the calendar widget needs to occupy. If the remaining space of the current desktop interface is not enough to place the calendar widget, it should Prompt the user that the current page does not have enough space to place the Widget; when the remaining space on the current desktop interface is sufficient to place the Calendar Widget, wait for further instructions from the user, and create the Calendar Widget after the indicated location is determined. At this point, the Widget generation location designated by the user is the target location of the view control referred to in the present invention.

进一步,请参阅图3,所述视图控件创建完成后需要在交互界面中显示出来,因此还需要步骤S15基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域,以预先在交互界面中划分出所述视图控件的显示区域。Further, please refer to FIG. 3. After the view control is created, it needs to be displayed in the interactive interface. Therefore, step S15 is also required to divide a correspondingly sized display area at the target position of the interactive interface based on the size information, so as to pre-set the interactive interface. The display area of the view control is divided in the interface.

读取视图控件的创建信息后,所述创建信息中包含有所述视图控件的尺寸信息,还包括步骤S14获取包含在所述创建信息中的所述视图控件的尺寸信息,在所述视图控件是目标位置确定后,即可在所述目标位置上基于所述尺寸信息对交互界面的视图进行划分,以划分出用于显示所述视图控件的区域。其中,步骤S14获取包含在所述创建信息中的所述视图控件的尺寸信息,在步骤S11读取视图控件的创建信息后即可开始进行,与步骤S12基于所述创建信息通过反射创建视图控件没有先后关系,但在步骤S13将所述视图控件放置到交互界面的目标位置上之前,当步骤S13和步骤S14均完成后,再进行步骤S15。After reading the creation information of the view control, the creation information includes the size information of the view control, and step S14 is also included to acquire the size information of the view control included in the creation information, and the view control After the target position is determined, the view of the interactive interface can be divided based on the size information at the target position, so as to divide the area for displaying the view control. Wherein, step S14 obtains the size information of the view control contained in the creation information, and can start after reading the creation information of the view control in step S11, and step S12 creates the view control based on the creation information through reflection There is no sequence relationship, but before the view control is placed on the target position of the interactive interface in step S13, after step S13 and step S14 are both completed, go to step S15.

结合实施例一和实施例二的所有特征,可得到如图4所示的实施例三,其包括以下步骤:Combining all the features of Embodiment 1 and Embodiment 2, Embodiment 3 as shown in Figure 4 can be obtained, which includes the following steps:

S11,读取视图控件的创建信息;S11, reading the creation information of the view control;

S12,基于所述创建信息通过反射创建视图控件;S12. Create a view control through reflection based on the creation information;

S13,将所述视图控件放置到交互界面的目标位置上;S13, placing the view control on the target position of the interactive interface;

其中,S11之后还包括步骤S14,获取包含在所述创建信息中的所述视图控件的尺寸信息;Wherein, step S14 is also included after S11, obtaining the size information of the view control contained in the creation information;

S13和S14之后还包括步骤S15,基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域;Step S15 is also included after S13 and S14, dividing a display area of a corresponding size at the target position of the interactive interface based on the size information;

S20,在所述视图控件中绘制3D视图;S20, draw a 3D view in the view control;

S30’将所述3D视图显示到所述显示区域中。S30' displaying the 3D view into the display area.

进一步的,请参阅图5,实施例四,需要使创建的Widget具有触摸响应时,实施例二中步骤S30将所述3D视图显示到所述之后,还应包括步骤S40在所述显示区域内布置触摸事件。例如,所创建的Widget是某具有3D视效的游戏的小窗口显示界面,以能够使用户在玩游戏的同时观看视频、视频聊天等多线程操作。所述触摸事件包括单击事件、长按事件、焦点改变事件、键盘事件、菜单事件等基本操作。例如,单击Widget中的某一区域时,响应于此次单击操作而启动Widget所对应的应用程序,长按Widget中的所述区域时,更新Widget所对应的应用程序来自云端的最新信息,并显示所述最新信息。对所述触摸事件的处理模型可为基于鉴定接口的时间处理、基于回调的事件处理。Further, please refer to Fig. 5, Embodiment 4, when it is necessary to make the created Widget have a touch response, after step S30 in Embodiment 2 displays the 3D view, it should also include step S40 in the display area Layout touch events. For example, the created Widget is a small window display interface of a game with 3D visual effect, so that the user can watch video, video chat and other multi-threaded operations while playing the game. The touch event includes basic operations such as a single click event, a long press event, a focus change event, a keyboard event, and a menu event. For example, when a certain area in the Widget is clicked, the application corresponding to the Widget is started in response to the click operation, and when the area in the Widget is long pressed, the application corresponding to the Widget is updated with the latest information from the cloud , and display the latest information. The processing model for the touch event may be time processing based on authentication interface or event processing based on callback.

请参阅图6,实施例一中,步骤S20在所述视图控件中绘制3D视图具体步骤包括:Please refer to Fig. 6, in the first embodiment, the specific steps of drawing a 3D view in the view control in step S20 include:

S21,接收Widget应用中用于绘制的视图数据;S21, receiving view data for drawing in the Widget application;

S22,调用视图绘制接口;S22, call the view drawing interface;

S23,基于所述视图数据在所述视图控件中绘制出3D视图。S23. Draw a 3D view in the view control based on the view data.

Widget中所需要呈现的视图内容来源于Widget应用,因此首先从Widget应用中获取绘制3D视图所需的视图数据;而后调用视图绘制接口,视图绘制接口用于驱动视图的绘制,所述视图绘制接口内包含有视图绘制函数,能够将所述视图数据渲染成具有3D视效的3D视图;最后,利用所述视图绘制接口为工具在所述视图控件中进行绘制。所述视图数据可为文字、2D图像、纹理视图等数据。优选的,所述视图绘制接口选用opengl。The view content that needs to be presented in the Widget comes from the Widget application, so first obtain the view data needed to draw the 3D view from the Widget application; then call the view drawing interface, which is used to drive the drawing of the view, and the view drawing interface It contains a view drawing function, which can render the view data into a 3D view with 3D visual effects; finally, use the view drawing interface as a tool to draw in the view control. The view data may be text, 2D image, texture view and other data. Preferably, the view drawing interface uses opengl.

请参阅图7,实施例一中,步骤S30输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。所述3D视图在所述视图控件中绘制完成,需要将绘制结果显示到交互界面中,这就需要通过显存来实现。具体步骤为:Please refer to FIG. 7 , in the first embodiment, step S30 inputs the 3D view into the interactive interface, and merges it with the view of the interactive interface to form a Widget. The 3D view is drawn in the view control, and the drawing result needs to be displayed on the interactive interface, which needs to be realized through video memory. The specific steps are:

S31,所述3D视图绘制完成后保存在显存中;S31. The 3D view is stored in the video memory after being drawn;

S32,从所述显存中获取所述3D视图;S32. Obtain the 3D view from the video memory;

S33,将所述3D视图显示到交互界面。S33. Display the 3D view on an interactive interface.

所述显存是用来存储显卡芯片处理过或者即将提取的渲染数据,是用来存储要处理的图形信息的部件。The video memory is used to store rendering data processed or to be extracted by the graphics card chip, and is a component used to store graphics information to be processed.

进一步的,上述实施例中,所述视图控件优选Textureview。应用程序的视频或者opengl内容通常显示在SurfaceView中。SurfaceView的工作方式是创建一个置于应用窗口之后的新窗口,这种方式的效率非常高,因为SurfaceView窗口刷新的时候不需要重绘应用程序的窗口(Android普通窗口的视图绘制机制是一层一层的,任何一个子元素或者是局部的刷新都会导致整个视图结构全部重绘一次,因此效率非常低下,不过满足普通应用界面的需求还是绰绰有余),但是SurfaceView也有一些非常不便的限制。因为SurfaceView的内容不在应用窗口上,所以不能使用变换(平移、缩放、旋转等)。与SurfaceView相比,TextureView并没有创建一个单独的Surface用来绘制,这使得它可以像一般的View一样执行一些变换操作,设置透明度等。另外,Textureview必须在硬件加速开启的窗口中。TextureView的使用非常简单,唯一要做的就是获取用于渲染内容的SurfaceTexture。SurfaceTexture从Android 3.0(API level 11)加入,它对图像流的处理并不直接显示,而是转为GL外部纹理,因此可用于图像流数据的二次处理(如Camera滤镜,桌面特效等)。Further, in the above embodiment, the view control is preferably Textureview. The application's video or opengl content is usually displayed in a SurfaceView. The way SurfaceView works is to create a new window placed behind the application window. This method is very efficient, because the SurfaceView window does not need to redraw the application window when the SurfaceView window is refreshed (the view drawing mechanism of Android ordinary windows is layer by layer. Layer, any child element or partial refresh will cause the entire view structure to be redrawn once, so the efficiency is very low, but it is more than enough to meet the needs of ordinary application interfaces), but SurfaceView also has some very inconvenient limitations. Because the SurfaceView's content is not on the app window, transformations (translation, scaling, rotation, etc.) cannot be used. Compared with SurfaceView, TextureView does not create a separate Surface for drawing, which allows it to perform some transformation operations, set transparency, etc. like a normal View. In addition, Textureview must be in a window with hardware acceleration turned on. The use of TextureView is very simple, the only thing to do is to get the SurfaceTexture used to render the content. SurfaceTexture was added from Android 3.0 (API level 11). Its processing of image streams is not directly displayed, but converted to GL external textures, so it can be used for secondary processing of image stream data (such as Camera filters, desktop special effects, etc.) .

比如Camera的预览数据,变成纹理后可以交给GLSurfaceView直接显示,也可以通过SurfaceTexture交给TextureView作为View heirachy中的一个硬件加速层来显示。首先,SurfaceTexture从图像流(来自Camera预览,视频解码,GL绘制场景等)中获得帧数据,当调用updateTexImage()时,根据内容流中最近的图像更新SurfaceTexture对应的GL纹理对象,接下来,就可以像操作普通GL纹理一样操作它了。For example, the preview data of Camera can be handed over to GLSurfaceView for direct display after being turned into a texture, or it can be handed over to TextureView through SurfaceTexture as a hardware acceleration layer in View heirachy for display. First, SurfaceTexture obtains frame data from the image stream (from Camera preview, video decoding, GL drawing scene, etc.). When updateTexImage() is called, the GL texture object corresponding to SurfaceTexture is updated according to the latest image in the content stream. Next, just It can be manipulated like a normal GL texture.

综合上述实施例中的步骤,可得到如图8的实施例五,在交互界面创建3D视效的Widget的方法。By synthesizing the steps in the above-mentioned embodiments, the method for creating a Widget with 3D visual effects on an interactive interface can be obtained as in Embodiment 5 shown in FIG. 8 .

其包括如下步骤:It includes the following steps:

S11,读取视图控件的创建信息;S11, reading the creation information of the view control;

S12,基于所述创建信息通过反射创建视图控件;S12. Create a view control through reflection based on the creation information;

S13,将所述视图控件放置到交互界面的目标位置上;S13, placing the view control on the target position of the interactive interface;

其中,S11之后还包括步骤S14,获取包含在所述创建信息中的所述视图控件的尺寸信息;Wherein, step S14 is also included after S11, obtaining the size information of the view control contained in the creation information;

S13和S14之后还包括步骤S15,基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域;Step S15 is also included after S13 and S14, dividing a display area of a corresponding size at the target position of the interactive interface based on the size information;

S21,接收Widget应用中用于绘制的视图数据;S21, receiving view data for drawing in the Widget application;

S22,调用视图绘制接口;S22, call the view drawing interface;

S23,基于所述视图数据在所述视图控件中绘制出3D视图。S23. Draw a 3D view in the view control based on the view data.

S31,所述3D视图绘制完成后保存在显存中;S31. The 3D view is stored in the video memory after being drawn;

S32,从所述显存中获取所述3D视图;S32. Obtain the 3D view from the video memory;

S33,将所述3D视图显示到交互界面。S33. Display the 3D view on an interactive interface.

S33’,将所述3D视图显示到所述显示区域中。S33', display the 3D view in the display area.

实施例六Embodiment six

请参阅图9,本发明所提供的桌面中3D视效的Widget的绘制装置,其包括以下单元:Please refer to Fig. 9, the drawing device of the Widget of 3D visual effect in the desktop provided by the present invention, it comprises the following units:

创建单元10,用于在交互界面中创建视图控件;The creating unit 10 is used to create a view control in the interactive interface;

绘制单元20,用于在所述视图控件中绘制3D视图;A drawing unit 20, configured to draw a 3D view in the view control;

显示单元30,用于输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。The display unit 30 is configured to input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget.

用户交互界面(UI)泛指用户的操作界面,UI设计主要指界面的样式,美观程度。而使用上,对软件的人机交互、操作逻辑、界面美观的整体设计则是同样重要的另一个门道。好的UI不仅是让软件变得有个性有品味,还要让软件的操作变得舒适、简单、自由,充分体现软件的定位和特点。通常交互界面可看做是Viewgroup,根据其功能需要,在其内部布置若干View。在安卓手机中,安卓系统桌面是使用最为频繁的交互界面之一。现有技术中,现有的安卓桌面中,Widget应用只可为2D的UI控件绘制而成的,其显示也仅为2D视效。User interaction interface (UI) generally refers to the user's operation interface, and UI design mainly refers to the style and aesthetics of the interface. In terms of use, the overall design of the human-computer interaction, operation logic, and beautiful interface of the software is another equally important approach. A good UI not only makes the software individual and tasteful, but also makes the operation of the software comfortable, simple, and free, fully reflecting the positioning and characteristics of the software. Generally, the interactive interface can be regarded as a Viewgroup, and several Views are arranged inside it according to its functional requirements. In an Android mobile phone, the Android system desktop is one of the most frequently used interactive interfaces. In the prior art, in the existing Android desktop, the Widget application can only be drawn for 2D UI controls, and its display is only for 2D visual effects.

创建单元10用于在交互界面中创建视图控件。交互界面中无法直接进行3D绘制,需要在交互界面中新建能够进行3D绘制的视图控件,借助所述视图控件,绘制3D视效的3D视图。因此在交互界面中创建视图控件是后续步骤的必要前提。The creating unit 10 is used for creating view controls in the interactive interface. 3D rendering cannot be performed directly in the interactive interface, and it is necessary to create a view control capable of 3D rendering in the interactive interface, and use the view control to draw a 3D view of 3D visual effects. Therefore, creating a view control in the interactive interface is a necessary prerequisite for the subsequent steps.

绘制单元20用于在所述视图控件中绘制3D视图。视图控件创建完成后,即可通过调用绘制接口在所述视图控件中绘制3D视效的3D视图。The drawing unit 20 is used for drawing a 3D view in the view control. After the view control is created, the 3D view of the 3D visual effect can be drawn in the view control by calling the drawing interface.

显示单元30用于输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。在所述视图控件中完成3D视图绘制后,即以完成了对Widget显示视图的3D化,这时所需做的即是将绘制完成的3D视图输出到交互界面中,并将3D视图和交互界面的视图进行合并。所述合并是指视图之间的拼接、叠加、覆盖等处理方式。合并的目的在于将3D视图的Widget融入到交互界面视图中,使两者共同显示在交互界面中。至此,具有3D视效的Widget绘制完成。The display unit 30 is configured to input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget. After the 3D view drawing is completed in the view control, the 3D rendering of the Widget display view is completed. At this time, all that needs to be done is to output the drawn 3D view to the interactive interface, and combine the 3D view with the interactive interface. Interface views are merged. The merging refers to processing methods such as splicing, overlaying, covering, etc. between views. The purpose of merging is to integrate the Widget of the 3D view into the view of the interactive interface, so that the two can be displayed together in the interactive interface. So far, the drawing of the Widget with 3D visual effect is completed.

本发明通过在交互界面中创建自定义视图控件,并在所述视图控件中绘制3D视图,最后将所述3D视图与交互界面的视图进行合并,从而实现在交互界面中创建具有3D视效的Widget。The present invention creates a custom view control in the interactive interface, draws a 3D view in the view control, and finally combines the 3D view with the view of the interactive interface, thereby creating a 3D visual effect in the interactive interface. Widget.

实施例七,请参阅图10,实施例六中的创建单元10包括:Embodiment 7, please refer to FIG. 10 , the creation unit 10 in Embodiment 6 includes:

读取单元11,用于读取视图控件的创建信息;A reading unit 11, configured to read the creation information of the view control;

生成单元12,用于基于所述创建信息通过反射创建视图控件;A generating unit 12, configured to create a view control through reflection based on the creation information;

位置单元13,用于将所述视图控件放置到交互界面的目标位置上。The position unit 13 is configured to place the view control on the target position of the interactive interface.

读取单元11用于读取视图控件的创建信息。所述创建信息包括有视图控件的创建代码、创建函数、调用类以及控件的尺寸等信息,其作用在于提供创建控件所需的控件信息。The reading unit 11 is used for reading creation information of the view control. The creation information includes information such as creation code, creation function, calling class, and size of the control of the view control, and its function is to provide control information required for creating the control.

进一步,所述创建信息包含在Widget应用的代码中。Widget所反映的是Widget应用的内容,其内容源于Widget应用的更新,Widget与Widget应用之间存在直接关系。因此,视图控件的创建信息存在于Widget应用的代码中,便于Widget直接调用所述创建信息。Further, the creation information is included in the code of the Widget application. What the Widget reflects is the content of the Widget application, the content of which is derived from the update of the Widget application, and there is a direct relationship between the Widget and the Widget application. Therefore, the creation information of the view control exists in the code of the Widget application, so that the Widget can directly call the creation information.

生成单元12用于基于所述创建信息通过反射创建视图控件。所述反射是指程序可以访问、检测和修改它本身状态或行为的一种能力,是使用另外一种方法来调用获取应用程序或者程序组件的一些信息,这个应用程序可以是正在运行的也可以是还没有运行的,只要是能够被.NET调用的文件都可以使用反射来获取文件的信息,如dll、exe、com组件等都可以使用反射来获取文件的信息,同时也可以使用反射来调用这些组件或者程序。简单的说,“反射”其实就是利用程序集的元数据信息。程序集包含模块,而模块包含类型,类型又包含成员。反射则提供了封装程序集、模块和类型的对象,通过反射动态地创建类型的实例,将类型绑定到现有对象,或从现有对象中获取类型,然后,可以调用类型的方法或访问其字段和属性。程序运行过程中,基于读取到的视图控件创建信息,反射创建视图控件,这时,视图控件的尺寸、边界、布局、属性等参数均定义完成。The generating unit 12 is configured to create a view control through reflection based on the creation information. The reflection refers to the ability of a program to access, detect and modify its own state or behavior. It uses another method to call to obtain some information about the application or program components. This application can be running or can be It is not running yet, as long as it is a file that can be called by .NET, you can use reflection to obtain file information, such as dll, exe, com components, etc. can use reflection to obtain file information, and you can also use reflection to call these components or programs. Simply put, "reflection" is actually using the metadata information of the assembly. Assemblies contain modules, and modules contain types, which in turn contain members. Reflection provides objects that encapsulate assemblies, modules, and types. Through reflection, dynamically create instances of types, bind types to existing objects, or obtain types from existing objects. Then, you can call methods of types or access its fields and properties. During the running of the program, based on the read view control creation information, the view control is created by reflection. At this time, the parameters such as the size, boundary, layout, and attributes of the view control are all defined.

位置单元13用于将所述视图控件放置到交互界面的目标位置上。所述目标位置应参考所述视图控件的尺寸大小,并最终根据用户的设置进行确定。需要说明的是,放置过程中还应存在空间判断机制,以提示用户Widget的可摆放位置。例如,在桌面中摆放日历Widget时,首先需要根据日历Widget需占用界面空间的大小,判断当前桌面界面是否有足够的空间,若当前桌面界面剩余空间不足以放置所述日历Widget时,则应提示用户当前页面没有足够的空间摆放此Widget;当前桌面界面剩余的空间足以摆放所述日历Widget时,则等待用户进一步的指示,待指示位置确定后,创建所述日历Widget。此时,用户指定的Widget生成位置即为本发明中所称的视图控件的目标位置。The position unit 13 is used to place the view control on the target position of the interactive interface. The target position should refer to the size of the view control, and finally be determined according to the settings of the user. It should be noted that there should also be a space judgment mechanism during the placing process to prompt the user where the Widget can be placed. For example, when placing a calendar widget on the desktop, it is first necessary to determine whether the current desktop interface has enough space according to the size of the interface space that the calendar widget needs to occupy. If the remaining space of the current desktop interface is not enough to place the calendar widget, it should Prompt the user that the current page does not have enough space to place the Widget; when the remaining space on the current desktop interface is sufficient to place the Calendar Widget, wait for further instructions from the user, and create the Calendar Widget after the indicated location is determined. At this point, the Widget generation location designated by the user is the target location of the view control referred to in the present invention.

进一步,请参阅图11,所述视图控件创建完成后需要在交互界面中显示出来,因此还需要用于基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域的划分单元15,以预先在交互界面中划分出所述视图控件的显示区域。Further, please refer to FIG. 11 , after the view control is created, it needs to be displayed in the interactive interface, so a dividing unit 15 for dividing a display area of a corresponding size at the target position of the interactive interface based on the size information is also required, The display area of the view control is divided in advance in the interactive interface.

读取视图控件的创建信息后,所述创建信息中包含有所述视图控件的尺寸信息,还需要用于获取包含在所述创建信息中的所述视图控件的尺寸信息的获取单元14,在所述视图控件是目标位置确定后,即可在所述目标位置上基于所述尺寸信息对交互界面的视图进行划分,以划分出用于显示所述视图控件的区域。其中,调用单元14在调用单元11之后,与单元12没有调用先后的关系,但调用单元13之前。After reading the creation information of the view control, the creation information includes the size information of the view control, and an acquisition unit 14 for obtaining the size information of the view control contained in the creation information is also required. After the target position of the view control is determined, the view of the interactive interface can be divided based on the size information at the target position, so as to divide an area for displaying the view control. Wherein, the calling unit 14 is after the calling unit 11 , and there is no call sequence relationship with the unit 12 , but it is before the calling unit 13 .

结合实施例六和实施例七的所有特征,可得到如图12所示的实施例八,其包括以下单元:Combining all the features of Embodiment 6 and Embodiment 7, Embodiment 8 as shown in Figure 12 can be obtained, which includes the following units:

读取单元11,用于读取视图控件的创建信息;A reading unit 11, configured to read the creation information of the view control;

生成单元12,用于基于所述创建信息通过反射创建视图控件;A generating unit 12, configured to create a view control through reflection based on the creation information;

位置单元13,用于将所述视图控件放置到交互界面的目标位置上;A position unit 13, configured to place the view control on the target position of the interactive interface;

其中,还包括获取单元14,用于获取包含在所述创建信息中的所述视图控件的尺寸信息;Wherein, an acquisition unit 14 is also included, configured to acquire the size information of the view control included in the creation information;

还包括划分单元15,用于基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域;It also includes a division unit 15, configured to divide a display area of a corresponding size at the target position of the interactive interface based on the size information;

绘制单元20,用于在所述视图控件中绘制3D视图;A drawing unit 20, configured to draw a 3D view in the view control;

显示单元30,用于将所述3D视图显示到所述显示区域中。The display unit 30 is configured to display the 3D view in the display area.

进一步的,请参阅图13,实施例九,需要使创建的Widget具有触摸响应时,实施例七中调用单元30后,还应包括用于在所述显示区域内布置触摸事件的事件布置单元40。例如,所创建的Widget是某具有3D视效的游戏的小窗口显示界面,以能够使用户在玩游戏的同时观看视频、视频聊天等多线程操作。所述触摸事件包括单击事件、长按事件、焦点改变事件、键盘事件、菜单事件等基本操作。例如,单击Widget中的某一区域时,响应于此次单击操作而启动Widget所对应的应用程序,长按Widget中的所述区域时,更新Widget所对应的应用程序来自云端的最新信息,并显示所述最新信息。对所述触摸事件的处理模型可为基于鉴定接口的时间处理、基于回调的事件处理。Further, please refer to FIG. 13 , in the ninth embodiment, when the created Widget needs to have a touch response, after the calling unit 30 in the seventh embodiment, an event arrangement unit 40 for arranging touch events in the display area should also be included . For example, the created Widget is a small window display interface of a game with 3D visual effects, so as to enable the user to watch video, video chat and other multi-threaded operations while playing the game. The touch event includes basic operations such as a single click event, a long press event, a focus change event, a keyboard event, and a menu event. For example, when a certain area in the Widget is clicked, the application corresponding to the Widget is started in response to the click operation, and when the area in the Widget is long pressed, the application corresponding to the Widget is updated with the latest information from the cloud , and display the latest information. The processing model for the touch event may be time processing based on authentication interface or event processing based on callback.

请参阅图14,实施例六中,绘制单元20包括:Please refer to Fig. 14, in the sixth embodiment, the drawing unit 20 includes:

接收单元21,用于接收Widget应用中用于绘制的视图数据;A receiving unit 21, configured to receive view data for drawing in the Widget application;

调用单元22,用于调用视图绘制接口;The calling unit 22 is used to call the view drawing interface;

渲染单元23,用于将所述视图数据渲染成3D视图。The rendering unit 23 is configured to render the view data into a 3D view.

Widget中所需要呈现的视图内容来源于Widget应用,因此首先从Widget应用中获取绘制3D视图所需的视图数据;而后调用视图绘制接口,视图绘制接口用于驱动视图的绘制,所述视图绘制接口内包含有视图绘制函数,能够将所述视图数据渲染成具有3D视效的3D视图;最后,利用所述视图绘制接口为工具在所述视图控件中进行绘制。所述视图数据可为文字、2D图像、纹理视图等数据。优选的,所述视图绘制接口选用opengl。The view content that needs to be presented in the Widget comes from the Widget application, so first obtain the view data needed to draw the 3D view from the Widget application; then call the view drawing interface, which is used to drive the drawing of the view, and the view drawing interface It includes a view drawing function, which can render the view data into a 3D view with 3D visual effects; finally, use the view drawing interface as a tool to draw in the view control. The view data may be text, 2D image, texture view and other data. Preferably, the view drawing interface uses opengl.

实施例六中,显示单元中包括显存,所述3D视图在所述视图控件中绘制完成,需要将绘制结果显示到交互界面中,这就需要通过显存来实现。所述显存是用来存储显卡芯片处理过或者即将提取的渲染数据,是用来存储要处理的图形信息的部件。In Embodiment 6, the display unit includes a video memory, the 3D view is drawn in the view control, and the drawing result needs to be displayed on the interactive interface, which needs to be realized through the video memory. The video memory is used to store rendering data processed or to be extracted by the graphics card chip, and is a component used to store graphics information to be processed.

进一步的,上述实施例中,所述视图控件优选Textureview。应用程序的视频或者opengl内容通常显示在SurfaceView中。SurfaceView的工作方式是创建一个置于应用窗口之后的新窗口,这种方式的效率非常高,因为SurfaceView窗口刷新的时候不需要重绘应用程序的窗口(Android普通窗口的视图绘制机制是一层一层的,任何一个子元素或者是局部的刷新都会导致整个视图结构全部重绘一次,因此效率非常低下,不过满足普通应用界面的需求还是绰绰有余),但是SurfaceView也有一些非常不便的限制。因为SurfaceView的内容不在应用窗口上,所以不能使用变换(平移、缩放、旋转等)。与SurfaceView相比,TextureView并没有创建一个单独的Surface用来绘制,这使得它可以像一般的View一样执行一些变换操作,设置透明度等。另外,Textureview必须在硬件加速开启的窗口中。TextureView的使用非常简单,唯一要做的就是获取用于渲染内容的SurfaceTexture。SurfaceTexture从Android 3.0(API level 11)加入,它对图像流的处理并不直接显示,而是转为GL外部纹理,因此可用于图像流数据的二次处理(如Camera滤镜,桌面特效等)。Further, in the above embodiment, the view control is preferably Textureview. The application's video or opengl content is usually displayed in a SurfaceView. The way SurfaceView works is to create a new window placed behind the application window. This method is very efficient, because the SurfaceView window does not need to redraw the application window when the SurfaceView window is refreshed (the view drawing mechanism of Android ordinary windows is layer by layer. Layer, any child element or partial refresh will cause the entire view structure to be redrawn once, so the efficiency is very low, but it is more than enough to meet the needs of ordinary application interfaces), but SurfaceView also has some very inconvenient limitations. Because the SurfaceView's content is not on the app window, transformations (translation, scaling, rotation, etc.) cannot be used. Compared with SurfaceView, TextureView does not create a separate Surface for drawing, which allows it to perform some transformation operations, set transparency, etc. like a normal View. In addition, Textureview must be in a window with hardware acceleration turned on. The use of TextureView is very simple, the only thing to do is to get the SurfaceTexture used to render the content. SurfaceTexture was added from Android 3.0 (API level 11). Its processing of image streams is not directly displayed, but converted to GL external textures, so it can be used for secondary processing of image stream data (such as Camera filters, desktop special effects, etc.) .

比如Camera的预览数据,变成纹理后可以交给GLSurfaceView直接显示,也可以通过SurfaceTexture交给TextureView作为View heirachy中的一个硬件加速层来显示。首先,SurfaceTexture从图像流(来自Camera预览,视频解码,GL绘制场景等)中获得帧数据,当调用updateTexImage()时,根据内容流中最近的图像更新SurfaceTexture对应的GL纹理对象,接下来,就可以像操作普通GL纹理一样操作它了。For example, the preview data of Camera can be handed over to GLSurfaceView for direct display after being turned into a texture, or it can be handed over to TextureView through SurfaceTexture as a hardware acceleration layer in View heirachy for display. First, SurfaceTexture obtains frame data from the image stream (from Camera preview, video decoding, GL drawing scene, etc.). When updateTexImage() is called, the GL texture object corresponding to SurfaceTexture is updated according to the latest image in the content stream. Next, just It can be manipulated like a normal GL texture.

综合上述实施例中的步骤,可得到实施例十,如图15所示,在交互界面创建3D视效的Widget的方法。其包括如下单元:By synthesizing the steps in the foregoing embodiments, Embodiment 10 can be obtained, as shown in FIG. 15 , a method for creating a 3D visual effect Widget on an interactive interface. It includes the following units:

读取单元11,用于读取视图控件的创建信息;A reading unit 11, configured to read the creation information of the view control;

生成单元12,用于基于所述创建信息通过反射创建视图控件;A generating unit 12, configured to create a view control through reflection based on the creation information;

位置单元13,用于将所述视图控件放置到交互界面的目标位置上;A position unit 13, configured to place the view control on the target position of the interactive interface;

其中,还包括获取单元14,用于获取包含在所述创建信息中的所述视图控件的尺寸信息;Wherein, an acquisition unit 14 is also included, configured to acquire the size information of the view control included in the creation information;

还包括划分单元15,用于基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域;It also includes a division unit 15, configured to divide a display area of a corresponding size at the target position of the interactive interface based on the size information;

接收单元21,用于接收Widget应用中用于绘制的视图数据;A receiving unit 21, configured to receive view data for drawing in the Widget application;

调用单元22,用于调用视图绘制接口;The calling unit 22 is used to call the view drawing interface;

渲染单元23,用于将所述视图数据渲染成3D视图;a rendering unit 23, configured to render the view data into a 3D view;

显示单元30,用于将所述3D视图显示到所述显示区域中。The display unit 30 is configured to display the 3D view in the display area.

本发明实施例还提供了一种在交互界面中绘制3D视效Widget的终端,具有诸如参照本发明后续的介绍的结构。如图16所示,为了便于说明,仅示出了与本发明实施例相关的部分,具体技术细节未揭示的,请参照本发明实施例方法部分。该终端可以为包括手机、平板电脑、PDA(Personal Digital Assistant,个人数字助理)、POS(Point of Sales,销售终端)、车载电脑等任意终端设备,以终端为手机为例:The embodiment of the present invention also provides a terminal for drawing a 3D visual effect Widget in an interactive interface, which has a structure such as that referred to in the subsequent introduction of the present invention. As shown in FIG. 16 , for the convenience of description, only the parts related to the embodiment of the present invention are shown. For specific technical details not disclosed, please refer to the method part of the embodiment of the present invention. The terminal can be any terminal device including mobile phone, tablet computer, PDA (Personal Digital Assistant, personal digital assistant), POS (Point of Sales, sales terminal), vehicle-mounted computer, etc. Taking the terminal as a mobile phone as an example:

图16示出的是与本发明实施例提供的终端相关的手机的部分结构的框图。参考图16,手机包括:射频(Radio Frequency,RF)电路1510、存储器1520、输入单元1530、图像单元1540、传感器1550、音频电路1560、无线保真(wireless fidelity,WiFi)模块1570(也即WiFi芯片模组)、处理器1580、以及电源1590等部件。本领域技术人员可以理解,图16中示出的手机结构并不构成对手机的限定,可以包括比图示更多或更少的部件,或者组合某些部件,或者不同的部件布置。FIG. 16 is a block diagram showing a partial structure of a mobile phone related to the terminal provided by the embodiment of the present invention. 16, the mobile phone includes: a radio frequency (Radio Frequency, RF) circuit 1510, a memory 1520, an input unit 1530, an image unit 1540, a sensor 1550, an audio circuit 1560, a wireless fidelity (wireless fidelity, WiFi) module 1570 (that is, a WiFi chip module), processor 1580, and power supply 1590 and other components. Those skilled in the art can understand that the structure of the mobile phone shown in FIG. 16 does not constitute a limitation to the mobile phone, and may include more or less components than shown in the figure, or combine certain components, or arrange different components.

下面结合图16对手机的各个构成部件进行具体的介绍:The following is a specific introduction to each component of the mobile phone in conjunction with Figure 16:

RF电路1510可用于收发信息或通话过程中,信号的接收和发送,特别地,将基站的下行信息接收后,给处理器1580处理;另外,将设计上行的数据发送给基站。通常,RF电路1510包括但不限于天线、至少一个放大器、收发信机、耦合器、低噪声放大器(Low NoiseAmplifier,LNA)、双工器等。此外,RF电路1510还可以通过无线通信与网络和其他设备通信。上述无线通信可以使用任一通信标准或协议,包括但不限于全球移动通讯系统(GlobalSystem of Mobile communication,GSM)、通用分组无线服务(General Packet RadioService,GPRS)、码分多址(Code Division Multiple Access,CDMA)、宽带码分多址(Wideband Code Division Multiple Access,WCDMA)、长期演进(Long Term Evolution,LTE)、电子邮件、短消息服务(Short Messaging Service,SMS)等。The RF circuit 1510 can be used for sending and receiving information or receiving and sending signals during a call. In particular, after receiving the downlink information from the base station, it is processed by the processor 1580; in addition, the designed uplink data is sent to the base station. Generally, the RF circuit 1510 includes, but is not limited to, an antenna, at least one amplifier, a transceiver, a coupler, a low noise amplifier (Low Noise Amplifier, LNA), a duplexer, and the like. In addition, RF circuitry 1510 may also communicate with networks and other devices via wireless communications. The above-mentioned wireless communication can use any communication standard or protocol, including but not limited to Global System of Mobile Communication (Global System of Mobile communication, GSM), General Packet Radio Service (General Packet Radio Service, GPRS), Code Division Multiple Access (Code Division Multiple Access) , CDMA), Wideband Code Division Multiple Access (WCDMA), Long Term Evolution (Long Term Evolution, LTE), email, Short Messaging Service (Short Messaging Service, SMS), etc.

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

输入单元1530可用于接收输入的数字或字符信息,以及产生与手机的用户设置以及功能控制有关的键信号输入。具体地,输入单元1530可包括触控面板1531以及其他输入设备1532。触控面板1531,也称为触摸屏,可收集用户在其上或附近的触摸操作(比如用户使用手指、触笔等任何适合的物体或附件在触控面板1531上或在触控面板1531附近的操作),并根据预先设定的程式驱动相应的连接装置。可选的,触控面板1531可包括触摸检测装置和触摸控制器两个部分。其中,触摸检测装置检测用户的触摸方位,并检测触摸操作带来的信号,将信号传送给触摸控制器;触摸控制器从触摸检测装置上接收触摸信息,并将它转换成触点坐标,再送给处理器1580,并能接收处理器1580发来的命令并加以执行。此外,可以采用电阻式、电容式、红外线以及表面声波等多种类型实现触控面板1531。除了触控面板1531,输入单元1530还可以包括其他输入设备1532。具体地,其他输入设备1532可以包括但不限于物理键盘、功能键(比如音量控制按键、开关按键等)、轨迹球、鼠标、操作杆等中的一种或多种。The input unit 1530 can be used to receive input numbers or character information, and generate key signal input related to user settings and function control of the mobile phone. Specifically, the input unit 1530 may include a touch panel 1531 and other input devices 1532 . The touch panel 1531, also referred to as a touch screen, can collect touch operations of the user on or near it (for example, the user uses any suitable object or accessory such as a finger or a stylus on the touch panel 1531 or near the touch panel 1531). operation), and drive the corresponding connection device according to the preset program. Optionally, the touch panel 1531 may include two parts, a touch detection device and a touch controller. Among them, the touch detection device detects the user's touch orientation, and detects the signal brought by the touch operation, and transmits the signal to the touch controller; the touch controller receives the touch information from the touch detection device, converts it into contact coordinates, and sends it to the to the processor 1580, and can receive and execute commands sent by the processor 1580. In addition, the touch panel 1531 can be implemented in various types such as resistive, capacitive, infrared, and surface acoustic wave. In addition to the touch panel 1531 , the input unit 1530 may also include other input devices 1532 . Specifically, other input devices 1532 may include but not limited to one or more of a physical keyboard, function keys (such as volume control keys, switch keys, etc.), trackball, mouse, joystick, and the like.

图像单元1540可用于显示由用户输入的信息或提供给用户的信息以及手机的各种菜单。图像单元1540可包括显示面板1541,可选的,可以采用液晶显示器(LiquidCrystal Display,LCD)、有机发光二极管(Organic Light-Emitting Diode,OLED)等形式来配置显示面板1541。进一步的,触控面板1531可覆盖显示面板1541,当触控面板1531检测到在其上或附近的触摸操作后,传送给处理器1580以确定触摸事件的类型,随后处理器1580根据触摸事件的类型在显示面板1541上提供相应的视觉输出。虽然在图16中,触控面板1531与显示面板1541是作为两个独立的部件来实现手机的输入和输入功能,但是在某些实施例中,可以将触控面板1531与显示面板1541集成而实现手机的输入和输出功能。The image unit 1540 may be used to display information input by or provided to the user and various menus of the mobile phone. The image unit 1540 may include a display panel 1541. Optionally, the display panel 1541 may be configured in the form of a liquid crystal display (Liquid Crystal Display, LCD), an organic light-emitting diode (Organic Light-Emitting Diode, OLED), or the like. Furthermore, the touch panel 1531 may cover the display panel 1541, and when the touch panel 1531 detects a touch operation on or near it, it transmits to the processor 1580 to determine the type of the touch event, and then the processor 1580 determines the type of the touch event according to the The type provides a corresponding visual output on the display panel 1541 . Although in FIG. 16 , the touch panel 1531 and the display panel 1541 are used as two independent components to realize the input and input functions of the mobile phone, in some embodiments, the touch panel 1531 and the display panel 1541 can be integrated to form a mobile phone. Realize the input and output functions of the mobile phone.

手机还可包括至少一种传感器1550,比如光传感器、运动传感器以及其他传感器。具体地,光传感器可包括环境光传感器及接近传感器,其中,环境光传感器可根据环境光线的明暗来调节显示面板1541的亮度,接近传感器可在手机移动到耳边时,关闭显示面板1541和/或背光。作为运动传感器的一种,加速计传感器可检测各个方向上(一般为三轴)加速度的大小,静止时可检测出重力的大小及方向,可用于识别手机姿态的应用(比如横竖屏切换、相关游戏、磁力计姿态校准)、振动识别相关功能(比如计步器、敲击)等;至于手机还可配置的陀螺仪、气压计、湿度计、温度计、红外线传感器等其他传感器,在此不再赘述。The handset may also include at least one sensor 1550, such as a light sensor, motion sensor, and other sensors. Specifically, the light sensor may include an ambient light sensor and a proximity sensor, wherein the ambient light sensor may adjust the brightness of the display panel 1541 according to the brightness of the ambient light, and the proximity sensor may turn off the display panel 1541 and/or when the mobile phone is moved to the ear. or backlight. As a kind of motion sensor, the accelerometer sensor can detect the magnitude of acceleration in various directions (generally three axes), and can detect the magnitude and direction of gravity when it is stationary, and can be used to identify the application of mobile phone posture (such as horizontal and vertical screen switching, related Games, magnetometer attitude calibration), vibration recognition related functions (such as pedometer, tap), etc.; as for other sensors such as gyroscope, barometer, hygrometer, thermometer, infrared sensor, etc. repeat.

音频电路1560、扬声器1561,传声器1562可提供用户与手机之间的音频接口。音频电路1560可将接收到的音频数据转换后的电信号,传输到扬声器1561,由扬声器1561转换为声音信号输出;另一方面,传声器1562将收集的声音信号转换为电信号,由音频电路1560接收后转换为音频数据,再将音频数据输出处理器1580处理后,经RF电路1510以发送给比如另一手机,或者将音频数据输出至存储器1520以便进一步处理。The audio circuit 1560, the speaker 1561, and the microphone 1562 can provide an audio interface between the user and the mobile phone. The audio circuit 1560 can transmit the electrical signal converted from the received audio data to the speaker 1561, and the speaker 1561 converts it into an audio signal for output; After being received, it is converted into audio data, and then the audio data is processed by the output processor 1580, and then sent to another mobile phone through the RF circuit 1510, or the audio data is output to the memory 1520 for further processing.

WiFi属于短距离无线传输技术,手机通过WiFi模块1570可以帮助用户收发电子邮件、浏览网页和访问流式媒体等,它为用户提供了无线的宽带互联网访问。虽然图16示出了WiFi模块1570,但是可以理解的是,其并不属于手机的必须构成,完全可以根据需要在不改变发明的本质的范围内而省略。WiFi is a short-distance wireless transmission technology. The mobile phone can help users send and receive emails, browse web pages, and access streaming media through the WiFi module 1570. It provides users with wireless broadband Internet access. Although Fig. 16 shows a WiFi module 1570, it can be understood that it is not an essential component of the mobile phone, and can be completely omitted according to needs without changing the essence of the invention.

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

手机还包括给各个部件供电的电源1590(比如电池),优选的,电源可以通过电源管理系统与处理器1580逻辑相连,从而通过电源管理系统实现管理充电、放电、以及功耗管理等功能。The mobile phone also includes a power supply 1590 (such as a battery) for supplying power to various components. Preferably, the power supply can be logically connected to the processor 1580 through the power management system, so that functions such as charging, discharging, and power consumption management can be realized through the power management system.

尽管未示出,手机还可以包括摄像头、蓝牙模块等,在此不再赘述。Although not shown, the mobile phone may also include a camera, a Bluetooth module, etc., which will not be repeated here.

适应于所述的便携式控制端设备,在本发明实施例中,该终端所包括的处理器1580还具有如前述绘制3D视效的Widget的方法/装置的多种不同实施例所实现的功能。Adapting to the portable control terminal device, in the embodiment of the present invention, the processor 1580 included in the terminal also has the functions realized by various embodiments of the above-mentioned method/apparatus for drawing a Widget with 3D visual effects.

适应于所述的便携式接入端设备,在本发明的实施例中,该终端包括的处理器1580还具有如前述具有绘制3D视效的Widget的方法/装置的多种不同实施例所实现的功能。Adapting to the portable access terminal device, in an embodiment of the present invention, the processor 1580 included in the terminal also has the functions realized in various embodiments of the aforementioned method/apparatus for drawing a Widget with 3D visual effect Function.

本领域领域技术人员可以清楚地了解到,为描述的方便和简洁,上述描述的系统,装置和单元的具体工作过程,可以参考前述方法实施例中的对应过程,在此不再赘述。Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working process of the above-described system, device and unit can refer to the corresponding process in the foregoing method embodiment, which will not be repeated here.

在本申请所提供的几个实施例中,应该理解到,所揭露的系统,装置和方法,可以通过其它的方式实现。例如,以上所描述的装置实施例仅仅是示意性的,例如,所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,装置或单元的间接耦合或通信连接,可以是电性,机械或其它的形式。In the several embodiments provided in this application, it should be understood that the disclosed system, device and method can be implemented in other ways. For example, the device embodiments described above are only illustrative. For example, the division of the units is only a logical function division. In actual implementation, there may be other division methods. For example, multiple units or components can be combined or May be integrated into another system, or some features may be ignored, or not implemented. In another point, the mutual coupling or direct coupling or communication connection shown or discussed may be through some interfaces, and the indirect coupling or communication connection of devices or units may be in electrical, mechanical or other forms.

所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的部分或者全部单元来实现本实施例方案的目的。The units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place, or may be distributed to multiple network units. Part or all of the units can be selected according to actual needs to achieve the purpose of the solution of this embodiment.

另外,在本发明各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。In addition, each functional unit in each embodiment of the present invention may be integrated into one processing unit, each unit may exist separately physically, or two or more units may be integrated into one unit. The above-mentioned integrated units can be implemented in the form of hardware or in the form of software functional units.

本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:只读存储器(ROM,Read Only Memory)、随机存取存储器(RAM,RandomAccess Memory)、磁盘或光盘等。Those of ordinary skill in the art can understand that all or part of the steps in the various methods of the above-mentioned embodiments can be completed by instructing related hardware through a program, and the program can be stored in a computer-readable storage medium, and the storage medium can include: Read Only Memory (ROM, Read Only Memory), Random Access Memory (RAM, Random Access Memory), magnetic disk or optical disk, etc.

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

以上对本发明所提供的系列方案进行了详细介绍,对于本领域的一般技术人员,依据本发明实施例的思想,在具体实施方式及应用范围上均会有改变之处,综上所述,本说明书内容不应理解为对本发明的限制。The series of solutions provided by the present invention have been introduced in detail above. For those of ordinary skill in the art, according to the ideas of the embodiments of the present invention, there will be changes in the specific implementation and application range. In summary, this The content of the description should not be construed as limiting the present invention.

综上所述,本发明所提供的技术方案如下所述:In summary, the technical solution provided by the present invention is as follows:

A1.在交互界面中创建3D视效的Widget的方法,其中,包括以下步骤:A1. The method for creating a Widget with 3D visual effects in an interactive interface, which includes the following steps:

在交互界面中创建视图控件;Create view controls in the interactive interface;

在所述视图控件中绘制3D视图;Draw a 3D view in the view control;

输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。Inputting the 3D view into the interactive interface, and merging it with the view of the interactive interface to form a Widget.

A2.根据A1所述的方法,其中,所述在交互界面中创建视图控件,包括:A2. The method according to A1, wherein said creating a view control in the interactive interface includes:

读取视图控件的创建信息;Read the creation information of the view control;

基于所述创建信息通过反射生成视图控件;generating a view control through reflection based on the creation information;

将所述视图控件放置到交互界面的目标位置上。Place the view control on the target position of the interactive interface.

A3.根据A2所述的方法,其中,所述创建信息包含在Widget应用的代码中。A3. The method according to A2, wherein the creation information is included in the code of the Widget application.

A4.根据A2所述的方法,其中,所述读取视图控件的创建信息之后,还包括:A4. The method according to A2, wherein, after reading the creation information of the view control, it also includes:

获取包含在所述创建信息中的所述视图控件的尺寸信息;Acquiring size information of the view control included in the creation information;

基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域。A display area of a corresponding size is divided at the target position of the interactive interface based on the size information.

A5.根据A4所述的方法,其中,所述在所述视图控件中绘制3D视图之后,将所述3D视图显示到所述显示区域中。A5. The method according to A4, wherein after the 3D view is drawn in the view control, the 3D view is displayed in the display area.

A6.根据A5所述的方法,其中,所述将所述3D视图显示到所述显示区域中之后,还包括:在所述显示区域内布置触摸事件。A6. The method according to A5, wherein after displaying the 3D view in the display area, further comprising: arranging a touch event in the display area.

A7.根据A1所述的方法,其中,所述在所述视图控件中绘制3D视图,包括:A7. The method according to A1, wherein said drawing a 3D view in said view control includes:

接收Widget应用中用于绘制的视图数据;Receive view data for drawing in the Widget application;

调用视图绘制接口;Call the view drawing interface;

基于所述视图数据在所述视图控件中绘制出3D视图。A 3D view is drawn in the view control based on the view data.

A8.根据A7所述的方法,其中,所述视图绘制接口为OpenGL。A8. The method according to A7, wherein the view drawing interface is OpenGL.

A9.根据A1所述的方法,其中,在所述视图控件中绘制3D视图之后,把所述3D视图保存在显存中。A9. The method according to A1, wherein after the 3D view is drawn in the view control, the 3D view is saved in the video memory.

A10.根据A9所述的方法,其中,所述输入所述3D视图至所述交互界面,包括:从所述显存中输入所述3D视图至所述交互界面。A10. The method according to A9, wherein the inputting the 3D view to the interactive interface includes: inputting the 3D view from the video memory to the interactive interface.

A11.根据A1所述的方法,其中,所述视图控件为Textureview。A11. The method according to A1, wherein the view control is Textureview.

A12.根据A1-A11任一所述的方法,其中,所述交互界面为安卓系统桌面。A12. The method according to any one of A1-A11, wherein the interactive interface is an Android system desktop.

A13.在交互界面中创建3D视效的Widget的装置,其中,包括以下单元:A13. A device for creating a Widget with 3D visual effects in an interactive interface, including the following units:

创建单元,用于在交互界面中创建视图控件;Create a unit for creating view controls in the interactive interface;

绘制单元,用于在所述视图控件中绘制3D视图;a drawing unit, configured to draw a 3D view in the view control;

显示单元,用于输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。The display unit is configured to input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget.

A14.根据A13所述的装置,其中,所述创建单元,包括:A14. The device according to A13, wherein the creating unit includes:

读取单元,用于读取视图控件的创建信息;The reading unit is used to read the creation information of the view control;

生成单元,用于基于所述创建信息通过反射生成视图控件;a generating unit, configured to generate a view control through reflection based on the creation information;

位置单元,用于将所述视图控件放置到交互界面的目标位置上。The position unit is used to place the view control on the target position of the interactive interface.

A15.根据A14所述的装置,其中,所述创建信息包含在Widget应用的代码中。A15. The device according to A14, wherein the creation information is included in the code of the Widget application.

A16.根据A14所述的装置,其中,还包括:A16. The device according to A14, further comprising:

获取单元,用于获取包含在所述创建信息中的所述视图控件的尺寸信息;an acquisition unit, configured to acquire the size information of the view control included in the creation information;

划分单元,用于基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域。A division unit, configured to divide a display area of a corresponding size at the target position of the interactive interface based on the size information.

A17.根据A16所述的装置,其中,还包括显存,所述3D视图绘制完成后,将所述3D视图显示到所述显示区域中。A17. The device according to A16, further comprising a video memory, and displaying the 3D view in the display area after the drawing of the 3D view is completed.

A18.根据A17所述的装置,其中,还包括:事件布置单元,用于在所述显示区域内布置触摸事件。A18. The device according to A17, further comprising: an event arrangement unit, configured to arrange touch events in the display area.

A19.根据A13所述的装置,其中,所述在所述视图控件中绘制3D视图,包括:A19. The device according to A13, wherein said drawing a 3D view in said view control comprises:

接收单元,用于接收Widget应用中用于绘制的视图数据;A receiving unit, configured to receive view data for drawing in the Widget application;

调用单元,用于调用视图绘制接口;The calling unit is used to call the view drawing interface;

渲染单元,用于将所述视图数据渲染成3D视图。A rendering unit, configured to render the view data into a 3D view.

A20.根据A19所述的装置,其中,所述视图绘制接口为OpenGL。A20. The device according to A19, wherein the view rendering interface is OpenGL.

A21.根据A13所述的装置,其中,还包括显存,用于保存所述3D视图。A21. The device according to A13, further comprising a video memory for storing the 3D view.

A22.根据A21所述的装置,其中,从所述显存中输入所述3D视图至所述交互界面。A22. The device according to A21, wherein the 3D view is input from the video memory to the interactive interface.

A23.根据A13所述的装置,其中,所述视图控件为Textureview。A23. The device according to A13, wherein the view control is Textureview.

A24.根据A13-A23任一所述的装置,其中,所述交互界面为安卓系统桌面。A24. The device according to any one of A13-A23, wherein the interactive interface is an Android system desktop.

A25.一种在交互界面中创建3D视效的Widget的终端,其包括:显示器,用于显示用户交互界面;存储器;一个或多个处理器,用于执行所述存储器中存储的程序;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并由所述一个或多个处理器执行;所述一个或多个应用程序用于执行A1至A12任一项所述的方法。A25. A terminal for creating a Widget with 3D visual effects in an interactive interface, comprising: a display for displaying a user interactive interface; a memory; one or more processors for executing programs stored in the memory; a or a plurality of application programs, wherein the one or more application programs are stored in the memory and executed by the one or more processors; the one or more application programs are used to execute any of A1 to A12 method described in the item.

Claims (10)

1.在交互界面中创建3D视效的Widget的方法,其特征在于,包括以下步骤:1. The method for creating the Widget of 3D visual effect in the interactive interface is characterized in that, comprising the following steps: 在交互界面中创建视图控件;Create view controls in the interactive interface; 在所述视图控件中绘制3D视图;Draw a 3D view in the view control; 输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。Inputting the 3D view into the interactive interface, and merging it with the view of the interactive interface to form a Widget. 2.根据权利要求1所述的方法,其特征在于,所述在交互界面中创建视图控件,包括:2. The method according to claim 1, wherein said creating a view control in the interactive interface comprises: 读取视图控件的创建信息;Read the creation information of the view control; 基于所述创建信息通过反射生成视图控件;generating a view control through reflection based on the creation information; 将所述视图控件放置到交互界面的目标位置上。Place the view control on the target position of the interactive interface. 3.根据权利要求2所述的方法,其特征在于,所述创建信息包含在Widget应用的代码中。3. The method according to claim 2, wherein the creation information is included in the code of the Widget application. 4.根据权利要求2所述的方法,其特征在于,所述读取视图控件的创建信息之后,还包括:4. The method according to claim 2, further comprising: after reading the creation information of the view control: 获取包含在所述创建信息中的所述视图控件的尺寸信息;Acquiring size information of the view control included in the creation information; 基于所述尺寸信息在交互界面的目标位置划分出相应大小的显示区域。A display area of a corresponding size is divided at the target position of the interactive interface based on the size information. 5.根据权利要求4所述的方法,其特征在于,所述在所述视图控件中绘制3D视图之后,将所述3D视图显示到所述显示区域中。5. The method according to claim 4, characterized in that, after the 3D view is drawn in the view control, the 3D view is displayed in the display area. 6.根据权利要求1所述的方法,其特征在于,所述在所述视图控件中绘制3D视图,包括:6. The method according to claim 1, wherein said drawing a 3D view in said view control comprises: 接收Widget应用中用于绘制的视图数据;Receive view data for drawing in the Widget application; 调用视图绘制接口;Call the view drawing interface; 基于所述视图数据在所述视图控件中绘制出3D视图。A 3D view is drawn in the view control based on the view data. 7.根据权利要求1所述的方法,其特征在于,在所述视图控件中绘制3D视图之后,把所述3D视图保存在显存中。7. The method according to claim 1, characterized in that, after the 3D view is drawn in the view control, the 3D view is saved in video memory. 8.根据权利要求7所述的方法,其特征在于,所述输入所述3D视图至所述交互界面,包括:从所述显存中输入所述3D视图至所述交互界面。8. The method according to claim 7, wherein the inputting the 3D view to the interactive interface comprises: inputting the 3D view from the video memory to the interactive interface. 9.在交互界面中创建3D视效的Widget的装置,其特征在于,包括以下单元:9. The device for creating the Widget of 3D visual effect in the interactive interface is characterized in that, comprising the following units: 创建单元,用于在交互界面中创建视图控件;Create a unit for creating view controls in the interactive interface; 绘制单元,用于在所述视图控件中绘制3D视图;a drawing unit, configured to draw a 3D view in the view control; 显示单元,用于输入所述3D视图至所述交互界面,并将其与交互界面的视图合并形成Widget。The display unit is configured to input the 3D view into the interactive interface, and combine it with the view of the interactive interface to form a Widget. 10.一种在交互界面中创建3D视效的Widget的终端,其包括:显示器,用于显示用户交互界面;存储器;一个或多个处理器,用于执行所述存储器中存储的程序;一个或多个应用程序,其中所述一个或多个应用程序被存储在所述存储器中并由所述一个或多个处理器执行;所述一个或多个应用程序用于执行权利要求1至8任一项所述的方法。10. A terminal for creating a Widget with 3D visual effects in an interactive interface, comprising: a display for displaying a user interactive interface; a memory; one or more processors for executing programs stored in the memory; a or more application programs, wherein said one or more application programs are stored in said memory and executed by said one or more processors; said one or more application programs are used to perform claims 1 to 8 any one of the methods described.
CN201710023789.6A 2017-01-13 2017-01-13 Method, device and terminal that 3D regards the Widget imitated are created in interactive interface Pending CN106873851A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201710023789.6A CN106873851A (en) 2017-01-13 2017-01-13 Method, device and terminal that 3D regards the Widget imitated are created in interactive interface

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201710023789.6A CN106873851A (en) 2017-01-13 2017-01-13 Method, device and terminal that 3D regards the Widget imitated are created in interactive interface

Publications (1)

Publication Number Publication Date
CN106873851A true CN106873851A (en) 2017-06-20

Family

ID=59158047

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201710023789.6A Pending CN106873851A (en) 2017-01-13 2017-01-13 Method, device and terminal that 3D regards the Widget imitated are created in interactive interface

Country Status (1)

Country Link
CN (1) CN106873851A (en)

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107426601A (en) * 2017-07-21 2017-12-01 青岛海信电器股份有限公司 The display methods and device of UI controls in a kind of intelligent television
CN107844255A (en) * 2017-10-10 2018-03-27 惠州Tcl移动通信有限公司 Touch event response control mehtod, smart machine and storage device
CN109117238A (en) * 2018-09-20 2019-01-01 四川长虹电器股份有限公司 A kind of legend display systems and method based on wechat small routine
CN109218644A (en) * 2017-07-04 2019-01-15 北大方正集团有限公司 Driving recording image pickup method and device
CN109976841A (en) * 2017-12-28 2019-07-05 上海擎感智能科技有限公司 The display methods and intelligent terminal of navigational guidance information
CN110362366A (en) * 2018-04-02 2019-10-22 青岛海信移动通信技术股份有限公司 A kind of application interface display methods and device

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102915232A (en) * 2011-08-01 2013-02-06 华为技术有限公司 3D (three-dimensional) controls interaction method and communication terminal
CN105068747A (en) * 2015-08-06 2015-11-18 深圳市金立通信设备有限公司 Generation method and device of desktop member
CN105761303A (en) * 2014-12-30 2016-07-13 达索系统公司 Creation Of Bounding Boxes On 3d Modeled Assembly

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102915232A (en) * 2011-08-01 2013-02-06 华为技术有限公司 3D (three-dimensional) controls interaction method and communication terminal
CN105761303A (en) * 2014-12-30 2016-07-13 达索系统公司 Creation Of Bounding Boxes On 3d Modeled Assembly
CN105068747A (en) * 2015-08-06 2015-11-18 深圳市金立通信设备有限公司 Generation method and device of desktop member

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109218644A (en) * 2017-07-04 2019-01-15 北大方正集团有限公司 Driving recording image pickup method and device
CN107426601A (en) * 2017-07-21 2017-12-01 青岛海信电器股份有限公司 The display methods and device of UI controls in a kind of intelligent television
CN107426601B (en) * 2017-07-21 2020-02-07 青岛海信电器股份有限公司 Display method and device of UI (user interface) control in smart television
CN107844255A (en) * 2017-10-10 2018-03-27 惠州Tcl移动通信有限公司 Touch event response control mehtod, smart machine and storage device
CN107844255B (en) * 2017-10-10 2021-02-19 惠州Tcl移动通信有限公司 Touch event response control method, intelligent device and storage device
CN109976841A (en) * 2017-12-28 2019-07-05 上海擎感智能科技有限公司 The display methods and intelligent terminal of navigational guidance information
CN109976841B (en) * 2017-12-28 2024-06-25 上海擎感智能科技有限公司 Navigation guidance information display method and intelligent terminal
CN110362366A (en) * 2018-04-02 2019-10-22 青岛海信移动通信技术股份有限公司 A kind of application interface display methods and device
CN110362366B (en) * 2018-04-02 2022-06-24 青岛海信移动通信技术股份有限公司 Application interface display method and device
CN109117238A (en) * 2018-09-20 2019-01-01 四川长虹电器股份有限公司 A kind of legend display systems and method based on wechat small routine
CN109117238B (en) * 2018-09-20 2021-04-27 四川长虹电器股份有限公司 WeChat applet-based legend display system and method

Similar Documents

Publication Publication Date Title
US11826649B2 (en) Water wave rendering of a dynamic object in image frames
US20240231555A1 (en) Systems, Methods, and Computer-Readable Media for Managing Collaboration on a Virtual Work of Art
US11360728B2 (en) Head mounted display apparatus and method for displaying a content
KR102063952B1 (en) Multi display apparatus and multi display method
CN106873851A (en) Method, device and terminal that 3D regards the Widget imitated are created in interactive interface
US10289376B2 (en) Method for displaying virtual object in plural electronic devices and electronic device supporting the method
WO2020125785A1 (en) Hair rendering method, device, electronic apparatus, and storage medium
WO2016173427A1 (en) Method, device and computer readable medium for creating motion blur effect
JP7480355B2 (en) Method, device and electronic device for displaying unread messages
US20170269712A1 (en) Immersive virtual experience using a mobile communication device
KR20140046327A (en) Multi display apparatus, input pen, multi display apparatus controlling method and multi display system
KR20140139377A (en) Method and apparatus for controlling screen display using environmental information
WO2022083241A1 (en) Information guide method and apparatus
CN109725956B (en) Scene rendering method and related device
US11886673B2 (en) Trackpad on back portion of a device
CN109215007A (en) A kind of image generating method and terminal device
CN107995440A (en) Method and device for generating video subtitle texture
CN107952242A (en) A kind of terminal software experiential method, terminal and computer-readable recording medium
CN108763317A (en) A kind of auxiliary chooses the method and terminal device of picture
CN110221761A (en) Display methods and terminal device
WO2022089512A1 (en) Load control method and apparatus, and device
CN106502608A (en) Display methods, device and terminal device
CN113129417A (en) Image rendering method in panoramic application and terminal equipment
US20140229823A1 (en) Display apparatus and control method thereof
US20230110543A1 (en) Display device and method for controlling same

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
TA01 Transfer of patent application right

Effective date of registration: 20170720

Address after: 100102, 18 floor, building 2, Wangjing street, Beijing, Chaoyang District, 1801

Applicant after: BEIJING ANYUN SHIJI SCIENCE AND TECHNOLOGY CO., LTD.

Address before: 100088 Beijing city Xicheng District xinjiekouwai Street 28, block D room 112 (Desheng Park)

Applicant before: Beijing Qihu Technology Co., Ltd.

TA01 Transfer of patent application right
RJ01 Rejection of invention patent application after publication

Application publication date: 20170620

RJ01 Rejection of invention patent application after publication