WO2023077951A1 - 数据渲染方法及装置 - Google Patents
数据渲染方法及装置 Download PDFInfo
- Publication number
- WO2023077951A1 WO2023077951A1 PCT/CN2022/117194 CN2022117194W WO2023077951A1 WO 2023077951 A1 WO2023077951 A1 WO 2023077951A1 CN 2022117194 W CN2022117194 W CN 2022117194W WO 2023077951 A1 WO2023077951 A1 WO 2023077951A1
- Authority
- WO
- WIPO (PCT)
- Prior art keywords
- data
- rendered
- interaction
- skeleton layer
- renderer
- Prior art date
Links
- 238000009877 rendering Methods 0.000 title claims abstract description 91
- 238000000034 method Methods 0.000 title claims abstract description 78
- 230000003993 interaction Effects 0.000 claims description 95
- 230000002452 interceptive effect Effects 0.000 claims description 26
- 238000004590 computer program Methods 0.000 claims description 15
- 230000004044 response Effects 0.000 claims description 9
- 230000008569 process Effects 0.000 description 16
- 238000010586 diagram Methods 0.000 description 15
- 230000006870 function Effects 0.000 description 9
- 238000004891 communication Methods 0.000 description 7
- 238000012545 processing Methods 0.000 description 7
- 230000003287 optical effect Effects 0.000 description 4
- 230000009471 action Effects 0.000 description 2
- 230000000694 effects Effects 0.000 description 2
- 239000013307 optical fiber Substances 0.000 description 2
- 230000000644 propagated effect Effects 0.000 description 2
- 239000004065 semiconductor Substances 0.000 description 2
- 238000012360 testing method Methods 0.000 description 2
- 230000005540 biological transmission Effects 0.000 description 1
- 230000008878 coupling Effects 0.000 description 1
- 238000010168 coupling process Methods 0.000 description 1
- 238000005859 coupling reaction Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 239000000835 fiber Substances 0.000 description 1
- 230000010365 information processing Effects 0.000 description 1
- 239000004973 liquid crystal related substance Substances 0.000 description 1
- 238000012423 maintenance Methods 0.000 description 1
- 238000000926 separation method Methods 0.000 description 1
- 238000012546 transfer Methods 0.000 description 1
- 230000001960 triggered effect Effects 0.000 description 1
Images
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/44—Arrangements for executing specific programs
- G06F9/451—Execution arrangements for user interfaces
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F3/00—Input 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/01—Input arrangements or combined input and output arrangements for interaction between user and computer
- G06F3/048—Interaction techniques based on graphical user interfaces [GUI]
- G06F3/0487—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser
- G06F3/0489—Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser using dedicated keyboard keys or combinations thereof
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F8/00—Arrangements for software engineering
- G06F8/30—Creation or generation of source code
- G06F8/38—Creation or generation of source code for implementing user interfaces
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements 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/44—Arrangements for executing specific programs
- G06F9/445—Program loading or initiating
- G06F9/44521—Dynamic linking or loading; Link editing at or after load time, e.g. Java class loading
- G06F9/44526—Plug-ins; Add-ons
Definitions
- the embodiments of the present disclosure relate to the field of computer technologies, and in particular to a data rendering method and device.
- the internal implementation of the image editor is a black box, and all rendering implementations and interaction codes are completed internally.
- all rendering implementations and interaction codes are completed internally.
- Embodiments of the present disclosure provide a data rendering method and device.
- an embodiment of the present disclosure provides a data rendering method, including: acquiring data to be rendered; rendering basic attribute data in the data to be rendered by a skeleton layer renderer to obtain a skeleton layer; on the skeleton layer, Render the specific description data in the data to be rendered by customizing the renderer to obtain the rendered data.
- the data to be rendered includes multiple types of data to be rendered; and the above-mentioned rendering of the basic attribute data in the data to be rendered by the skeleton layer renderer to obtain the skeleton layer includes: using the skeleton layer renderer Render the basic attribute data in each type of data to be rendered to obtain multiple skeleton layers.
- the specific description data in the data to be rendered is rendered by a custom renderer to obtain the rendered data, including: for each type of data to be rendered, through the type of data to be rendered
- the custom renderer corresponding to the data renders the specific description data in the type of data to be rendered on the skeleton layer corresponding to the type of data to be rendered to obtain the rendered data.
- the basic attribute data in the data to be rendered is rendered by the skeleton layer renderer to obtain the skeleton layer, it also includes: determining the interactive events executable on the skeleton layer; Customize the interaction method to perform interactive operations on the rendered data.
- performing an interaction operation on the rendered data includes: in response to receiving a trigger operation on the rendered data, based on the user-defined interaction method corresponding to the interaction event, Render the interactive interface corresponding to the interactive event; receive and execute the interactive operation on the interactive interface.
- an embodiment of the present disclosure provides a data rendering device, including: an acquisition unit configured to acquire data to be rendered; a first rendering unit configured to render the basic The attribute data is used to obtain the skeleton layer; the second rendering unit is configured to render the specific description data in the data to be rendered through a custom renderer on the skeleton layer to obtain the rendered data.
- the data to be rendered includes multiple types of data to be rendered; and the first rendering unit is further configured to: render the basic attribute data in each type of data to be rendered by using a skeleton layer renderer, Get multiple skeleton layers.
- the second rendering unit is further configured to: for each type of data to be rendered, through the custom renderer corresponding to the type of data to be rendered, in the skeleton diagram corresponding to the type of data to be rendered The specific description data in the data to be rendered of this type is rendered on the layer to obtain the rendered data.
- the above-mentioned apparatus further includes: a determination unit configured to determine an executable interaction event on the skeleton layer; an interaction unit configured to execute the rendered data based on a custom interaction method corresponding to the interaction event interactive operation.
- the interaction unit is further configured to: in response to receiving the trigger operation on the rendered data, based on the custom interaction method corresponding to the interaction event, render the interaction interface corresponding to the interaction event; receive and execute the interaction interface interactive operation.
- an embodiment of the present disclosure provides a computer-readable medium, on which a computer program is stored, wherein, when the program is executed by a processor, the method described in any implementation manner of the first aspect is implemented.
- an embodiment of the present disclosure provides an electronic device, including: one or more processors; a storage device, on which one or more programs are stored, and when the one or more programs are executed by the one or more processors Execute, so that one or more processors implement the method described in any implementation manner of the first aspect.
- an embodiment of the present disclosure provides a computer program product including a computer program, and when the computer program is executed by a processor, the method described in any implementation manner of the first aspect can be implemented.
- FIG. 1 is an exemplary system architecture diagram to which an embodiment of the present disclosure can be applied;
- FIG. 2 is a flowchart of an embodiment of a data rendering method according to the present disclosure
- FIG. 3 is a schematic diagram of a skeleton layer obtained by the skeleton layer renderer according to this embodiment
- FIG. 4 is a schematic diagram of an application scenario of the data rendering method according to this embodiment.
- FIG. 5 is a schematic diagram of an interaction effect of rendered data according to this embodiment.
- Fig. 6 is a flow chart of another embodiment of the data rendering method according to the present disclosure.
- FIG. 7 is a schematic diagram of a network structure according to the data rendering method of the present disclosure.
- Fig. 8 is a structural diagram of an embodiment of a data rendering device according to the present disclosure.
- FIG. 9 is a schematic structural diagram of a computer system suitable for implementing the embodiments of the present disclosure.
- FIG. 1 shows an exemplary architecture 100 to which the data rendering method and device of the present disclosure can be applied.
- a system architecture 100 may include terminal devices 101 , 102 , 103 , a network 104 and a server 105 .
- the communication connections between the terminal devices 101 , 102 , and 103 constitute a topological network, and the network 104 is used to provide a communication link medium between the terminal devices 101 , 102 , 103 and the server 105 .
- Network 104 may include various connection types, such as wires, wireless communication links, or fiber optic cables, among others.
- the terminal devices 101, 102, and 103 may be hardware devices or software that support network connections for data interaction and data processing.
- the terminal devices 101, 102, 103 are hardware, they can be various electronic devices that support network connection, information acquisition, interaction, display, processing and other functions, including but not limited to smartphones, tablet computers, e-book readers, Laptops and desktop computers and more.
- the terminal devices 101, 102, 103 are software, they can be installed in the electronic devices listed above. It can be implemented, for example, as a plurality of software or software modules for providing distributed services, or as a single software or software module. No specific limitation is made here.
- the server 105 may be a server that provides various services, such as a background processing server that decouples the rendering process of basic attribute data and the rendering process of specific description data during the data rendering process based on the operation instructions of the terminal devices 101 , 102 , and 103 .
- the server may feed back the rendered data obtained by rendering to the terminal device.
- server 105 may be a cloud server.
- the server may be hardware or software.
- the server can be implemented as a distributed server cluster composed of multiple servers, or as a single server.
- the server is software, it can be implemented as multiple software or software modules (such as software or software modules for providing distributed services), or as a single software or software module. No specific limitation is made here.
- each part (for example, each unit) included in the data rendering apparatus may be all set in the server, all may be set in the terminal device, or may be respectively set in the server and the terminal device.
- the numbers of terminal devices, networks and servers in Fig. 1 are only illustrative. According to the implementation needs, there can be any number of terminal devices, networks and servers.
- the system architecture may only include the electronic device (such as a server or terminal device) on which the data rendering method runs.
- the data rendering method and device obtained by the embodiments of the present disclosure obtain the data to be rendered; render the basic attribute data in the data to be rendered by the skeleton layer renderer to obtain the skeleton layer; on the skeleton layer, use the custom renderer
- the specific description data in the data to be rendered is rendered to obtain the rendered data, thereby providing a rendering method for decoupling the rendering process of the basic attribute data and the rendering process of the specific description data, and improving the flexibility and efficiency of data rendering.
- a flow 200 of an embodiment of the data rendering method is shown, including the following steps:
- Step 201 acquire data to be rendered.
- the execution subject of the data rendering method can obtain the data to be rendered remotely or locally based on a wired connection or a wireless connection.
- the data to be rendered may be any type of data to be rendered, including but not limited to image type data and text type data.
- the data to be rendered includes basic attribute data and specific description data.
- the basic attribute data may be, for example, size information, position information, and type information of the target object;
- specific description data may be, for example, data describing specific content of the target object.
- the target object is a specific presentation of the rendered data obtained by rendering based on the data to be rendered. Taking picture data as an example, the corresponding target object is the rendered picture.
- the specific description data may be information such as pixels, resolution, and grayscale in the picture.
- the rendering process of the data to be rendered often needs to render multiple layers to combine to obtain the rendered data, that is, the data to be rendered includes data corresponding to multiple layers. As shown in the following table, specific information of a data to be rendered is shown.
- Step 202 Render the basic attribute data in the data to be rendered by the skeleton layer renderer to obtain the skeleton layer.
- the execution subject may render the basic attribute data in the data to be rendered through the skeleton layer renderer to obtain the skeleton layer.
- the skeleton layer renderer is only responsible for rendering the basic attribute data in the data to be rendered into the view container. Taking the basic attribute data as position information and size information as an example, the skeleton layer renderer can render the area of the size represented by the size information at the position indicated by the position information, so that the subsequent custom renderer can create Render the specific content.
- the data to be rendered includes multiple types of data to be rendered.
- the data to be rendered includes data to be rendered of multiple image types and data to be rendered of multiple text types.
- the data to be rendered includes data to be rendered of one type of text and data to be rendered of two types of images.
- the execution subject may perform the above step 202 in the following manner: the skeleton layer renderer renders the basic attribute data in each type of data to be rendered to obtain multiple skeleton layers.
- multiple data to be rendered belonging to the same type can be rendered to one skeleton layer, or rendered to multiple skeleton layers.
- its basic attribute data is position information and size information.
- the view container 300 rendered by the skeleton layer renderer is shown in FIG. 3 , including skeleton layers 301 and 302 corresponding to image type data, and Skeleton layer 303 corresponding to text type data.
- the skeleton layer renderer distinguishes the type of data to be rendered, and renders different skeleton layers for different types of data to be rendered, so that the skeleton layers can be rendered in an orderly manner, and the rendering efficiency is improved.
- Step 203 on the skeleton layer, use a custom renderer to render the specific description data in the data to be rendered to obtain the rendered data.
- the execution subject can render the specific description data in the data to be rendered by using a custom renderer on the skeleton layer to obtain the rendered data.
- the above execution subject may transmit the skeleton layer data representing the skeleton layer and the specific description data in the data to be rendered to the custom renderer, and the rendered data may be obtained through rendering by the custom renderer.
- the custom renderer can complete the rendering of the specific description data in any of the following ways: the rendered data is obtained based on the data to be rendered, and the rendered data is fed back to the data caller; the data caller feeds back coordinates and other information to the custom renderer , the custom renderer renders directly at the coordinate information.
- the above execution subject may perform the above step 203 in the following manner: for each type of data to be rendered, through the custom renderer corresponding to the type of data to be rendered, in the Render the specific description data in the type of data to be rendered on the skeleton layer corresponding to the type of data to be rendered to obtain the rendered data.
- the above-mentioned execution subject or the electronic device communicatively connected with the above-mentioned execution subject is provided with custom renderers corresponding to different types of data to be rendered, and each custom renderer executes the corresponding type of data to be rendered rendering tasks.
- the specific rendering functions of each custom renderer can be set by relevant technical personnel according to the actual situation, and are not limited here.
- the rendering of different types of data is performed in a targeted manner, which avoids a large number of scene branch codes in the renderer code caused by the execution of all rendering tasks by the same renderer. complicated question. Moreover, the rendering efficiency of the rendered data is improved.
- the execution subject may implement the skeleton layer renderer and various custom renderers in the form of plug-ins, so as to realize the multiplexing of renderers.
- the rendering order of the skeleton layer renderer and the custom renderer does not necessarily mean that all the skeleton layers are rendered by the skeleton layer renderer first and then the custom renderer is rendered. After a skeleton layer is finished, the subsequent rendering of the custom renderer on the skeleton layer is performed directly.
- FIG. 4 is a schematic diagram 400 of an application scenario of the data rendering method according to this embodiment.
- the server obtains the data to be rendered 401; then, the skeleton layer renderer renders the basic attribute data in the data to be rendered in the view container, such as size information and position information, to obtain the skeleton layer , 402 , 403 and 404 ; on the skeleton layers 402 , 403 and 404 , use a custom renderer to render the specific description data in the data to be rendered to obtain the rendered data 405 .
- the method provided by the above-mentioned embodiments of the present disclosure obtains the data to be rendered; renders the basic attribute data in the data to be rendered through the skeleton layer renderer to obtain the skeleton layer; on the skeleton layer, renders the data to be rendered through the custom renderer
- the specific description data in the data is used to obtain the rendered data, thereby providing a rendering method that decouples the rendering process of the basic attribute data and the rendering process of the specific description data, and improves the flexibility and efficiency of data rendering.
- the execution subject after the execution subject renders the basic attribute data in the data to be rendered by the skeleton layer renderer and obtains the skeleton layer, it may also perform the following operations:
- the execution subject may bind the interaction event executable by the user on the skeleton layer with the skeleton layer, so as to establish a connection between the skeleton layer and the interaction event.
- the interactive events executable on different skeleton layers may be the same or different, which are specifically set according to specific situations, and are not limited here. Users can interact with the rendered data based on the interaction events that can be performed on the skeleton layer.
- the interaction event may be related mouse or keyboard events such as click (click), mousedown (mouse is pressed), mouseover (mouse slides over), and the like.
- a corresponding custom interaction method may be set in the execution subject or a terminal device communicatively connected with the execution subject, and the user of the custom interaction method executes a corresponding response according to an interaction operation.
- the interaction event is clicking on a picture
- the response from the custom interaction method is an instruction interface prompting the user to rotate the picture.
- the above execution subject may perform the above second step in the following manner:
- the interaction interface corresponding to the interaction event is rendered; then, the interaction operation on the interaction interface is received and executed.
- the triggering operation may be any operation related to the rendered data.
- the triggering action could be mouse over the rendered data.
- 4 custom click events are bound to the skeleton layer corresponding to the rendered data.
- the 4 bound events are: rendering rotation UI (User Interface, user interface) to the interactive container; rendering click Replace the picture UI to the interactive container; render 8 stretched ICONs (icons) to the interactive container; render the status box to the interactive container when the layer is selected.
- an effect diagram 500 corresponding to the above four interaction events is shown.
- interaction event corresponding to the skeleton layer can be bound after the rendering of the corresponding skeleton layer is completed, or the event can be uniformly performed on each skeleton layer after the rendering of all the skeleton layers is completed. Binding is not limited here.
- FIG. 6 a schematic flow 600 of an embodiment of the data rendering method according to the present disclosure is shown, including the following steps:
- Step 601 acquire data to be rendered.
- the data to be rendered includes multiple types of data to be rendered.
- Step 602 Render the basic attribute data in each type of data to be rendered by the skeleton layer renderer to obtain multiple skeleton layers.
- Step 603 determine executable interaction events on each skeleton layer.
- Step 604 for each type of data to be rendered, use the custom renderer corresponding to the type of data to be rendered to render the specific description in the type of data to be rendered on the skeleton layer corresponding to the type of data to be rendered Data, get the rendered data.
- Step 605 in response to receiving a trigger operation on the rendered data, based on the custom interaction method corresponding to the interaction event, the interaction interface corresponding to the interaction event is rendered.
- Step 606 receiving and executing an interactive operation on the interactive interface.
- the process 600 of the data rendering method in this embodiment specifically illustrates the rendering process and interaction process of decoupling data.
- Different scenarios only need to be customized Write different renderers in a different way or load the plug-ins corresponding to different renderers to achieve the purpose of on-demand use, thereby reducing the size of the editor for data rendering; and in different scenarios, the interaction can be realized through custom events .
- the separation of business codes reduces the cost of post-maintenance. Developers can also encapsulate codes and plug-in them to make them reusable.
- the specific flow of the data rendering method involves the calling side 701 , skeleton layer renderer 702 , custom renderer 703 , interaction event binding 704 , event registration 705 and interaction container 706 .
- the data to be rendered is transmitted to the skeleton layer renderer, and the skeleton layer renderer renders the basic attribute information such as size information and position information to obtain the skeleton layer.
- the interaction event is registered on the interaction container, and the rendered data is fed back to the user layer.
- the calling side triggers an interaction event.
- the custom interaction method corresponding to the triggered interaction event based on the data of the interaction event, renders the interaction interface in the interaction container, and feeds back the interaction interface to the calling side.
- the calling side triggers the interactive interface, and the skeleton layer renderer updates the skeleton layer based on the operations in the interactive interface.
- the custom renderer updates the specific description data, obtains the updated rendered data, and feeds back the updated data to be rendered to the user.
- the present disclosure provides an embodiment of a data rendering device.
- the device embodiment corresponds to the method embodiment shown in FIG. 2 , and the device can specifically Used in various electronic equipment.
- the data rendering device includes: an acquisition unit 801 configured to acquire data to be rendered; a first rendering unit 802 configured to render basic attribute data in the data to be rendered by a skeleton layer renderer to obtain a skeleton layer; the second rendering unit 803 is configured to render the specific description data in the data to be rendered by using a custom renderer on the skeleton layer to obtain the rendered data.
- the data to be rendered includes multiple types of data to be rendered; and the first rendering unit 802 is further configured to: render each type of data to be rendered by using a skeleton layer renderer Render the basic attribute data in the data to get multiple skeleton layers.
- the second rendering unit 803 is further configured to: for each type of data to be rendered, through the custom renderer corresponding to the type of data to be rendered, in this type Render the specific description data in the type of data to be rendered on the skeleton layer corresponding to the data to be rendered to obtain the rendered data.
- the above-mentioned device further includes: a determination unit (not shown in the figure), configured to determine an executable interaction event on the skeleton layer; an interaction unit (not shown in the figure) Out), configured to perform interactive operations on the rendered data based on the custom interaction method corresponding to the interaction event.
- the interaction unit (not shown in the figure) is further configured to: in response to receiving a trigger operation on the rendered data, based on a custom interaction method corresponding to the interaction event, Render the interactive interface corresponding to the interactive event; receive and execute the interactive operation on the interactive interface.
- the acquisition unit in the data rendering device acquires the data to be rendered; the first rendering unit renders the basic attribute data in the data to be rendered through the skeleton layer renderer to obtain the skeleton layer; the second rendering unit obtains the skeleton layer
- the rendering unit obtains the skeleton layer
- FIG. 9 shows a schematic structural diagram of a computer system 900 suitable for implementing the devices of the embodiments of the present disclosure (such as the devices 101 , 102 , 103 , and 105 shown in FIG. 1 ).
- the device shown in FIG. 9 is only an example, and should not limit the functions and scope of use of the embodiments of the present disclosure.
- a computer system 900 includes a processor (such as CPU, central processing unit) 901, which can be loaded into a random access memory (RAM) according to a program stored in a read-only memory (ROM) 902 or from a storage section 908.
- the program in 903 performs various appropriate actions and processing.
- various programs and data necessary for the operation of the system 900 are also stored.
- the processor 901 , ROM 902 , and RAM 903 are connected to each other via a bus 904 .
- An input/output (I/O) interface 905 is also connected to the bus 904 .
- the following components are connected to the I/O interface 905: an input section 906 including a keyboard, a mouse, etc.; an output section 907 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker; a storage section 908 including a hard disk, etc. and a communication section 909 including a network interface card such as a LAN card, a modem, or the like.
- the communication section 909 performs communication processing via a network such as the Internet.
- a drive 910 is also connected to the I/O interface 905 as needed.
- a removable medium 911 such as a magnetic disk, optical disk, magneto-optical disk, semiconductor memory, etc. is mounted on the drive 910 as necessary so that a computer program read therefrom is installed into the storage section 908 as necessary.
- embodiments of the present disclosure include a computer program product, which includes a computer program carried on a computer-readable medium, where the computer program includes program codes for executing the methods shown in the flowcharts.
- the computer program may be downloaded and installed from a network via communication portion 909 and/or installed from removable media 911 .
- the processor 901 When the computer program is executed by the processor 901, the above-mentioned functions defined in the methods of the present disclosure are performed.
- the computer-readable medium in the present disclosure may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two.
- a computer readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of computer-readable storage media may include, but are not limited to, electrical connections with one or more wires, portable computer diskettes, hard disks, random access memory (RAM), read-only memory (ROM), erasable Programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination of the above.
- a computer-readable storage medium may be any tangible medium that contains or stores a program that can be used by or in conjunction with an instruction execution system, apparatus, or device.
- a computer-readable signal medium may include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code therein. Such propagated data signals may take many forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the foregoing.
- a computer-readable signal medium may also be any computer-readable medium other than a computer-readable storage medium, which can send, propagate, or transmit a program for use by or in conjunction with an instruction execution system, apparatus, or device.
- Program code embodied on a computer readable medium may be transmitted using any appropriate medium, including but not limited to wireless, wireline, optical fiber cable, RF, etc., or any suitable combination of the foregoing.
- Computer program code for carrying out the operations of the present disclosure can be written in one or more programming languages, or combinations thereof, including object-oriented programming languages—such as Java, Smalltalk, C++, and conventional procedural programming language—such as "C" or a similar programming language.
- the program code may execute entirely on the client computer, partly on the client computer, as a stand-alone software package, partly on the client computer and partly on a remote computer or entirely on the remote computer or server.
- the remote computer can be connected to the client computer through any kind of network, including a local area network (LAN) or a wide area network (WAN), or it can be connected to an external computer (such as through an Internet service provider). Internet connection).
- LAN local area network
- WAN wide area network
- Internet service provider such as AT&T, MCI, Sprint, EarthLink, MSN, GTE, etc.
- each block in a flowchart or block diagram may represent a module, program segment, or portion of code that contains one or more logical functions for implementing specified executable instructions.
- the functions noted in the block may occur out of the order noted in the figures. For example, two blocks shown in succession may, in fact, be executed substantially concurrently, or they may sometimes be executed in the reverse order, depending upon the functionality involved.
- each block of the block diagrams and/or flowchart illustrations, and combinations of blocks in the block diagrams and/or flowchart illustrations can be implemented by a dedicated hardware-based system that performs the specified functions or operations , or may be implemented by a combination of dedicated hardware and computer instructions.
- the units involved in the embodiments described in the present disclosure may be implemented by software or by hardware.
- the described units may also be set in a processor, for example, may be described as: a processor including an acquisition unit, a first rendering unit, and a second rendering unit.
- the names of these units do not constitute a limitation of the unit itself under certain circumstances.
- the second rendering unit can also be described as "on the skeleton layer, use a custom renderer to render the data to be rendered Specifically describe the data and get the unit of the rendered data.”
- the present disclosure also provides a computer-readable medium, which may be included in the device described in the above embodiments, or may exist independently without being assembled into the device.
- the above-mentioned computer-readable medium carries one or more programs, and when the above-mentioned one or more programs are executed by the device, the computer device: obtains the data to be rendered; renders the basic attributes in the data to be rendered through the skeleton layer renderer Data to get the skeleton layer; on the skeleton layer, use the custom renderer to render the specific description data in the data to be rendered to get the rendered data.
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- General Engineering & Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Physics & Mathematics (AREA)
- Human Computer Interaction (AREA)
- Image Generation (AREA)
Abstract
本公开公开了一种数据渲染方法及装置。方法的一具体实施方式包括:获取待渲染数据;通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
Description
相关申请的交叉引用
本专利申请要求于2021年11月8日提交的、申请号为202111312862.4、发明名称为“数据渲染方法及装置”的中国专利申请的优先权,该申请的全文以引用的方式并入本申请中。
本公开实施例涉及计算机技术领域,具体涉及一种数据渲染方法及装置。
目前,图片编辑器内部实现属于一个黑盒,所有的渲染实现及交互代码都在内部完成,导致如果某一个场景只需要部分功能,或在不同的场景下图层的交互不同,容易使编辑器内部耦合业务场景代码,在代码层会出现大量场景分支,使得后期的问题成本提高,且扩展性也受限。
发明内容
本公开实施例提出了一种数据渲染方法及装置。
第一方面,本公开实施例提供了一种数据渲染方法,包括:获取待渲染数据;通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
在一些实施例中,待渲染数据中包括多种类型的待渲染数据;以及上述通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层,包括:通过骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
在一些实施例中,上述在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据,包括:对于每种类型 的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到渲染后数据。
在一些实施例中,在上述通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层之后,还包括:确定在骨架图层上可执行的交互事件;基于交互事件对应的自定义交互方法,执行对于渲染后数据的交互操作。
在一些实施例中,上述基于交互事件对应的自定义交互方法,执行对于渲染后数据的交互操作,包括:响应于接收到对渲染后数据的触发操作,基于交互事件对应的自定义交互方法,渲染交互事件对应的交互界面;接收并执行对交互界面的交互操作。
第二方面,本公开实施例提供了一种数据渲染装置,包括:获取单元,被配置成获取待渲染数据;第一渲染单元,被配置成通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;第二渲染单元,被配置成在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
在一些实施例中,待渲染数据中包括多种类型的待渲染数据;以及第一渲染单元,进一步被配置成:通过骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
在一些实施例中,第二渲染单元,进一步被配置成:对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到渲染后数据。
在一些实施例中,上述装置还包括:确定单元,被配置成确定在骨架图层上可执行的交互事件;交互单元,被配置成基于交互事件对应的自定义交互方法,执行对于渲染后数据的交互操作。
在一些实施例中,交互单元,进一步被配置成:响应于接收到对渲染后数据的触发操作,基于交互事件对应的自定义交互方法,渲染交互事件对应的交互界面;接收并执行对交互界面的交互操作。
第三方面,本公开实施例提供了一种计算机可读介质,其上存储 有计算机程序,其中,程序被处理器执行时实现如第一方面任一实现方式描述的方法。
第四方面,本公开实施例提供了一种电子设备,包括:一个或多个处理器;存储装置,其上存储有一个或多个程序,当一个或多个程序被一个或多个处理器执行,使得一个或多个处理器实现如第一方面任一实现方式描述的方法。
第五方面,本公开实施例提供了一种包括计算机程序的计算机程序产品,该计算机程序在被处理器执行时能够实现如第一方面任一实现方式描述的方法。
通过阅读参照以下附图所作的对非限制性实施例所作的详细描述,本公开的其它特征、目的和优点将会变得更明显:
图1是本公开的一个实施例可以应用于其中的示例性系统架构图;
图2是根据本公开数据渲染方法的一个实施例的流程图;
图3是根据本实施例的骨架图层渲染器得到的骨架图层的示意图;
图4是根据本实施例的数据渲染方法的应用场景的示意图;
图5是根据本实施例的渲染后数据的交互效果示意图;
图6是根据本公开的数据渲染方法的又一个实施例的流程图;
图7是根据本公开数据渲染方法的网络结构示意图;
图8是根据本公开的数据渲染装置的一个实施例的结构图;
图9是适于用来实现本公开实施例的计算机系统的结构示意图。
下面结合附图和实施例对本公开作进一步的详细说明。可以理解的是,此处所描述的具体实施例仅仅用于解释相关发明,而非对该发明的限定。另外还需要说明的是,为了便于描述,附图中仅示出了与有关发明相关的部分。
需要说明的是,在不冲突的情况下,本公开中的实施例及实施例中的特征可以相互组合。下面将参考附图并结合实施例来详细说明本 公开。
图1示出了可以应用本公开的数据渲染方法及装置的示例性架构100。
如图1所示,系统架构100可以包括终端设备101、102、103,网络104和服务器105。终端设备101、102、103之间通信连接构成拓扑网络,网络104用以在终端设备101、102、103和服务器105之间提供通信链路的介质。网络104可以包括各种连接类型,例如有线、无线通信链路或者光纤电缆等等。
用户可以使用终端设备101、102、103通过网络104与服务器105交互,以接收或发送消息等。终端设备101、102、103可以是支持网络连接从而进行数据交互和数据处理的硬件设备或软件。当终端设备101、102、103为硬件时,其可以是支持网络连接,信息获取、交互、显示、处理等功能的各种电子设备,包括但不限于智能手机、平板电脑、电子书阅读器、膝上型便携计算机和台式计算机等等。当终端设备101、102、103为软件时,可以安装在上述所列举的电子设备中。其可以实现成例如用来提供分布式服务的多个软件或软件模块,也可以实现成单个软件或软件模块。在此不做具体限定。
服务器105可以是提供各种服务的服务器,例如基于终端设备101、102、103的操作指令,在数据渲染过程中,解耦合基本属性数据的渲染过程和具体描述数据的渲染过程的后台处理服务器。可选的,服务器可以将渲染得到的渲染后数据反馈至终端设备。作为示例,服务器105可以是云端服务器。
需要说明的是,服务器可以是硬件,也可以是软件。当服务器为硬件时,可以实现成多个服务器组成的分布式服务器集群,也可以实现成单个服务器。当服务器为软件时,可以实现成多个软件或软件模块(例如用来提供分布式服务的软件或软件模块),也可以实现成单个软件或软件模块。在此不做具体限定。
还需要说明的是,本公开的实施例所提供的数据渲染方法可以由服务器执行,也可以由终端设备执行,还可以由服务器和终端设备彼此配合执行。相应地,数据渲染装置包括的各个部分(例如各个单元) 可以全部设置于服务器中,也可以全部设置于终端设备中,还可以分别设置于服务器和终端设备中。
应该理解,图1中的终端设备、网络和服务器的数目仅仅是示意性的。根据实现需要,可以具有任意数目的终端设备、网络和服务器。当数据渲染方法运行于其上的电子设备不需要与其他电子设备进行数据传输时,该系统架构可以仅包括数据渲染方法运行于其上的电子设备(例如服务器或终端设备)。
本公开实施例提供的数据渲染方法及装置,通过获取待渲染数据;通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据,从而提供了一种解耦合基本属性数据的渲染过程和具体描述数据的渲染过程的渲染方法,提高了数据渲染的灵活性和效率。
继续参考图2,示出了数据渲染方法的一个实施例的流程200,包括以下步骤:
步骤201,获取待渲染数据。
本实施例中,数据渲染方法的执行主体(例如图1中的终端设备或服务器)可以基于有线连接方式或无线连接方式从远程,或从本地获取待渲染数据。
待渲染数据可以是待渲染的任意类型的数据,包括但不限于是图片类型数据、文本类型数据。待渲染数据包括基本属性数据和具体描述数据。其中,基本属性数据例如可以是目标对象的尺寸信息、位置信息、类型信息;具体描述数据例如可以是描述目标对象的具体内容的数据。
目标对象是基于待渲染数据渲染得到的渲染后数据的具体呈现。以图片数据为例,其对应的目标对象即为渲染得到的图片。其具体描述数据可以是图片中的像素、分辨率、灰度等信息。
待渲染数据的渲染过程往往需要渲染多种图层以组合得到渲染后数据,也即,待渲染数据中包括多种图层对应的数据。如下表所示, 示出了一个待渲染数据的具体信息。
图层ID | 图层类型 | 坐标 | 宽高 | 图片地址 | 文本 | …… |
1 | 图片 | 100,69 | 200,100 | test.png | ||
2 | 图片 | 230,178 | 187,67 | Test2.png | ||
3 | 文本 | 300,0 | 200,50 | 这是测试 |
步骤202,通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层。
本实施例中,上述执行主体可以通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层。
骨架图层渲染器只负责渲染待渲染数据中的基本属性数据渲染到视图容器里。以基本属性数据为位置信息和尺寸信息为例,骨架图层渲染器可以在位置信息所指示的位置处,渲染尺寸信息所表征的尺寸的区域,以供后续的自定义渲染器在骨架图层进行具体内容的渲染。
在本实施例的一些可选的实现方式中,待渲染数据中包括多种类型的待渲染数据。例如,待渲染数据中同时包括多种图片类型的待渲染数据和多种文本类型的待渲染数据。继续参见上述列表,待渲染数据中即包括一种文本类型的待渲染数据和两种图片类型的待渲染数据。
本实现方式中,上述执行主体可以通过如下方式执行上述步骤202:通过骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
其中,属于同一种类型下的多个待渲染数据可以被渲染至一个骨架图层,也可以渲染至多个骨架图层。继续参见上述列表,其基本属性数据为位置信息和尺寸信息,通过骨架图层渲染器进行渲染后的视图容器300如图3所示,包括对应于图片类型数据的骨架图层301、302,以及对应于文本类型数据的骨架图层303。
本实现方式中,骨架图层渲染器区分待渲染数据所属的类型,不同类型待渲染数据渲染不同的骨架图层,可有序地渲染骨架图层,提高了渲染效率。
步骤203,在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
本实施例中,上述执行主体可以在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
作为示例,上述执行主体可以将表征骨架图层的骨架图层数据和待渲染数据中的具体描述数据传输给自定义渲染器,通过自定义渲染器渲染得到渲染后数据。
自定义渲染器可以通过如下任意方式完成具体描述数据的渲染:基于待渲染数据渲染得到渲染后数据,并将渲染后数据反馈至数据调用者;数据调用者将坐标等信息反馈至自定义渲染器,自定义渲染器直接在坐标信息处进行渲染。
在本实施例的一些可选的实现方式中,上述执行主体可以通过如下方式执行上述步骤203:对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到渲染后数据。
本实现方式中,上述执行主体或与上述执行主体通信连接的电子设备中设置有对应于不同类型的待渲染数据的自定义渲染器,每种自定义渲染器执行所对应的类型的待渲染数据的渲染任务。每种自定义渲染器的具体渲染功能可根据实际情况由相关技术人进行设置,在此不做限定。
通过设置不同类型的待渲染数据的自定义渲染器,有针对性地执行不同类型的数据的渲染,避免了由同一渲染器执行所有的渲染任务而造成的渲染器代码出现大量场景分支代码,代码复杂的问题。并且,提高了渲染后数据的渲染效率。
在本实施例的一些可选的实现方式中,上述执行主体可以采用插件的形式实现骨架图层渲染器和各种自定义渲染器,以实现渲染器的复用。
需要说明的是,骨架图层渲染器和自定义渲染器的渲染顺序并不一定是先通过骨架图层渲染器渲染完所有的骨架图层后再执行自定义渲染器的渲染,也可以在渲染完一个骨架图层后直接执行自定义渲染器在该骨架图层上的后续渲染。
继续参见图4,图4是根据本实施例的数据渲染方法的应用场景的一个示意图400。在图4的应用场景中,首先,服务器获取待渲染数据401;然后,通过骨架图层渲染器在视图容器中渲染待渲染数据中的基本属性数据,例如尺寸信息、位置信息,得到骨架图层、402、403和404;在骨架图层402、403和404上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据405。
本公开的上述实施例提供的方法,获取待渲染数据;通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据,从而提供了一种解耦合基本属性数据的渲染过程和具体描述数据的渲染过程的渲染方法,提高了数据渲染的灵活性和效率。
在本实施例的一些可选的实现方式中,上述执行主体在通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层之后,还可以执行如下操作:
第一,确定在骨架图层上可执行的交互事件。
具体的,上述执行主体可以将用户在骨架图层上可执行的交互事件与该骨架图层进行绑定,从而建立骨架图层与交互事件之间的联系。其中,在不同的骨架图层上可执行的交互事件可以相同也可以不同,其根据具体情况具体设置,在此不做限定。基于在骨架图层上可执行的交互事件,用户可以与渲染后数据进行交互。
作为示例,交互事件例如可以是click(点击)、mousedown(按鼠标)、mouseover(鼠标滑过)等相关的鼠标或键盘事件。
第二,基于交互事件对应的自定义交互方法,执行对于渲染后数据的交互操作。
本实现方式中,对于每种交互事件,可以在上述执行主体或与上述执行主体通信连接的终端设备中设置所对应的自定义交互方法,自定义交互方法用户根据交互操作,执行对应的响应。
作为示例,交互事件为点击图片,自定义交互方法做出的响应为提示用户旋转图片的指示界面。
本实现方式中,解耦合数据的渲染过程和交互过程,提高了数据渲染和交互之间的灵活性。
在本实施例的一些可选的实现方式中,上述执行主体可以通过如下方式执行上述第二步骤:
首先,响应于接收到对渲染后数据的触发操作,基于交互事件对应的自定义交互方法,渲染交互事件对应的交互界面;然后,接收并执行对交互界面的交互操作。
其中,触发操作可以是与渲染后数据相关的任意操作。作为示例,触发操作可以是鼠标在渲染后数据上滑过。
作为示例,在渲染后数据对应的骨架图层中绑定了4个自定义的点击事件,该绑定的4个事件分别为:渲染旋转UI(User Interface,用户界面)到交互容器;渲染点击替换图片UI到交互容器;渲染8个拉伸ICON(图标)到交互容器;渲染图层选中时状态框到交互容器。
参考图5,示出了上述4个交互事件对应的效果图500。在点击渲染后数据所表征的图片501后,展示用于指示用户旋转图片501的指示信息502,用于指示用户替换图片501的指示信息503,用于指示用户向上、下、左、右、左上、左下、右上、右下8个方向拉伸的指示信息504以及表示选中图片501的状态框505。
需要说明的是,骨架图层对应的交互事件可以在完成所对应的骨架图层的渲染后即进行绑定,也可以在完成所有的骨架图层的渲染后,统一对各骨架图层进行事件绑定,在此不做限定。
继续参考图6,示出了根据本公开的数据渲染方法的一个实施例的示意性流程600,包括如下步骤:
步骤601,获取待渲染数据。
待渲染数据中包括多种类型的待渲染数据。
步骤602,通过骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
步骤603,确定在每个骨架图层上可执行的交互事件。
步骤604,对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到渲染后数据。
步骤605,响应于接收到对渲染后数据的触发操作,基于交互事件对应的自定义交互方法,渲染交互事件对应的交互界面。
步骤606,接收并执行对交互界面的交互操作。
从本实施例中可以看出,与图2对应的实施例相比,本实施例中的数据渲染方法的流程600具体说明了解耦合数据的渲染过程和交互过程,不同的场景只需按自定义的方式编写不同渲染器或通过加载不同渲染器对应的插件,达到按需使用的目的,从而减少用于数据渲染的编辑器的体积;并且在不同的场景下可通过自定义事件的方式实现交互,业务代码分离,降低为后期维护成本,开发者也可封装代码,进行插件化,使其具备可复用性。
为了进一步说明本公开,给出关于数据渲染和数据交互的一种具体的处理流程:
如图7所示,示出了数据渲染方法的具体流程涉及调用侧701、骨架图层渲染器702、自定义渲染器703、交互事件绑定704、事件注册705和交互容器706。
具体的,其信息处理流程如下:
1、待渲染数据传输至骨架图层渲染器,骨架图层渲染器渲染其中的尺寸信息、位置信息等基本属性信息,得到骨架图层。
2、将骨架图层和待渲染数据传输至自定义渲染器,自定义渲染器在骨架图层上渲染待渲染数据,得到渲染后数据。
3、在骨架图层上绑定可执行的交互事件。
4、基于交互事件对应的自定义交互方法,在交互容器上注册交互事件,并向用户层反馈渲染后数据。
5、调用侧触发交互事件。
6、所触发的交互事件对应的自定义交互方法,基于交互事件的数据,在交互容器中渲染交互界面,并向调用侧反馈交互界面。
7、调用侧触发交互界面,骨架图层渲染器基于在交互界面中的操作更新骨架图层。
8、自定义渲染器更新具体描述数据,得到更新后的渲染后数据,并向用户反馈更新后的待渲染数据。
继续参考图8,作为对上述各图所示方法的实现,本公开提供了一种数据渲染装置的一个实施例,该装置实施例与图2所示的方法实施例相对应,该装置具体可以应用于各种电子设备中。
如图8所示,数据渲染装置包括:获取单元801,被配置成获取待渲染数据;第一渲染单元802,被配置成通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;第二渲染单元803,被配置成在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
在本实施例的一些可选的实现方式中,待渲染数据中包括多种类型的待渲染数据;以及第一渲染单元802,进一步被配置成:通过骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
在本实施例的一些可选的实现方式中,第二渲染单元803,进一步被配置成:对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到渲染后数据。
在本实施例的一些可选的实现方式中,上述装置还包括:确定单元(图中未示出),被配置成确定在骨架图层上可执行的交互事件;交互单元(图中未示出),被配置成基于交互事件对应的自定义交互方法,执行对于渲染后数据的交互操作。
在本实施例的一些可选的实现方式中,交互单元(图中未示出),进一步被配置成:响应于接收到对渲染后数据的触发操作,基于交互事件对应的自定义交互方法,渲染交互事件对应的交互界面;接收并执行对交互界面的交互操作。
本实施例中,数据渲染装置中的获取单元获取待渲染数据;第一 渲染单元通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;第二渲染单元在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据,从而提供了一种解耦合基本属性数据的渲染过程和具体描述数据的渲染过程的渲染装置,提高了数据渲染的灵活性和效率。
下面参考图9,其示出了适于用来实现本公开实施例的设备(例如图1所示的设备101、102、103、105)的计算机系统900的结构示意图。图9示出的设备仅仅是一个示例,不应对本公开实施例的功能和使用范围带来任何限制。
如图9所示,计算机系统900包括处理器(例如CPU,中央处理器)901,其可以根据存储在只读存储器(ROM)902中的程序或者从存储部分908加载到随机访问存储器(RAM)903中的程序而执行各种适当的动作和处理。在RAM903中,还存储有系统900操作所需的各种程序和数据。处理器901、ROM902以及RAM903通过总线904彼此相连。输入/输出(I/O)接口905也连接至总线904。
以下部件连接至I/O接口905:包括键盘、鼠标等的输入部分906;包括诸如阴极射线管(CRT)、液晶显示器(LCD)等以及扬声器等的输出部分907;包括硬盘等的存储部分908;以及包括诸如LAN卡、调制解调器等的网络接口卡的通信部分909。通信部分909经由诸如因特网的网络执行通信处理。驱动器910也根据需要连接至I/O接口905。可拆卸介质911,诸如磁盘、光盘、磁光盘、半导体存储器等等,根据需要安装在驱动器910上,以便于从其上读出的计算机程序根据需要被安装入存储部分908。
特别地,根据本公开的实施例,上文参考流程图描述的过程可以被实现为计算机软件程序。例如,本公开的实施例包括一种计算机程序产品,其包括承载在计算机可读介质上的计算机程序,该计算机程序包含用于执行流程图所示的方法的程序代码。在这样的实施例中,该计算机程序可以通过通信部分909从网络上被下载和安装,和/或从可拆卸介质911被安装。在该计算机程序被处理器901执行时,执行 本公开的方法中限定的上述功能。
需要说明的是,本公开的计算机可读介质可以是计算机可读信号介质或者计算机可读存储介质或者是上述两者的任意组合。计算机可读存储介质例如可以是——但不限于——电、磁、光、电磁、红外线、或半导体的系统、装置或器件,或者任意以上的组合。计算机可读存储介质的更具体的例子可以包括但不限于:具有一个或多个导线的电连接、便携式计算机磁盘、硬盘、随机访问存储器(RAM)、只读存储器(ROM)、可擦式可编程只读存储器(EPROM或闪存)、光纤、便携式紧凑磁盘只读存储器(CD-ROM)、光存储器件、磁存储器件、或者上述的任意合适的组合。在本公开中,计算机可读存储介质可以是任何包含或存储程序的有形介质,该程序可以被指令执行系统、装置或者器件使用或者与其结合使用。而在本公开中,计算机可读的信号介质可以包括在基带中或者作为载波一部分传播的数据信号,其中承载了计算机可读的程序代码。这种传播的数据信号可以采用多种形式,包括但不限于电磁信号、光信号或上述的任意合适的组合。计算机可读的信号介质还可以是计算机可读存储介质以外的任何计算机可读介质,该计算机可读介质可以发送、传播或者传输用于由指令执行系统、装置或者器件使用或者与其结合使用的程序。计算机可读介质上包含的程序代码可以用任何适当的介质传输,包括但不限于:无线、电线、光缆、RF等等,或者上述的任意合适的组合。
可以以一种或多种程序设计语言或其组合来编写用于执行本公开的操作的计算机程序代码,程序设计语言包括面向目标的程序设计语言—诸如Java、Smalltalk、C++,还包括常规的过程式程序设计语言—诸如”C”语言或类似的程序设计语言。程序代码可以完全地在客户计算机上执行、部分地在客户计算机上执行、作为一个独立的软件包执行、部分在客户计算机上部分在远程计算机上执行、或者完全在远程计算机或服务器上执行。在涉及远程计算机的情形中,远程计算机可以通过任意种类的网络——包括局域网(LAN)或广域网(WAN)—连接到客户计算机,或者,可以连接到外部计算机(例如利用因特网服务提供商来通过因特网连接)。
附图中的流程图和框图,图示了按照本公开各种实施例的装置、方法和计算机程序产品的可能实现的体系架构、功能和操作。在这点上,流程图或框图中的每个方框可以代表一个模块、程序段、或代码的一部分,该模块、程序段、或代码的一部分包含一个或多个用于实现规定的逻辑功能的可执行指令。也应当注意,在有些作为替换的实现中,方框中所标注的功能也可以以不同于附图中所标注的顺序发生。例如,两个接连地表示的方框实际上可以基本并行地执行,它们有时也可以按相反的顺序执行,这依所涉及的功能而定。也要注意的是,框图和/或流程图中的每个方框、以及框图和/或流程图中的方框的组合,可以用执行规定的功能或操作的专用的基于硬件的系统来实现,或者可以用专用硬件与计算机指令的组合来实现。
描述于本公开实施例中所涉及到的单元可以通过软件的方式实现,也可以通过硬件的方式来实现。所描述的单元也可以设置在处理器中,例如,可以描述为:一种处理器,包括获取单元、第一渲染单元和第二渲染单元。其中,这些单元的名称在某种情况下并不构成对该单元本身的限定,例如,第二渲染单元还可以被描述为“在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据的单元”。
作为另一方面,本公开还提供了一种计算机可读介质,该计算机可读介质可以是上述实施例中描述的设备中所包含的;也可以是单独存在,而未装配入该设备中。上述计算机可读介质承载有一个或者多个程序,当上述一个或者多个程序被该装置执行时,使得该计算机设备:获取待渲染数据;通过骨架图层渲染器渲染待渲染数据中的基本属性数据,得到骨架图层;在骨架图层上,通过自定义渲染器渲染待渲染数据中的具体描述数据,得到渲染后数据。
以上描述仅为本公开的较佳实施例以及对所运用技术原理的说明。本领域技术人员应当理解,本公开中所涉及的发明范围,并不限于上述技术特征的特定组合而成的技术方案,同时也应涵盖在不脱离上述发明构思的情况下,由上述技术特征或其等同特征进行任意组合而形成的其它技术方案。例如上述特征与本公开中公开的(但不限于)具有 类似功能的技术特征进行互相替换而形成的技术方案。
Claims (13)
- 一种数据渲染方法,包括:获取待渲染数据;通过骨架图层渲染器渲染所述待渲染数据中的基本属性数据,得到骨架图层;在所述骨架图层上,通过自定义渲染器渲染所述待渲染数据中的具体描述数据,得到渲染后数据。
- 根据权利要求1所述的方法,其中,所述待渲染数据中包括多种类型的待渲染数据;以及所述通过骨架图层渲染器渲染所述待渲染数据中的基本属性数据,得到骨架图层,包括:通过所述骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
- 根据权利要求2所述的方法,其中,所述在所述骨架图层上,通过自定义渲染器渲染所述待渲染数据中的具体描述数据,得到渲染后数据,包括:对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到所述渲染后数据。
- 根据权利要求1-3中任一项所述的方法,其中,在所述通过骨架图层渲染器渲染所述待渲染数据中的基本属性数据,得到骨架图层之后,还包括:确定在所述骨架图层上可执行的交互事件;基于所述交互事件对应的自定义交互方法,执行对于所述渲染后数据的交互操作。
- 根据权利要求4所述的方法,其中,所述基于所述交互事件对应的自定义交互方法,执行对于所述渲染后数据的交互操作,包括:响应于接收到对所述渲染后数据的触发操作,基于所述交互事件对应的自定义交互方法,渲染所述交互事件对应的交互界面;接收并执行对所述交互界面的交互操作。
- 一种数据渲染装置,包括:获取单元,被配置成获取待渲染数据;第一渲染单元,被配置成通过骨架图层渲染器渲染所述待渲染数据中的基本属性数据,得到骨架图层;第二渲染单元,被配置成在所述骨架图层上,通过自定义渲染器渲染所述待渲染数据中的具体描述数据,得到渲染后数据。
- 根据权利要求6所述的装置,其中,所述待渲染数据中包括多种类型的待渲染数据;以及所述第一渲染单元,进一步被配置成:通过所述骨架图层渲染器渲染每种类型的待渲染数据中的基本属性数据,得到多个骨架图层。
- 根据权利要求7所述的装置,其中,所述第二渲染单元,进一步被配置成:对于每种类型的待渲染数据,通过该类型的待渲染数据对应的自定义渲染器,在该类型的待渲染数据对应的骨架图层上渲染该类型的待渲染数据中的具体描述数据,得到所述渲染后数据。
- 根据权利要求6-8中任一项所述的装置,其中,还包括:确定单元,被配置成确定在所述骨架图层上可执行的交互事件;交互单元,被配置成基于所述交互事件对应的自定义交互方法,执行对于所述渲染后数据的交互操作。
- 根据权利要求9所述的装置,其中,所述交互单元,进一步被配置成:响应于接收到对所述渲染后数据的触发操作,基于所述交互事件对应的自定义交互方法,渲染所述交互事件对应的交互界面;接收并执行对所述交互界面的交互操作。
- 一种计算机可读介质,其上存储有计算机程序,其中,所述程序被处理器执行时实现权利要求1-5中任一所述的方法。
- 一种电子设备,包括:一个或多个处理器;存储装置,其上存储有一个或多个程序,当所述一个或多个程序被所述一个或多个处理器执行,使得所述一个或多个处理器实现权利要求1-5中任一所述的方法。
- 一种计算机程序产品,包括计算机程序,所述计算机程序在被处理器执行时实现权利要求1-5中任一所述的方法。
Applications Claiming Priority (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202111312862.4 | 2021-11-08 | ||
CN202111312862.4A CN114064172A (zh) | 2021-11-08 | 2021-11-08 | 数据渲染方法及装置 |
Publications (1)
Publication Number | Publication Date |
---|---|
WO2023077951A1 true WO2023077951A1 (zh) | 2023-05-11 |
Family
ID=80274119
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
PCT/CN2022/117194 WO2023077951A1 (zh) | 2021-11-08 | 2022-09-06 | 数据渲染方法及装置 |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN114064172A (zh) |
WO (1) | WO2023077951A1 (zh) |
Cited By (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116594718A (zh) * | 2023-07-18 | 2023-08-15 | 禾多科技(北京)有限公司 | 用于仿真测试的元素渲染方法、装置、设备和可读介质 |
Families Citing this family (1)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN114064172A (zh) * | 2021-11-08 | 2022-02-18 | 北京沃东天骏信息技术有限公司 | 数据渲染方法及装置 |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108984714A (zh) * | 2018-07-09 | 2018-12-11 | 北京三快在线科技有限公司 | 页面渲染方法、装置、电子设备及计算机可读介质 |
CN110807161A (zh) * | 2019-11-08 | 2020-02-18 | 深圳乐信软件技术有限公司 | 一种页面骨架渲染方法、装置、设备及介质 |
CN112100543A (zh) * | 2020-08-31 | 2020-12-18 | 东软集团股份有限公司 | 渲染网页的方法、装置、存储介质及电子设备和服务器 |
CN113515328A (zh) * | 2020-04-09 | 2021-10-19 | 北京沃东天骏信息技术有限公司 | 页面渲染的方法、装置、电子设备和存储介质 |
CN114064172A (zh) * | 2021-11-08 | 2022-02-18 | 北京沃东天骏信息技术有限公司 | 数据渲染方法及装置 |
Family Cites Families (14)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN103049924B (zh) * | 2012-12-11 | 2016-03-02 | 广东威创视讯科技股份有限公司 | 多图层分布式渲染方法及系统 |
CN106909354A (zh) * | 2015-12-22 | 2017-06-30 | 北京奇虎科技有限公司 | 图片显示方法及装置 |
GB2551113A (en) * | 2016-05-27 | 2017-12-13 | Grypp Corp Ltd | Interactive display synchronisation |
CN107203312B (zh) * | 2017-05-04 | 2020-09-25 | Tcl移动通信科技(宁波)有限公司 | 移动终端及其图片的渲染方法、存储装置 |
CN110764849A (zh) * | 2018-07-25 | 2020-02-07 | 优视科技有限公司 | 用户界面的渲染方法、设备、客户端装置及电子设备 |
CN109948103A (zh) * | 2019-04-17 | 2019-06-28 | 北京华宇信息技术有限公司 | 基于网页的图像编辑方法、图像编辑装置和电子设备 |
CN111026463B (zh) * | 2019-12-20 | 2023-12-26 | 深圳乐信软件技术有限公司 | 一种页面加载方法、装置、设备和存储介质 |
CN111462292B (zh) * | 2020-03-20 | 2023-02-24 | 稿定(厦门)科技有限公司 | 图层化渲染方法、介质、设备及装置 |
CN111506372B (zh) * | 2020-04-07 | 2023-09-26 | 口碑(上海)信息技术有限公司 | 对象可视化处理方法及装置 |
CN112001995B (zh) * | 2020-10-28 | 2021-01-08 | 湖南新云网科技有限公司 | 渲染装置、方法、电子设备及可读存储介质 |
CN112862940A (zh) * | 2021-03-10 | 2021-05-28 | 广州南方卫星导航仪器有限公司 | 一种地图渲染方法、装置、设备和存储介质 |
CN112800164A (zh) * | 2021-03-17 | 2021-05-14 | 统信软件技术有限公司 | 一种地图加载方法、装置、计算设备及可读存储介质 |
CN214627005U (zh) * | 2021-03-22 | 2021-11-05 | 苏州物图数字科技有限公司 | 基于大模型bim文件的轻量化组织存储展示系统 |
CN113052942B (zh) * | 2021-03-31 | 2023-06-30 | 抖音视界有限公司 | 图表生成方法、装置、存储介质及电子设备 |
-
2021
- 2021-11-08 CN CN202111312862.4A patent/CN114064172A/zh active Pending
-
2022
- 2022-09-06 WO PCT/CN2022/117194 patent/WO2023077951A1/zh unknown
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN108984714A (zh) * | 2018-07-09 | 2018-12-11 | 北京三快在线科技有限公司 | 页面渲染方法、装置、电子设备及计算机可读介质 |
CN110807161A (zh) * | 2019-11-08 | 2020-02-18 | 深圳乐信软件技术有限公司 | 一种页面骨架渲染方法、装置、设备及介质 |
CN113515328A (zh) * | 2020-04-09 | 2021-10-19 | 北京沃东天骏信息技术有限公司 | 页面渲染的方法、装置、电子设备和存储介质 |
CN112100543A (zh) * | 2020-08-31 | 2020-12-18 | 东软集团股份有限公司 | 渲染网页的方法、装置、存储介质及电子设备和服务器 |
CN114064172A (zh) * | 2021-11-08 | 2022-02-18 | 北京沃东天骏信息技术有限公司 | 数据渲染方法及装置 |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN116594718A (zh) * | 2023-07-18 | 2023-08-15 | 禾多科技(北京)有限公司 | 用于仿真测试的元素渲染方法、装置、设备和可读介质 |
CN116594718B (zh) * | 2023-07-18 | 2023-09-19 | 禾多科技(北京)有限公司 | 用于仿真测试的元素渲染方法、装置、设备和可读介质 |
Also Published As
Publication number | Publication date |
---|---|
CN114064172A (zh) | 2022-02-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
WO2023077951A1 (zh) | 数据渲染方法及装置 | |
CN109460233B (zh) | 页面的原生界面显示更新方法、装置、终端设备及介质 | |
JP6092381B2 (ja) | ウェブクライアントを介したリモートアプリケーションへのアクセスを提供する方法、システム、及びコンピュータ読取可能記憶媒体 | |
CN108833787B (zh) | 用于生成短视频的方法和装置 | |
US20120066679A1 (en) | Disposable virtual desktop for transient use by multiple users | |
CN109918604A (zh) | 网页绘图方法、装置、设备及存储介质 | |
CN111045653B (zh) | 系统生成方法、装置、计算机可读介质及电子设备 | |
CN110058854B (zh) | 用于生成应用的方法、终端设备和计算机可读介质 | |
US11095957B2 (en) | Method and apparatus for publishing information, and method and apparatus for processing information | |
CN109582317B (zh) | 用于调试寄宿应用的方法和装置 | |
CN108052377B (zh) | 基于云的输入处理方法、装置、服务器和存储介质 | |
CN111294395A (zh) | 一种终端页面传输方法、装置、介质和电子设备 | |
CN112395027A (zh) | 微件界面生成方法、装置、存储介质与电子设备 | |
CN112486482A (zh) | 一种页面展示方法和装置 | |
CN110673886B (zh) | 用于生成热力图的方法和装置 | |
CN113220381A (zh) | 一种点击数据展示方法和装置 | |
CN114255084A (zh) | 一种广告页面展示方法、装置及系统 | |
CN114168853A (zh) | 一种数据可视化展示方法、装置、介质及电子设备 | |
CN113986258A (zh) | 业务发布方法、装置、设备及存储介质 | |
CN113553123A (zh) | 数据处理方法、装置、电子设备及存储介质 | |
CN113313623A (zh) | 水印信息显示方法、装置、电子设备、计算机可读介质 | |
CN114756228A (zh) | 页面处理方法、装置、设备及存储介质 | |
CN113535304B (zh) | 设计软件中插入、展示、编辑第三方模型的方法与装置 | |
CN116775174A (zh) | 一种基于用户界面框架的处理方法、装置、设备及介质 | |
CN113656041A (zh) | 数据处理方法、装置、设备及存储介质 |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
121 | Ep: the epo has been informed by wipo that ep was designated in this application |
Ref document number: 22888982 Country of ref document: EP Kind code of ref document: A1 |
|
NENP | Non-entry into the national phase |
Ref country code: DE |