Ship position display method and device, electronic equipment and storage medium

By generating tile maps on the backend and displaying them on the frontend, the efficiency problem of displaying a large number of ship locations in ship monitoring and real-time traffic was solved, thereby improving system stability and user experience.

CN120973874APending Publication Date: 2025-11-18BEIJING HIGHLANDER DIGITAL TECH
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202510889203.9
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-06-30
Publication Date
2025-11-18

AI Technical Summary

Technical Problem

In ship monitoring and real-time traffic applications, existing technologies cannot efficiently display and update a large amount of dynamic ship location information on a map in real time, resulting in excessive memory usage of the front-end page, high network bandwidth consumption, and system instability, which affects user experience and system performance.

Method used

The backend pre-generates a tile map of the target ship, and the frontend requests the corresponding tiles based on the current map layer for display, reducing the rendering pressure on the frontend and the dependence on network bandwidth. The corresponding tile map is only displayed when the display range is less than a threshold.

Benefits of technology

This effectively reduces front-end rendering pressure and network bandwidth consumption, ensures real-time display of ship positions, and improves system stability and user experience.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120973874A_ABST
    Figure CN120973874A_ABST
Patent Text Reader

Abstract

The invention discloses a ship position display method and device, electronic equipment and a storage medium. The method comprises the steps of obtaining current position information of a target ship; generating a tile map of the target ship according to the target level and the current position information of the target ship; and in response to determining that the display range of the target ship on the target display page is smaller than or equal to the target threshold value, displaying a tile map corresponding to the target ship level on the target display page. According to the method, when the page map level is low and the display range is large, single targets of all ships are not rendered in real time any more, the tile map of the corresponding level is generated by the rear end in advance according to the real-time position of the ship, and the tile map is displayed by the front end according to the corresponding tile requested by the current map level; therefore, the rendering pressure of the front end and the dependence on the network bandwidth are reduced, and meanwhile, the real-time display of the ship position is ensured.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application belongs to the technical field of ship navigation and navigation, and particularly relates to a ship position display method, a ship position display device, an electronic device, and a computer readable storage medium. BACKGROUND

[0002] In modern geographic information systems (GIS) and map applications, Mercator projection is a commonly used map projection method and is widely used in network maps, navigation systems and other fields. Based on the map grading technology of Mercator projection, the map data is efficiently stored, transmitted and rendered by dividing the map into multiple levels of tiles.

[0003] However, in ship monitoring, real-time traffic and other application scenarios, it is necessary to display and update the position information of a large number of dynamic targets (such as ships) on the map in real time. In the most complex case, such as when the map level is low, tens of thousands of target positions in the entire world range need to be displayed and maintained at the same time, and the positions of these targets need to be updated in real time. Such high-frequency DOM operations and redrawing can cause high memory usage of the front-end page, and further cause page lag, unresponsive operation, and even page crashes, which seriously affects user experience and system stability.

[0004] Therefore, how to efficiently display and update the position information of a large number of dynamic ships on the map in real time has become a technical problem to be solved in the current ship navigation and navigation technical field. SUMMARY

[0005] The present application aims to at least solve one of the technical problems existing in the prior art. To this end, the present application provides a ship position display method, device, electronic device and storage medium.

[0006] In a first aspect, the embodiments of the present application provide a ship position display method, comprising:

[0007] obtaining current position information of a target ship;

[0008] generating a tile map of the target ship according to a target level of the target ship and the current position information;

[0009] in response to determining that the display range of the target ship in the target display page is less than or equal to a target threshold, displaying the tile map corresponding to the target ship level in the target display page.

[0010] In some embodiments, obtaining the current position information of the target ship comprises:

[0011] determining a first storage space of the target ship; wherein the first storage space is a backend resource storage space;

[0012] The current location information of the target vessel is determined in the first storage space; wherein, the current location information includes the latitude and longitude information of the target vessel.

[0013] In some embodiments, a tile map of the target vessel is generated based on the target vessel's target level and current location information, including:

[0014] Determine the target level of the target vessel;

[0015] Convert latitude and longitude information into coordinate point information at the target level;

[0016] The pixel position of the target ship in the target level is determined based on latitude and longitude information;

[0017] Based on coordinate point information and pixel position, a tile map of the target ship at the target level is generated.

