Graphical rendering method, apparatus, electronic device, and non-transitory storage medium
By acquiring raw graphics data and encapsulating it into drawing objects, the system detects the graphics interfaces supported by the current operating environment of the graphics rendering system, determines the target rendering implementation module, achieves smooth compatibility and expansion of multiple versions of graphics interfaces, solves the problem of strong coupling between the graphics rendering system and specific versions of graphics interfaces, and reduces the cost of system reconstruction.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEITAI ZHENHUAN (CHONGQING) TECH CO LTD
- Filing Date
- 2026-04-17
- Publication Date
- 2026-07-24
AI Technical Summary
In existing technologies, graphics rendering systems have failed to effectively resolve the strong coupling problem of multiple versions of graphics interfaces, leading to technical problems for developers.
By acquiring the raw graphics data and encapsulating it into a drawing object, detecting the graphics interface supported by the current operating environment of the graphics rendering system, and determining the target rendering implementation module based on the graphics interface, the drawing object is rendered using this module. This method achieves smooth compatibility and expansion of multiple versions of graphics interfaces by removing the graphics interface.
It achieves smooth compatibility and expansion of multiple graphics interface versions without modifying the drawing data structure, reducing system reconstruction costs and improving rendering efficiency and system scalability.
Smart Images

Figure CN122049170B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of computer graphics technology, and more specifically, to a graphics rendering method, apparatus, electronic device, and non-volatile storage medium. Background Technology
[0002] With the continuous development of scientific visualization and cross-platform graphics applications, graphics rendering systems have become a core component of related software systems. Their performance, scalability, and compatibility directly affect the stability and maintainability of the overall system. In related technologies, most graphics rendering systems are typically designed and implemented around a specific version of the graphics interface. That is, during the system development phase, a fixed version of the rendering interface standard is bound, and the drawing process, object management mechanism, and window refresh logic are built on this basis.
[0003] However, in real-world applications, graphics interface versions are subject to continuous upgrades and the coexistence of multiple versions. For example, the capabilities of graphics interfaces supported by different hardware platforms, operating system environments, or driver conditions vary. When the system operating environment changes, or when it is necessary to be compatible with multiple interface versions simultaneously, the relevant technical solutions often require extensive adjustments to the original rendering modules, or even a complete reconstruction of the entire rendering system. This leads to extended development cycles, significantly increased maintenance costs, and increased system upgrade risks.
[0004] There is currently no effective solution to the above problems. Summary of the Invention
[0005] This application provides a graphics rendering method, apparatus, electronic device, and non-volatile storage medium to at least solve the technical problem in the related art where graphics rendering systems are strongly coupled with specific versions of graphics interfaces, making it difficult to support the coexistence and switching of multiple versions of graphics interfaces.
[0006] According to one aspect of the embodiments of this application, a graphics rendering method is provided, comprising: acquiring raw graphics data and encapsulating the raw graphics data into a drawing object, wherein the raw graphics data is used to characterize the attribute information of the graphics to be drawn, and the drawing object is a basic unit for managing the state changes of the raw graphics data; detecting the graphics interface supported by the current operating environment of the graphics rendering system, and determining a target rendering implementation module based on the graphics interface, wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules; and rendering the drawing object using the target rendering implementation module to obtain a rendering result.
[0007] Optionally, obtaining raw graphic data includes: receiving a graphic drawing request triggered by an upper-layer application, wherein the graphic drawing request is used to indicate the attribute information of the graphic to be drawn; extracting the attribute information from the graphic drawing request, wherein the attribute information includes at least one of the following: geometric description information, appearance feature information, and auxiliary control information, wherein the geometric description information is used to characterize the spatial position and / or shape boundary of the graphic to be drawn, the appearance feature information is used to characterize the appearance presentation effect of the graphic to be drawn, and the auxiliary control information is used to characterize the display behavior and interactive attributes of the graphic to be drawn; and organizing the extracted attribute information according to a preset structure to form raw graphic data with a standardized data format.
[0008] Optionally, encapsulating the raw graphic data into a drawing object includes: allocating a drawing object container to the raw graphic data, and using the allocated drawing object container to encapsulate the raw graphic data to obtain a drawing object; establishing a unique identifier for the drawing object, and setting a status flag for the drawing object, wherein the status flag is used to characterize the lifecycle stage and update requirement type of the drawing object; and adding the drawing object to an object pool for unified management.
[0009] Optionally, determining the target rendering implementation module based on the graphics interface includes: obtaining environment attribute information corresponding to the current operating environment of the graphics rendering system, wherein the environment attribute information includes at least one of the following: graphics card hardware information, graphics card driver information; determining the list of graphics interface capabilities supported by the current operating environment based on the environment attribute information, wherein the list of graphics interface capabilities is used to characterize the types and functional support of graphics interfaces supported by the current operating environment; determining the drawing object that needs to be rendered, and determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the list of graphics interface capabilities according to the target rendering strategy, wherein the target rendering strategy includes at least one of the following: a compatibility priority strategy to ensure the maximum range of hardware support, a performance priority strategy to pursue the highest frame rate and lowest latency, and a mandatory specification strategy for using a specific interface version pre-defined by the user.
[0010] Optionally, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: monitoring the current operating status of the graphics rendering system's operating environment, wherein the operating status is used to characterize the real-time load level of the current operating environment; determining the rendering complexity corresponding to the drawing object that needs to be rendered, wherein the rendering complexity is used to characterize the computational load and resource requirements required for the rendering processing of the drawing object; determining the comprehensive fitness score of each rendering implementation module corresponding to each graphics interface in the graphics interface capability list under the operating status and rendering complexity, wherein the comprehensive fitness score is a comprehensive quantitative indicator used to characterize the expected rendering performance, resource utilization efficiency, and stability performance of each rendering implementation module under the operating status and rendering complexity; and determining the rendering implementation module with the highest comprehensive fitness score as the target rendering implementation module for the drawing object.
[0011] Optionally, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: obtaining the first running state data of the current running environment of the graphics rendering system in a first time period; predicting the second running state data of the current running environment in a second time period based on the first running state data, wherein the second time period is a time period after the first time period, and the second time period includes: the time period for rendering the drawing object; and determining the target rendering implementation module for rendering the drawing object based on the second running state data and the rendering complexity corresponding to the drawing object.
[0012] Optionally, the method further includes: when a status flag of the drawing object is detected indicating that the drawing object has changed, determining the target data that has changed in the drawing object and the affected area corresponding to the target data in the rendering result; calling the target rendering implementation module to render the target data to update the affected area in the rendering result, wherein the update operation only refreshes the affected area while keeping other unchanged areas in the rendering result unchanged.
[0013] According to another aspect of the embodiments of this application, a graphics rendering apparatus is also provided, comprising: an object encapsulation module, configured to acquire raw graphics data and encapsulate the raw graphics data into a drawing object, wherein the raw graphics data is used to characterize the attribute information of the graphics to be drawn, and the drawing object is a basic unit for managing the state changes of the raw graphics data; a rendering adaptation module, configured to detect the graphics interface supported by the current operating environment of the graphics rendering system, and determine a target rendering implementation module based on the graphics interface, wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules; and a rendering execution module, configured to render the drawing object using the target rendering implementation module to obtain a rendering result.
[0014] According to another aspect of the embodiments of this application, an electronic device is also provided, including: a memory and a processor, the processor being configured to run a program stored in the memory, wherein the program executes a graphics rendering method during runtime.
[0015] According to another aspect of the embodiments of this application, a non-volatile storage medium is also provided, the non-volatile storage medium including a stored computer program, wherein the device where the non-volatile storage medium is located executes a graphics rendering method by running the computer program.
[0016] According to another aspect of the embodiments of this application, a computer program product is also provided, including a computer program that, when executed by a processor, implements the steps of a graphics rendering method.
[0017] In this embodiment, the method involves acquiring raw graphic data and encapsulating it into a drawing object. The raw graphic data represents the attribute information of the graphic to be drawn, and the drawing object is a basic unit for managing the state changes of the raw graphic data. The method also involves detecting the graphics interface supported by the current operating environment of the graphics rendering system and determining the target rendering implementation module based on the graphics interface. This target rendering implementation module converts the drawing object into drawing instructions executable by the graphics interface, with different graphics interfaces corresponding to different rendering implementation modules. The target rendering implementation module then renders the drawing object to obtain the rendering result. By decoupling the drawing object from the rendering implementation, the method achieves smooth compatibility and expansion across multiple versions of graphics interfaces, thereby solving the technical problem in related technologies where the graphics rendering system is strongly coupled to a specific version of the graphics interface, making it difficult to support the coexistence and switching of multiple versions of graphics interfaces. Attached Figure Description
[0018] The accompanying drawings, which are included to provide a further understanding of this application and form part of this application, illustrate exemplary embodiments and are used to explain this application, but do not constitute an undue limitation of this application. In the drawings:
[0019] Figure 1 This is a hardware structure block diagram of a computer terminal (or electronic device) for implementing a graphics rendering method according to an embodiment of this application;
[0020] Figure 2 This is a schematic diagram of a graphics rendering method flow according to an embodiment of this application;
[0021] Figure 3 This is a schematic diagram of the system architecture of a graphics rendering system according to an embodiment of this application;
[0022] Figure 4This is a flowchart illustrating a layered graphics rendering management method supporting multiple versions of graphics interfaces, provided according to an embodiment of this application.
[0023] Figure 5 This is a schematic diagram of a window refresh control flow according to an embodiment of this application;
[0024] Figure 6 This is a schematic diagram of the structure of a graphics rendering device provided according to an embodiment of this application. Detailed Implementation
[0025] To enable those skilled in the art to better understand the present application, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present application, and not all embodiments. Based on the embodiments in the present application, all other embodiments obtained by those of ordinary skill in the art without creative effort should fall within the scope of protection of the present application.
[0026] It should be noted that the terms "first," "second," etc., in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a specific order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms "comprising" and "having," and any variations thereof, are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0027] In graphics rendering systems using related technologies, most applications are bound to a fixed version of the graphics interface standard during the development phase, and the drawing process, object management mechanism, and window refresh logic are built on this basis. The drawing objects in the system are usually directly coupled to the API call method of a specific graphics interface, and their data structures are highly bound to rendering instructions, resulting in a lack of clear boundaries between drawing logic, object lifecycle, and rendering implementation. When the system operating environment changes (such as hardware upgrades, operating system updates, or differences in driver compatibility), adapting to a new graphics interface version often requires a large-scale reconstruction of the rendering module, or even a redesign of the entire drawing pipeline, leading to extended development cycles, soaring maintenance costs, and a significantly increased risk of system upgrade failure.
[0028] Furthermore, traditional graphics rendering systems generally employ a full-window redraw strategy, triggering a re-render of the entire viewport regardless of whether the drawn object has undergone local changes. This leads to a large amount of redundant computation and resource waste in complex visualization scenarios, resulting in decreased system responsiveness. Simultaneously, due to the lack of a unified drawing object management mechanism and layered architecture, adding rendering capabilities or adapting to new graphics interface versions often requires modifying the code of multiple modules. This results in poor system scalability, high coupling, and difficulty in supporting the continuous demands of scientific visualization and cross-platform applications for long-term maintenance and multi-environment compatibility.
[0029] To address the aforementioned issues, this application provides a solution that proposes a novel graphics rendering technology. This solution decouples the drawing object from the rendering implementation while maintaining the stability of the existing drawing data structure. It supports compatibility and switching between multiple versions of graphics interfaces and provides a unified drawing object management and on-demand refresh mechanism, thereby reducing system upgrade and maintenance costs and improving rendering efficiency and system scalability. The following provides a detailed description of this solution.
[0030] According to an embodiment of this application, a method embodiment for graphics rendering is provided. It should be noted that the steps shown in the flowchart in the accompanying drawings can be executed in a computer system such as a set of computer-executable instructions. Furthermore, although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in a different order than that shown here.
[0031] The methods and embodiments provided in this application can be executed on mobile terminals, computer terminals, or similar computing devices. Figure 1 A hardware block diagram of a computer terminal (or electronic device) for implementing a graphics rendering method is shown. Figure 1 As shown, the computer terminal 10 (or electronic device) may include one or more processors 102 (shown as 102a, 102b, ..., 102n in the figure) 102 (processor 102 may include, but is not limited to, a microprocessor MCU or a programmable logic device FPGA, etc.), a memory 104 for storing data, and a transmission device 106 for communication functions. In addition, it may also include: a display, an input / output interface (I / O interface), a universal serial bus (USB) port (which may be included as one of the ports of a BUS bus), a network interface, a power supply, and / or a camera. Those skilled in the art will understand that... Figure 1 The structure shown is for illustrative purposes only and does not limit the structure of the aforementioned electronic device. For example, computer terminal 10 may also include... Figure 1 The more or fewer components shown, or having the same Figure 1 The different configurations shown.
[0032] It should be noted that the aforementioned one or more processors 102 and / or other data processing circuits are generally referred to herein as "data processing circuits". These data processing circuits may be embodied, in whole or in part, in software, hardware, firmware, or any other combination thereof. Furthermore, the data processing circuits may be a single, independent processing module, or may be integrated, in whole or in part, into any other element within the computer terminal 10 (or electronic device). As involved in the embodiments of this application, the data processing circuits serve as a processor control mechanism (e.g., selection of a variable resistor termination path connected to an interface).
[0033] The memory 104 can be used to store software programs and modules of application software, such as the program instructions / data storage device corresponding to the graphics rendering method in this embodiment. The processor 102 executes various functional applications and data processing by running the software programs and modules stored in the memory 104, thereby realizing the above-mentioned graphics rendering method. The memory 104 may include high-speed random access memory, and may also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid-state memory. In some instances, the memory 104 may further include memory remotely located relative to the processor 102, and these remote memories can be connected to the computer terminal 10 via a network. Examples of such networks include, but are not limited to, the Internet, corporate intranets, local area networks, mobile communication networks, and combinations thereof.
[0034] The transmission device 106 is used to receive or send data via a network. Specific examples of the network described above may include a wireless network provided by the communication provider of the computer terminal 10. In one example, the transmission device 106 includes a Network Interface Controller (NIC), which can connect to other network devices via a base station to communicate with the Internet. In another example, the transmission device 106 may be a Radio Frequency (RF) module, used for wireless communication with the Internet.
[0035] The display may be, for example, a touchscreen liquid crystal display (LCD) that allows the user to interact with the user interface of the computer terminal 10 (or electronic device).
[0036] Under the above operating environment, this application embodiment provides a graphics rendering method. Figure 2 This is a schematic diagram of a graphics rendering method flow provided according to an embodiment of this application, such as... Figure 2 As shown, the method includes the following steps:
[0037] Step S202: Obtain the original graphic data and encapsulate the original graphic data into a drawing object. The original graphic data is used to characterize the attribute information of the graphic to be drawn, and the drawing object is the basic unit used to manage the state changes of the original graphic data.
[0038] In this embodiment, raw graphic data can be acquired first. This data is used to characterize the attribute information of the graphic to be drawn, such as visual features like geometric shape, color, position, and size, but does not contain any drawing instructions or rendering parameters related to a specific graphics interface. Subsequently, this raw graphic data is encapsulated into a drawing object, so that the originally independent data content is organized into a basic unit with state management capabilities. As a carrier of the raw graphic data, the core function of this drawing object is to separate the data from its subsequent rendering behavior, forming an independent entity that can be uniformly identified and operated, thereby providing basic structural support for subsequent state change tracking and scheduling.
[0039] Step S204: Detect the graphics interface supported by the current operating environment of the graphics rendering system, and determine the target rendering implementation module based on the graphics interface. The target rendering implementation module is used to convert the drawing object into drawing instructions that can be executed by the graphics interface. Different graphics interfaces correspond to different rendering implementation modules.
[0040] In this embodiment, the graphics interfaces supported by the current operating environment of the graphics rendering system can be detected, and the available graphics interface capability information of the system can be obtained through the environment recognition mechanism, thereby clarifying the interface types that can be called in the current environment; then, based on the detected graphics interfaces, the target rendering implementation module that matches them can be determined.
[0041] The function of the target rendering implementation module is to convert the drawing object into drawing instructions that the graphics interface can directly execute, ensuring that the rendering operation is strictly compatible with the underlying interface specification. Different graphics interfaces correspond to different rendering implementation modules, and each module is independently encapsulated to adapt to its own interface instruction set and calling specification.
[0042] Step S206: The target rendering module is used to render the drawing object and obtain the rendering result.
[0043] Based on the currently selected specific rendering implementation module, the system converts the encapsulated drawing object into the graphics interface instruction set supported by that module, performs the corresponding drawing operations, and finally outputs visual output content that conforms to the interface specification. This process does not involve the intervention of other modules, but only relies on the target rendering implementation module's own ability to parse the drawing object and generate instructions, directly producing rendering results that match the selected interface version.
[0044] By decoupling the drawing object from the rendering implementation through the above steps, the goal of achieving smooth compatibility and expansion of multiple versions of graphics interfaces is achieved. This solves the technical problem in related technologies where the graphics rendering system is strongly coupled with a specific version of the graphics interface, making it difficult to support the coexistence and switching of multiple versions of the graphics interface.
[0045] The graphics rendering method in steps S202 to S206 of the embodiments of this application will be further described below.
[0046] In this embodiment, a multi-version graphics rendering architecture is proposed for scientific computing result visualization and interactive data analysis scenarios and cross-platform applications. This architecture can be used to execute the graphics rendering methods in steps S202 to S206. By decoupling the original graphics data, drawing objects, rendering implementation, and window refresh logic into layers, this architecture achieves independence between the drawing data and the specific graphics interface version. Its specific structure is as follows: Figure 3 As shown, it includes: 1) a raw data (abstract) layer, which makes raw data independent of the graphics interface; 2) a drawing object management layer, which is used to uniformly encapsulate and manage the lifecycle of drawing objects; 3) a rendering adaptation layer, which contains multiple interface version implementation modules; and 4) a window refresh control layer, which drives local refresh through changes in object state. At the same time, a unified interface mechanism is established between the layers, which can communicate through interface calls and time notification mechanisms. There is no direct data structure coupling between the layers, thus making the layers loosely coupled.
[0047] This application embodiment achieves unified rendering of multiple versions of graphics interfaces by constructing a graphics raw data abstraction layer, a drawing object management layer, a rendering adaptation layer, and a window refresh control layer. The specific graphics rendering process is as follows: Figure 4 As shown, the system encapsulates the raw data of the graphics to be drawn into independent drawing objects and establishes their association with the rendering adaptation layer. The rendering adaptation layer selects the corresponding rendering implementation based on the current runtime environment to complete the drawing. The window refresh control layer triggers the corresponding rendering process based on the addition, update, or deletion status of the drawing objects, thereby achieving unified management and on-demand refreshing of the drawing objects. Through this method, the rendering system can be expanded and upgraded while maintaining the original drawing data structure. The following sections will explain the above process steps in detail.
[0048] First, a raw data abstraction layer can be used to uniformly describe the data content and attribute information of the graphics to be drawn (i.e., to obtain the raw data of the graphics). In this embodiment, the raw data abstraction layer is only responsible for data representation and does not contain specific rendering instructions, thus making the raw data independent of the specific graphics interface implementation. Specifically, as follows.
[0049] In some embodiments of this application, obtaining raw graphic data includes: receiving a graphic drawing request triggered by an upper-layer application, wherein the graphic drawing request is used to indicate attribute information of the graphic to be drawn; extracting attribute information from the graphic drawing request, wherein the attribute information includes at least one of the following: geometric description information, appearance feature information, and auxiliary control information, wherein the geometric description information is used to characterize the spatial position and / or shape boundary of the graphic to be drawn, the appearance feature information is used to characterize the appearance presentation effect of the graphic to be drawn, and the auxiliary control information is used to characterize the display behavior and interactive attributes of the graphic to be drawn; and organizing the extracted attribute information according to a preset structure to form raw graphic data with a standardized data format.
[0050] Specifically, by receiving graphic drawing requests triggered by upper-level applications (such as scientific visualization tools, CAD software, etc.), the system can extract the geometric description information, appearance feature information, and auxiliary control information contained therein, and standardize and organize this information according to a preset structure to form graphic raw data with a unified structure and clear semantics. This provides a reliable and consistent data foundation for the subsequent encapsulation of drawing objects, avoiding parsing ambiguity and encapsulation failure caused by the diverse or lack of standardization of upper-level instruction formats.
[0051] The geometric description information mentioned above may include, but is not limited to: vertex coordinates (two-dimensional or three-dimensional spatial position), topology (connection method between vertices, such as point list, line list, triangle face, polygon, etc.), normal vector (surface orientation used for lighting calculation), and bounding box (minimum bounding rectangle or cube, used for fast collision detection and view frustum clipping), etc.; the appearance feature information mentioned above may include, but is not limited to: color attributes (RGBA values, gradient color definition, color map index), texture information (texture coordinate UV mapping, texture resource reference, sampling method), material parameters (diffuse coefficient, specular coefficient, transparency, blending mode), and line type and fill attributes (line width, line type style, fill pattern, edge smoothing settings), etc.; the auxiliary control information mentioned above may include, but is not limited to: visibility flag (whether it is displayed and the display scale range), depth level (Z-axis order and rendering priority), interaction attributes (whether it can be selected, hover response area), and metadata tags (unique object identifier, group to which it belongs, user-defined data), etc., which extract information to control graphic behavior and interaction.
[0052] Furthermore, the drawing object management layer can be used to encapsulate the raw graphics data into drawing objects and uniformly manage their state information. At the same time, it can maintain the drawing object set and send scheduling requests to the rendering adaptation layer, thereby achieving centralized control of the drawing object lifecycle, as detailed below.
[0053] In some embodiments of this application, encapsulating raw graphic data into drawing objects includes: allocating a drawing object container to the raw graphic data, and encapsulating the raw graphic data using the allocated drawing object container to obtain a drawing object; establishing a unique identifier for the drawing object, and setting a status flag for the drawing object, wherein the status flag is used to characterize the lifecycle stage and update requirement type of the drawing object; and adding the drawing object to an object pool for unified management.
[0054] Specifically, a dedicated drawing object container can be allocated to the raw graphics data, and the raw graphics data can be structurally encapsulated based on this container to form drawing objects with complete data carrying capacity. Then, each drawing object is assigned a unique identifier for accurate identification, and a status flag is set to dynamically record its life cycle stage and update requirement type. This gives the drawing objects traceable identity attributes and state semantics after generation. They are then uniformly included in the object pool for centralized management and scheduling, thereby building a complete drawing object life cycle management system. This system ensures that when the graphics rendering system switches between different versions of the graphics interface, the target rendering implementation module can quickly locate the target object based on the unique identifier, accurately determine whether it needs to be redrawn, updated, or discarded based on the status flag, and achieve unified access and resource reuse of all drawing objects through the object pool. This effectively avoids scheduling chaos and rendering errors caused by objects without identifiers, ambiguous states, or scattered management, and ultimately achieves efficient, accurate, and stable rendering of drawing objects in multi-version graphics interface environments.
[0055] Subsequently, the corresponding rendering implementation (i.e., the target rendering implementation module) can be selected based on the runtime environment, thereby supporting the coexistence and switching of different versions of graphics interfaces within the same system. The rendering adaptation layer in this embodiment includes multiple rendering implementation modules, each corresponding to a different graphics interface version or capability level. This layer can detect the graphics interface capabilities supported by the runtime environment or select a rendering implementation according to a preset strategy, and convert the drawing object into drawing instructions executable by the corresponding interface, thereby completing the drawing operation. Specifically, as follows.
[0056] In some embodiments of this application, determining the target rendering implementation module based on the graphics interface includes: obtaining environment attribute information corresponding to the current operating environment of the graphics rendering system, wherein the environment attribute information includes at least one of the following: graphics card hardware information, graphics card driver information; determining a list of graphics interface capabilities supported by the current operating environment based on the environment attribute information, wherein the list of graphics interface capabilities is used to characterize the types and functional support of graphics interfaces supported by the current operating environment; determining the drawing object that needs to be rendered, and determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the list of graphics interface capabilities according to the target rendering strategy, wherein the target rendering strategy includes at least one of the following: a compatibility priority strategy to ensure the maximum range of hardware support, a performance priority strategy to pursue the highest frame rate and lowest latency, and a mandatory specification strategy for using a specific interface version pre-defined by the user.
[0057] Specifically, by acquiring the graphics card hardware information and / or graphics card driver information corresponding to the current operating environment of the graphics rendering system, an environment attribute information that accurately reflects the hardware capabilities and driver support status can be formed. Based on this, an interface capability list representing the types of graphics interfaces and their functional characteristics that the current environment can support can be constructed. Then, combined with the specific needs of the objects to be rendered, and based on diversified rendering strategies such as compatibility priority, performance priority, or user-mandated specification, the rendering implementation module that is most suitable for the current environment conditions and application goals can be intelligently selected. This enables dynamic optimization and precise matching of the rendering path in a complex environment where multiple graphics interfaces coexist. It effectively breaks through the limitations of traditional systems that rely solely on basic interface detection and cannot balance differences in hardware capabilities and performance requirements, significantly improving the adaptability, stability, and operating efficiency of graphics rendering.
[0058] In this embodiment, the above-mentioned target rendering strategy may include, but is not limited to: 1) Performance-first strategy: for real-time interactive scenarios, pursuing the highest frame rate and lowest latency; 2) Compatibility-first strategy: for cross-platform deployment, ensuring the widest range of hardware support; 3) Functionality-completeness-first strategy: for complex visualization effects, requiring all graphics features; 4) Energy-saving-first strategy: for mobile devices or battery power, extending battery life; 5) Forced specification strategy: for users or administrators to explicitly specify the use of a specific interface version; 6) Dynamic adaptive strategy: the system automatically optimizes and selects based on real-time load and environmental changes.
[0059] For example, when researchers start the visualization system on a workstation equipped with an NVIDIA Quadro graphics card and driver version 470.141, the system can automatically obtain the graphics card hardware information and driver information of the current operating environment, and generate a list of graphics interface capabilities including OpenGL 4.6, OpenGL 3.3 and OpenGL 2.1. The system detects that the drawing object to be rendered contains complex 3D volume data and real-time interactive controls, and then selects the corresponding rendering implementation module of OpenGL 4.6 from the capability list as the target rendering implementation module according to the performance priority strategy, and completes high-precision, low-latency drawing instruction conversion and execution, ensuring that rendering efficiency is maximized without degrading functionality.
[0060] In addition, as an optional implementation method, the selection of the target rendering implementation module can also take into account the current load level of the operating environment and the rendering complexity of the drawing objects to be rendered, as follows.
[0061] In some embodiments of this application, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: monitoring the current operating status of the graphics rendering system's operating environment, wherein the operating status is used to characterize the real-time load level of the current operating environment; determining the rendering complexity corresponding to the drawing object that needs to be rendered, wherein the rendering complexity is used to characterize the computational load and resource requirements required for the rendering processing of the drawing object; determining the comprehensive fitness score corresponding to each rendering implementation module corresponding to each graphics interface in the graphics interface capability list under the operating status and rendering complexity, wherein the comprehensive fitness score is a comprehensive quantitative index used to characterize the expected rendering performance, resource utilization efficiency, and stability performance of each rendering implementation module under the operating status and rendering complexity; and determining the rendering implementation module with the highest comprehensive fitness score as the target rendering implementation module for the drawing object.
[0062] Specifically, by monitoring the real-time load level of the current operating environment of the graphics rendering system (e.g., CPU utilization, GPU utilization, remaining video memory, remaining system memory, power status, heat dissipation status, current rendering frame rate, frame time stability, etc.), and combining this with the computational load and resource requirements of the objects to be rendered (e.g., by analyzing rendering complexity through parameters such as vertex count, primitive type, texture resolution, shader computational complexity, update frequency, and screen coverage ratio), the expected performance, resource utilization efficiency, and stability of each rendering implementation module under different graphics interfaces under the current comprehensive operating conditions can be dynamically evaluated. This allows for the calculation of a comprehensive adaptability score for each module, and ultimately, the rendering implementation module with the highest score is selected to execute the rendering task. Based on the graphics interface capability list and preset rendering strategies, this achieves adaptive optimal selection of rendering modules, effectively addressing performance risks caused by fluctuations in the operating environment load and changes in the complexity of the rendered objects. It avoids frame rate drops, rendering stutters, or system instability due to resource overload or improper adaptation, significantly improving the adaptability, operating efficiency, and overall system stability of the graphics rendering process.
[0063] For example, when a scientific visualization system runs in parallel on multiple workstations equipped with different graphics card drivers, the system monitors the load level of the current operating environment in real time. It finds that the GPU utilization of a certain device has reached 85% and the video memory usage exceeds 90%. At the same time, the object to be rendered has high rendering complexity due to the inclusion of high-precision three-dimensional isosurfaces and dynamic streamline fields. The system then queries the comprehensive adaptability score of each rendering implementation module in the graphics interface capability list under this load and complexity (for example, it can retrieve historical performance records of similar operating states and rendering complexity combinations in the knowledge base to obtain the expected frame rate, stability score and resource usage data of each candidate rendering implementation module under this combination). It finds that the OpenGL 4.6 implementation module has the highest score due to its efficient parallel shader scheduling and video memory management mechanism, while the OpenGL 3.3 and WebGL implementation modules have lower scores due to excessive resource consumption or significant frame rate fluctuations. Finally, the system determines the OpenGL 4.6 rendering implementation module with the highest score as the target module to perform the rendering task of the object.
[0064] Furthermore, based on the above methods, the operating status of the graphics rendering system can be actively predicted, and the operating capacity of future rendering periods can be anticipated, thereby enabling more precise selection of the target rendering implementation module, as detailed below.
[0065] In some embodiments of this application, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: obtaining the first running state data of the current running environment of the graphics rendering system in a first time period; predicting the second running state data of the current running environment in a second time period based on the first running state data, wherein the second time period is a time period after the first time period, and the second time period includes: the time period for rendering the drawing object; and determining the target rendering implementation module for rendering the drawing object based on the second running state data and the rendering complexity corresponding to the drawing object.
[0066] Specifically, by acquiring the first operational status data of the graphics rendering system in the first time period and combining it with dynamic predictions of system resource usage trends in the subsequent second time period, a prediction of the operational capabilities for future rendering periods can be formed. This prediction result is then analyzed in conjunction with the rendering complexity of the objects to be rendered, thus breaking through the limitations of traditional methods that rely solely on a list of graphics interface capabilities or static rendering strategies. This allows for precise selection of the target rendering implementation module. This method ensures that the selection of rendering modules not only matches the current interface support capabilities but also adapts to the actual available system resources and task load requirements in the future. It effectively avoids rendering performance fluctuations or resource redundancy waste caused by environmental fluctuations, significantly improving the stability, efficiency, and adaptability of graphics rendering. Ultimately, it achieves the technical effect of intelligent, dynamic, and highly reliable rendering scheduling in an environment where multiple versions of graphics interfaces coexist.
[0067] For example, when a scientific visualization system loads complex 3D isosurface data on a high-performance workstation equipped with different versions of graphics drivers, the system first obtains the GPU load rate, memory usage, and driver version compatibility information of the current operating environment in the last 5 seconds as the first operating status data. Based on this data, the system uses a dynamic prediction model to calculate the GPU resource demand trend corresponding to the drawing objects that the rendering window will process in the next 10 seconds. Then, combined with the rendering complexity level of the drawing object (such as the number of vertices exceeding 100,000 and containing dynamic shading effects), the system comprehensively judges that it should call the high-order rendering implementation module that supports OpenGL 4.6 instead of the lightweight module that is only compatible with OpenGL 3.3, so as to ensure that a stable frame rate and consistent image quality are maintained during the rendering period when resources are expected to be tight.
[0068] Furthermore, in this embodiment, the window refresh control layer can be used to trigger the rendering process based on changes in the state of the drawing object, driving the window refresh and avoiding a full redraw, thereby improving rendering efficiency. This allows for a smooth upgrade and expansion of the rendering system without modifying the existing drawing data structure. Details are as follows.
[0069] In some embodiments of this application, the method further includes: when a status flag of a drawing object is detected indicating that the drawing object has changed, determining the target data that has changed in the drawing object and the affected area corresponding to the target data in the rendering result; calling the target rendering implementation module to render the target data to update the affected area in the rendering result, wherein the update operation only refreshes the affected area while keeping other unchanged areas in the rendering result unchanged.
[0070] Specifically, status flags can be set for drawn objects to indicate their changes, such as... Figure 5 As shown, when a status marker update is detected (i.e., when an update to the drawing object is detected), the changed target data in the drawing object and its corresponding affected area in the rendering result are accurately identified. Then, the target rendering implementation module is called to perform a local redraw operation only on the affected area, while retaining the original content of the unchanged area in the rendering result (only the affected area is refreshed without a full window redraw). This avoids the full redraw problem caused by single-point data updates in traditional solutions, significantly reduces the computational overhead and resource consumption in the graphics rendering process, improves the rendering response speed and the overall system efficiency, and ultimately achieves a collaborative optimization effect of high compatibility and high-performance rendering for dynamic graphical interfaces in multi-version graphics interface environments.
[0071] This application's solution decouples the drawing object from the rendering implementation, enabling smooth compatibility and expansion across multiple versions of graphics interfaces, thus reducing system reconstruction costs associated with interface upgrades. Specifically, by acquiring raw graphics data and encapsulating it into a drawing object, it achieves abstract isolation between graphics attribute information and specific rendering logic. Combined with dynamic detection of the graphics interfaces supported by the current operating environment, it intelligently matches the corresponding rendering implementation module, allowing the drawing object to adapt to different versions of graphics interfaces for efficient rendering. This completely decouples the graphics rendering system from specific versions of graphics interfaces, enabling the coexistence and seamless switching of multiple versions of graphics interfaces within the same system. This effectively improves the compatibility, maintainability, and scalability of the graphics rendering system, ultimately solving the technical problems of difficult system upgrades, high multi-environment adaptation costs, and lack of dynamic support for interface switching caused by fixed interface versions in existing technologies. Simultaneously, the on-demand refresh mechanism reduces redundant redrawing operations, improves rendering efficiency and system response performance in complex drawing scenarios, reduces repetitive development work, enhances system maintainability and scalability, and forms a stable technical accumulation and barrier for scientific visualization and cross-platform graphics applications.
[0072] According to an embodiment of this application, an embodiment of a graphics rendering apparatus is also provided. Figure 6 This is a schematic diagram of the structure of a graphics rendering apparatus according to an embodiment of this application. Figure 6 As shown, the device includes:
[0073] The object encapsulation module 60 is used to acquire the original graphic data and encapsulate the original graphic data into a drawing object. The original graphic data is used to characterize the attribute information of the graphic to be drawn, and the drawing object is the basic unit used to manage the state changes of the original graphic data.
[0074] The rendering adaptation module 62 is used to detect the graphics interface supported by the current operating environment of the graphics rendering system, and determine the target rendering implementation module based on the graphics interface. The target rendering implementation module is used to convert the drawing object into drawing instructions that can be executed by the graphics interface. Different graphics interfaces correspond to different rendering implementation modules.
[0075] The rendering execution module 64 is used to render the drawing object using the target rendering implementation module and obtain the rendering result.
[0076] Optionally, obtaining raw graphic data includes: receiving a graphic drawing request triggered by an upper-layer application, wherein the graphic drawing request is used to indicate the attribute information of the graphic to be drawn; extracting the attribute information from the graphic drawing request, wherein the attribute information includes at least one of the following: geometric description information, appearance feature information, and auxiliary control information, wherein the geometric description information is used to characterize the spatial position and / or shape boundary of the graphic to be drawn, the appearance feature information is used to characterize the appearance presentation effect of the graphic to be drawn, and the auxiliary control information is used to characterize the display behavior and interactive attributes of the graphic to be drawn; and organizing the extracted attribute information according to a preset structure to form raw graphic data with a standardized data format.
[0077] Optionally, encapsulating the raw graphic data into a drawing object includes: allocating a drawing object container to the raw graphic data, and using the allocated drawing object container to encapsulate the raw graphic data to obtain a drawing object; establishing a unique identifier for the drawing object, and setting a status flag for the drawing object, wherein the status flag is used to characterize the lifecycle stage and update requirement type of the drawing object; and adding the drawing object to an object pool for unified management.
[0078] Optionally, determining the target rendering implementation module based on the graphics interface includes: obtaining environment attribute information corresponding to the current operating environment of the graphics rendering system, wherein the environment attribute information includes at least one of the following: graphics card hardware information, graphics card driver information; determining the list of graphics interface capabilities supported by the current operating environment based on the environment attribute information, wherein the list of graphics interface capabilities is used to characterize the types and functional support of graphics interfaces supported by the current operating environment; determining the drawing object that needs to be rendered, and determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the list of graphics interface capabilities according to the target rendering strategy, wherein the target rendering strategy includes at least one of the following: a compatibility priority strategy to ensure the maximum range of hardware support, a performance priority strategy to pursue the highest frame rate and lowest latency, and a mandatory specification strategy for using a specific interface version pre-defined by the user.
[0079] Optionally, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: monitoring the current operating status of the graphics rendering system's operating environment, wherein the operating status is used to characterize the real-time load level of the current operating environment; determining the rendering complexity corresponding to the drawing object that needs to be rendered, wherein the rendering complexity is used to characterize the computational load and resource requirements required for the rendering processing of the drawing object; determining the comprehensive fitness score of each rendering implementation module corresponding to each graphics interface in the graphics interface capability list under the operating status and rendering complexity, wherein the comprehensive fitness score is a comprehensive quantitative indicator used to characterize the expected rendering performance, resource utilization efficiency, and stability performance of each rendering implementation module under the operating status and rendering complexity; and determining the rendering implementation module with the highest comprehensive fitness score as the target rendering implementation module for the drawing object.
[0080] Optionally, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: obtaining the first running state data of the current running environment of the graphics rendering system in a first time period; predicting the second running state data of the current running environment in a second time period based on the first running state data, wherein the second time period is a time period after the first time period, and the second time period includes: the time period for rendering the drawing object; and determining the target rendering implementation module for rendering the drawing object based on the second running state data and the rendering complexity corresponding to the drawing object.
[0081] Optionally, the graphics rendering apparatus is further configured to: when a status flag of a drawing object is detected indicating that the drawing object has changed, determine the target data that has changed in the drawing object and the affected area corresponding to the target data in the rendering result; call the target rendering implementation module to render the target data to update the affected area in the rendering result, wherein the update operation only refreshes the affected area while keeping other unchanged areas in the rendering result unchanged.
[0082] It should be noted that the modules in the above-mentioned graphics rendering device can be program modules (e.g., a set of program instructions to implement a certain function) or hardware modules. For the latter, they can be represented in the following forms, but are not limited to these: each of the above modules is represented by a processor, or the functions of each of the above modules are implemented by a processor.
[0083] It should be noted that the graphics rendering device provided in this embodiment can be used to perform... Figure 2 The graphics rendering method shown above is also applicable to the embodiments of this application, and will not be repeated here.
[0084] This application embodiment also provides a non-volatile storage medium, which includes a stored computer program. The device containing the non-volatile storage medium executes the following graphics rendering method by running the computer program: acquiring raw graphics data and encapsulating the raw graphics data into a drawing object, wherein the raw graphics data is used to characterize the attribute information of the graphics to be drawn, and the drawing object is a basic unit used to manage the state changes of the raw graphics data; detecting the graphics interface supported by the current operating environment of the graphics rendering system, and determining a target rendering implementation module based on the graphics interface, wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules; and using the target rendering implementation module to render the drawing object to obtain a rendering result.
[0085] This application also provides a computer program product, including a computer program that, when executed by a processor, implements the steps of the graphics rendering method described in various embodiments of this application: acquiring raw graphics data and encapsulating the raw graphics data into a drawing object, wherein the raw graphics data is used to characterize the attribute information of the graphics to be drawn, and the drawing object is a basic unit used to manage the state changes of the raw graphics data; detecting the graphics interface supported by the current operating environment of the graphics rendering system, and determining the target rendering implementation module based on the graphics interface, wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules; and using the target rendering implementation module to render the drawing object to obtain a rendering result.
[0086] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0087] In the above embodiments of this application, the descriptions of each embodiment have different focuses. For parts not described in detail in a certain embodiment, please refer to the relevant descriptions of other embodiments.
[0088] In the several embodiments provided in this application, it should be understood that the disclosed technical content can be implemented in other ways. The device embodiments described above are merely illustrative; for example, the division of units can be a logical functional division, and in actual implementation, there may be other division methods. For instance, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the displayed or discussed mutual coupling, direct coupling, or communication connection may be through some interfaces; the indirect coupling or communication connection between units or modules may be electrical or other forms.
[0089] The units described as separate components may or may not be physically separate. The components shown as units may or may not be physical units; that is, they may be located in one place or distributed across multiple units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0090] Furthermore, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit. The integrated unit can be implemented in hardware or as a software functional unit.
[0091] If the integrated unit is implemented as a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or all or part of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as a USB flash drive, read-only memory (ROM), random access memory (RAM), portable hard drive, magnetic disk, or optical disk.
[0092] The above description is only a preferred embodiment of this application. It should be noted that for those skilled in the art, several improvements and modifications can be made without departing from the principle of this application, and these improvements and modifications should also be considered within the scope of protection of this application.
Claims
1. A graphics rendering method, characterized in that, include: The process of acquiring raw graphic data and encapsulating it into a drawing object includes: allocating a drawing object container to the raw graphic data and encapsulating the raw graphic data using the allocated drawing object container to obtain the drawing object; establishing a unique identifier for the drawing object and setting a status flag for the drawing object, wherein the status flag is used to characterize the lifecycle stage and update requirement type of the drawing object; and adding the drawing object to an object pool for unified management. The raw graphic data is used to characterize the attribute information of the graphic to be drawn, and the drawing object is managed uniformly in the object pool through a unique identifier and a status flag. The status flag characterizes the lifecycle stage and update requirement type. The drawing object is the basic unit for managing the state changes of the raw graphic data, and the drawing object supports state change tracking and scheduling. The method involves detecting the graphics interfaces supported by the current operating environment of the graphics rendering system and determining the target rendering implementation module based on the graphics interfaces. This includes: acquiring environment attribute information corresponding to the current operating environment of the graphics rendering system, wherein the environment attribute information includes at least one of the following: graphics card hardware information and graphics card driver information; determining a list of graphics interface capabilities supported by the current operating environment based on the environment attribute information, wherein the list of graphics interface capabilities is used to characterize the types and functional support of the graphics interfaces supported by the current operating environment; determining the drawing object that needs to be rendered, and, according to a target rendering strategy, determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the list of graphics interface capabilities, wherein the target rendering strategy includes at least one of the following: a compatibility-first strategy to ensure maximum hardware support, a performance-first strategy to pursue the highest frame rate and lowest latency, and a forced specification strategy where the user pre-defines the use of a specific interface version; wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules. The determination of the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: monitoring the current operating status of the graphics rendering system, wherein the operating status is used to characterize the real-time load level of the current operating environment; determining the rendering complexity corresponding to the drawing object that needs to be rendered, wherein the rendering complexity is used to characterize the computational load and resource requirements required for the rendering processing of the drawing object; determining the comprehensive fitness score of each rendering implementation module corresponding to each graphics interface in the graphics interface capability list under the operating status and the rendering complexity, wherein the comprehensive fitness score is a comprehensive quantitative index used to characterize the expected rendering performance, resource utilization efficiency and stability performance of each rendering implementation module under the operating status and the rendering complexity; and determining the rendering implementation module with the highest comprehensive fitness score as the target rendering implementation module for the drawing object. The determination of the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: obtaining first running state data of the current running environment of the graphics rendering system in a first time period; predicting second running state data of the current running environment in a second time period based on the first running state data, wherein the second time period is a time period after the first time period, and the second time period includes: a time period for rendering the drawing object; and determining the target rendering implementation module for rendering the drawing object based on the second running state data and the rendering complexity corresponding to the drawing object. The target rendering module is used to render the drawing object and obtain the rendering result.
2. The graphics rendering method according to claim 1, characterized in that, Obtaining the raw data for the graph includes: Receive a graphics drawing request triggered by an upper-layer application, wherein the graphics drawing request is used to indicate the attribute information of the graphics to be drawn; Extract the attribute information from the graphics drawing request, wherein the attribute information includes at least one of the following: geometric description information, appearance feature information, and auxiliary control information. The geometric description information is used to characterize the spatial position and / or shape boundary of the graphics to be drawn, the appearance feature information is used to characterize the appearance presentation effect of the graphics to be drawn, and the auxiliary control information is used to characterize the display behavior and interactive attributes of the graphics to be drawn. The extracted attribute information is organized and structured according to a preset structure to form the original graphic data with a standardized data format.
3. The graphics rendering method according to claim 1, characterized in that, The method further includes: If a status flag of the drawing object indicates that the drawing object has changed, the target data that has changed in the drawing object and the affected area of the target data in the rendering result are determined. The target rendering implementation module is invoked to render the target data, thereby updating the affected area in the rendering result. The update operation only refreshes the affected area while keeping other unchanged areas in the rendering result unchanged.
4. A graphics rendering apparatus, characterized in that, include: An object encapsulation module is used to acquire raw graphic data and encapsulate the raw graphic data into drawing objects. This includes: allocating a drawing object container to the raw graphic data and encapsulating the raw graphic data using the allocated drawing object container to obtain the drawing object; establishing a unique identifier for the drawing object and setting a status flag for the drawing object, wherein the status flag is used to characterize the lifecycle stage and update requirement type of the drawing object; and adding the drawing object to an object pool for unified management. The raw graphic data is used to characterize the attribute information of the graphic to be drawn, and the drawing object is the basic unit for managing the state changes of the raw graphic data. The drawing object is uniformly managed in the object pool through a unique identifier and a status flag. The status flag is used to characterize the lifecycle stage and update requirement type, and the drawing object supports state change tracking and scheduling. A rendering adaptation module is used to detect the graphics interfaces supported by the current operating environment of the graphics rendering system, and determine the target rendering implementation module based on the graphics interfaces. This includes: obtaining environment attribute information corresponding to the current operating environment of the graphics rendering system, wherein the environment attribute information includes at least one of the following: graphics card hardware information and graphics card driver information; determining a list of graphics interface capabilities supported by the current operating environment based on the environment attribute information, wherein the list of graphics interface capabilities is used to characterize the types and functional support of the graphics interfaces supported by the current operating environment; determining the drawing object that needs to be rendered, and determining the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the list of graphics interface capabilities according to the target rendering strategy, wherein the target rendering strategy includes at least one of the following: a compatibility priority strategy to ensure the maximum range of hardware support, a performance priority strategy to pursue the highest frame rate and lowest latency, and a forced specification strategy for using a specific interface version pre-defined by the user, wherein the target rendering implementation module is used to convert the drawing object into drawing instructions executable by the graphics interface, and different graphics interfaces correspond to different rendering implementation modules. The determination of the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: monitoring the current operating status of the graphics rendering system, wherein the operating status is used to characterize the real-time load level of the current operating environment; determining the rendering complexity corresponding to the drawing object that needs to be rendered, wherein the rendering complexity is used to characterize the computational load and resource requirements required for the rendering processing of the drawing object; determining the comprehensive fitness score of each rendering implementation module corresponding to each graphics interface in the graphics interface capability list under the operating status and the rendering complexity, wherein the comprehensive fitness score is a comprehensive quantitative index used to characterize the expected rendering performance, resource utilization efficiency and stability performance of each rendering implementation module under the operating status and the rendering complexity; and determining the rendering implementation module with the highest comprehensive fitness score as the target rendering implementation module for the drawing object. The determination of the target rendering implementation module for rendering the drawing object from the rendering implementation modules corresponding to each graphics interface in the graphics interface capability list further includes: obtaining first running state data of the current running environment of the graphics rendering system in a first time period; predicting second running state data of the current running environment in a second time period based on the first running state data, wherein the second time period is a time period after the first time period, and the second time period includes: a time period for rendering the drawing object; and determining the target rendering implementation module for rendering the drawing object based on the second running state data and the rendering complexity corresponding to the drawing object. The rendering execution module is used to render the drawing object using the target rendering implementation module to obtain the rendering result.
5. An electronic device, characterized in that, include: A memory and a processor, the processor being configured to run a program stored in the memory, wherein the program, when running, performs the graphics rendering method according to any one of claims 1 to 3.
6. A non-volatile storage medium, characterized in that, The non-volatile storage medium includes a stored computer program, wherein the device containing the non-volatile storage medium executes the graphics rendering method according to any one of claims 1 to 3 by running the computer program.
7. A computer program product, comprising a computer program, characterized in that, When the computer program is executed by the processor, it implements the steps of the graphics rendering method according to any one of claims 1 to 3.