Map rendering methods, architecture, devices, and storage media
By setting window handles and rendering threads for multiple screens, the problems of varying refresh rates and low efficiency in multi-screen map rendering are solved, achieving independent map rendering and efficient map refreshing.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-07-23
- Publication Date
- 2026-04-03
AI Technical Summary
In multi-screen environments within automobiles, existing technologies cannot meet the independent map usage needs of different in-vehicle screens and the diverse requirements for map refresh rates, resulting in low rendering efficiency.
By setting a window handle for each screen and creating a corresponding map instance and rendering thread in the rendering engine, independent rendering of multiple screens is achieved. Multiple rendering threads are used to render their respective map instances to meet the refresh rate requirements of different screens.
It achieves diversity and high efficiency in multi-screen map rendering, meets the independent refresh rate requirements of each screen for electronic maps, and improves the flexibility and efficiency of map rendering.
Smart Images

Figure CN113970334B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of map rendering technology, and in particular to a map rendering method, architecture, device and storage medium. Background Technology
[0002] As the number of screens in automobiles (referred to as in-vehicle screens) increases from one to multiple (two or more), such as two screens (one on the instrument panel and one on the center console) or three screens (one on the center console and one on each of the backrests of the two front seats), the number of in-vehicle screens increases. However, even with multiple screens, there is only one infotainment system capable of running the in-vehicle software. This means that the functions of the in-vehicle software used by users on different screens are actually supported by the same software running on the infotainment system, rather than each screen having its own independent software. The inventors discovered that users on different screens in the same vehicle may need to view different maps. Therefore, how to enable the in-vehicle software to support the independent usage needs of each screen user is a problem that needs to be solved by those skilled in the art. Summary of the Invention
[0003] This application provides a map rendering method, architecture, device, and storage medium for independently rendering electronic maps on multiple screens, which helps to meet the diverse requirements of multi-screen map rendering.
[0004] This application provides a rendering architecture, which includes: a human-computer interaction interface and a rendering engine;
[0005] The human-computer interaction interface is used to set window handles to the rendering engine, and each window handle corresponds one-to-one with the screen.
[0006] The rendering engine is used to create a corresponding map instance and rendering thread for the window handle, bind the window handle to the corresponding map instance and rendering thread, and render the map instance bound to the window handle on the screen corresponding to the window handle based on the rendering thread bound to the window handle.
[0007] This application also provides a map rendering method, including: setting a window handle to a rendering engine; the window handle being one-to-one with the screen; creating a corresponding map instance and rendering thread for the window handle; binding the window handle to the corresponding map instance and rendering thread; and rendering the map instance bound to the window handle on the screen corresponding to the window handle based on the rendering thread bound to the window handle.
[0008] This application also provides a map rendering method, including: determining the rendering thread and map instance bound to each of the window handles according to the window handles corresponding to each of the multiple screens; and using the rendering thread bound to each window handle to render the map instance bound to the corresponding window handle on the multiple screens to obtain the electronic map corresponding to each of the multiple screens.
[0009] This application also provides an electronic device, including: a memory, a processor, and a communication component; wherein the memory is used to store a computer program;
[0010] The processor is coupled to the memory and is used to execute the computer program to perform the steps in the above-described map rendering methods.
[0011] This application embodiment also provides a mobile device, including: a mechanical body and a navigation terminal and multiple screens disposed on the mechanical body;
[0012] The navigation device can be used to perform the steps in the above-described map rendering methods.
[0013] This application also provides a computer-readable storage medium storing computer instructions, which, when executed by one or more processors, cause the one or more processors to perform the steps in the above-described map rendering methods.
[0014] In this embodiment, for multi-screen map rendering scenarios, the human-computer interaction interface in the navigation software is set as window handles within the rendering engine. Each window handle corresponds one-to-one with a screen. The rendering engine can create corresponding map instances and rendering threads for each window handle, binding the window handles to their respective map instances and rendering threads. Thus, when rendering electronic maps across multiple screens, the rendering engine can render the map instance bound to each window handle on the screen corresponding to that window handle, based on the rendering thread bound to that window handle. This achieves independent rendering of electronic maps across multiple screens, not only helping to meet the diverse requirements of multi-screen map rendering but also improving rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately. Attached Figure Description
[0015] 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:
[0016] Figure 1a A schematic diagram of a rendering architecture provided in an embodiment of this application;
[0017] Figure 1bThis is a schematic diagram of the structure of a navigation system provided in an embodiment of this application;
[0018] Figure 1c and Figure 1d A flowchart illustrating the map rendering method provided in this application embodiment;
[0019] Figure 2a A flowchart illustrating another map rendering method provided in an embodiment of this application;
[0020] Figure 2b A schematic diagram illustrating the process of establishing the correspondence between the window handle of the screen and the rendering environment provided in the embodiments of this application;
[0021] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application;
[0022] Figure 4 This is a schematic diagram of the structure of a mobile device provided in an embodiment of this application. Detailed Implementation
[0023] To make the objectives, technical solutions, and advantages of this application clearer, the technical solutions of this application will be clearly and completely described below in conjunction with specific embodiments and corresponding drawings. Obviously, the described embodiments are only a part of the embodiments of this application, and not all of them. Based on the embodiments in this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.
[0024] Existing system rendering methods use a single rendering frame rate to render the electronic map corresponding to each screen, which cannot meet the diverse map refresh rate requirements of multi-screen navigation. To address this technical problem, in some embodiments of this application, for multi-screen map rendering scenarios, the human-computer interaction interface of the navigation system sets window handles for multiple screen resolutions; and sets multiple window handles in the rendering engine. The rendering engine can create corresponding map instances and rendering threads for each of the multiple window handles, binding the map instances corresponding to each window handle to their respective rendering threads. In this way, when rendering electronic maps on multiple screens, the rendering engine can call the rendering threads corresponding to each of the multiple window handles to render the map instances corresponding to each screen, realizing independent rendering of electronic maps on multiple screens. This not only helps to meet the diverse requirements of multi-screen map rendering, but also improves rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately.
[0025] The technical solutions provided by the various embodiments of this application are described in detail below with reference to the accompanying drawings.
[0026] It should be noted that the same reference numerals denote the same object in the following figures and embodiments. Therefore, once an object is defined in one figure or embodiment, it does not need to be discussed further in subsequent figures and embodiments.
[0027] Figure 1a This is a schematic diagram of a rendering architecture provided in an embodiment of this application. This rendering architecture can be implemented as a rendering architecture for an application software product. The function of each module in the rendering architecture can be implemented as a rendering method, which can be applied to application software products. The application software can be installed on a computer device. The object mounted on the computer device has multiple screens. "Multiple" refers to two or more. The multiple screens can be fixedly mounted on the object mounted on the computer device, or they can be plug-and-play screens. Accordingly, the object mounted on the computer device is provided with an interface for mounting the screens. For example, the computer device can be mounted on a motor vehicle, and the motor vehicle can be provided with a screen mounting interface through which terminal devices such as smartphones or tablets can be installed on the motor vehicle as a screen.
[0028] For rendering architecture, such as Figure 1a As shown, the rendering architecture includes a Human Machine Interaction (HMI) 10a and a rendering engine 10b. In this embodiment, the HMI 10a refers to an interface program module that enables user interaction with computer devices. In this embodiment, the HMI 10a can set window handles for each screen and set the window handle corresponding to each screen in the rendering engine 10b. Each window handle corresponds one-to-one with a screen. For multiple screens, there are multiple window handles. "Multiple" means two or more.
[0029] For rendering engine 10b, a corresponding map instance can be created for each of the multiple window handles. Optionally, rendering engine 10b can determine the map instance for each screen's corresponding window handle based on the screen's identifier and the electronic map's identifier, and bind the window handle to the map instance.
[0030] Furthermore, the rendering engine 10b can create separate rendering threads for multiple window handles. Then, the rendering engine can bind each window handle to its corresponding map instance and rendering thread, that is, bind each map instance corresponding to a window handle to its corresponding rendering thread. In this way, when rendering electronic maps across multiple screens, the rendering engine 10b can render the map instance bound to the window handle on the screen corresponding to that window handle, based on the rendering thread bound to the window handle. This achieves independent rendering of electronic maps across multiple screens, which not only helps meet the diverse requirements of multi-screen map rendering, but also improves rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately.
[0031] Accordingly, when rendering a map instance bound to a window handle, rendering engine 10b can invoke the rendering thread bound to the window handle to render the map instance, thereby obtaining the electronic map of the screen corresponding to the window handle. Furthermore, rendering engine 10b can provide the electronic map of the screen corresponding to the window handle to the screen through human-computer interaction interface 10a. Multiple screens can display their respective electronic maps.
[0032] Optionally, the rendering engine 10b can pre-create rendering environments (Contexts) corresponding to multiple window handles. A rendering environment can be understood as an internal data structure containing state information required for rendering operations. The rendering environment may contain references to vertex shader and fragment shader data, as well as window handles, the RGB values of the screen corresponding to each window handle, and the number of color bits. Optionally, the human-computer interaction interface 10a can set multiple window handles into the rendering engine 10b. The rendering engine 11b can create rendering environments for multiple window handles and bind the window handles to the rendering environments, thus establishing a correspondence between window handles and rendering environments. In this embodiment, the storage format of the correspondence between screen window handles and rendering environments is not limited. Optionally, the correspondence between window handles and rendering environments can be stored in a device information list and managed by the rendering engine 10b.
[0033] Accordingly, when rendering a map instance corresponding to a window handle, the rendering engine 10b can query the device information list using the window handle to obtain the rendering environment corresponding to each window handle. Furthermore, the rendering engine 10b can bind the rendering thread bound to each window handle to the rendering environment corresponding to that window handle. Then, it calls the rendering thread bound to each window handle, and within that rendering thread, uses the rendering environment bound to that rendering thread to render the map instance bound to the window handle, thereby obtaining an electronic map of the screen corresponding to the window handle.
[0034] Optionally, rendering engine 10b can call rendering functions to create rendering environments for multiple window handles. These rendering functions can be Embedded-System Graphics Library (EGL) functions. EGL functions include: egl Initializeegl (initializes the EGL for the screen), Create Window Surface (creates the on-screen rendering surface), egl Create Context (creates a context), and egl MakeCurrent, etc. The egl MakeCurrent function binds the created context to the current rendering thread and binds the created context and surface.
[0035] In this embodiment, the electronic maps displayed on the multiple screens serve different purposes, and correspondingly, the refresh rates of the electronic maps displayed on the multiple screens also differ. For example, in a multi-screen in-vehicle navigation system, the electronic map displayed on the screen corresponding to the center console primarily provides navigation functionality for vehicle users. This requires the electronic map to be updated in real-time as the vehicle moves, thus demanding a high refresh rate. The screens on the rear seats provide location and navigation services to passengers, helping them understand the vehicle's current location. Since passengers do not need to know their current location in real time, the real-time update requirements for the electronic map are lower, and consequently, the refresh rate requirements for the electronic map on the rear seat screens are also lower.
[0036] In this embodiment, to meet the diverse refresh rate requirements of multiple screens for the electronic map, i.e., to meet the refresh rate requirements of each screen for the electronic map, multiple rendering threads are configured in the rendering engine. "Multiple" refers to two or more. In this embodiment, the specific number of rendering threads is not limited. Optionally, the number of rendering threads is less than or equal to the number of screens. Preferably, the number of rendering threads is equal to the number of screens, i.e., one screen corresponds to one rendering thread. Optionally, if the refresh rate requirements of multiple screens for the electronic map are different, i.e., the rendering rate requirements of multiple screens are different, then the number of rendering threads can be equal to the number of screens, i.e., one rendering thread corresponds to one screen and renders the electronic map for its corresponding screen. Correspondingly, if there are screens among the multiple screens that have the same refresh rate requirements for the electronic map, i.e., the rendering rate requirements of multiple screens are partially or completely the same, then the same rendering thread can be configured for screens with the same refresh rate requirements for the electronic map. Of course, different rendering threads can also be configured for each screen.
[0037] To meet the screen's requirements for the electronic map refresh rate, in this embodiment, developers can configure the corresponding rendering frame rate for the rendering thread bound to the window handle based on the screen's rendering rate requirements. Accordingly, the rendering engine 10b can configure the rendering frame rate for the rendering thread bound to the window handle in response to the configuration operation for the rendering frame rate. The rendering frame rate refers to the frequency at which the rendering thread renders the electronic map in frames, which can be understood as the number of frames of the electronic map rendered per unit of time. The higher the screen's rendering rate requirements, the higher the rendering frame rate of the rendering thread bound to its window handle. For example, if the screen's rendering rate requirement is to refresh one frame of the electronic map every 0.05 seconds, then the rendering frame rate can be greater than or equal to 1 / 0.05s = 20Hz.
[0038] The rendering frame rate for each rendering thread can be configured by the navigation system's technicians based on the rendering speed requirements of the screen corresponding to each rendering thread, and stored in the rendering engine 10b. Alternatively, the rendering engine 10b can also configure the rendering speed based on the screen corresponding to each rendering thread, and store the configuration in the rendering engine 10b.
[0039] Optionally, rendering engine 10b can create rendering threads for window handles, resulting in the aforementioned multiple rendering threads; and configure the rendering frame rate for the rendering threads bound to the window handles in response to configuration operations for the rendering frame rate.
[0040] Optionally, the rendering engine 10b can create a rendering thread for each window handle and configure the rendering frame rate for the rendering thread bound to the window handle according to the rendering rate requirements of the screen corresponding to that window handle. Thus, when the rendering engine 10b calls the rendering thread to render the map instance bound to the window handle, the map instance can be rendered in the rendering thread bound to the window handle according to the rendering frame rate configured for that rendering thread, thereby obtaining the electronic map of the screen corresponding to that window handle.
[0041] In this embodiment, the rendering rate requirements of multiple screens can be the same or different. If multiple screens have the same rendering rate requirement, the corresponding rendering frame rates for all screens can be the same. If multiple screens have different rendering rate requirements, at least two rendering frame rates can be configured for each rendering thread. Optionally, each rendering thread can have a different rendering frame rate. The rendering frame rates of the multiple rendering threads and the number of different rendering frame rate types can be determined by the rendering rate requirements of the screens corresponding to each of the multiple rendering threads.
[0042] In this embodiment, the rendering engine 10b can call the rendering thread bound to each window handle, and render the map instance corresponding to the window handle according to the rendering frame rate corresponding to the rendering thread, thereby obtaining the electronic map of the screen corresponding to the window handle. Specifically, the rendering engine 10b can call the rendering thread bound to the window handle, and render the map instance corresponding to the window handle using the rendering environment and rendering frame rate bound to the rendering thread, thereby obtaining the electronic map of the screen corresponding to the window handle; and provide the electronic map of the screen corresponding to the window handle to the screen for display through the human-computer interaction interface 10a. Since the rendering thread renders the electronic map according to the rendering rate requirements of its corresponding screen, the refresh rate requirements of each screen for the electronic map can be met, thereby improving the diversity of map rendering rates and helping to meet the diverse map refresh rate requirements of multiple screens.
[0043] On the other hand, having multiple rendering threads render map instances on multiple screens in parallel also helps improve map rendering efficiency.
[0044] In this embodiment, the human-computer interaction interface 10a can provide the window handle of the screen to be rendered to the rendering engine 10b. The rendering engine 10b can determine the target rendering thread to which the window handle of the screen to be rendered is bound from multiple rendering threads. Specifically, the rendering engine 10b can match the window handle of the screen to be rendered in the correspondence between window handles and rendering threads to determine the target rendering thread corresponding to the screen to be rendered. The rendering engine 10b can query the aforementioned device information list to obtain the correspondence between window handles and rendering threads.
[0045] Furthermore, the rendering engine 10b can invoke the target rendering thread to render the map instance of the screen to be rendered according to the rendering frame rate corresponding to the target rendering thread, so as to obtain the electronic map corresponding to the screen to be rendered. Furthermore, the rendering engine 10b can provide the electronic map corresponding to the screen to be rendered to the screen through the human-computer interaction interface 10a, for display by the screen.
[0046] Optionally, the rendering engine 10b can query the aforementioned device information list based on the window handle of the screen to be rendered, obtain the target rendering environment bound to the window handle of the screen to be rendered, and call the target rendering thread. In the target rendering thread, the map instance corresponding to the screen to be rendered is rendered according to the rendering frame rate corresponding to the target rendering thread and using the target rendering environment to obtain the electronic map of the screen to be rendered.
[0047] Figure 1b This is a schematic diagram of the structure of a navigation system provided in an embodiment of this application. Figure 1bAs shown, the system includes a navigation terminal 11 and multiple screens 12. "Multiple" refers to two or more screens, the specific number of which is determined by the actual application scenario of the navigation system. Figure 1b The illustration shows only four screens 12, but this is not a limitation. The navigation terminal 11 and the multiple screens 12 can be mounted on a mobile object. A mobile object refers to any device equipped with a drive component that can move. For example, a mobile object can be a motor vehicle, such as a car, taxi, truck, motorcycle, or electric vehicle. Correspondingly, the multiple screens 12 can be in-vehicle screens, such as screen 12a on the center console, screen 12b on the instrument panel, or screen 12c on the rear seat. Alternatively, the mobile object can be an autonomous mobile device, such as a robot, driverless vehicle, or drone. Furthermore, the mobile object can be an aircraft, such as an airplane.
[0048] In this embodiment, the navigation terminal 11 and the screen 12 can be connected wirelessly or via a wired connection. Optionally, the navigation terminal 11 can communicate with the screen 12 via a mobile network. Accordingly, the mobile network standard can be any one of 2G (GSM), 2.5G (GPRS), 3G (WCDMA, TD-SCDMA, CDMA2000, UTMS), 4G (LTE), 4G+ (LTE+), 5G, WiMax, etc. Optionally, the navigation terminal 11 can also communicate with the screen 12 via Bluetooth, WiFi, infrared, etc.
[0049] Alternatively, when the navigation terminal 11 and the screen 12 are connected by a wired connection, they can communicate via network cable, fiber optic cable, or a human-machine interface. The human-machine interface can be a serial bus interface, such as a PCIe interface, USB interface, RS485 bus interface, or RS-232 bus interface.
[0050] In this embodiment, the navigation system is a multi-screen navigation system. In this embodiment, the navigation terminal 11 is a software module, application, service, or physical device capable of responding to service requests from the screen 12 and providing map rendering services to the screen 12. If the navigation terminal 11 is a software module, application, or service, it can be deployed in any physical device containing any screen 12, or it can be deployed in any other physical module with data processing capabilities among the mobile objects mounted on multiple screens 12.
[0051] Accordingly, the navigation terminal 11 can be deployed on any display device on the motor vehicle, or it can be deployed in other physical modules of the motor vehicle that have data functions, such as the central control system of the motor vehicle, etc.
[0052] Optionally, the navigation terminal 11 can be a physical device deployed locally on the mobile object, or a server device deployed in the cloud. For example, the server device can be a single server device, a cloud-based server array, or a virtual machine (VM) running in a cloud-based server array. In addition, the server device can also refer to other computing devices with corresponding service capabilities, such as computer terminals (running service programs), etc.
[0053] In this embodiment, screen 12 is an electronic device deployed locally on the mobile object, and it has display functions and the ability to communicate with the navigation terminal 11. Optionally, screen 12 may also have certain data processing functions. Multiple screens can be fixedly installed on the mobile object, or they can be plug-and-play screens. Correspondingly, the object on which the computer device is mounted is provided with an interface for inserting screens.
[0054] The screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touchscreen to receive input signals from the user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors can sense not only the boundaries of the touch or swipe action, but also the duration and pressure associated with the touch or swipe operation.
[0055] In this embodiment, screen 12 can display an electronic map to provide navigation functionality for users on mobile devices. Optionally, screen 12 may have navigation-related applications (APPs) installed, which can provide electronic maps to users. Multiple screens 12 may display the same or different electronic maps. Optionally, the electronic maps displayed on multiple screens 12 can be set by the user on the mobile device and pre-stored in screen 12. Alternatively, screen 12 can request relevant electronic maps from navigation terminal 11. Optionally, screen 12 can respond to user operations related to electronic map identifiers by providing the identifier of the selected electronic map and the identifier of screen 12 to navigation terminal 11. Accordingly, navigation terminal 11 can determine the electronic map corresponding to screen 12 based on the electronic map identifier and the identifier of screen 12.
[0056] In this embodiment, the navigation terminal 11 may be equipped with navigation software. The navigation software includes a human-computer interaction interface 11a and a rendering engine 11b. The human-computer interaction interface 11a can set window handles for multiple screens 12 respectively, resulting in multiple window handles. Each screen 12 corresponds to one window handle. Furthermore, the human-computer interaction interface 11a can set multiple window handles in the rendering engine 11b.
[0057] For rendering engine 11b, it can create corresponding map instances for multiple window handles. Optionally, rendering engine 11b can determine the map instance corresponding to screen 12 based on the identifier of the electronic map and the identifier of screen 12, and use the map instance corresponding to screen 12 as the map instance of the window handle corresponding to that screen.
[0058] Furthermore, the rendering engine 11b can create separate rendering threads for multiple window handles. Then, each window handle is bound to its corresponding map instance and rendering thread; that is, the map instance corresponding to each window handle is bound to the rendering thread corresponding to that window handle. In this way, when rendering electronic maps across multiple screens, the rendering engine 11b can render the map instance bound to that window handle on each screen based on the rendering thread bound to that window handle, achieving independent rendering of electronic maps across multiple screens. This not only helps meet the diverse requirements of multi-screen map rendering, but also improves rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately.
[0059] Accordingly, when the rendering engine 11b binds the corresponding map instance to the rendering window handle, it can call the rendering threads corresponding to the window handles of multiple screens 11b respectively to render the map instances corresponding to the multiple window handles, thereby obtaining the electronic maps corresponding to the multiple screens 12 respectively. Furthermore, the rendering engine 11b can provide the electronic maps corresponding to the multiple screens 12 to the multiple screens 12 through the human-computer interaction interface 11a. The multiple screens 12 can then display their respective electronic maps.
[0060] Optionally, the rendering engine 11b can pre-create rendering environments (Contexts) corresponding to multiple window handles. For a description of the rendering environments, please refer to the relevant content in the above embodiments, which will not be repeated here. Optionally, the human-computer interaction interface 11a can set multiple window handles to the rendering engine 11b. The rendering engine 11b can create rendering environments for multiple window handles and bind the window handles of multiple screens 12 to the corresponding rendering environments of multiple screens 12, that is, establish a correspondence between window handles and rendering environments. In this embodiment, the storage format of the correspondence between screen window handles and rendering environments is not limited. Optionally, the correspondence between window handles and rendering environments can be stored in a device information list and managed by the rendering engine in the rendering engine 11b.
[0061] Accordingly, when rendering map instances corresponding to multiple window handles, the rendering engine 11b can query the device information list using multiple window handles to obtain the rendering environment bound to each window handle. Specifically, the rendering engine 11b matches each window handle against the mapping between window handles and rendering environments to obtain the rendering environment bound to each window handle. Furthermore, the rendering engine 11b can bind the rendering thread corresponding to each window handle to the rendering environment corresponding to that window handle. Then, it calls the rendering threads corresponding to the bindings of multiple window handles, and in each rendering thread, it uses the rendering environment bound to that rendering thread to render the map instance bound to that rendering thread, thereby obtaining the electronic map of the screen corresponding to the window handle.
[0062] Optionally, the rendering engine 11b can call rendering functions to create rendering environments for multiple window handles. A description of the rendering functions can be found in the relevant content of the above embodiments, and will not be repeated here.
[0063] In this embodiment, the electronic maps displayed on the multiple screens 12 serve different purposes, and correspondingly, the refresh rates of the electronic maps displayed on the multiple screens 12 are also different. To meet the diverse refresh rate requirements of the multiple screens 12, that is, to meet the refresh rate requirements of each screen 12, multiple rendering threads are set in the rendering engine 11b. "Multiple" means two or more. In this embodiment, the specific number of rendering threads is not limited. Optionally, the number of rendering threads is less than or equal to the number of screens 12. Preferably, the number of rendering threads is equal to the number of screens 12, that is, one rendering thread corresponds to one screen. Optionally, if the refresh rate requirements of the multiple screens 12 are different, that is, the rendering rate requirements of the multiple screens 12 are different, then the number of rendering threads can be equal to the number of screens 12, that is, one rendering thread corresponds to one screen and renders the electronic map for its corresponding screen. Accordingly, if there are multiple screens 12 that have the same requirement for the refresh rate of the electronic map, that is, multiple screens 12 have the same requirement for the rendering rate, then the same rendering thread can be configured for the screens 12 that have the same requirement for the refresh rate of the electronic map. Of course, different rendering threads can also be configured for each screen 12.
[0064] To meet the refresh rate requirements of the electronic map on screen 12, in this embodiment, a corresponding rendering frame rate can be configured for the rendering thread bound to the corresponding window handle of screen 12 according to the rendering rate requirements of screen 12. Accordingly, rendering engine 11b can configure the rendering frame rate for multiple rendering threads in response to the configuration operation for the rendering frame rate.
[0065] The rendering frame rate for each rendering thread can be configured by the navigation system's technicians based on the rendering speed requirements of the screen corresponding to each rendering thread, and stored in the rendering engine 11b. Alternatively, the rendering engine 11b can also configure the rendering speed based on the screen corresponding to each rendering thread, and store it in the rendering engine 11b.
[0066] Optionally, the rendering engine 11b can create rendering threads for multiple window handles respectively, resulting in the aforementioned multiple rendering threads; and configure the rendering frame rate for the rendering threads corresponding to the multiple screens 12 according to the rendering rate requirements of the screens 12 corresponding to the multiple window handles. Each window handle corresponds one-to-one with a screen.
[0067] Optionally, the rendering engine 11b can create a rendering thread for each window handle and configure the rendering frame rate for the rendering thread bound to the window handle according to the rendering rate requirements of the screen 12 corresponding to that window handle. In this way, when the rendering engine 11b calls the rendering thread to render the map instance bound to the window handle, the map instance bound to the window handle can be rendered according to the rendering frame rate configured by the rendering thread bound to the window handle.
[0068] In this embodiment, the rendering engine 11b can call the rendering thread bound to each window handle and render the map instance bound to that window handle according to the rendering frame rate configured for that rendering thread, thereby obtaining the electronic map of the screen corresponding to the window handle. Specifically, the rendering engine 11b can call the rendering thread bound to the window handle, utilize the rendering environment and rendering frame rate bound to the rendering thread, render the map instance corresponding to the window handle, thereby obtaining the electronic map of the screen corresponding to the window handle; and provide the electronic map of the screen corresponding to the window handle to the screen for display through the human-computer interaction interface 10a. Since the rendering thread renders the electronic map according to the rendering rate requirements of its corresponding screen, the refresh rate requirements of each screen for the electronic map can be met, thereby improving the diversity of map rendering rates and helping to meet the diverse map refresh rate requirements of multiple screens.
[0069] On the other hand, having multiple rendering threads render map instances on multiple screens in parallel also helps improve map rendering efficiency.
[0070] Accordingly, when an electronic map needs to be displayed, screen 12 can provide a rendering request to navigation terminal 12. This rendering request includes the window handle of the screen to be rendered. Optionally, screen 12 can determine that an electronic map needs to be displayed upon detecting a power-on operation and provide a rendering request to navigation terminal 12. Alternatively, screen 12 can display electronic map usage controls on its screen, and upon detecting a trigger operation on the electronic map usage controls, determine that an electronic map needs to be displayed and provide a rendering request to navigation terminal 12.
[0071] Accordingly, the navigation terminal 12 can obtain a rendering request and parse the window handle of the screen to be rendered from it. Further, the navigation terminal 12 can determine the target rendering thread corresponding to the screen to be rendered from multiple rendering threads based on the window handle of the screen to be rendered. Specifically, the navigation terminal 12 can match the window handle of the screen to be rendered in the correspondence between window handles and rendering threads to determine the target rendering thread corresponding to the screen to be rendered. The rendering engine 11b can query the aforementioned device information list to obtain the correspondence between the screen's window handle and the rendering thread.
[0072] Furthermore, the rendering engine 11b can invoke the target rendering thread. In the target rendering thread, the map instance bound to the target rendering thread is rendered according to the rendering frame rate configured for the target rendering thread, so as to obtain the electronic map corresponding to the screen to be rendered. Furthermore, the rendering engine 11b can provide the electronic map corresponding to the screen to be rendered to the screen through the human-computer interaction interface 11a, so that the screen can display it.
[0073] Optionally, the navigation terminal 12 can query the above-mentioned device information list according to the window handle of the screen to be rendered, obtain the target rendering environment bound to the window handle of the screen to be rendered, and call the target rendering thread. In the target rendering thread, the map instance corresponding to the screen to be rendered is rendered according to the rendering frame rate corresponding to the target rendering thread and using the target rendering environment to obtain the electronic map corresponding to the screen to be rendered.
[0074] In addition to the navigation system provided in the above embodiments, this application also provides a map rendering method applicable to the above-mentioned navigation terminal. The map rendering method provided in this embodiment will be described exemplarily below.
[0075] Figure 1c This is a flowchart illustrating a map rendering method provided in an embodiment of this application. Figure 1c As shown, the method includes:
[0076] 101a. Set the window handle in the rendering engine, with each window handle corresponding to a screen.
[0077] 102a. Create a corresponding map instance and rendering thread for the window handle.
[0078] 103a. Bind the window handle to its corresponding map instance and rendering thread.
[0079] 104a. The rendering thread based on the window handle binding renders the map instance bound to the window handle on the screen corresponding to the window handle.
[0080] In this embodiment, the screen can display an electronic map to provide navigation functionality for the user of the moving object. Optionally, the electronic device on which the screen is located can have navigation-related applications (APPs) or other software installed, which can provide the user with electronic maps. Multiple screens can display the same or different electronic maps. Optionally, the user of the moving object can independently set the electronic maps displayed on multiple screens and pre-store them in the screens. Alternatively, the screen can request relevant electronic maps from the navigation terminal. Optionally, the screen can respond to the user's operation on the electronic map identifier by providing the identifier of the selected electronic map and the screen's identifier to the navigation terminal. Accordingly, the navigation terminal can determine the electronic map corresponding to the screen based on the electronic map identifier and the screen's identifier.
[0081] In this embodiment, the navigation terminal is equipped with navigation software, which includes a human-computer interaction interface and a rendering engine. For the navigation terminal, window handles can be set for multiple screens to obtain multiple window handles. Each screen corresponds to one window handle. Furthermore, multiple window handles can be set in the rendering engine. Each window handle corresponds one-to-one with a screen.
[0082] Furthermore, the navigation terminal can create a corresponding map instance for the window handle. Optionally, the rendering engine can determine the map instance corresponding to the screen based on the identifiers of the electronic map and the screen itself.
[0083] Furthermore, a corresponding rendering thread can be created for each window handle. Then, the window handle is bound to its corresponding map instance and rendering thread; that is, the map instance corresponding to each window handle is bound to the rendering thread corresponding to that window handle. In this way, when rendering electronic maps across multiple screens, the rendering thread bound to each screen's window handle can be used to render its respective map instance. This allows for independent rendering of electronic maps across multiple screens, which not only helps meet the diverse requirements of multi-screen map rendering but also improves rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately.
[0084] Accordingly, embodiments of this application also provide a map rendering method, which will be described below in conjunction with... Figure 1d An example is provided. Figure 1d As shown, the map rendering method includes:
[0085] 101b. Based on the window handles corresponding to each of the multiple screens, determine the rendering thread and map instance bound to each window handle.
[0086] 102b. Call the rendering thread bound to each window handle to render the map instance bound to the corresponding window handle on multiple screens, and obtain the electronic map corresponding to each of the multiple screens.
[0087] In this embodiment, when the navigation terminal renders electronic maps on multiple screens, it can determine the rendering thread and map instance bound to each window handle of each screen based on the window handles of the multiple screens; and use the rendering thread bound to each window handle to render the corresponding map instance bound to each window handle on the multiple screens, thereby obtaining the electronic maps corresponding to each of the multiple screens. The multiple screens can display their respective electronic maps.
[0088] Optionally, the navigation terminal can pre-create rendering environments (Contexts) corresponding to multiple window handles. Optionally, the navigation terminal can create rendering environments for multiple window handles and bind the window handles of multiple screens to their corresponding rendering environments, thus establishing a correspondence between window handles and rendering environments. In this embodiment, the storage format of the correspondence between screen window handles and rendering environments is not limited. Optionally, the correspondence between window handles and rendering environments can be stored in a device information list and managed by the rendering engine within the rendering engine.
[0089] Accordingly, when rendering map instances bound to their respective window handles on multiple screens, the navigation terminal can query the device information list using the window handle of each screen to obtain the rendering environment bound to each window handle. More precisely, the rendering engine matches each window handle against the mapping between window handles and rendering environments to obtain the rendering environment bound to each window handle. Further, the rendering engine can bind the rendering thread bound to each window handle to the rendering environment corresponding to that window handle. Then, it calls the rendering thread corresponding to each window handle, and within each rendering thread, it uses the rendering environment bound to that rendering thread to render the map instance bound to that rendering thread, thereby obtaining the electronic map for the screen corresponding to that rendering thread.
[0090] Optionally, the rendering engine can call rendering functions to create rendering environments for multiple window handles. For a description of the rendering functions, please refer to the relevant content in the above embodiments, which will not be repeated here.
[0091] In this embodiment, the electronic maps displayed on multiple screens serve different purposes, and correspondingly, the refresh rates of the electronic maps displayed on the multiple screens are also different. Based on this, this application embodiment also provides a map rendering method. For example... Figure 2a As shown, the method mainly includes:
[0092] 201. Based on the window handles corresponding to each of the multiple screens, call the rendering thread bound to each window handle.
[0093] 202. In each rendering thread, according to the rendering frame rate configured for that rendering thread, the map instance bound to the window handle is rendered on the screen corresponding to the window handle, so as to obtain the electronic map corresponding to each of the multiple screens.
[0094] In this embodiment, to meet the diverse refresh rate requirements of multiple screens for the electronic map, i.e., to meet the refresh rate requirements of each screen for the electronic map, multiple rendering threads are configured in the navigation terminal. "Multiple" refers to two or more. In this embodiment, the specific number of rendering threads is not limited. Optionally, the number of rendering threads is less than or equal to the number of screens. Preferably, the number of rendering threads is equal to the number of screens, i.e., one rendering thread corresponds to one screen. Optionally, if the refresh rate requirements of multiple screens for the electronic map are different, i.e., the rendering rate requirements of multiple screens are different, then the number of rendering threads can be equal to the number of screens, i.e., one rendering thread corresponds to one screen and renders the electronic map for its corresponding screen. Correspondingly, if there are screens among the multiple screens that have the same refresh rate requirements for the electronic map, i.e., the rendering rate requirements of multiple screens are partially or completely the same, then the same rendering thread can be configured for screens with the same refresh rate requirements for the electronic map. Of course, different rendering threads can also be configured for each screen.
[0095] To meet the screen's requirements for electronic map refresh rate, in this embodiment, a corresponding rendering frame rate can be configured for the screen's rendering thread based on the screen's rendering speed requirements. The rendering frame rate refers to the frequency at which the rendering thread renders the electronic map in frames, which can be understood as the number of frames of the electronic map rendered per unit of time. The higher the screen's rendering speed requirements, the higher the rendering frame rate of its corresponding rendering thread.
[0096] The rendering frame rate for each rendering thread can be configured by the navigation system's technicians based on the rendering speed requirements of the screen corresponding to each rendering thread, and then stored in the navigation terminal. Alternatively, the navigation terminal can also configure the rendering rate based on the rendering speed requirements of the screen corresponding to each rendering thread, and then store the configuration in the navigation terminal.
[0097] Optionally, prior to step 201, rendering threads can be created for multiple screens respectively, resulting in the aforementioned multiple rendering threads; and in response to the rendering frame rate configuration operation, the rendering frame rate is configured for the rendering threads corresponding to the multiple screens. Optionally, this process can be completed before the mobile object mounted on the screen leaves the factory.
[0098] Optionally, a rendering thread can be created for each screen, and the rendering frame rate can be configured for that rendering thread according to the screen's rendering speed requirements. In this way, when the rendering thread is invoked to render the map instance corresponding to that screen, the map instance can be rendered according to the rendering frame rate configured for that screen's rendering thread. The process of obtaining the map instance corresponding to a screen can be found in the section on determining the electronic map corresponding to a screen in the navigation terminal section above, and will not be repeated here.
[0099] In this embodiment, the rendering rate requirements of multiple screens can be the same or different. If multiple screens have the same rendering rate requirement, the corresponding rendering frame rates for all screens can be the same. If multiple screens have different rendering rate requirements, at least two rendering frame rates can be configured for each rendering thread. Optionally, each rendering thread can have a different rendering frame rate. The rendering frame rates of the multiple rendering threads and the number of different rendering frame rate types can be determined by the rendering rate requirements of the screens corresponding to each of the multiple rendering threads.
[0100] In this embodiment, in step 201, the rendering thread bound to each window handle can be invoked according to the window handles corresponding to each of the multiple screens; and in step 202, in each rendering thread, the map instance bound to the window handle is rendered on the screen corresponding to the window handle according to the rendering frame rate configured for that rendering thread. Specifically, the rendering thread bound to the window handle is invoked, and the map instance corresponding to the window handle is rendered using the rendering environment and rendering frame rate bound to the rendering thread, thereby obtaining the electronic map of the screen corresponding to the window handle. Since the rendering thread renders the electronic map according to the rendering rate requirements of its corresponding screen, the refresh rate requirements of each screen for the electronic map can be met, thereby improving the diversity of map rendering rates and helping to meet the diverse map refresh rate requirements of multiple screens.
[0101] In this embodiment, after creating rendering threads for window handles corresponding to multiple screens, a correspondence between window handles and rendering threads can be established and maintained. Accordingly, a correspondence between screen window handles and rendering threads can be established. In this embodiment, the storage format of the correspondence between screen window handles and rendering threads is not limited. Optionally, the correspondence between window handles and rendering threads is stored in a list. This list can be called a device information list and can be managed by the rendering engine.
[0102] Accordingly, when the screen requires the display of an electronic map, it can provide a rendering request to the navigation terminal. This rendering request includes an identifier of the screen to be rendered. For details on how the navigation terminal determines the need to display an electronic map, please refer to the relevant content in the above system embodiments, which will not be repeated here.
[0103] Accordingly, one optional implementation of step 201 is as follows: Obtain a rendering request and parse out the identifier of the screen to be rendered from it; determine the target rendering thread corresponding to the screen to be rendered from multiple rendering threads based on the identifier of the screen to be rendered; further, call the target rendering thread to render the map instance of the screen to be rendered according to the rendering frame rate corresponding to the target rendering thread, so as to obtain the electronic map corresponding to the screen to be rendered. Further, the electronic map corresponding to the screen to be rendered can be provided to the screen for display.
[0104] Optionally, a target rendering environment bound to the identifier of the screen to be rendered can be obtained according to the identifier of the screen to be rendered; and the target rendering thread can be called to render the map instance corresponding to the screen to be rendered according to the rendering frame rate corresponding to the target rendering thread, and the target rendering environment can be used to render the map instance corresponding to the screen to be rendered, so as to obtain the electronic map corresponding to the screen to be rendered.
[0105] Optionally, the rendering engine can be used to call rendering functions to create rendering environments for multiple screens. These rendering functions can be EGL functions. For a description of EGL functions, please refer to the relevant content in the above system embodiment; it will not be repeated here.
[0106] To more clearly illustrate the correspondence between the screen identifier (screen window handle identifier) and the rendering thread, as well as the process of establishing the correspondence between the screen window handle identifier and the rendering environment, the following section combines... Figure 2b The diagram illustrating the creation process is provided as an example. Figure 2b As shown, the process of establishing the correspondence between the screen's window handle identifier and the rendering environment mainly includes:
[0107] S1: The human-computer interaction interface sets the window handle identifiers of multiple screens to the rendering engine.
[0108] S2: The rendering engine creates rendering environments for multiple window handles.
[0109] S3: Bind the window handle of each screen to its corresponding rendering environment, and store the correspondence between the window handle and the rendering environment of multiple screens in the device information list managed by the rendering engine.
[0110] S4: The rendering engine creates a map instance for each screen's window handle.
[0111] S5: The rendering engine creates an independent rendering thread for each map instance and binds the rendering thread to the map instance.
[0112] S6: Store the map instances bound to each rendering thread in the device information list.
[0113] It should be noted that the execution subject of each step in the method provided in the above embodiments can be the same device, or the method can be executed by different devices. For example, the execution subject of steps 202 and 203 can be device A; or the execution subject of step 201 can be device A, and the execution subject of step 203 can be device B; and so on. For example, in the above embodiments, steps 201-203 can be executed by the navigation terminal or the server device alone; or they can be completed by the navigation terminal and the server device in cooperation. For example, steps 201 and 202 can be executed by the server device, and step 203 can be executed by the navigation terminal; and so on.
[0114] Furthermore, some processes described in the above embodiments and accompanying drawings include multiple operations that appear in a specific order. However, it should be clearly understood that these operations may not be executed in the order they appear herein, or they may be executed in parallel. The operation numbers, such as 201, 202, etc., are merely used to distinguish different operations and do not represent any execution order. In addition, these processes may include more or fewer operations, and these operations may be executed sequentially or in parallel.
[0115] Accordingly, embodiments of this application also provide a computer-readable storage medium storing computer instructions, which, when executed by one or more processors, cause one or more processors to perform the steps in the map rendering method described above.
[0116] Figure 3 This is a schematic diagram of the structure of an electronic device provided in an embodiment of this application. Figure 3 As shown, the terminal device includes: a memory 30a, a processor 30b, and a communication component 30c. The memory 30a is used to store computer programs.
[0117] The processor 30b is coupled to the memory 30c for executing computer programs to: set window handles to the rendering engine; correspond one-to-one between window handles and screens; create corresponding map instances and rendering threads for window handles; bind window handles to corresponding map instances and rendering threads; and render the map instance bound to the window handle on the screen corresponding to the window handle based on the rendering thread bound to the window handle.
[0118] Accordingly, when the processor 30b renders the map instance bound to the window handle on the screen corresponding to the window handle, it specifically performs the following: calls the rendering thread corresponding to the window handle to render the map instance bound to the window handle, thereby obtaining an electronic map on the screen corresponding to the window handle; calls the rendering thread corresponding to the window handle; and renders the map instance bound to the window handle onto the screen corresponding to the window handle in the rendering thread corresponding to the window handle.
[0119] Furthermore, when the processor 30b renders map instances corresponding to multiple window handles, it specifically performs the following steps: It queries the device information list managed by the rendering engine using the window handle to obtain the rendering environment corresponding to the window handle; the device information list stores the correspondence between window handles and rendering environments; it binds the rendering thread bound to the window handle to the rendering environment corresponding to the window handle; it calls the rendering thread bound to the window handle, and in the rendering thread bound to the window handle, it uses the rendering environment bound to the rendering thread to render the map instance bound to the window handle onto the screen corresponding to the window handle.
[0120] In some embodiments, the processor 30b is further configured to: create a rendering environment for a window handle; have a one-to-one correspondence between the rendering environment and the window handle; and store the correspondence between the window handle and the rendering environment in a device information list.
[0121] Optionally, when the processor 30b creates rendering environments for multiple window handles respectively, it specifically calls a rendering function to create a rendering environment for each window handle. Optionally, the rendering function may be an EGL function.
[0122] Optionally, the processor 30b is also configured to: configure the rendering frame rate for the rendering thread to which the window handle is bound in response to a configuration operation for the rendering frame rate.
[0123] Accordingly, when the processor 30b renders map instances corresponding to multiple window handles, it specifically performs the following: calls the rendering thread bound to the window handle, and renders the map instance bound to the window handle according to the rendering frame rate configured by the rendering thread bound to the window handle, so as to obtain the electronic map of the screen corresponding to the window handle. Specifically, it calls the rendering thread bound to the window handle, and renders the map instance bound to the window handle using the rendering thread bound to the window handle and the rendering frame rate, so as to obtain the electronic map of the screen corresponding to the window handle.
[0124] In some other embodiments, the processor 30b is further configured to: determine the rendering thread and map instance bound to each window handle according to the window handles corresponding to each of the multiple screens; and render the map instances bound to the window handles on the multiple screens using the rendering threads bound to the window handles respectively, thereby obtaining the electronic maps corresponding to the multiple screens.
[0125] Optionally, each of the multiple rendering threads is configured with a rendering frame rate. When the processor 30b calls multiple rendering threads to render map instances corresponding to multiple screens, it specifically performs the following: in the rendering thread bound to each window handle, according to the rendering frame rate configured by the rendering thread, renders the map instance bound to the window handle onto the screen corresponding to the window handle, so as to obtain the electronic map of the screen corresponding to the window handle.
[0126] In some alternative implementations, such as Figure 3 As shown, the electronic device may be a screen, and may also include components such as a screen 30d, a power supply component 30e, and an audio component 30f. The electronic device may also be a server device, which may further include components such as a power supply component 30e. Figure 3 The diagram only shows some components and does not mean that the electronic device must contain them. Figure 3 The fact that all components are shown does not mean that an electronic device can only include... Figure 3 The components shown.
[0127] In this embodiment, the memory is used to store computer programs and can be configured to store various other data to support operations on the device where the memory resides. The processor can execute the computer programs stored in the memory to implement corresponding control logic. The memory can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable programmable read-only memory (EPROM), programmable read-only memory (PROM), read-only memory (ROM), magnetic storage, flash memory, magnetic disk, or optical disk.
[0128] In the embodiments of this application, the processor can be any hardware processing device capable of executing the above-described method logic. Optionally, the processor can be a central processing unit (CPU), a graphics processing unit (GPU), or a microcontroller unit (MCU); it can also be a field-programmable gate array (FPGA), a programmable array logic (PAL), a general array logic (GAL), a complex programmable logic device (CPLD), or other programmable devices; or it can be an advanced reduced instruction set (RISC) processor (ARM) or a system on chip (SOC), etc., but is not limited thereto.
[0129] In this embodiment, the communication component is configured to facilitate wired or wireless communication between its host device and other devices. The device housing the communication component can access wireless networks based on communication standards, such as WiFi, 2G or 3G, 4G, 5G, or combinations thereof. In one exemplary embodiment, the communication component receives broadcast signals or broadcast-related information from an external broadcast management system via a broadcast channel. In another exemplary embodiment, the communication component may also be implemented based on Near Field Communication (NFC), Radio Frequency Identification (RFID), Infrared Data Association (IrDA), Ultra Wideband (UWB), Bluetooth (BT), or other technologies. The communication component may also be a serial communication bus. The serial bus interface may be a PCIe interface, USB interface, RS485 bus interface, or RS-232 bus interface, etc.
[0130] In embodiments of this application, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen can be implemented as a touchscreen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensors can sense not only the boundaries of touch or swipe actions but also the duration and pressure associated with the touch or swipe operation.
[0131] In this embodiment, a power supply component is configured to provide power to various components of the device in which it resides. The power supply component may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power to the device in which the power supply component resides.
[0132] In embodiments of this application, the audio component can be configured to output and / or input audio signals. For example, the audio component includes a microphone (MIC), which is configured to receive external audio signals when the device containing the audio component is in an operating mode, such as a call mode, recording mode, or voice recognition mode. The received audio signals can be further stored in memory or transmitted via a communication component. In some embodiments, the audio component also includes a speaker for outputting audio signals. For example, in electronic devices with voice interaction capabilities, voice interaction with the user can be achieved through the audio component.
[0133] In the electronic device provided in this embodiment, for multi-screen map rendering scenarios, the human-computer interaction interface of the navigation system sets window handles for multiple screen resolutions; and sets multiple window handles in the rendering engine. The rendering engine can create corresponding map instances and rendering threads for each of the multiple window handles, and bind the window handles to their corresponding map instances and rendering threads. In this way, when rendering electronic maps on multiple screens, the rendering engine can call the rendering thread bound to each window handle to render the map instance bound to that window handle on the screen corresponding to the window handle, realizing independent rendering of electronic maps on multiple screens. This not only helps to meet the diverse requirements of multi-screen map rendering, but also helps to improve rendering efficiency by using multiple rendering threads to render the map instances corresponding to each of the multiple screens separately.
[0134] Figure 4 This is a schematic diagram of the structure of a mobile device provided in an embodiment of this application. Figure 4 As shown, the mobile device includes a mechanical body 40 and a navigation terminal 41 and multiple screens 42 disposed on the mechanical body 40. The implementation details of the navigation terminal 41 and screens 42 can be found in the relevant content of the above system embodiment, and will not be repeated here.
[0135] It is worth noting that the navigation terminal 41 and multiple screens 42 can be located inside the mechanical body 40 or on the surface of the mechanical body 40.
[0136] The mechanical body 40 is the actuator of the mobile device, capable of performing operations specified by the mobile device within a defined environment. The mechanical body 40, to a certain extent, reflects the physical form of the mobile device. However, in this embodiment, the physical form of the mobile device is not limited. The form of the mechanical body is determined by the implementation form of the mobile device. The mechanical body 40 primarily refers to the fuselage of the mobile device and its internal mechanical structures. For example, if the mobile device is a motor vehicle, then the mechanical body 40 primarily refers to the fuselage of the motor vehicle; if the mobile device is an aircraft (such as an airplane), then the mechanical body 40 primarily refers to the fuselage of the aircraft and its internal mechanical structures; and if the mobile device is an autonomous mobile device, then the mechanical body 40 primarily refers to the fuselage of the autonomous mobile device and its internal mechanical structures.
[0137] It is worth noting that the mechanical body 40 also includes some basic components of the mobile device, such as a drive component, odometer, power supply component, audio component, etc. Optionally, the drive component may include drive wheels, drive motor, casters, etc. The basic components and their configurations may vary in different mobile devices; the embodiments listed in this application are only some examples.
[0138] In this embodiment, the navigation terminal 41 includes a human-computer interaction interface and a rendering engine.
[0139] The human-computer interaction interface is used to set window handles to the rendering engine, with each window handle corresponding to a specific screen. The rendering engine is used to create corresponding map instances and rendering threads for each window handle, bind the window handle to the corresponding map instance and rendering thread, and render the map instance bound to the window handle on the screen corresponding to the window handle based on the rendering thread bound to the window handle.
[0140] In some embodiments, the rendering engine is further configured to: create a rendering environment for a window handle, wherein the rendering environment corresponds one-to-one with the window handle; and store the correspondence between the window handle and the rendering environment in a device information list.
[0141] Optionally, when the rendering engine creates a rendering environment for the window handle, it specifically involves: calling a rendering function to create a rendering environment for the window handle. Optionally, the rendering function is an EGL function.
[0142] In some embodiments, when rendering a map instance bound to a window handle, the rendering engine specifically performs the following: calls the rendering thread bound to the window handle to render the map instance bound to the window handle, obtaining an electronic map of the screen corresponding to the window handle; and provides the electronic map of the screen corresponding to the window handle to the screen for display through a human-computer interaction interface.
[0143] Optionally, when rendering map instances corresponding to multiple window handles, the rendering engine specifically performs the following: queries the device information list using multiple window handles to obtain the rendering environment corresponding to each window handle; binds the rendering thread corresponding to each window handle to the rendering environment corresponding to that window handle; calls the rendering threads corresponding to each of the multiple window handles, and in each rendering thread, renders the map instance bound to that rendering thread using the rendering environment bound to that rendering thread, so as to obtain the electronic map of the screen corresponding to that rendering thread.
[0144] Furthermore, the rendering engine uses the map instance bound to the rendering window handle specifically to: query the device information list using the window handle to obtain the rendering environment corresponding to the window handle; bind the rendering thread bound to the window handle to the rendering environment corresponding to the window handle; call the rendering thread bound to the window handle, and in the rendering thread bound to the window handle, use the rendering environment bound to the rendering thread to render the map instance bound to the rendering thread to obtain the electronic map of the screen corresponding to the window handle.
[0145] In other embodiments, the rendering engine is also configured to: configure the rendering frame rate for the rendering thread to which the window handle is bound in response to a configuration operation for the rendering frame rate.
[0146] Optionally, when the rendering engine calls the rendering threads corresponding to multiple window handles to render the map instances corresponding to the multiple window handles, it specifically calls the rendering thread bound to the window handle and renders the map instances bound to the window handle according to the rendering frame rate configured by the rendering thread bound to the window handle, so as to obtain the electronic map of the screen corresponding to the window handle.
[0147] In other embodiments, the rendering engine is also used to: determine the rendering thread and map instance bound to each window handle according to the window handles corresponding to each of the multiple screens; and use the rendering thread bound to each window handle to render the map instance bound to the corresponding window handle on the multiple screens to obtain the electronic map corresponding to each of the multiple screens.
[0148] Optionally, each of the multiple rendering threads is configured with a rendering frame rate. When the rendering engine renders the map instance bound to its corresponding window handle on multiple screens, it specifically performs the following: in the rendering thread bound to each window handle, according to the rendering frame rate configured by the rendering thread, renders the map instance bound to the window handle onto the screen corresponding to the window handle, so as to obtain the electronic map of the screen corresponding to the window handle.
[0149] The mobile device provided in this embodiment is equipped with a navigation terminal and multiple screens. The navigation terminal has navigation software installed. For multi-screen map rendering scenarios, the human-computer interaction interface in the navigation software is set in the rendering engine as window handles corresponding to each screen. The rendering engine can create corresponding map instances and rendering threads for each window handle, binding the window handle to its corresponding map instance and rendering thread. In this way, when rendering electronic maps on multiple screens, the rendering engine can call the rendering thread bound to each window handle to render the map instance bound to that window handle on the corresponding screen, achieving independent rendering of electronic maps on multiple screens. This not only helps meet the diverse requirements of multi-screen map rendering but also improves rendering efficiency by using multiple rendering threads to render the map instances corresponding to each screen separately.
[0150] It should be noted that the terms "first" and "second" in this article are used to distinguish different messages, devices, modules, etc., and do not represent a chronological order, nor do they limit "first" and "second" to different types.
[0151] Those skilled in the art will understand that embodiments of this application can be provided as methods, systems, or computer program products. Therefore, this application can take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, this application can take the form of a computer program product embodied on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0152] This application is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of this application. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more flowchart illustrations and / or one or more block diagrams.
[0153] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0154] These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable apparatus, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0155] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0156] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0157] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information using any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic magnetic disk storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0158] It should also be noted that the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.
[0159] The above description is merely an embodiment of this application and is not intended to limit this application. Various modifications and variations can be made to this application by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principle of this application should be included within the scope of the claims of this application.
Claims
1. A rendering architecture, wherein, include: Human-computer interaction interface and rendering engine; The human-computer interaction interface is used to set window handles to the rendering engine. Each window handle corresponds to a screen, and there are multiple screens, each corresponding to a multiple window handle. The rendering engine is used to create a corresponding map instance and rendering thread for the window handle, and bind the window handle to the corresponding map instance and rendering thread. And call the rendering thread bound to the window handle. In the rendering thread bound to each window handle, render the map instance bound to the window handle to the screen corresponding to the window handle according to the rendering frame rate configured by the rendering thread, so as to obtain the electronic map of the screen corresponding to the window handle. The electronic map is provided to the screen corresponding to the window handle for display through the human-computer interaction interface.
2. The architecture according to claim 1, wherein, The rendering engine is also used for: Create a rendering environment for the window handle; each rendering environment corresponds one-to-one with a window handle. The mapping between window handles and rendering environments is stored in the device information list managed by the rendering engine; The step of invoking the rendering thread bound to the window handle to render the map instance bound to the window handle, in order to obtain an electronic map of the screen corresponding to the window handle, specifically involves: The window handle is used to query the device information list managed by the rendering engine to obtain the rendering environment corresponding to the window handle; the device information list stores the correspondence between window handles and rendering environments; Bind the rendering thread to the window handle to the rendering environment corresponding to the window handle; The rendering thread bound to the window handle is invoked, and the rendering environment bound to the rendering thread is used to render the map instance bound to the rendering thread in order to obtain the electronic map of the screen corresponding to the window handle.
3. The architecture according to claim 2, wherein, Creating a rendering environment for the window handle specifically includes: The rendering function is invoked to create a rendering environment for the window handle.
4. The architecture according to claim 2, wherein, The rendering engine is also used for: In response to a configuration operation for the rendering frame rate, configure the rendering frame rate for the rendering thread to which the window handle is bound.
5. A map rendering method, wherein, include: Set the window handle to the rendering engine; Each window handle corresponds one-to-one with a screen, and there are multiple screens, each corresponding to a multiple window handle; Create a corresponding map instance and rendering thread for the window handle; Bind the window handle to the corresponding map instance and rendering thread; The rendering thread bound to the window handle is invoked, and the map instance bound to the window handle is rendered using the rendering thread and rendering frame rate to obtain the electronic map of the screen corresponding to the window handle.
6. The method according to claim 5, wherein, Rendering the map instance bound to the window handle onto the screen corresponding to the window handle includes: The window handle is used to query the device information list managed by the rendering engine to obtain the rendering environment corresponding to the window handle; the device information list stores the correspondence between window handles and rendering environments; Bind the rendering thread to the window handle to the rendering environment corresponding to that window handle; The rendering thread bound to the window handle is invoked, and within the rendering thread bound to the window handle, the rendering environment bound to the rendering thread is used to render the map instance bound to the window handle onto the screen corresponding to the window handle.
7. The method according to claim 6, wherein, Also includes: A rendering environment is created for each window handle; each rendering environment corresponds one-to-one with a window handle. Store the mapping between window handles and rendering environments in the device information list.
8. The method according to claim 7, wherein, Creating a rendering environment for the window handle includes: The rendering function is invoked to create a rendering environment for the window handle.
9. The method according to claim 8, wherein, The method further includes: In response to a configuration operation for the rendering frame rate, configure the rendering frame rate for the rendering thread to which the window handle is bound.
10. A map rendering method, wherein, The method includes: Based on the window handles corresponding to each of the multiple screens, determine the rendering thread and map instance bound to each window handle; The rendering thread bound to the window handle is invoked. In the rendering thread bound to each window handle, the map instance bound to the window handle is rendered onto the screen corresponding to the window handle according to the rendering frame rate configured by the rendering thread, so as to obtain the electronic map of the screen corresponding to the window handle; the electronic map is provided to the screen corresponding to the window handle for display through the human-computer interaction interface.
11. The method according to claim 10, wherein, Each of the multiple rendering threads is configured with a rendering frame rate; Utilizing the rendering thread bound to each of the window handles, the map instance corresponding to that window handle is rendered on the multiple screens, including: In the rendering thread bound to each window handle, the map instance bound to the window handle is rendered onto the screen corresponding to the window handle according to the rendering frame rate configured by the rendering thread, so as to obtain the electronic map of the screen corresponding to the window handle.
12. An electronic device, comprising: Memory, processor, and communication components; wherein the memory is used to store computer programs; The processor is coupled to the memory for executing the computer program to perform the steps of the method according to any one of claims 5-11.
13. A mobile device, comprising: The mechanical body, as well as the navigation device and multiple screens mounted on the mechanical body; The navigation device can be used to perform the steps in the method according to any one of claims 5-11.
14. The device according to claim 13, wherein the movable device is a motor vehicle, an autonomous mobile device, or an aircraft.
15. A computer-readable storage medium storing computer instructions that, when executed by one or more processors, cause the one or more processors to perform the steps of the method according to any one of claims 5-11.
Citation Information
Patent Citations
Multi region graphics protracting method and device applied to intelligent operating system
CN106502662A
Multi-window rendering method and device
CN107423014A