[0018] In some embodiments, converting latitude and longitude information into coordinate point information at the target level includes:

[0019]

[0020] Where X represents the X-axis coordinate of the target vessel in the target level, Y represents the Y-axis coordinate of the target vessel in the target level, lon represents the longitude of the target vessel, φ represents the latitude of the target vessel, and zoomLevel represents the level information of the target level.

[0021] In some embodiments, determining the pixel position of the target ship in the target hierarchy based on latitude and longitude information includes:

[0022] Determine the target vessel's current longitude and latitude information based on latitude and longitude information;

[0023] The pixel position of the target ship is determined based on the current longitude and latitude information.

[0024] In some embodiments, after generating a tile map of the target ship at the target level, the method further includes:

[0025] Identify the second storage space of the target vessel; wherein, the second storage space is the front-end resource storage space;

[0026] The historical map in the second storage space is updated based on the tile map, and the current map information of the target ship is obtained.

[0027] In some embodiments, in response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold, displaying a tile map corresponding to the target vessel's level on the target display page includes:

[0028] In response to determining that the display range of the target vessel on the target display page is less than or equal to the target threshold, the current map information is displayed on the target display page.

[0029] Secondly, embodiments of this application provide a display device for a ship's position, comprising:

[0030] The location information acquisition module is configured to acquire the current location information of the target vessel;

[0031] The tile map generation module is configured to generate a tile map of the target ship based on the target ship's target level and current location information.

[0032] The tile map display module is configured to display a tile map corresponding to the target vessel's level on the target display page in response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold.

[0033] Thirdly, embodiments of this application provide an electronic device, including: a processor and a memory, wherein the memory stores a program or instructions executable on the processor, and the program or instructions, when executed by the processor, implement the steps of the ship position display method as described in the first aspect.

[0034] Fourthly, embodiments of this application provide a computer-readable storage medium storing a program or instructions that, when executed by a processor, implement the steps of the ship position display method as described in the first aspect.

[0035] The technical solution provided in this application first obtains the current location information of the target vessel. Further, based on the target vessel's target level and current location information, a tile map of the target vessel is generated. Then, in response to determining that the display area of ​​the target vessel on the target display page is less than or equal to a target threshold, the tile map corresponding to the target vessel's level is displayed on the target display page. When the page map level is low and the display area is large, this application no longer renders individual targets of all vessels in real time. Instead, it utilizes the backend to pre-generate tile maps of corresponding levels based on the real-time location of the vessels, and the frontend requests the corresponding tiles based on the current map level for display. This reduces the rendering pressure on the frontend and its dependence on network bandwidth, while ensuring the real-time display of vessel positions.

[0036] Additional aspects and advantages of this application will be set forth in part in the description which follows, and in part will be obvious from the description, or may be learned by practice of this application. Attached Figure Description

[0037] The above and / or additional aspects and advantages of this application will become apparent and readily understood from the description of the embodiments taken in conjunction with the following drawings, in which:

[0038] Figure 1 This is a flowchart illustrating a method for displaying the position of a ship, as provided in an embodiment of this application.

[0039] Figure 2 This is a schematic diagram of a blank tile map provided in an embodiment of this application.

[0040] Figure 3 This is a schematic diagram of a tile map corresponding to a target ship level, provided in an embodiment of this application.

[0041] Figure 4 This is a schematic diagram of a ship position display device provided in an embodiment of this application.

[0042] Figure 5 This is a schematic diagram of the structure of an electronic device according to an embodiment of this application. Detailed Implementation

[0043] Embodiments of this application will now be described in more detail with reference to the accompanying drawings. While some embodiments of this application are shown in the drawings, it should be understood that this application can be implemented in various forms and should not be construed as limited to the embodiments set forth herein. Rather, these embodiments are provided to provide a more thorough and complete understanding of this application. It should be understood that the drawings and embodiments of this application are for illustrative purposes only and are not intended to limit the scope of protection of this application.

[0044] It should be understood that the steps described in the method embodiments of this application may be performed in different orders and / or in parallel. Furthermore, the method embodiments may include additional steps and / or omit the steps shown. The scope of this application is not limited in this respect.

