A method, device and electronic device for rendering intersection area
By obtaining road segment information and marker points to determine the vertices of the intersection area, the problem of consuming server resources when rendering the intersection area in existing technologies is solved, and efficient local rendering and interactive operations are achieved.
Patent Information
- Application Number
- CN202010349037.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-28
- Publication Date
- 2024-11-08
- Estimated Expiration
- 2040-04-28
AI Technical Summary
Existing map applications require servers to consume a large amount of computing and storage resources when rendering intersection areas, resulting in low efficiency.
By acquiring road segment information of related road segments and the marker points of the target intersection, the vertices of the intersection area are determined, and the intersection area is rendered on the map, reducing the dependence on servers and utilizing the local computing and storage resources of electronic devices.
It reduces the amount of data transmission between electronic devices and map servers, lowers computing and storage requirements, supports interactive operations with users, and enables various display styles for intersection areas.
Smart Images

Figure CN113568992B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer processing technology, and more specifically, to a method for rendering an intersection area, a device for rendering an intersection area, an electronic device, and a computer-readable storage medium. Background Art
[0002] With the development of technology, map applications provide more and more functions, for example, including the function of displaying intersections.
[0003] The existing method of rendering road sections and intersections in a map through a map application is usually that a server pre-calculates all road sections and intersections, generates corresponding tiles, and sends the tiles to a terminal device for rendering.
[0004] However, in the existing rendering method, generating tiles requires a large amount of computing resources and storage resources of the server. Summary of the invention
[0005] An object of the present invention is to provide a new technical solution for rendering intersection areas in a map.
[0006] According to a first aspect of the present invention, a method for rendering an intersection area is provided, comprising:
[0007] Acquire the road section information of the associated road section and the identification point of the target intersection; wherein the associated road section is the road section connected to the target intersection; the road section information includes the road width of the corresponding associated road section and the position information of the identification line used to indicate the corresponding associated road section;
[0008] Determine the vertex of the intersection area corresponding to the target intersection according to the road section information and the identification point;
[0009] The intersection area is rendered in a map according to the vertices.
[0010] Optionally, determining the vertex of the intersection area corresponding to the target intersection according to the road section information and the identification point includes:
[0011] Determining the edge of each of the associated road sections according to the road section information;
[0012] Determine the intersection of adjacent edges in each pair of adjacent associated road segments;
[0013] According to the intersection point and the identification point, the vertex of the intersection area corresponding to the target intersection is determined.
[0014] Optionally, determining the intersection of adjacent sidelines in each pair of adjacent associated road segments includes:
[0015] Obtaining the angle of each associated road segment relative to a specified direction;
[0016] Determining adjacent associated road sections according to the angle;
[0017] For each pair of adjacent associated road segments, the intersection of the adjacent edges is determined.
[0018] Optionally, obtaining the angle of each associated road segment relative to the specified direction includes:
[0019] Determine the starting point and the end point of each of the associated road sections;
[0020] According to the starting point and the end point of each associated road segment, the angle of the corresponding associated road segment relative to the specified direction is determined.
[0021] Optionally, determining the vertex of the intersection area corresponding to the target intersection according to the intersection point and the identification point includes:
[0022] Determine the distance between each of the intersection points and the identification point;
[0023] For each intersection point on the associated road section, determine a symmetrical point with respect to the identification line of the corresponding associated road section which is farther from the identification point;
[0024] All the intersection points and the symmetric points are regarded as the vertices.
[0025] Optionally, the acquiring the identification point of the target intersection includes:
[0026] According to the road section information, the intersection of the identification lines of all the associated road sections is determined as the identification point.
[0027] Optionally, also include:
[0028] Obtain the identification of the intersection connected to each road section in the preset area;
[0029] The associated road section is determined according to the identifier of the target intersection and the identifier of the intersection connected to each of the road sections in the preset area.
[0030] Optionally, rendering the intersection area of the target intersection in the map according to the vertex includes:
[0031] Determine the intersection area of the target intersection according to all the vertices;
[0032] The intersection area is rendered in the map.
[0033] Optionally, also include:
[0034] In response to a request to view the target intersection, an intersection area corresponding to the target intersection is highlighted.
[0035] Optionally, also include:
[0036] In response to a request to view the target intersection, a road segment associated with the target intersection is highlighted.
[0037] Optionally, also include:
[0038] In response to a request to view a target segment, segment information of the target segment is displayed.
[0039] According to a second aspect of the present invention, a method for rendering an intersection area is provided, comprising:
[0040] Acquire the road section information of the associated road section connected to the target intersection; wherein the road section information includes the road width of the corresponding associated road section and the position information of the marking line used to indicate the corresponding associated road section;
[0041] Determine, according to the road section information, the vertex of the intersection area corresponding to the target intersection;
[0042] The intersection area is rendered in the map according to the vertices.
[0043] Optionally, determining the vertex of the intersection area corresponding to the target intersection according to the road section information includes:
[0044] Determining the edge of each of the associated road sections according to the road section information;
[0045] Determine the intersection of adjacent edges in each pair of adjacent associated road segments;
[0046] The intersection point is used as the vertex of the intersection area.
[0047] According to a third aspect of the present invention, there is provided a rendering device for an intersection area, comprising:
[0048] An information acquisition module, used to acquire the road section information of the associated road section and the identification point of the target intersection; wherein the associated road section is a road section connected to the target intersection; the road section information includes the road width of the corresponding associated road section and the position information of the identification line used to indicate the corresponding associated road section;
[0049] A vertex determination module, used to determine the vertex of the intersection area corresponding to the target intersection according to the road section information and the identification point;
[0050] The intersection rendering module is used to render the intersection area in the map according to the vertices.
[0051] According to a fourth aspect of the present invention, an electronic device is provided, comprising a processor and a memory, wherein the memory is used to store an executable computer program, and the computer program is used to control the processor to execute the method according to the first aspect or the second aspect of the present invention.
[0052] According to a fifth aspect of the present invention, there is provided a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the method according to the first aspect or the second aspect of the present invention.
[0053] In an embodiment of the present invention, by obtaining the obtained section information of the associated section and the identification point of the target intersection, the vertices of the intersection area corresponding to the target intersection are determined, and the intersection area of the target intersection is rendered in the map according to all the vertices, without relying on additional computing and storage resources. Moreover, the electronic device obtains the section information of the associated section and the identification point of the target intersection from the map server, which can reduce the amount of data transmission between the electronic device and the map server. In addition, the electronic device renders the intersection area of the target intersection according to the vertices determined by itself, which can support interactive operations with the user, and can support multiple display styles of the intersection area.
[0054] Further features and advantages of the present invention will become apparent from the following detailed description of exemplary embodiments of the present invention with reference to the attached drawings. BRIEF DESCRIPTION OF THE DRAWINGS
[0055] The accompanying drawings, which are incorporated in and constitute a part of the specification, illustrate embodiments of the invention and, together with the description, serve to explain the principles of the invention.
[0056] Figure 1 is a block diagram of an example of a hardware configuration of an electronic device that can be used to implement an embodiment of the present invention.
[0057] Figure 2 is a block diagram of another example of a hardware configuration of an electronic device that can be used to implement an embodiment of the present invention;
[0058] Figure 3 is a schematic flow chart of a method for rendering an intersection area according to a first embodiment of the present invention;
[0059] Figure 4 is a schematic diagram of an intersection area according to a first embodiment of the present invention;
[0060] Figure 5 is a schematic flow chart of a method for rendering an intersection area according to a second embodiment of the present invention;
[0061] Figure 6 is a schematic diagram of an intersection area according to a second embodiment of the present invention;
[0062] Figure 7 is a schematic diagram of an application scenario of a method for rendering an intersection area according to an embodiment of the present invention;
[0063] Figure 8 is a principle block diagram of a rendering device for an intersection area according to an embodiment of the present invention;
[0064] Fig. 9 is a principle block diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0065] Various exemplary embodiments of the present invention will now be described in detail with reference to the accompanying drawings. It should be noted that the relative arrangement of components and steps, numerical expressions and numerical values set forth in these embodiments do not limit the scope of the present invention unless otherwise specifically stated.
[0066] The following description of at least one exemplary embodiment is merely illustrative in nature and is in no way intended to limit the invention, its application, or uses.
[0067] Technologies, methods, and equipment known to ordinary technicians in the relevant art may not be discussed in detail, but where appropriate, the technologies, methods, and equipment should be considered as part of the specification.
[0068] In all examples shown and discussed herein, any specific values should be interpreted as merely exemplary and not limiting. Therefore, other examples of the exemplary embodiments may have different values.
[0069] It should be noted that like reference numerals and letters refer to similar items in the following figures, and therefore, once an item is defined in one figure, it need not be further discussed in subsequent figures.
[0070] <Hardware Configuration>
[0071] Figure 1 and Figure 2 It is a block diagram of the hardware configuration of the electronic device 1000 that can be used to implement the method for rendering the intersection area according to any embodiment of the present invention.
[0072] In one embodiment, Figure 1 As shown, the electronic device 1000 may be a server 1100 .
[0073] Server 1100 provides a computer for processing, database, and communication facilities. Server 1100 can be a monolithic server or a distributed server across multiple computers or computer data centers. The server can be of various types, such as but not limited to, a network server, a news server, a mail server, a message server, an advertising server, a file server, an application server, an interactive server, a database server, or a proxy server. In some embodiments, each server may include hardware, software, or an embedded logic component or a combination of two or more such components for executing the appropriate functions supported or implemented by the server. For example, a server such as a blade server, a cloud server, etc., or a server group consisting of multiple servers, which may include one or more of the above-mentioned types of servers, etc.
[0074] In this embodiment, the server 1100 can be as follows Figure 1 As shown, it includes a processor 1110 , a memory 1120 , an interface device 1130 , a communication device 1140 , a display device 1150 , and an input device 1160 .
[0075] In this embodiment, the server 1100 may also include a speaker, a microphone, etc., which are not limited here.
[0076] The processor 1110 may be a dedicated server processor, or a desktop processor or a mobile processor that meets the performance requirements, which is not limited here. The memory 1120 includes, for example, ROM (read-only memory), RAM (random access memory), non-volatile memory such as a hard disk, etc. The interface device 1130 includes, for example, various bus interfaces, such as a serial bus interface (including a USB interface), a parallel bus interface, etc. The communication device 1140 is capable of wired or wireless communication, for example. The display device 1150 is, for example, a liquid crystal display, an LED display, a touch display, etc. The input device 1160 may include, for example, a touch screen, a keyboard, etc.
[0077] In this embodiment, the memory 1120 of the server 1100 is used to store instructions, which are used to control the processor 1110 to operate to at least perform the rendering method of the intersection area according to any embodiment of the present invention. A technician can design instructions according to the scheme disclosed in the present invention. How instructions control the processor to operate is well known in the art, so it will not be described in detail here.
[0078] Despite Figure 1 , multiple devices of the server 1100 are shown; however, the present invention may only involve some of the devices, for example, the server 1100 only involves the memory 1120 and the processor 1110 .
[0079] In one embodiment, the electronic device 1000 may be a terminal device 1200 such as a PC or a laptop computer used by an operator, which is not limited here.
[0080] In this embodiment, refer to Figure 2 As shown, the terminal device 1200 may include a processor 1210, a memory 1220, an interface device 1230, a communication device 1240, a display device 1250, an input device 1260, a speaker 1270, a microphone 1280, and the like.
[0081] The processor 1210 may be a mobile version processor. The memory 1220 may include, for example, a ROM (read-only memory), a RAM (random access memory), a non-volatile memory such as a hard disk, etc. The interface device 1230 may include, for example, a USB interface, a headphone interface, etc. The communication device 1240 may, for example, be capable of wired or wireless communication. The communication device 1240 may include a short-range communication device, for example, any device for short-range wireless communication based on short-range wireless communication protocols such as Hilink protocol, WiFi (IEEE 802.11 protocol), Mesh, Bluetooth, ZigBee, Thread, Z-Wave, NFC, UWB, LiFi, etc. The communication device 1240 may also include a remote communication device, for example, any device for WLAN, GPRS, 2G / 3G / 4G / 5G remote communication. The display device 1250 may, for example, be a liquid crystal display, a touch display, etc. The input device 1260 may include, for example, a touch screen, a keyboard, etc. The user may input / output voice information through the speaker 1270 and the microphone 1280.
[0082] In this embodiment, the memory 1220 of the terminal device 1200 is used to store instructions, and the instructions are used to control the processor 1210 to operate to at least perform the rendering method of the intersection area according to any embodiment of the present invention. A technician can design instructions according to the scheme disclosed in the present invention. How instructions control the processor to operate is well known in the art, so it will not be described in detail here.
[0083] Despite Figure 2 , multiple devices of the terminal device 1200 are shown, but the present invention may only involve some of the devices, for example, the terminal device 1200 only involves the memory 1220, the processor 1210, and the display device 1250.
[0084] <Method Example>
[0085] <First Embodiment>
[0086] In this embodiment, a method for rendering an intersection area is provided. The method may be implemented by an electronic device. The electronic device may be Figure 1The server 1100 shown, or Figure 2 Terminal device 1200 is shown.
[0087] The rendering method of the intersection area of the present embodiment can be specifically applied in a scene where the intersection area needs to be displayed, such as a map scene, a film and television scene, or a game scene.
[0088] according to Figure 3 As shown, the rendering method of the intersection area in this embodiment may include the following steps S3100 to S3300:
[0089] Step S3100, obtaining the section information of the associated section and the identification point of the target intersection.
[0090] The associated road section is a road section connected to the target intersection.
[0091] The road section information includes the road width of the corresponding associated road section and the position information of the marking line used to indicate the corresponding associated road section, wherein the marking line can be the center line or any side line of the corresponding associated road section.
[0092] The position information of the marking line may specifically be a position sequence consisting of the positions of multiple points (including at least the starting point and the end point) on the marking line, for example, it may be a longitude and latitude sequence consisting of the longitude and latitude coordinates representing the positions of multiple points on the marking line.
[0093] The identification point described in the embodiment of the present invention may be a latitude and longitude coordinate used to indicate the location of the identification point. The identification point may be, for example, the center point of the corresponding intersection.
[0094] The road section in the embodiment of the present invention may be a road between adjacent intersections.
[0095] In one embodiment of the present invention, the electronic device may obtain the road section information and identification points from a map server in response to a specified operation, or may obtain the road section information and identification points from a local cache in response to the specified operation.
[0096] In one embodiment of the present invention, the designated operation may be, for example, an operation of opening a designated map application. Then, when the user opens the designated map application through the electronic device, the electronic device may be triggered to obtain the section information of the associated section and the identification point of the target intersection.
[0097] In one embodiment of the present invention, the electronic device may also obtain the section information of the associated section from the local cache or the map server, and obtain the identification point of the target intersection according to the section information.
[0098] In the embodiment of obtaining the identification point according to the road section information, the specific method of obtaining the identification point may include:
[0099] According to the road section information, the intersection of the identification lines of all related road sections is determined as the identification point of the target intersection.
[0100] Specifically, the intersection of the identification lines of all the associated road sections may be determined according to the position information of the identification line representing each associated road section.
[0101] In one embodiment of the present invention, the method may further include a step of acquiring associated road sections, which may specifically include:
[0102] Obtain the identifier of the intersection connected to each road section in the preset area; determine the associated road section according to the identifier of the target intersection and the identifier of the intersection connected to each road section in the preset area.
[0103] In one embodiment of the present invention, the preset area may be an area pre-set according to an application scenario or specific requirements. For example, the preset area may be a city where the electronic device is located.
[0104] In this embodiment, each intersection has a unique identifier. Since a road section is a road between adjacent intersections, each road section is connected to two intersections, indicating that the road section is a road located between the two intersections.
[0105] Specifically, the road section including the identification of the target intersection in the identification of the connected intersection may be used as the associated road section.
[0106] For example, Figure 4 As shown, the intersections connected by section R1 are intersection I1 and intersection I2, the intersections connected by section R2 are intersection I1 and intersection I4, the intersections connected by section R3 are intersection I1 and intersection I5, the intersections connected by section R4 are intersection I1 and intersection I6, the intersections connected by section R5 are intersection I1 and intersection I7, the intersections connected by section R6 are intersection I8 and intersection I2, the intersections connected by section R7 are intersection I2 and intersection I3, and the intersections connected by section R8 are intersection I3 and intersection I4. In the case where the target section is intersection 1, the intersections connected by sections R1, R2, R3, R4 and R5 include intersection 1, so sections R1, R2, R3, R4 and R5 can be used as associated sections.
[0107] Step S3200, determining the vertices of the intersection area corresponding to the target intersection according to the road section information and the identification points.
[0108] The vertices in the embodiment of the present invention may be longitude and latitude coordinates used to indicate the locations of the corresponding vertices.
[0109] In one embodiment of the present invention, determining the vertices of the intersection area corresponding to the target intersection according to the road section information and the identification points may include the following steps S3210 to S3230:
[0110] Step S3210, determining the edge of each associated road section according to the road section information.
[0111] The edgeline in the embodiment of the present invention may be a position sequence consisting of position information of multiple points in the edgeline, and more specifically, may be a longitude and latitude sequence consisting of longitude and latitude coordinates representing the positions of multiple points (including at least the starting point and the end point) in the edgeline.
[0112] In one embodiment of the present invention, each road section includes two sidelines for indicating the boundary of the corresponding road section, and each sideline is parallel to the driving direction of the corresponding road section. The area between the two sidelines of each road section is the area where vehicles can travel in the corresponding road section.
[0113] Specifically, the sidelines of the corresponding associated road sections can be determined based on the road surface width and marking lines of each associated road section, wherein the vertical distance between the two sidelines of each associated road section is the road surface width of the corresponding associated road section, and the distances between the marking lines of each associated road section and the corresponding two sidelines are equal, both being half of the road surface width.
[0114] Step S3220, determining the intersection points of adjacent edge lines in each pair of adjacent associated road segments.
[0115] The intersection point in the embodiment of the present invention may be the longitude and latitude coordinates indicating the location of the intersection point.
[0116] In one embodiment of the present invention, determining the intersection of adjacent edge lines in each pair of adjacent associated road segments may include steps S3221 to S3223 as follows:
[0117] Step S3221, obtaining the angle of each associated road segment relative to the specified direction.
[0118] In one embodiment of the present invention, the specified direction may be a direction specified in advance according to an application scenario or specific requirements. For example, the specified direction may be the due north direction.
[0119] In one embodiment of the present invention, the angle of each associated road segment relative to the specified direction may be obtained from the server. For example, when obtaining the road segment information of the associated road segment, the angle of the associated road segment relative to the specified direction may also be obtained.
[0120] In another embodiment of the present invention, a method of obtaining the angle of each associated road segment relative to the specified direction may include:
[0121] Determine the starting point and the end point of each associated road segment; and determine the angle of the corresponding associated road segment relative to the specified direction according to the starting point and the end point of each associated road segment.
[0122] Specifically, the identification point of the target intersection may be used as the starting point of each associated road section, and the identification point of another intersection (except the target intersection) connected to each associated road section may be used as the end point of the corresponding associated road section.
[0123] In one embodiment of the present invention, the angle of the ray from the start point to the end point of each associated road segment relative to the specified direction may be used as the angle of the corresponding road segment relative to the specified direction.
[0124] In such Figure 4 In the illustrated embodiment, the designated direction may be the direction indicated by the arrow, and the angle of the associated road section 1 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 2 relative to the designated direction; the angle of the associated road section 2 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 4 relative to the designated direction; the angle of the associated road section 3 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 5 relative to the designated direction; the angle of the associated road section 4 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 6 relative to the designated direction; the angle of the associated road section 5 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 7 relative to the designated direction.
[0125] Step S3222: Determine adjacent associated road sections based on the angle.
[0126] In one embodiment of the present invention, the associated road sections may be sorted according to the angle, and the sorting value of each associated road section may be obtained. Specifically, the sorting may be in descending order or ascending order.
[0127] In this embodiment, two associated road sections corresponding to adjacent ranking values may also be adjacent. In addition, an associated road section with a maximum ranking value and an associated road section with a minimum ranking value may also be adjacent.
[0128] In such Figure 4 In the shown embodiment, if the associated road sections are sorted in ascending order according to the angle relative to the specified direction, then the sorting value corresponding to the associated road section 1 can be 1, the sorting value corresponding to the associated road section 2 can be 2, the sorting value corresponding to the associated road section 3 can be 3, the sorting value corresponding to the associated road section 4 can be 4, and the sorting value corresponding to the associated road section 5 can be 5.
[0129] In this embodiment, it can be determined that associated road section 1 is adjacent to associated road section 2, associated road section 2 is adjacent to associated road section 3, associated road section 3 is adjacent to associated road section 4, associated road section 4 is adjacent to associated road section 5, and associated road section 5 is adjacent to associated road section 1.
[0130] Step S3223: for each pair of adjacent associated road segments, determine the intersection of adjacent edge lines.
[0131] Specifically, for each associated road segment, a sideline with a smaller angle with the specified direction may be used as a first sideline, and a sideline with a larger angle with the specified direction may be used as a second sideline.
[0132] Then, for a pair of associated road segments with adjacent ranking values, the second sideline of the associated road segment with a smaller angle relative to the specified direction and the first sideline of the associated road segment with a larger angle relative to the specified direction are adjacent sidelines.
[0133] For a pair of associated road segments with the largest and smallest ranking values, a first edge line of the associated road segment with a smaller angle relative to the specified direction and a second edge line of the associated road segment with a larger angle relative to the specified direction are adjacent edges.
[0134] Each pair of adjacent boundary line intersection points can be obtained according to a longitude and latitude sequence consisting of longitude and latitude coordinates used to represent the locations of a plurality of points (including at least a starting point and an end point) on the boundary line.
[0135] In such Figure 4 In the illustrated embodiment, for adjacent associated road section 1 and associated road section 2, the second sideline L1-2 of associated road section 1 and the first sideline L2-1 of associated road section 2 are adjacent sidelines; for adjacent associated road section 2 and associated road section 3, the second sideline L2-2 of associated road section 2 and the first sideline L3-1 of associated road section 3 are adjacent sidelines; for adjacent associated road section 3 and associated road section 4, the second sideline L3-2 of associated road section 3 and the first sideline L4-1 of associated road section 4 are adjacent sidelines; for adjacent associated road section 4 and associated road section 5, the second sideline L4-2 of associated road section 4 and the first sideline L5-1 of associated road section 5 are adjacent sidelines; for adjacent associated road section 5 and associated road section 5, the second sideline L5-2 of associated road section 5 and the first sideline L1-1 of associated road section 1 are adjacent sidelines.
[0136] On the basis of this embodiment, it is possible to determine the intersection D1 of the second sideline L1-2 of the associated section 1 and the first sideline L2-1 of the associated section 2, the intersection D2 of the second sideline L2-2 of the associated section 2 and the first sideline L3-1 of the associated section 3, the intersection D3 of the second sideline L3-2 of the associated section 3 and the first sideline L4-1 of the associated section 4, the intersection D4 of the second sideline L4-2 of the associated section 4 and the first sideline L5-1 of the associated section 5, and the intersection D5 of the second sideline L5-2 of the associated section 5 and the first sideline L1-1 of the associated section 1.
[0137] Step S3230, determining the vertex of the intersection area corresponding to the target intersection according to the intersection point and the identification point.
[0138] In one embodiment of the present invention, the step of determining the vertex of the intersection area corresponding to the target intersection according to the intersection point and the identification point may include steps S3231 to S3233 as follows:
[0139] Step S3231, determine the distance between each intersection point and the identification point.
[0140] Specifically, the distance between each intersection point and the marking point may be determined based on the longitude and latitude coordinates used to indicate the location of each intersection point and the longitude and latitude coordinates used to indicate the location of the marking point.
[0141] Step S3232: for each intersection on the associated road segment, determine a symmetrical point that is farther from the identification point and is relative to the identification line of the corresponding associated road segment.
[0142] In one embodiment of the present invention, if the distances between two intersection points on one of the associated road sections and the identification point of the target intersection are equal, then the two intersection points can be symmetrical points relative to the identification line of the associated road section, and there is no need to perform the step of determining a symmetrical point relative to the identification line of the corresponding associated road section that is farther away from the identification point.
[0143] In such Figure 4 In the illustrated embodiment, for intersections D1 and D5 on the associated road section 1, a symmetric point D51 of intersection D5 having a greater distance from the identification point relative to the identification line of the associated road section 1 is determined; for intersections D1 and D2 on the associated road section 2, the distances between intersections D1 and D2 and the identification point are equal, and there is no need to determine a symmetric point of intersection D1 or D2 relative to the identification line of the associated road section 1; for intersections D2 and D3 on the associated road section 3, a symmetric point D21 of intersection D2 having a greater distance from the identification point relative to the identification line of the associated road section 1 is determined; for intersections D3 and D4 on the associated road section 4, a symmetric point D41 of intersection D4 having a greater distance from the identification point relative to the identification line of the associated road section 4 is determined; for intersections D4 and D5 on the associated road section 5, a symmetric point D42 of intersection D4 having a greater distance from the identification point relative to the identification line of the associated road section 5 is determined.
[0144] Step S3233, all intersection points and symmetric points are regarded as vertices.
[0145] In such Figure 4 In the illustrated embodiment, all intersection points D1 to D5 and symmetrical points D51 , D21 , D41 , and D42 may be used as vertices of the intersection area of the target intersection.
[0146] Step S3300, rendering the intersection area in the map according to all vertices.
[0147] In one embodiment of the present invention, rendering the intersection area of the target intersection in the map according to the vertices may include: determining the intersection area of the target intersection according to all the vertices; and rendering the intersection area in the map.
[0148] Specifically, an intersection area with the vertices obtained in step S3200 as vertices may be rendered in the map.
[0149] In such Figure 4 In the illustrated embodiment, the intersection area determined based on all vertices may be an area surrounded by a thick frame line.
[0150] In one embodiment of the present invention, the electronic device may render the intersection area of the target intersection onto a map according to all vertices through gas.
[0151] In one embodiment of the present invention, the electronic device may display according to a preset style, for example, may display the intersection area of the target intersection by a preset filling method.
[0152] In another embodiment of the present invention, the user may set or adjust the style of the intersection area through the electronic device, and the electronic device obtains the style of the intersection area specified by the user and renders the intersection area of the target intersection according to the style.
[0153] Furthermore, the electronic device may also display the intersection area of the corresponding intersection in the map according to a preset style of the intersection area of each intersection.
[0154] In one embodiment of the present invention, after rendering the intersection area on the map, the method further includes: in response to a request to view the target intersection, highlighting the intersection area corresponding to the target intersection. Specifically, the intersection areas corresponding to other intersections may be displayed on the map using a preset first color, and the intersection area corresponding to the target intersection may be displayed on the map using a preset second color.
[0155] Furthermore, in response to a request to view a target intersection, intersection information of the target intersection may also be displayed. The intersection information may include, for example, at least one of the following: an identification, latitude and longitude coordinates of the identification point, and a type.
[0156] In one embodiment of the present invention, the method may further include: in response to a request to view the target intersection, highlighting the associated road section of the target intersection. Specifically, the associated road section of the target intersection may be displayed in the map using a preset third color, and the road sections other than the associated road section may be displayed in the map using a preset second color.
[0157] In one embodiment of the present invention, the method may further include: in response to a request to view the target intersection, displaying the section information of the associated section. In this embodiment, the section information may further include at least one of the following: the road width of the corresponding section, the position information of the marking line used to indicate the corresponding section, the road type, the marking, and the connected intersection.
[0158] In an embodiment of the present invention, a user may click on a target intersection in a map through an electronic device to trigger a request to view the target intersection.
[0159] In one embodiment of the present invention, the method may further include: in response to a request to view the target road section, displaying the road section information of the target road section. In this embodiment, the target road section may be any road section displayed in the map, or any associated road section of the target intersection. In one example, the user may trigger a request to view the target road section by clicking on the target road section in the map through an electronic device.
[0160] In an embodiment of the present invention, by obtaining the obtained section information of the associated section and the identification point of the target intersection, the vertices of the intersection area corresponding to the target intersection are determined, and the intersection area of the target intersection is rendered in the map according to all the vertices, without relying on additional computing and storage resources. Moreover, the electronic device obtains the section information of the associated section and the identification point of the target intersection from the map server, which can reduce the amount of data transmission between the electronic device and the map server. In addition, the electronic device renders the intersection area of the target intersection according to the vertices determined by itself, which can support interactive operations with the user, and can support multiple display styles of the intersection area.
[0161] In one embodiment of the present invention, the vertices of the intersection area corresponding to the target intersection may be provided to the traffic simulation application so that the traffic simulation application can express the target intersection in a refined manner on the map.
[0162] <Second Embodiment>
[0163] In this embodiment, a method for rendering an intersection area is provided. The method may be implemented by an electronic device. The electronic device may be Figure 1 The server 1100 shown, or Figure 2 Terminal device 1200 is shown.
[0164] The rendering method of the intersection area of the present embodiment can be specifically applied in a scene where the intersection area needs to be displayed, such as a map scene, a film and television scene, or a game scene.
[0165] according to Figure 5 As shown, the rendering method of the intersection area in this embodiment may include the following steps S5100 to S5300:
[0166] Step S5100, obtaining the section information of the associated section connected to the target intersection.
[0167] The road section information includes the road width of the corresponding associated road section and the position information of the marking line used to indicate the corresponding associated road section. The marking line may be the center line or any side line of the corresponding associated road section.
[0168] The position information of the marking line may specifically be a position sequence consisting of the positions of multiple points (including at least the starting point and the end point) on the marking line, for example, it may be a longitude and latitude sequence consisting of the longitude and latitude coordinates representing the positions of multiple points on the marking line.
[0169] The road section in the embodiment of the present invention may be a road between adjacent intersections.
[0170] In one embodiment of the present invention, the electronic device may obtain the road section information from a map server in response to a specified operation, or may obtain the road section information from a local cache in response to the specified operation.
[0171] In one embodiment of the present invention, the designated operation may be, for example, an operation of opening a designated map application. Then, when the user opens the designated map application through the electronic device, the electronic device may be triggered to obtain the road segment information of the associated road segment.
[0172] In one embodiment of the present invention, the electronic device may also obtain the road segment information of the associated road segment from a local cache or a map server.
[0173] In one embodiment of the present invention, the method may further include a step of acquiring associated road sections, which may specifically include:
[0174] Obtain the identifier of the intersection connected to each road section in the preset area; determine the associated road section according to the identifier of the target intersection and the identifier of the intersection connected to each road section in the preset area.
[0175] In one embodiment of the present invention, the preset area may be an area pre-set according to an application scenario or specific requirements. For example, the preset area may be a city where the electronic device is located.
[0176] In this embodiment, each intersection has a unique identifier. Since a road section is a road between adjacent intersections, each road section is connected to two intersections, indicating that the road section is a road located between the two intersections.
[0177] Specifically, the road section including the identification of the target intersection in the identification of the connected intersection may be used as the associated road section.
[0178] Step S5200: Determine the vertices of the intersection area corresponding to the target intersection according to the road section information.
[0179] The vertices in the embodiment of the present invention may be longitude and latitude coordinates used to indicate the locations of the corresponding vertices.
[0180] In one embodiment of the present specification, determining the vertices of the intersection area corresponding to the target intersection according to the road section information may include steps S5210 to S5230 as follows:
[0181] Step S5210, determining the edge line of each associated road section according to the road section information.
[0182] The edgeline in the embodiment of the present invention may be a position sequence consisting of position information of multiple points in the edgeline, and more specifically, may be a longitude and latitude sequence consisting of longitude and latitude coordinates representing the positions of multiple points (including at least the starting point and the end point) in the edgeline.
[0183] In one embodiment of the present invention, each road section includes two sidelines for indicating the boundary of the corresponding road section, and each sideline is parallel to the driving direction of the corresponding road section. The area between the two sidelines of each road section is the area where vehicles can travel in the corresponding road section.
[0184] Specifically, the sidelines of the corresponding associated road sections can be determined based on the road surface width and marking lines of each associated road section, wherein the vertical distance between the two sidelines of each associated road section is the road surface width of the corresponding associated road section, and the distances between the marking lines of each associated road section and the corresponding two sidelines are equal, both being half of the road surface width.
[0185] Step S5220, determining the intersection points of adjacent edge lines in each pair of adjacent associated road segments.
[0186] The intersection point in the embodiment of the present invention may be the longitude and latitude coordinates indicating the location of the intersection point.
[0187] In one embodiment of the present invention, determining the intersection of adjacent edge lines in each pair of adjacent associated road segments may include steps S5221 to S5223 as follows:
[0188] Step S5221, obtaining the angle of each associated road segment relative to the specified direction.
[0189] In one embodiment of the present invention, the specified direction may be a direction specified in advance according to an application scenario or specific requirements. For example, the specified direction may be the due north direction.
[0190] In one embodiment of the present invention, the angle of each associated road segment relative to the specified direction may be obtained from the server. For example, when obtaining the road segment information of the associated road segment, the angle of the associated road segment relative to the specified direction may also be obtained.
[0191] In another embodiment of the present invention, a method of obtaining the angle of each associated road segment relative to the specified direction may include:
[0192] Determine the starting point and the end point of each associated road segment; and determine the angle of the corresponding associated road segment relative to the specified direction according to the starting point and the end point of each associated road segment.
[0193] Specifically, the identification point of the target intersection may be used as the starting point of each associated road section, and the identification point of another intersection (except the target intersection) connected to each associated road section may be used as the end point of the corresponding associated road section.
[0194] In one embodiment of the present invention, the angle of the ray from the start point to the end point of each associated road segment relative to the specified direction may be used as the angle of the corresponding road segment relative to the specified direction.
[0195] In such Figure 6 In the illustrated embodiment, the designated direction may be the direction indicated by the arrow, and the angle of the associated road section 1 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 2 relative to the designated direction; the angle of the associated road section 2 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 4 relative to the designated direction; the angle of the associated road section 3 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 5 relative to the designated direction; the angle of the associated road section 4 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 6 relative to the designated direction; the angle of the associated road section 5 relative to the designated direction may be the angle of the ray from intersection 1 to intersection 7 relative to the designated direction.
[0196] Step S5222: Determine adjacent associated road sections based on the angle.
[0197] In one embodiment of the present invention, the associated road sections may be sorted according to the angle, and the sorting value of each associated road section may be obtained. Specifically, the sorting may be in descending order or ascending order.
[0198] In this embodiment, two associated road sections corresponding to adjacent ranking values may also be adjacent. In addition, an associated road section with a maximum ranking value and an associated road section with a minimum ranking value may also be adjacent.
[0199] In such Figure 6In the shown embodiment, if the associated road sections are sorted in ascending order according to the angle relative to the specified direction, then the sorting value corresponding to the associated road section 1 can be 1, the sorting value corresponding to the associated road section 2 can be 2, the sorting value corresponding to the associated road section 3 can be 3, the sorting value corresponding to the associated road section 4 can be 4, and the sorting value corresponding to the associated road section 5 can be 5.
[0200] In this embodiment, it can be determined that associated road section 1 is adjacent to associated road section 2, associated road section 2 is adjacent to associated road section 3, associated road section 3 is adjacent to associated road section 4, associated road section 4 is adjacent to associated road section 5, and associated road section 5 is adjacent to associated road section 1.
[0201] Step S5223: for each pair of adjacent associated road segments, determine the intersection of adjacent edge lines.
[0202] Specifically, for each associated road segment, a sideline with a smaller angle with the specified direction may be used as a first sideline, and a sideline with a larger angle with the specified direction may be used as a second sideline.
[0203] Then, for a pair of associated road segments with adjacent ranking values, the second sideline of the associated road segment with a smaller angle relative to the specified direction and the first sideline of the associated road segment with a larger angle relative to the specified direction are adjacent sidelines.
[0204] For a pair of associated road segments with the largest and smallest ranking values, a first edge line of the associated road segment with a smaller angle relative to the specified direction and a second edge line of the associated road segment with a larger angle relative to the specified direction are adjacent edges.
[0205] Each pair of adjacent boundary line intersection points can be obtained according to a longitude and latitude sequence consisting of longitude and latitude coordinates used to represent the locations of a plurality of points (including at least a starting point and an end point) on the boundary line.
[0206] In such Figure 6 In the illustrated embodiment, for adjacent associated road section 1 and associated road section 2, the second sideline L1-2 of associated road section 1 and the first sideline L2-1 of associated road section 2 are adjacent sidelines; for adjacent associated road section 2 and associated road section 3, the second sideline L2-2 of associated road section 2 and the first sideline L3-1 of associated road section 3 are adjacent sidelines; for adjacent associated road section 3 and associated road section 4, the second sideline L3-2 of associated road section 3 and the first sideline L4-1 of associated road section 4 are adjacent sidelines; for adjacent associated road section 4 and associated road section 5, the second sideline L4-2 of associated road section 4 and the first sideline L5-1 of associated road section 5 are adjacent sidelines; for adjacent associated road section 5 and associated road section 5, the second sideline L5-2 of associated road section 5 and the first sideline L1-1 of associated road section 1 are adjacent sidelines.
[0207] On the basis of this embodiment, it is possible to determine the intersection D1 of the second sideline L1-2 of the associated section 1 and the first sideline L2-1 of the associated section 2, the intersection D2 of the second sideline L2-2 of the associated section 2 and the first sideline L3-1 of the associated section 3, the intersection D3 of the second sideline L3-2 of the associated section 3 and the first sideline L4-1 of the associated section 4, the intersection D4 of the second sideline L4-2 of the associated section 4 and the first sideline L5-1 of the associated section 5, and the intersection D5 of the second sideline L5-2 of the associated section 5 and the first sideline L1-1 of the associated section 1.
[0208] Step S5230: taking the intersection point as the vertex of the intersection area.
[0209] In such Figure 6 In the illustrated embodiment, all intersection points D1 - D5 may be used as vertices of the intersection area of the target intersection.
[0210] Step S5300: Render the intersection area in the map according to the vertex.
[0211] In one embodiment of the present invention, rendering the intersection area of the target intersection in the map according to the vertices may include: determining the intersection area of the target intersection according to all the vertices; and rendering the intersection area in the map.
[0212] Specifically, an intersection area with the vertices obtained in step S3200 as vertices may be rendered in the map.
[0213] In such Figure 6 In the illustrated embodiment, the intersection area determined based on all vertices may be an area surrounded by a thick frame line.
[0214] In one embodiment of the present invention, the electronic device may render the intersection area of the target intersection onto a map according to all vertices through gas.
[0215] In one embodiment of the present invention, the electronic device may display according to a preset style, for example, may display the intersection area of the target intersection by a preset filling method.
[0216] In another embodiment of the present invention, the user may set or adjust the style of the intersection area through the electronic device, and the electronic device obtains the style of the intersection area specified by the user and renders the intersection area of the target intersection according to the style.
[0217] Furthermore, the electronic device may also display the intersection area of the corresponding intersection in the map according to a preset style of the intersection area of each intersection.
[0218] In one embodiment of the present invention, after rendering the intersection area on the map, the method further includes: in response to a request to view the target intersection, highlighting the intersection area corresponding to the target intersection. Specifically, the intersection areas corresponding to other intersections may be displayed on the map using a preset first color, and the intersection area corresponding to the target intersection may be displayed on the map using a preset second color.
[0219] In one embodiment of the present invention, the method may further include: in response to a request to view the target intersection, highlighting the associated road section of the target intersection. Specifically, the associated road section of the target intersection may be displayed in the map using a preset third color, and the road sections other than the associated road section may be displayed in the map using a preset second color.
[0220] In one embodiment of the present invention, the method may further include: in response to a request to view the target intersection, displaying the section information of the associated section. In this embodiment, the section information may further include at least one of the following: the road width of the corresponding section, the position information of the marking line used to indicate the corresponding section, the road type, the marking, and the connected intersection.
[0221] In an embodiment of the present invention, a user may click on a target intersection in a map through an electronic device to trigger a request to view the target intersection.
[0222] In one embodiment of the present invention, the method may further include: in response to a request to view the target road section, displaying the road section information of the target road section. In this embodiment, the target road section may be any road section displayed in the map, or any associated road section of the target intersection. In one example, the user may trigger a request to view the target road section by clicking on the target road section in the map through an electronic device.
[0223] In an embodiment of the present invention, by acquiring the road section information of the associated road section, the vertices of the intersection area corresponding to the target intersection are determined, and the intersection area of the target intersection is rendered in the map according to all the vertices, without relying on additional computing and storage resources. Moreover, the electronic device obtains the road section information of the associated road section from the map server, which can reduce the amount of data transmission between the electronic device and the map server. In addition, the electronic device renders the intersection area of the target intersection according to the vertices determined by itself, which can support interactive operations with the user, and can support multiple display styles of the intersection area.
[0224] In one embodiment of the present invention, the vertices of the intersection area corresponding to the target intersection may be provided to the traffic simulation application so that the traffic simulation application can express the target intersection in a refined manner on the map.
[0225] <Application scenarios>
[0226] Figure 7It is a schematic diagram of an application scenario of the method for rendering an intersection area according to an embodiment of the present invention.
[0227] like Figure 7 As shown, the electronic device sends an information acquisition request to the server in response to the specified operation. The server returns the section information of the associated section and the identification point of the target intersection to the electronic device in response to the information acquisition request. The electronic device determines the vertices of the intersection area corresponding to the target intersection based on the received section information of the associated section and the identification point of the target intersection, and renders the intersection area corresponding to the target intersection in the map based on all the vertices.
[0228] <Device Example>
[0229] In this embodiment, a rendering device 6000 for an intersection area is provided. Figure 8 As shown, it includes an information acquisition module 6100, a vertex determination module 6200 and an intersection rendering module 6300. The information acquisition module 6100 is used to obtain the section information of the associated section and the identification point of the target intersection; wherein the associated section is the section connected to the target intersection; the section information includes the road width of the corresponding associated section and the position information of the identification line used to represent the corresponding associated section; the vertex determination module 6200 is used to determine the vertex of the intersection area corresponding to the target intersection according to the section information and the identification point; the intersection rendering module 6300 is used to render the intersection area in the map according to the vertex.
[0230] In one embodiment of the present invention, the vertex determination module 6200 may also be used to:
[0231] According to the road section information, determine the edge line of each associated road section;
[0232] Determine the intersection of adjacent edges in each pair of adjacent associated road segments;
[0233] According to the intersection points and the identification points, the vertices of the intersection area corresponding to the target intersection are determined.
[0234] In one embodiment of the present invention, determining the intersection of adjacent edge lines in each pair of adjacent associated road segments includes:
[0235] Get the angle of each associated road segment relative to the specified direction;
[0236] According to the included angle, adjacent related road sections are determined;
[0237] For each pair of adjacent associated road segments, the intersection of the adjacent edges is determined.
[0238] In one embodiment of the present invention, obtaining the angle of each associated road segment relative to the specified direction includes:
[0239] Determine the starting point and end point of each associated road segment;
[0240] According to the starting point and the end point of each associated road segment, the angle of the corresponding associated road segment relative to the specified direction is determined.
[0241] In one embodiment of the present invention, determining the vertex of the intersection area corresponding to the target intersection according to the intersection point and the identification point includes:
[0242] Determine the distance between each intersection point and the marked point;
[0243] For each intersection point on the associated road section, determine a symmetrical point that is farther from the identification point and is relative to the identification line of the corresponding associated road section;
[0244] All intersection points and symmetry points are regarded as vertices.
[0245] In one embodiment of the present invention, obtaining the identification point of the target intersection includes:
[0246] According to the road section information, the intersection of the identification lines of all related road sections is determined as the identification point.
[0247] In one embodiment of the present invention, the rendering device 6000 of the intersection area may further include:
[0248] A module for obtaining the identification of the intersections connected to each road section in a preset area;
[0249] A module for determining associated road sections according to the identification of a target intersection and the identification of the intersections connected to each road section in a preset area.
[0250] In one embodiment of the present invention, the intersection rendering module 6300 may also be used for:
[0251] Determine the intersection area of the target intersection based on all vertices;
[0252] Render intersection areas in the map.
[0253] In one embodiment of the present invention, the rendering device 6000 of the intersection area may further include:
[0254] A module for highlighting an intersection area corresponding to a target intersection in response to a request to view the target intersection.
[0255] In one embodiment of the present invention, the rendering device 6000 of the intersection area may further include:
[0256] A module for highlighting a road segment associated with a target intersection in response to a request to view the target intersection.
[0257] In one embodiment of the present invention, the rendering device 6000 of the intersection area may further include:
[0258] A module for displaying the segment information of a target segment in response to a request to view the target segment.
[0259] Those skilled in the art should understand that the rendering device 6000 of the intersection area can be implemented in various ways. For example, the rendering device 6000 of the intersection area can be implemented by configuring the processor with instructions. For example, the instructions can be stored in a ROM, and when the device is started, the instructions are read from the ROM into a programmable device to implement the rendering device 6000 of the intersection area. For example, the rendering device 6000 of the intersection area can be solidified into a dedicated device (such as an ASIC). The rendering device 6000 of the intersection area can be divided into independent units, or they can be combined together for implementation. The rendering device 6000 of the intersection area can be implemented by one of the various implementations described above, or can be implemented by a combination of two or more of the various implementations described above.
[0260] In this embodiment, the rendering device 6000 of the intersection area can have multiple implementation forms. For example, the rendering device 6000 of the intersection area can be a functional module running in any software product or application that provides rendering services, or it can be an external embedded component, plug-in, patch, etc. of these software products or applications, or it can also be these software products or applications themselves.
[0261] <Electronic equipment>
[0262] In this embodiment, an electronic device 1000 is also provided. The electronic device 1000 may be Figure 1 The server 1100 shown may also be Figure 2 The terminal device 1200 is shown.
[0263] like Fig. 9 As shown, the electronic device 1000 may further include a processor 1300 and a memory 1400, wherein the memory 1400 is used to store an executable computer program; the computer program is used to control the processor 1300 to execute the method for rendering an intersection area according to any embodiment of the present invention.
[0264] <Computer Readable Storage Medium>
[0265] In this embodiment, a computer-readable storage medium is further provided, on which a computer program is stored. When the computer program is executed by a processor, the method for rendering an intersection area according to any embodiment of the present invention is implemented.
[0266] The present invention may be a system, a method and / or a computer program product. The computer program product may include a computer-readable storage medium carrying computer-readable program instructions for causing a processor to implement various aspects of the present invention.
[0267] A computer-readable storage medium may be a tangible device that can hold and store instructions used by an instruction execution device. A computer-readable storage medium may be, for example, but not limited to, an electrical storage device, a magnetic storage device, an optical storage device, an electromagnetic storage device, a semiconductor storage device, or any suitable combination of the foregoing. More specific examples of computer-readable storage media (a non-exhaustive list) include: a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), a static random access memory (SRAM), a portable compact disk read-only memory (CD-ROM), a digital versatile disk (DVD), a memory stick, a floppy disk, a mechanical encoding device, such as a punch card or a raised structure in a groove on which instructions are stored, and any suitable combination of the foregoing. As used herein, a computer-readable storage medium is not to be interpreted as a transient signal per se, such as a radio wave or other freely propagating electromagnetic wave, an electromagnetic wave propagating through a waveguide or other transmission medium (e.g., a light pulse through a fiber optic cable), or an electrical signal transmitted through a wire.
[0268] The computer-readable program instructions described herein can be downloaded from a computer-readable storage medium to each computing / processing device, or downloaded to an external computer or external storage device via a network, such as the Internet, a local area network, a wide area network, and / or a wireless network. The network can include copper transmission cables, optical fiber transmissions, wireless transmissions, routers, firewalls, switches, gateway computers, and / or edge servers. The network adapter card or network interface in each computing / processing device receives the computer-readable program instructions from the network and forwards the computer-readable program instructions for storage in the computer-readable storage medium in each computing / processing device.
[0269] The computer program instructions for performing the operation of the present invention may be assembly instructions, instruction set architecture (ISA) instructions, machine instructions, machine-related instructions, microcode, firmware instructions, state setting data, or source code or object code written in any combination of one or more programming languages, including object-oriented programming languages, such as Smalltalk, C++, etc., and conventional procedural programming languages, such as "C" language or similar programming languages. Computer-readable program instructions may be executed entirely on a user's computer, partially on a user's computer, as an independent software package, partially on a user's computer, partially on a remote computer, or entirely on a remote computer or server. In the case of a remote computer, the remote computer may be connected to the user's computer via any type of network, including a local area network (LAN) or a wide area network (WAN), or may be connected to an external computer (e.g., using an Internet service provider to connect via the Internet). In some embodiments, an electronic circuit, such as a programmable logic circuit, a field programmable gate array (FPGA), or a programmable logic array (PLA), may be personalized by utilizing the state information of the computer-readable program instructions, and the electronic circuit may execute the computer-readable program instructions, thereby realizing various aspects of the present invention.
[0270] Various aspects of the present invention are described herein with reference to the flow charts and / or block diagrams of the methods, devices (systems) and computer program products according to embodiments of the present invention. It should be understood that each box of the flow chart and / or block diagram and the combination of each box in the flow chart and / or block diagram can be implemented by computer-readable program instructions.
[0271] These computer-readable program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, thereby producing a machine, so that when these instructions are executed by the processor of the computer or other programmable data processing device, a device that implements the functions / actions specified in one or more boxes in the flowchart and / or block diagram is generated. These computer-readable program instructions can also be stored in a computer-readable storage medium, and these instructions cause the computer, programmable data processing device, and / or other equipment to work in a specific manner, so that the computer-readable medium storing the instructions includes a manufactured product, which includes instructions for implementing various aspects of the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0272] Computer-readable program instructions may also be loaded onto a computer, other programmable data processing apparatus, or other device so that a series of operating steps are performed on the computer, other programmable data processing apparatus, or other device to produce a computer-implemented process, thereby causing the instructions executed on the computer, other programmable data processing apparatus, or other device to implement the functions / actions specified in one or more boxes in the flowchart and / or block diagram.
[0273] The flow charts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the systems, methods and computer program products according to multiple embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a part of a module, a program segment or an instruction, and a part of the module, a program segment or an instruction contains one or more executable instructions for realizing the specified logical function. In some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or flow chart, and the combination of the boxes in the block diagram and / or flow chart can be implemented by a dedicated hardware-based system that performs the specified function or action, or can be implemented by a combination of dedicated hardware and computer instructions. It is well known to those skilled in the art that it is equivalent to implement it by hardware, implement it by software, and implement it by combining software and hardware.
[0274] Embodiments of the present invention have been described above, and the above description is exemplary, not exhaustive, and is not limited to the disclosed embodiments. Many modifications and variations will be apparent to those of ordinary skill in the art without departing from the scope and spirit of the described embodiments. The selection of terms used herein is intended to best explain the principles of the embodiments, practical applications, or technical improvements in the marketplace, or to enable other persons of ordinary skill in the art to understand the embodiments disclosed herein. The scope of the present invention is defined by the appended claims.
Claims
1. A method for rendering an intersection area, comprising: Acquire the road section information of the associated road section and the identification point of the target intersection; wherein the associated road section is the road section connected to the target intersection; the road section information includes the road width of the corresponding associated road section and the position information of the identification line used to indicate the corresponding associated road section; the identification line is the center line or any side line of the corresponding associated road section, and the identification point is the intersection of the identification lines of all the associated road sections; Determine the vertices of the intersection area corresponding to the target intersection according to the road section information and the identification point; wherein the vertices include the intersection points of adjacent sidelines in each pair of adjacent associated road sections, and the symmetric point of an intersection point on each associated road section that is farther from the identification point relative to the identification line of the associated road section; The intersection area is rendered in a map according to the vertices.
2. According to the method of claim 1, the intersection of adjacent edge lines in each pair of adjacent associated road segments is determined by the following process: Obtaining the angle of each associated road segment relative to a specified direction; Determining adjacent associated road sections according to the angle; For each pair of adjacent associated road segments, the intersection of the adjacent edges is determined.
3. According to the method of claim 2, obtaining the angle of each associated road segment relative to the specified direction comprises: Determine the starting point and the end point of each of the associated road sections; According to the starting point and the end point of each associated road segment, the angle of the corresponding associated road segment relative to the specified direction is determined.
4. The method according to claim 1, further comprising: Obtain the identification of the intersection connected to each road section in the preset area; The associated road section is determined according to the identifier of the target intersection and the identifier of the intersection connected to each of the road sections in the preset area.
5. The method according to claim 1, wherein rendering the intersection area of the target intersection in the map according to the vertex comprises: Determine the intersection area of the target intersection according to all the vertices; The intersection area is rendered in the map.
6. The method according to claim 1, further comprising: In response to a request to view the target intersection, an intersection area corresponding to the target intersection is highlighted.
7. The method according to claim 1, further comprising: In response to a request to view the target intersection, a road segment associated with the target intersection is highlighted.
8. The method according to claim 1, further comprising: In response to a request to view a target segment, segment information of the target segment is displayed.
9. A rendering device for an intersection area, comprising: An information acquisition module, used to acquire the road section information of the associated road section and the identification point of the target intersection; wherein the associated road section is the road section connected to the target intersection; the road section information includes the road width of the corresponding associated road section and the position information of the identification line used to indicate the corresponding associated road section; the identification line is the center line or any side line of the corresponding associated road section, and the identification point is the intersection of the identification lines of all the associated road sections; A vertex determination module, used to determine the vertex of the intersection area corresponding to the target intersection according to the road section information and the identification point; wherein the vertex includes the intersection point of the adjacent edge lines in each pair of adjacent associated road sections, and the symmetric point of an intersection point on each associated road section that is farther from the identification point relative to the identification line of the associated road section; The intersection rendering module is used to render the intersection area in the map according to the vertex. 10 . An electronic device comprising a processor and a memory, wherein the memory is used to store an executable computer program, and the computer program is used to control the processor to execute the method according to any one of claims 1 to 8.
11. A computer-readable storage medium having a computer program stored thereon, wherein the computer program implements the method according to any one of claims 1 to 8 when executed by a processor.