[0045] As described in the background section, applications such as ship monitoring and real-time traffic require the real-time display and updating of the location information of a large number of dynamic targets (such as ships) on a map. However, in the most complex cases, such as when the map level is 1, it is necessary to simultaneously display and maintain the locations of tens of thousands (e.g., 70,000+) of targets across the entire world, and update the positions of these targets in real time. This high frequency of DOM manipulation and repainting leads to the following serious problems:

[0046] Excessive CPU and memory usage: Front-end pages need to constantly process and render the location information of a large number of targets, leading to excessive consumption of CPU and memory resources, which in turn causes page lag, unresponsiveness, or even crashes. The problem persists even after refreshing the page, severely impacting user experience and system stability.

[0047] Network bandwidth limitations: Maintaining and updating so many target locations simultaneously requires frequent data requests to the server, resulting in significant network bandwidth consumption. In poor network conditions, the latency of real-time updates will be further exacerbated, affecting data accuracy.

[0048] Front-end physical machine performance limitations: The hardware performance of front-end devices is limited and cannot withstand long-term, high-intensity rendering tasks. Over-reliance on the performance of the front-end machine can lead to system instability or even failure to function properly.

[0049] Traditional real-time rendering methods have significant limitations when handling large-scale dynamic targets. These methods typically require the front-end page to directly process and render the positional information of all targets, resulting in excessive resource consumption and failing to meet the needs of practical applications. Therefore, a new technical solution is needed to address these issues and improve system performance and stability.

[0050] Therefore, this application proposes a method, apparatus, electronic device, and storage medium for displaying ship positions. First, the current position information of the target ship is obtained. When the page map level is low and the display range is large, this application no longer renders individual targets of all ships in real time. Instead, it uses the backend to pre-generate tile maps of the corresponding level based on the real-time position of the ships, and uses the frontend to request the corresponding tiles based on the current map level for display, thereby reducing the rendering pressure on the frontend and the dependence on network bandwidth, while ensuring the real-time display of ship positions.

[0051] The technical solution of this application will be further described in detail below through specific embodiments.

[0052] Mercator projection is a widely used map projection method in Geographic Information Systems (GIS) and online map services. Based on Mercator projection, maps are divided into multiple levels of tiles, each level consisting of 2 tiles of the same size. For example, a level 0 map consists of 1 tile, representing the entire world; a level 1 map consists of 2 tiles; a level 2 map consists of 4 tiles, and so on, up to level 18. As the map level increases, the geographical area displayed on the screen gradually decreases, but the map detail and accuracy correspondingly increase. Tiles are typically 256 pixels × 256 pixels in standard size, facilitating efficient transmission and rendering.

[0053] refer to Figure 1 This is a flowchart illustrating a method for displaying the position of a ship provided in an embodiment of this application.

[0054] Step S101: Obtain the current location information of the target vessel.

[0055] Specifically, the current location information of the target vessel typically comes from the vessel's positioning equipment (such as GPS, AIS, etc.), which transmits the vessel's latitude and longitude information in real time. This location information is then transmitted to a backend server via wireless communication networks (such as satellite communication, 4G / 5G networks, etc.). The backend server stores the received location information in a database or cache (i.e., backend resource storage space) for subsequent querying and use.

[0056] As an optional embodiment, obtaining the current location information of the target vessel includes: determining a first storage space for the target vessel; wherein the first storage space is a backend resource storage space; determining the current location information of the target vessel in the first storage space; wherein the current location information includes the latitude and longitude information of the target vessel.

[0057] Specifically, the primary storage space refers to the backend resource storage space, typically a server or database that centrally stores and manages ship location information. This storage space can be a physical server, a cloud storage service, or a distributed database system. The selection of storage space must consider reliability, meaning choosing storage space with high reliability and redundancy mechanisms to ensure that location information is not lost due to hardware failure. Scalability must also be considered, meaning that considering the future increase in the number of ships, the storage space should have good scalability and be able to dynamically adjust its capacity. Security is paramount, meaning that encryption technologies (such as SSL / TLS) should be used to protect the security of data transmission and storage, preventing data leakage and tampering.

[0058] Furthermore, the current location information primarily includes the latitude and longitude of the target vessel, and may also include additional information such as timestamps, headings, and speeds. The latest location information of the target vessel can be retrieved in real-time from the primary storage space via API interfaces or database queries. For scenarios requiring the retrieval of multiple vessel location information, a batch query mechanism can be employed to improve query efficiency. In addition, location information is typically stored and transmitted in structured data formats (such as JSON and XML), facilitating front-end parsing and processing.

[0059] Step S102: Generate a tile map of the target ship based on the target ship's target level and current location information.

[0060] refer to Figure 2 This is a schematic diagram of a blank tile map provided in an embodiment of this application.

[0061] Tile maps are typically a series of fixed-size images (e.g., 256 pixels x 256 pixels) that can be efficiently transmitted and rendered.

[0062] refer to Figure 3This is a schematic diagram of a tile map corresponding to a target ship level provided in an embodiment of this application.

[0063] Specifically, the target layer on the map where the target ship will be displayed is determined based on the map zoom level or user needs. Higher layers display more detail but also require more computation. Then, the latitude and longitude information of the target ship is converted into coordinate point information at the target layer. In this embodiment, a map projection algorithm (such as Mercator projection) is preferably used to ensure the accuracy of the coordinate transformation. Further, based on the transformed coordinate point information, a tile map of the target ship at the target layer is generated.

[0064] For example, each level of the tile map is generated sequentially. For each ship, its X-axis coordinates, Y-axis coordinates, and pixel position within the tile are calculated using its latitude and longitude information. Pixels can be marked with a special color (such as green). For instance, a ship with latitude and longitude (0,0) would be located in the first tile of the first row, corresponding to the first pixel in the first row of that tile. Once all ships have been calculated, one level of the map is generated; once all levels have been calculated, one version of the map is complete. Inland waterway vessels typically travel at 22-27 km / h, averaging 367-450 meters per minute. In the 11th-level map, a tile is approximately 19.56 x 9.78 km, and a standard tile size is 256 x 256 pixels. A pixel's latitude and longitude is approximately 76.4 x 38.2 meters. Inland waterways mostly run east-west; with an 11-level map, ships travel an average of 7-8 pixels per minute, which basically meets real-time requirements.

[0065] As an optional embodiment, a tile map of the target vessel is generated based on the target vessel's target level and current location information, including: determining the target level of the target vessel; converting latitude and longitude information into coordinate point information in the target level; determining the pixel position of the target vessel in the target level based on the latitude and longitude information; and generating a tile map of the target vessel in the target level based on the coordinate point information and the pixel position.

[0066] Specifically, the target level refers to the map zoom level, usually represented by an integer (e.g., level 0 represents a global view, level 18 represents a street-level view). Higher levels display more detail, but also require more computation and data transfer. In practical applications, level selection can be based on the user's specific needs (e.g., global monitoring, local tracking). It can also be based on the performance of the front-end device (e.g., CPU, memory, network bandwidth) to avoid performance degradation due to excessively high levels. Finally, a default level can be set and used when the user does not specify one.

[0067] Furthermore, the Mercator projection algorithm is typically used to convert latitude and longitude information into planar coordinates. This algorithm ensures that points on the Earth's surface retain their angles after projection, but the area will be distorted as latitude increases.

[0068] As an optional embodiment, converting latitude and longitude information into coordinate point information at the target level includes:

[0069]

[0070] Where X represents the X-axis coordinate of the target vessel in the target level, Y represents the Y-axis coordinate of the target vessel in the target level, lon represents the longitude of the target vessel, φ represents the latitude of the target vessel, and zoomLevel represents the level information of the target level.

[0071] Furthermore, it is necessary to convert the longitude information of the target ship into the X-axis pixel position in the target level, and convert the latitude information of the target ship into the Y-axis pixel position in the target level.

[0072] As an optional embodiment, determining the pixel position of the target ship in the target level based on latitude and longitude information includes: determining the current longitude and current latitude information of the target ship based on the latitude and longitude information; and determining the pixel position of the target ship based on the current longitude and current latitude information.

[0073]

[0074] Where x represents the X-axis pixel position of the target ship in the target level, y represents the Y-axis pixel position of the target ship in the target level, lon represents the longitude of the target ship, φ represents the latitude of the target ship, and zoomLevel represents the level information of the target level. This represents the remainder function.

[0075] It should be noted that pixels exceeding the map boundaries can be cropped or looped to ensure display accuracy. Pixel positions can also be dynamically adjusted based on map panning and zooming operations.

[0076] Furthermore, the map is divided into fixed-size tiles (e.g., 256 pixels × 256 pixels), each tile corresponding to a unique coordinate identifier. Based on the coordinate information and pixel positions, a map image of the tile containing the target ship is generated. The generated tiles are cached to reduce redundant generation and improve response speed.

[0077] It's worth noting that a preloading strategy can be employed, prioritizing the loading of tiles within the current viewport to improve user experience. If multiple tiles exist, they need to be stitched together to form a complete map view, ensuring seamless integration. Furthermore, the performance of tile generation and loading should be monitored in real-time to ensure stable system operation.

[0078] As an optional embodiment, after generating the tile map of the target ship at the target level, the method further includes: determining a second storage space for the target ship; wherein the second storage space is a front-end resource storage space; updating the historical map in the second storage space based on the tile map, and obtaining the current map information of the target ship.

[0079] Specifically, the second storage space refers to the front-end resource storage space, typically browser cache, local storage (such as LocalStorage, IndexedDB), or front-end server cache. This storage space is used for temporary or persistent storage of map data to facilitate fast access and reduce network requests. In this application, a storage space with fast access speed (such as memory cache) needs to be selected to reduce map loading latency. The storage space can also be selected based on data persistence requirements (e.g., LocalStorage is suitable for long-term storage, while memory cache is suitable for short-term use). The selection of storage space also needs to consider capacity limitations to avoid performance degradation due to storing too much data.

[0080] Furthermore, the map in the second storage space adopts an incremental update method, that is, only the tile map of the current viewport or the area where the target ship is located is updated, avoiding the performance overhead of a full update. In this embodiment, version management of the tile map is also performed (the caching and updating of the tile map can be managed using a front-end caching library (such as lru-cache, quick-lru)) to ensure that the front-end uses the latest map data.

[0081] For map caching strategies, one approach is to load tile maps only when needed, reducing initial loading time. Another approach is preloading, which involves predicting potential user actions (such as zooming and panning) and loading the relevant tile maps in advance.

[0082] Finally, the current map information includes metadata such as the tile map data of the target ship, the pixel location information of the target ship, the map layer, viewport range, and zoom level. The updated tile map is then integrated with the pixel location information of the target ship to generate complete current map information for the target ship.

[0083] In step S103, in response to determining that the display range of the target vessel on the target display page is less than or equal to the target threshold, a tile map corresponding to the target vessel's level is displayed on the target display page.

[0084] Specifically, the display range of a target vessel on the target display page can be monitored in real time by calculating the distance or area between the target vessel and the viewport boundary. Furthermore, based on system performance and user experience requirements, a target threshold is set. When the display range is less than or equal to this threshold, the tile map is triggered. The tile map corresponding to the target vessel's level is then loaded and displayed on the target display page.

[0085] As an optional embodiment, in response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold, displaying a tile map corresponding to the target vessel's level on the target display page includes: in response to determining that the display range of the target vessel on the target display page is less than or equal to the target threshold, displaying current map information on the target display page.

[0086] Specifically, the system monitors the display range of the target vessel on the target display page in real time (e.g., the size of the pixel area occupied by the vessel icon or marker). When the display range is less than or equal to the preset target threshold, it means that the current display range meets the current requirements, and the current map information can be kept loaded.

[0087] When the display range is less than or equal to the target threshold, a tile map corresponding to the target ship's level is loaded. The appropriate level can be automatically selected based on the display range (e.g., the smaller the display range, the higher the level). The loaded tile map contains detailed geographic information about the target ship and its surrounding area (such as coastlines, ports, and waterways).

[0088] In this embodiment, users can manually set levels or thresholds, and can also overlay icons or markers of target ships on the tile map and display their current location information. Users can zoom, pan, and perform other operations on the tile map.

[0089] It should be noted that when the map is panned, zoomed, or the ship's position is updated, the display range needs to be recalculated and a threshold judgment needs to be triggered.

[0090] It's important to note that the target threshold can be continuously optimized based on actual application scenarios and user feedback to improve system response speed and user experience. Lazy loading or preloading strategies can be employed to reduce page load time and enhance user experience. Real-time monitoring of system performance, including CPU utilization, memory usage, and network bandwidth, can ensure stable system operation.

[0091] This application provides a method for displaying ship positions. First, it obtains the current position information of the target ship. Then, based on the target ship's target level and current position information, it generates a tile map of the target ship. Next, in response to determining that the display area of ​​the target ship on the target display page is less than or equal to a target threshold, it displays the tile map corresponding to the target ship's level on the target display page. When the page map level is low and the display area is large, this application no longer renders individual targets of all ships in real time. Instead, it utilizes the backend to pre-generate tile maps of corresponding levels based on the real-time positions of the ships, and the frontend requests the corresponding tiles based on the current map level for display. This reduces the rendering pressure on the frontend and its dependence on network bandwidth, while ensuring the real-time display of ship positions.

[0092] It should be noted that the method of this embodiment can be executed by a single device, such as a computer or server. The method of this embodiment can also be applied to a distributed scenario, where multiple devices cooperate to complete the task. In such a distributed scenario, one of these devices may execute only one or more steps of the method of this embodiment, and the multiple devices will interact with each other to complete the above method.

[0093] It should be noted that the above description describes some embodiments of the present invention. Other embodiments are within the scope of the appended claims. In some cases, the actions or steps described in the claims may be performed in a different order than that shown in the above embodiments and still achieve the desired results. Furthermore, the processes depicted in the drawings do not necessarily require a specific or sequential order to achieve the desired results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.

[0094] Corresponding to the above embodiments, the present invention also proposes a display device for ship position.

[0095] like Figure 4 The diagram shown is a schematic of a ship position display device provided in an embodiment of this application.

[0096] The ship position display device 400 of this embodiment includes:

[0097] The location information acquisition module 401 is configured to acquire the current location information of the target vessel;

[0098] The tile map generation module 402 is configured to generate a tile map of the target ship based on the target level and current location information of the target ship.

[0099] The tile map display module 403 is configured to display a tile map corresponding to the target ship's level on the target display page in response to determining that the display range of the target ship on the target display page is less than or equal to a target threshold.

[0100] Optionally, the location information acquisition module 401 is also configured as follows:

[0101] Identify the first storage space of the target vessel; wherein, the first storage space is the backend resource storage space;

[0102] The current location information of the target vessel is determined in the first storage space; wherein, the current location information includes the latitude and longitude information of the target vessel.

[0103] Optionally, the tile map generation module 402 is also configured as follows:

[0104] Determine the target level of the target vessel;

[0105] Convert latitude and longitude information into coordinate point information at the target level;

[0106] The pixel position of the target ship in the target level is determined based on latitude and longitude information;

[0107] Based on coordinate point information and pixel position, a tile map of the target ship at the target level is generated.

[0108] Optionally, the latitude and longitude information is converted into coordinate point information at the target level, including:

[0109]

[0110] Where X represents the X-axis coordinate of the target vessel in the target level, Y represents the Y-axis coordinate of the target vessel in the target level, lon represents the longitude of the target vessel, φ represents the latitude of the target vessel, and zoomLevel represents the level information of the target level.

[0111] Optionally, the tile map generation module 402 is also configured as follows:

[0112] Determine the target vessel's current longitude and latitude information based on latitude and longitude information;

[0113] The pixel position of the target ship is determined based on the current longitude and latitude information.

[0114] Optionally, the tile map generation module 402 is also configured as follows:

[0115] Identify the second storage space of the target vessel; wherein, the second storage space is the front-end resource storage space;

[0116] The historical map in the second storage space is updated based on the tile map, and the current map information of the target ship is obtained.

[0117] Optionally, the tile map display module 403 is also configured as follows:

[0118] In response to determining that the display range of the target vessel on the target display page is less than or equal to the target threshold, the current map information is displayed on the target display page.

[0119] This application provides a device for displaying ship positions. First, it acquires the current position information of the target ship. Then, based on the target ship's target level and current position information, it generates a tile map of the target ship. Next, in response to determining that the display area of ​​the target ship on the target display page is less than or equal to a target threshold, it displays the tile map corresponding to the target ship's level on the target display page. When the page map level is low and the display area is large, this application no longer renders individual targets of all ships in real time. Instead, it utilizes the backend to pre-generate tile maps of corresponding levels based on the real-time positions of the ships, and the frontend requests the corresponding tiles based on the current map level for display. This reduces the rendering pressure on the frontend and its dependence on network bandwidth, while ensuring the real-time display of ship positions.

[0120] For ease of description, the above apparatus is described in terms of its functions, divided into various modules. Of course, in implementing this invention, the functions of each module can be implemented in one or more software and / or hardware components.

[0121] The apparatus of the above embodiments is used to implement the corresponding method in any of the foregoing embodiments and has the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0122] Corresponding to the above embodiments, the present invention also proposes an electronic device.

[0123] refer to Figure 5 The diagram below is a block diagram of an electronic device according to some embodiments of the present invention. It illustrates a more specific hardware structure of the electronic device provided in this embodiment. The device may include: a processor 510, a memory 520, an input / output interface 530, a communication interface 540, and a bus 550. The processor 510, memory 520, input / output interface 530, and communication interface 540 are interconnected internally via the bus 550.

[0124] The processor 510 can be implemented using a general-purpose CPU (Central Processing Unit), microprocessor, application-specific integrated circuit (ASIC), or one or more integrated circuits, and is used to execute relevant programs to implement the technical solutions provided in the embodiments of this specification.

[0125] The memory 520 can be implemented in the form of ROM (Read Only Memory), RAM (Random Access Memory), static storage device, dynamic storage device, etc. The memory 520 can store the operating system and other applications. When the technical solutions provided in the embodiments of this specification are implemented by software or firmware, the relevant program code is stored in the memory 520 and is called and executed by the processor 510.

[0126] Input / output interface 530 is used to connect input / output modules to realize information input and output. Input / output modules can be configured as components in the device (not shown in the figure) or externally connected to the device to provide corresponding functions. Input devices may include keyboards, mice, touch screens, microphones, various sensors, etc., and output devices may include displays, speakers, vibrators, indicator lights, etc.

[0127] The communication interface 540 is used to connect a communication module (not shown in the figure) to enable communication between this device and other devices. The communication module can communicate via wired means (e.g., USB, Ethernet cable) or wireless means (e.g., mobile network, Wi-Fi, Bluetooth).

[0128] Bus 550 includes a pathway for transmitting information between various components of the device, such as processor 510, memory 520, input / output interface 530, and communication interface 540.

[0129] It should be noted that although the above-described device only shows the processor 510, memory 520, input / output interface 530, communication interface 540, and bus 550, in specific implementations, the device may also include other components necessary for normal operation. Furthermore, those skilled in the art will understand that the above-described device may only include the components necessary for implementing the embodiments of this specification, and not necessarily all the components shown in the figures.

[0130] The electronic devices described above are used to implement the corresponding methods in any of the foregoing embodiments and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0131] Based on the same inventive concept, corresponding to the methods of any of the above embodiments, the present invention also provides a computer-readable storage medium storing computer instructions for causing a computer to perform the methods of any of the above embodiments.

[0132] The aforementioned computer-readable storage medium can be any available medium or data storage device that a computer can access, including but not limited to magnetic storage (e.g., floppy disks, hard disks, magnetic tapes, magneto-optical disks (MOs), etc.), optical storage (e.g., CDs, DVDs, BDs, HVDs, etc.), and semiconductor storage (e.g., ROMs, EPROMs, EEPROMs, non-volatile memory (NAND flash), solid-state drives (SSDs)).

[0133] The computer instructions stored in the storage medium of the above embodiments are used to cause the computer to perform the methods of any of the above exemplary method sections, and have the beneficial effects of the corresponding method embodiments, which will not be repeated here.

[0134] Furthermore, although the operations of the method of the present invention are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in that specific order, or that all of the operations shown must be performed to achieve the desired result. Rather, the steps depicted in the flowchart may be performed in a different order. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0135] It should be understood that various parts of the present invention can be implemented in hardware, software, firmware, or a combination thereof. In the above embodiments, multiple steps or methods can be implemented in software or firmware stored in memory and executed by a suitable instruction execution system. For example, if implemented in hardware, as in another embodiment, it can be implemented using any one or a combination of the following techniques known in the art: discrete logic circuits having logic gates for implementing logical functions on data signals, application-specific integrated circuits (ASICs) having suitable combinational logic gates, programmable gate arrays (PGAs), field-programmable gate arrays (FPGAs), etc.

[0136] It should be noted that, unless otherwise defined, the technical or scientific terms used in the embodiments of this invention should have the ordinary meaning understood by those skilled in the art. The terms "first," "second," and similar terms used in the embodiments of this invention do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Terms such as "comprising" or "including" mean that the element or object preceding the word covers the element or object listed after the word and its equivalents, without excluding other elements or objects. Terms such as "connected" or "linked" are not limited to physical or mechanical connections, but can include electrical connections, whether direct or indirect. Terms such as "upper," "lower," "left," and "right" are only used to indicate relative positional relationships; when the absolute position of the described object changes, the relative positional relationship may also change accordingly.

[0137] While the spirit and principles of the invention have been described with reference to several specific embodiments, it should be understood that the invention is not limited to the disclosed specific embodiments, and the division of aspects does not imply that features in these aspects cannot be combined for benefit; such division is merely for ease of description. The invention is intended to cover various modifications and equivalent arrangements included within the spirit and scope of the appended claims. The scope of the appended claims is to be interpreted in the broadest sense, thereby encompassing all such modifications and equivalent structures and functions.

Claims

1. A method for displaying the position of a ship, characterized in that, include: Obtain the current location information of the target vessel; Based on the target level of the target vessel and the current location information, generate a tile map of the target vessel; In response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold, a tile map corresponding to the target vessel's level is displayed on the target display page.

2. The method for displaying the ship's position according to claim 1, characterized in that, The acquisition of the target vessel's current location information includes: The first storage space of the target vessel is determined; wherein, the first storage space is a backend resource storage space; The current location information of the target vessel is determined in the first storage space; wherein the current location information includes the latitude and longitude information of the target vessel.

3. The method for displaying the ship's position according to claim 2, characterized in that, The step of generating a tile map of the target vessel based on the target vessel's target level and its current location information includes: Determine the target level of the target vessel; The latitude and longitude information is converted into coordinate point information in the target level; The pixel position of the target vessel in the target level is determined based on the latitude and longitude information; Based on the coordinate point information and the pixel position, a tile map of the target ship at the target level is generated.

4. The method for displaying the ship's position according to claim 3, characterized in that, The step of converting the latitude and longitude information into coordinate point information at the target level includes: Wherein, X represents the X-axis coordinate of the target vessel in the target level, Y represents the Y-axis coordinate of the target vessel in the target level, lon represents the longitude of the target vessel, φ represents the latitude of the target vessel, and zoomLevel represents the level information of the target level.

5. The method for displaying the ship's position according to claim 3, characterized in that, Determining the pixel position of the target vessel in the target layer based on the latitude and longitude information includes: The current longitude and current latitude of the target vessel are determined based on the latitude and longitude information. The pixel position of the target ship is determined based on the current longitude and latitude information.

6. The method for displaying the position of a ship according to claim 3, characterized in that, After generating the tile map of the target ship at the target level, the method further includes: Determine the second storage space of the target vessel; wherein, the second storage space is a front-end resource storage space; The historical map in the second storage space is updated based on the tile map, and the current map information of the target ship is obtained.

7. The method for displaying the position of a ship according to claim 6, characterized in that, The step of responding to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold, and displaying a tile map corresponding to the target vessel's level on the target display page, includes: In response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold, the current map information is displayed on the target display page.

8. A device for displaying the position of a ship, characterized in that, include: The location information acquisition module is configured to acquire the current location information of the target vessel; The tile map generation module is configured to generate a tile map of the target vessel based on the target level of the target vessel and the current location information. The tile map display module is configured to display a tile map corresponding to the target vessel's level on the target display page in response to determining that the display range of the target vessel on the target display page is less than or equal to a target threshold.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of the method for displaying the position of a ship as described in any one of claims 1 to 7.

10. A computer-readable storage medium storing computer instructions for causing a computer to perform the steps of the method for displaying the position of a ship as described in any one of claims 1 to 7.

Citation Information

Patent Citations

  • System and method for updating and displaying dynamic object mark position in real time

    CN102230968A

  • Hand-drawn map cutting presentation method and intelligent tour guide system

    CN112908146A

  • Marine large-data-volume ship target identification method

    CN118865744A