Map generation method, device, computer device and computer-readable storage medium
By generating three-dimensional plots in the game and splicing and adjustments, the problem of waste of manpower and material resources required to generate multiple maps for each level in the prior art is solved, and the effect of generating multiple maps under a small amount of resources is achieved, reducing costs and saving development cycles.
Patent Information
- Application Number
- CN202111583886.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-11-27
- Publication Date
- 2025-05-27
- Estimated Expiration
- 2040-11-27
AI Technical Summary
In the prior art, generating multiple maps for each level requires a lot of manpower and material resources, and a large number of maps lead to excessive volume of game installation packages, which increases the cost of generating maps and waste of storage resources.
When generating a map through detection requests, the starting three-dimensional plot is determined according to the set target generation style, and the starting extension channel query can be spliced three-dimensional plots, establish a connection relationship, splicing the three-dimensional plots and adjusting the parameters at the splicing to generate a target map.
There is no need to develop a large number of complete maps, and a modular processing solution is adopted to combine a large number of different maps under a small amount of three-dimensional plot resources to reduce the cost of map production, save development cycles, and avoid occupying a large amount of storage resources.
Smart Images

Figure CN114225405B_ABST
Abstract
Description
[0001] This application is a divisional application of the Chinese patent application submitted to the China Patent Office on November 27, 2020, with application number 202011362509.2 and application name "Map generation method, device, computer equipment and computer-readable storage medium". Technical Field
[0002] The present application relates to the field of game design technology, and in particular to a map generation method, device, computer equipment and computer-readable storage medium. Background Art
[0003] With the improvement of living standards, people's quality of life and living environment have undergone earth-shaking changes. Large-scale urban construction has brought high-quality enjoyment to people's lives, but also brought huge pressure. People are prone to anxiety, lack of concentration, and inability to complete work normally under stressful environments. Therefore, many games that can be used to relieve fatigue and entertain have emerged. In recent years, game design technology has developed rapidly, and scene-based games on the market have been favored by a large number of players. Most scene-based games are chase shots, which provide players with a more immersive gaming experience. The route and fun of the levels in the game are extremely important. Therefore, when developing games, game developers usually generate multiple different maps for each level, and randomly display maps when players experience the levels, so that the gameplay of the game increases and players can experience a different gaming experience.
[0004] In the related art, game developers usually generate multiple maps for each level in the game, bind the multiple maps corresponding to the level to the level, and carry the bound maps in the game installation package. When the player downloads the game, the map is also downloaded together, so that when the game is subsequently run, each time the player enters a level, a map will be randomly displayed.
[0005] In the process of implementing this application, the applicant found that the related technology has at least the following problems:
[0006] Generating multiple maps for each level requires a lot of manpower and resources, and a large number of maps will cause the game installation package to be too large, which not only makes the cost of generating maps too high, but also wastes a lot of storage resources. Summary of the invention
[0007] In view of this, the present application provides a map generation method, apparatus, computer device and computer-readable storage medium, the main purpose of which is to solve the problem that generating multiple maps for each level currently requires a lot of manpower and material resources, and a large number of maps will cause the game installation package to be too large, which not only leads to excessively high costs for generating maps, but also wastes a lot of storage resources.
[0008] According to a first aspect of the present application, a map generation method is provided, the method comprising:
[0009] When a request to generate a map is detected, a starting three-dimensional plot is determined according to the set target generation style;
[0010] Determine a selected starting extension channel on the starting three-dimensional plot, and query at least one connectable three-dimensional plot based on the starting extension channel, wherein the at least one connectable three-dimensional plot meets the target generation style and has a connectable extension channel matching the starting extension channel;
[0011] Establishing a connection relationship between the starting extension channel and the connectable extension channel, and splicing the starting three-dimensional plot with the at least one splicable three-dimensional plot;
[0012] Determine a joint generated by joining the starting three-dimensional land parcel and the at least one joinable three-dimensional land parcel, and count joint parameters of the joint, wherein the joint parameters include at least land parcel thickness difference and land parcel gap data;
[0013] The two three-dimensional plots to be adjusted at the joint are adjusted vertically according to the plot thickness difference, and the two three-dimensional plots to be adjusted are adjusted horizontally according to the plot gap data to generate a target map.
[0014] In another embodiment, the step of determining the starting three-dimensional land parcel according to the set target generation style includes:
[0015] Determine the target generation style set when requesting map generation, and obtain a plurality of preset three-dimensional plots corresponding to the target generation style;
[0016] Determining a selected preset three-dimensional land parcel among the plurality of preset three-dimensional land parcels;
[0017] The map attributes of the selected preset three-dimensional land parcel are set as the starting attributes, and the preset three-dimensional land parcel after setting is used as the starting three-dimensional land parcel.
[0018] In another embodiment, querying at least one connectable three-dimensional land parcel based on the starting extension channel includes:
[0019] Acquire at least one candidate preset three-dimensional land parcel from a plurality of preset three-dimensional land parcels corresponding to the target generation style, wherein the at least one candidate preset three-dimensional land parcel is a preset three-dimensional land parcel among the plurality of preset three-dimensional land parcels except the starting three-dimensional land parcel;
[0020] Determining the starting channel type of the starting extension channel;
[0021] For each candidate preset three-dimensional land parcel in the at least one candidate preset three-dimensional land parcel, querying a channel type corresponding to an extended channel included in the candidate preset three-dimensional land parcel;
[0022] When it is determined through the query that the candidate preset three-dimensional land parcel includes a connectable and extendable channel whose channel type is consistent with the type of the starting channel, the candidate preset three-dimensional land parcel is used as the connectable three-dimensional land parcel, and the query of the at least one candidate preset three-dimensional land parcel is continued until the query of the at least one candidate preset three-dimensional land parcel is completed, thereby obtaining the at least one connectable three-dimensional land parcel;
[0023] When the query determines that the candidate preset three-dimensional plot does not include a connectable extendable channel whose channel type is consistent with the starting channel type, the candidate preset three-dimensional plot is skipped, and the query of at least one candidate preset three-dimensional plot continues until the query of at least one candidate preset three-dimensional plot is completed to obtain the at least one splicable three-dimensional plot.
[0024] In another embodiment, the establishing a connection relationship between the starting extension channel and the connectable extension channel, and splicing the starting three-dimensional plot with the at least one splicable three-dimensional plot, includes:
[0025] Detecting a trigger operation, and determining a target spliceable three-dimensional plot selected by the trigger operation in the at least one spliceable three-dimensional plot;
[0026] Determine, in the target connectable three-dimensional land mass, a connectable extension channel whose channel type is consistent with the starting extension channel;
[0027] Moving the target connectable three-dimensional land parcel, connecting the connectable extension channel with the starting extension channel, and controlling the target connectable three-dimensional land parcel to be connected with the starting three-dimensional land parcel;
[0028] Continue to detect the next trigger operation and execute the splicing of the splicable three-dimensional land parcel selected by the next trigger operation until it is detected that the occurrence of the trigger operation sets the map attribute of the selected splicable three-dimensional land parcel to the termination attribute.
[0029] In another embodiment, after moving the target connectable three-dimensional land parcel, connecting the connectable extension channel with the starting extension channel, and controlling the target connectable three-dimensional land parcel to be connected with the starting three-dimensional land parcel, the method further includes:
[0030] Detecting whether there is an overlapping portion between the target splicable three-dimensional land block and the starting three-dimensional land block after splicing;
[0031] When an overlap is detected, a production failure reminder is generated and displayed;
[0032] When it is detected that there is no overlapping part, the next trigger operation is continuously detected, the stitching of the stitchable three-dimensional land blocks selected by the next trigger operation is performed, and after the stitching is completed, it is detected whether there is an overlapping part.
[0033] In another embodiment, the method further comprises:
[0034] Generate a map navigation grid of the target map, determine at least one module splicing point in the map navigation network, and activate and connect the at least one module splicing point, wherein the at least one module splicing point is generated by splicing three-dimensional plots;
[0035] Performing illumination processing on the map navigation grid, and adding illumination to the map navigation grid;
[0036] The added map navigation grid is displayed.
[0037] In another embodiment, the performing illumination processing on the map navigation grid and adding illumination to the map navigation grid includes:
[0038] For the at least one module joint in the map navigation network, performing illumination processing on the at least one module joint based on a point light mode to add illumination to the at least one module joint;
[0039] For the module center area in the map navigation grid, preset lighting information is obtained, and the module center area is rendered using the preset lighting information to increase lighting for the module center area. The module center area is the center area of the starting three-dimensional plot and the at least one splicable three-dimensional plot.
[0040] In another embodiment, the vertical adjustment of the two three-dimensional blocks to be adjusted at the joint according to the block thickness difference includes:
[0041] Determine a first three-dimensional plot to be adjusted and a second three-dimensional plot to be adjusted from the two three-dimensional plots to be adjusted, reduce the plot thickness of the first three-dimensional plot to be adjusted by using the plot thickness difference, and control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be in the same horizontal plane; or,
[0042] The thickness difference of the plot is used to increase the plot thickness of the second three-dimensional plot to be adjusted, so as to control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be on the same horizontal plane;
[0043] The plot thickness of the first three-dimensional plot to be adjusted is greater than the plot thickness of the second three-dimensional plot to be adjusted.
[0044] In another embodiment, the adjusting the two to-be-adjusted three-dimensional plots in a horizontal direction according to the plot gap data includes:
[0045] When the plot gap data indicates that there is a third 3D plot to be adjusted with a curved boundary in the two 3D plots to be adjusted, stretching the boundary of the third 3D plot to be adjusted, controlling the boundary of the third 3D plot to be adjusted to match the boundary of a fourth 3D plot to be adjusted, the fourth 3D plot to be adjusted being another 3D plot to be adjusted in the two 3D plots to be adjusted except the third 3D plot to be adjusted; and / or
[0046] Determine the gap distance indicated by the plot gap data, control the third three-dimensional plot to be adjusted to extend the length indicated by the gap distance to the fourth three-dimensional plot to be adjusted, or control the fourth three-dimensional plot to be adjusted to extend the length indicated by the gap distance to the third three-dimensional plot to be adjusted.
[0047] According to a second aspect of the present application, a map generating device is provided, the device comprising:
[0048] A determination module, for determining a starting three-dimensional plot according to a set target generation style when a request for map generation is detected;
[0049] A query module is used to determine a selected starting extension channel on the starting three-dimensional plot, and based on the starting extension channel, query at least one connectable three-dimensional plot, wherein the at least one connectable three-dimensional plot meets the target generation style and has a connectable extension channel matching the starting extension channel;
[0050] A splicing module, used to establish a connection relationship between the starting extension channel and the connectable extension channel, and splice the starting three-dimensional plot with the at least one connectable three-dimensional plot;
[0051] A statistics module is used to determine a joint generated by joining the starting three-dimensional land block and the at least one three-dimensional land block that can be joined, and to count the joint parameters of the joint, wherein the joint parameters at least include land block thickness difference and land block gap data;
[0052] The adjustment module is used to adjust the two three-dimensional plots to be adjusted at the joint in the vertical direction according to the plot thickness difference, and to adjust the two three-dimensional plots to be adjusted in the horizontal direction according to the plot gap data to generate a target map.
[0053] In another embodiment, the determining module includes:
[0054] An acquisition unit, configured to determine the target generation style set when requesting map generation, and acquire a plurality of preset three-dimensional plots corresponding to the target generation style;
[0055] a determination unit, configured to determine a selected preset three-dimensional land parcel from among the plurality of preset three-dimensional land parcels;
[0056] The setting unit is used to set the map attribute of the selected preset three-dimensional land parcel as the starting attribute, and use the set preset three-dimensional land parcel as the starting three-dimensional land parcel.
[0057] In another embodiment, the query module includes:
[0058] an acquisition unit, configured to acquire at least one candidate preset three-dimensional land parcel from a plurality of preset three-dimensional land parcels corresponding to the target generation style, wherein the at least one candidate preset three-dimensional land parcel is a preset three-dimensional land parcel among the plurality of preset three-dimensional land parcels except the starting three-dimensional land parcel;
[0059] A first determining unit, used to determine the starting channel type of the starting extension channel;
[0060] A query unit, configured to query, for each candidate preset three-dimensional land parcel in the at least one candidate preset three-dimensional land parcel, a channel type corresponding to an extended channel included in the candidate preset three-dimensional land parcel;
[0061] A second determining unit is configured to, when it is determined through query that the candidate preset three-dimensional land parcel includes a connectable and extendable channel whose channel type is consistent with the type of the starting channel, use the candidate preset three-dimensional land parcel as the connectable three-dimensional land parcel, and continue to query the at least one candidate preset three-dimensional land parcel until the query of the at least one candidate preset three-dimensional land parcel is completed, thereby obtaining the at least one connectable three-dimensional land parcel;
[0062] The query unit is further configured to skip the candidate preset three-dimensional plot when it is determined through the query that the candidate preset three-dimensional plot does not include a connectable extendable channel whose channel type is consistent with the starting channel type, and continue to query the at least one candidate preset three-dimensional plot until all of the at least one candidate preset three-dimensional plots are queried to obtain the at least one splicable three-dimensional plot.
[0063] In another embodiment, the splicing module includes:
[0064] A first detection unit is used to detect a trigger operation and determine a target spliceable three-dimensional plot selected by the trigger operation in the at least one spliceable three-dimensional plot;
[0065] A determination unit, configured to determine, in the target connectable three-dimensional land parcel, a connectable extension channel whose channel type is consistent with the starting extension channel;
[0066] A control unit, used for moving the target connectable three-dimensional land parcel, connecting the connectable extension channel with the starting extension channel, and controlling the target connectable three-dimensional land parcel to be connected with the starting three-dimensional land parcel;
[0067] The first detection unit is further configured to continue detecting a next trigger operation and executing the splicing of the splicable three-dimensional land parcel selected by the next trigger operation until it is detected that the occurrence of the trigger operation sets the map attribute of the selected splicable three-dimensional land parcel to the termination attribute.
[0068] In another embodiment, the splicing module further includes:
[0069] A second detection unit is used to detect whether there is an overlapping part between the target splicable three-dimensional land block and the starting three-dimensional land block after being spliced;
[0070] A generating unit, for generating and displaying a production failure reminder when an overlapping portion is detected;
[0071] The second detection unit is further configured to, when it is detected that there is no overlapping part, continue to detect the next trigger operation, execute the splicing of the splicable three-dimensional plots selected by the next trigger operation, and detect whether there is an overlapping part after the splicing is completed.
[0072] In another embodiment, the apparatus further comprises:
[0073] A generation module, used for generating a map navigation grid of the target map, determining at least one module joint in the map navigation network, activating and connecting the at least one module joint, wherein the at least one module joint is generated by the joint between three-dimensional plots;
[0074] A processing module, used for performing illumination processing on the map navigation grid and adding illumination to the map navigation grid;
[0075] The display module is used to display the increased map navigation grid.
[0076] In another embodiment, the processing module is used to perform lighting processing on the at least one module joint in the map navigation network based on the point light mode to add lighting to the at least one module joint; for the module center area in the map navigation grid, obtain preset lighting information, use the preset lighting information to render the module center area, and add lighting to the module center area, wherein the module center area is the center area of the starting three-dimensional plot and the at least one splicable three-dimensional plot.
[0077] In another embodiment, the adjustment module is used to determine a first three-dimensional plot to be adjusted and a second three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted, and use the plot thickness difference to reduce the plot thickness of the first three-dimensional plot to be adjusted, so as to control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be in the same horizontal plane; or, use the plot thickness difference to increase the plot thickness of the second three-dimensional plot to be adjusted, so as to control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be in the same horizontal plane; wherein the plot thickness of the first three-dimensional plot to be adjusted is greater than the plot thickness of the second three-dimensional plot to be adjusted.
[0078] In another embodiment, the adjustment module is used to stretch the boundary of the third three-dimensional plot to be adjusted, and control the boundary of the third three-dimensional plot to be adjusted to match the boundary of a fourth three-dimensional plot to be adjusted when the plot gap data indicates that there is a third three-dimensional plot to be adjusted with a curved boundary between the two three-dimensional plots to be adjusted, and the fourth three-dimensional plot to be adjusted is another three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted except the third three-dimensional plot to be adjusted; and / or determine the gap distance indicated by the plot gap data, control the third three-dimensional plot to be adjusted to extend to the fourth three-dimensional plot to be adjusted by the length indicated by the gap distance, or control the fourth three-dimensional plot to be adjusted to extend to the third three-dimensional plot to be adjusted by the length indicated by the gap distance.
[0079] According to a third aspect of the present application, a computer device is provided, including a memory and a processor, wherein the memory stores a computer program, and when the processor executes the computer program, the steps of the method described in the first aspect are implemented.
[0080] According to a fourth aspect of the present application, a computer-readable storage medium is provided, on which a computer program is stored. When the computer program is executed by a processor, the steps of the method described in the first aspect are implemented.
[0081] By means of the above technical scheme, the present application provides a map generation method, apparatus, computer equipment and computer-readable storage medium. When the present application detects a request to generate a map, it determines the starting three-dimensional plot according to the input target generation style, and selects the usable spliced three-dimensional plot according to the starting extension channel of the starting three-dimensional plot, connects the connectable extension channels of the same channel type of different spliced three-dimensional plots to realize the splicing of the three-dimensional plots, and adjusts the splicing points produced by the splicing to generate the target map. There is no need for developers to produce a large number of complete maps. By adopting a scheme of modularizing the maps, a large number of different maps can be combined with a small number of three-dimensional plot resources, thereby reducing the cost of map production, saving the development cycle, and avoiding occupying a large amount of storage resources.
[0082] The above description is only an overview of the technical solution of the present application. In order to more clearly understand the technical means of the present application, it can be implemented in accordance with the contents of the specification. In order to make the above and other purposes, features and advantages of the present application more obvious and easy to understand, the specific implementation methods of the present application are listed below. BRIEF DESCRIPTION OF THE DRAWINGS
[0083] Various other advantages and benefits will become apparent to those of ordinary skill in the art by reading the detailed description of the preferred embodiments below. The accompanying drawings are only for the purpose of illustrating the preferred embodiments and are not to be considered as limiting the present application. Also, the same reference symbols are used throughout the accompanying drawings to represent the same components. In the accompanying drawings:
[0084] Figure 1 A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0085] Figure 2A A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0086] Figure 2B A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0087] Figure 2C A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0088] Figure 2D A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0089] Figure 2E A schematic diagram of a map generation method provided in an embodiment of the present application is shown;
[0090] Figure 3A A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0091] Figure 3B A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0092] Figure 3C A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0093] Figure 3D A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0094] Figure 3E A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0095] Figure 3F A schematic diagram of the structure of a map generating device provided in an embodiment of the present application is shown;
[0096] Figure 4 A schematic diagram of the device structure of a computer device provided in an embodiment of the present application is shown. DETAILED DESCRIPTION
[0097] The exemplary embodiments of the present application will be described in more detail below with reference to the accompanying drawings. Although the exemplary embodiments of the present application are shown in the accompanying drawings, it should be understood that the present application can be implemented in various forms and should not be limited by the embodiments set forth herein. On the contrary, these embodiments are provided in order to enable a more thorough understanding of the present application and to fully convey the scope of the present application to those skilled in the art.
[0098] The present application embodiment provides a map generation method, such as Figure 1 As shown, the method includes:
[0099] 101. When a request to generate a map is detected, a starting three-dimensional plot is determined according to a set target generation style.
[0100] 102. Determine a selected starting extension channel on the starting three-dimensional plot, and based on the starting extension channel, query at least one connectable three-dimensional plot, wherein the at least one connectable three-dimensional plot meets the target generation style and has a connectable extension channel matching the starting extension channel.
[0101] 103. Establish a connection relationship between the starting extension channel and the connectable extension channel, and connect the starting three-dimensional plot with at least one connectable three-dimensional plot.
[0102] 104. Determine a joint resulting from the jointing of the starting three-dimensional land parcel and at least one three-dimensional land parcel that can be joined, and count joint parameters of the joint, where the joint parameters at least include land parcel thickness difference and land parcel gap data.
[0103] 105. Adjust the two three-dimensional plots to be adjusted at the joint in a vertical direction according to the plot thickness difference, and adjust the two three-dimensional plots to be adjusted in a horizontal direction according to the plot gap data to generate a target map.
[0104] The method provided in the embodiment of the present application, when a request for map generation is detected, determines the starting three-dimensional plot according to the input target generation style, selects the usable spliced three-dimensional plot according to the starting extension channel of the starting three-dimensional plot, connects the connectable extension channels of the same channel type of different spliced three-dimensional plots, realizes the splicing of the three-dimensional plots, and adjusts the splicing joints to generate the target map. There is no need for developers to produce a large number of complete maps. By adopting a solution of modularizing the maps, a large number of different maps can be combined with a small number of three-dimensional plot resources, thereby reducing the cost of map production, saving the development cycle, and avoiding occupying a large amount of storage resources.
[0105] The present application embodiment provides a map generation method, such as Figure 2A As shown, the method includes:
[0106] 201. When a request to generate a map is detected, a starting three-dimensional plot is determined according to a set target generation style.
[0107] In many games currently on the market, a large number of scene maps are often required as carriers for level gameplay in the levels of the same chapter. Maps are usually made by developers based on a certain set generation style to make multiple complete maps, reused, or the map of each level is selected in a purely random manner. The applicant recognizes that the multiple maps made to avoid the monotony of the level will lead to excessively high production costs for the level map, and a large amount of map data makes the size of the game installation package too large. Moreover, the use of a purely random method to select the map of each level is usually applied to 2D (2-Dimension, two-dimensional) games. Considering that 3D (3-Dimension, three-dimensional) games are mostly chase shots, more emphasis is placed on immersive game experience, and have a more complex environment. If a purely random method is used for 3D games, it will cause problems such as the 3D game field of view being blocked, the light source being difficult to control, and the game scene lacking aesthetics. In addition, for games running on mobile devices such as mobile phones and tablets, the route and fun of the level are extremely important parts, which need to be planned and designed in the production stage of the game, and it is impossible to plan and design using a purely random method, and it is difficult to generate a map with a clear route and strong fun. Therefore, the present invention proposes a map generation method, in which a plurality of incomplete preset three-dimensional plots of different generation styles are pre-set, and one or more connectable extension channels are set in each preset three-dimensional plot. When a request to generate a map is detected, the three-dimensional plots that can be used are selected according to the input generation style, and the connectable extension channels of the same channel type of different three-dimensional plots that can be spliced are connected according to the channel type, so as to realize the splicing of the three-dimensional plots that can be spliced and generate the map of the level. There is no need for developers to make a large number of completed maps. By adopting a solution of modularizing the map, a large number of different maps can be combined with a small number of three-dimensional plot resources, thereby reducing the cost of map production, saving the development cycle, avoiding the boredom caused by repeated maps, improving the novelty of the game, increasing the playability of the game, and being more suitable for games running on mobile devices.
[0108] In order to implement the technical solution of the present application, the developer can set some preset 3D plots in the development tool in advance, and set the preset 3D plots to different generation styles, namely Style. The styles of the preset 3D plots under the same Style are unified, and the modular map is used to ensure that the field of view, route, and layout in the same module are controllable and ideal. For example, see Figure 2B, under Style1, three preset three-dimensional plots can be included, namely ①, ② and ③. And under Style2, three preset three-dimensional plots can be included, namely ④, ⑤ and ⑥. When a request to generate a map is detected, the target generation style set when requesting to generate the map is obtained, and based on the target generation style, it is determined which preset three-dimensional plot is used as the starting three-dimensional plot. Among them, first, the target generation style set when requesting to generate a map is determined, and multiple preset three-dimensional plots corresponding to the target generation style are obtained. Because the style of map to be generated has been set when requesting to generate a map, the use of preset three-dimensional plots of other styles is inconsistent with the original intention of requesting to generate a map, so it is necessary to obtain multiple preset three-dimensional plots corresponding to the target generation style, and determine the selected preset three-dimensional plot among the multiple preset three-dimensional plots. Since the map generation process has not yet started, only one preset three-dimensional plot is selected, so the currently selected preset three-dimensional plot can be used as the starting point of splicing, the map attributes of the selected preset three-dimensional plot are set as the starting attributes, and the preset three-dimensional plot after setting is used as the starting three-dimensional plot.
[0109] It should be noted that the process of splicing preset three-dimensional plots to generate maps can be performed during the game production stage, so that developers do not need to prepare a large number of complete maps. Alternatively, it can also be performed during the game running process, so that the game installation package only needs to carry these preset three-dimensional plots to generate a large number of maps of different styles, which not only reduces the pressure on developers, but also reduces the size of the game installation package. This application does not specifically limit when to splice the preset three-dimensional plots.
[0110] 202. Determine a selected starting extension channel on the starting three-dimensional land parcel, and query at least one connectable three-dimensional land parcel based on the starting extension channel.
[0111] In the embodiment of the present application, each preset 3D plot is actually provided with one or more defined extension channels, and the channel type, that is, PathType, of each extension channel is different. Only two identical PathTypes are allowed to be spliced, thereby reducing the splicing sense of the generated target map. Figure 2BFor the three preset 3D plots under Style1, one extension channel is set in ①, and the PathType of the extension channel is PathTypeA; one extension channel is set in ②, and the PathType of the extension channel is PathTypeA; two extension channels are set in ③, and the PathType of the extension channels is PathTypeA. For the three preset 3D plots under Style2, three extension channels are set in ④, and the PathType of the extension channels is PathTypeA and PathTypeB respectively; two extension channels are set in ⑤, and the PathType of the extension channels is PathTypeA and PathTypeB respectively; two extension channels are set in ⑥, and the PathType of the extension channels is PathTypeA and PathTypeB respectively. Therefore, it is necessary to determine the selected extension channel as the starting extension channel on the determined starting 3D plot, start with the starting extension channel, and determine the next preset 3D plot that can be spliced according to the channel type of the starting extension channel, so as to splice the preset 3D plots and finally obtain the target map.
[0112] Since only two extended channels of the same channel type can be spliced, the preset three-dimensional plots that do not have an extended channel of the same channel type as the starting extended channel are not considered. Therefore, based on the starting extended channel, at least one splicable three-dimensional plot is queried, so that at least one splicable three-dimensional plot meets the target generation style and there is a connectable extended channel that matches the starting extended channel. Specifically, when searching for at least one splicable three-dimensional plot, first, at least one candidate preset three-dimensional plot is obtained from multiple preset three-dimensional plots corresponding to the target generation style. The at least one candidate preset three-dimensional plot is a preset three-dimensional plot other than the starting three-dimensional plot in the multiple preset three-dimensional plots. Subsequently, the starting channel type of the starting extended channel is determined, and for each candidate preset three-dimensional plot in the at least one candidate preset three-dimensional plot, the channel type corresponding to the extended channel included in the candidate preset three-dimensional plot is queried. On the one hand, when the query determines that the candidate preset three-dimensional land parcel includes a connectable and extendable channel whose channel type is consistent with the starting channel type, it means that the candidate preset three-dimensional land parcel can be spliced with the starting three-dimensional land parcel and can be used as an option for subsequent splicing. Therefore, the candidate preset three-dimensional land parcel is used as a splicable three-dimensional land parcel, and the query of at least one candidate preset three-dimensional land parcel is continued until at least one candidate preset three-dimensional land parcel is queried, and at least one splicable three-dimensional land parcel can be obtained. On the other hand, when the query determines that the candidate preset three-dimensional land parcel does not include a connectable and extendable channel whose channel type is consistent with the starting channel type, it means that the candidate preset three-dimensional land parcel cannot participate in the current map generation process, and the candidate preset three-dimensional land parcel can be skipped, and the query of at least one candidate preset three-dimensional land parcel is continued until at least one candidate preset three-dimensional land parcel is queried, and at least one splicable three-dimensional land parcel is obtained.
[0113] It should be noted that the above process of searching for at least one connectable three-dimensional land parcel can also be completed by a development tool. When the starting extension channel is selected, the development tool activates the starting extension channel and searches for at least one connectable three-dimensional land parcel that can be connected to the extension channel matching the starting extension channel and directly extracts it.
[0114] 203. Establish a connection relationship between the starting extension channel and the connectable extension channel, and connect the starting three-dimensional plot with at least one connectable three-dimensional plot.
[0115] In an embodiment of the present application, after at least one connectable three-dimensional plot is determined, a target connectable three-dimensional plot selected by a trigger operation is determined in at least one connectable three-dimensional plot according to a currently detected trigger operation, and the stitching process of the target connectable three-dimensional plot is started first, and the starting three-dimensional plot is magnetically spliced with the target connectable three-dimensional plot. When stitching, first determine in the target connectable three-dimensional plot a target connectable extension channel whose channel type is consistent with the starting extension channel. Subsequently, move the target connectable three-dimensional plot, connect the target connectable extension channel with the starting extension channel, and control the stitching of the target connectable three-dimensional plot with the starting three-dimensional plot, thereby completing the magnetic stitching of the starting three-dimensional plot with the target connectable three-dimensional plot. For example, see Figure 2C , the same channel type between the starting 3D plot and the target connectable 3D plot is PathTypeA, then the starting extension channel indicated by PathTypeA in the starting 3D plot is connected with the target connectable extension channel indicated by PathTypeA in the target connectable 3D plot, and the result is Figure 2C After that, the next trigger operation is detected and the stitching of the stitchable 3D land parcel selected by the next trigger operation is performed, that is, the stitching of the stitchable 3D land parcel selected thereafter is continued until the trigger operation is detected to set the map attribute of the selected stitchable 3D land parcel to the termination attribute.
[0116] In actual application, sometimes some preset three-dimensional plots may contain more than one connectable extension channel of the same channel type as the starting extension channel. At this time, the application supports rotating and replacing the preset three-dimensional plot, and the desired connectable extension channel can be selected for splicing.
[0117] In addition, in the present application, map attributes include "starting attributes" and "ending attributes". The preset three-dimensional plot whose map attribute is set to "starting attribute" is the starting three-dimensional plot, and the preset three-dimensional plot whose map attribute is set to "ending attribute" is the ending three-dimensional plot. When both map attributes are defined, it indicates that the splicing of the three-dimensional plots has been completed.
[0118] It should be noted that after the three-dimensional plots are spliced, there may be overlaps between the spliced three-dimensional plots. Figure 2D , Figure 2DThere is an overlap between the preset three-dimensional plot ① and the preset three-dimensional plot ②, and the overlapping part is the oblique line filling part. This situation does not meet the map production standard and cannot be applied to generate a map. Therefore, when the target splicing three-dimensional plot is spliced with the starting three-dimensional plot, it is necessary to detect whether there is an overlapping part after the target splicing three-dimensional plot is spliced with the starting three-dimensional plot. When it is detected that there is an overlapping part, a reminder of production failure is generated and displayed. When it is detected that there is no overlapping part, the next trigger operation is continued to be detected, and the splicing of the splicing three-dimensional plot selected by the next trigger operation is performed, and after the splicing is completed, it is detected whether there is an overlapping part. The above detection process is to complete the splicing of a three-dimensional plot and then perform a detection of whether it overlaps, which can avoid some subsequent splicing work from being invalid. In the actual application process, it is also possible to detect whether there is an overlapping part when the entire splicing process is completed. If there is an overlapping part, a reminder of production failure is generated and displayed. If there is no overlapping part, the splicing operation is terminated, thereby reducing the number of times the overlap is detected. This application does not specifically limit the timing of detecting whether an overlap occurs.
[0119] 204. Determine a joint resulting from the jointing of the starting three-dimensional land parcel and at least one three-dimensional land parcel that can be joined, and count joint parameters of the joint.
[0120] In the embodiment of the present application, since the three-dimensional plot is actually used to indicate the land and is three-dimensional, the three-dimensional plot has a three-dimensional boundary, and it is very likely that a gap or height difference will occur when the plots are spliced. Therefore, it is necessary to determine the splicing point generated by the splicing of the starting three-dimensional plot and at least one splicable three-dimensional plot, and to count the splicing parameters of the splicing point, and then adjust the spliced three-dimensional plots according to the splicing parameters, so that the splicing traces between the three-dimensional plots are difficult to detect, and ensure that the target map generated by the splicing is beautiful and natural. Among them, the splicing parameters include at least the plot thickness difference and the plot gap data. The plot thickness difference is used to indicate the height difference between the two three-dimensional plots, and can be used in the subsequent adjustment operation of the height of the three-dimensional plot to realize the disappearance operation of the plot and make the splicing point flat. The plot gap data is used to indicate how large the gap between the two three-dimensional plots is, and can be used to extend the three-dimensional plots in the future to realize the growth operation of the plots.
[0121] 205. Adjust the two three-dimensional plots to be adjusted at the joint in a vertical direction according to the plot thickness difference, and adjust the two three-dimensional plots to be adjusted in a horizontal direction according to the plot gap data to generate a target map.
[0122] In an embodiment of the present application, after the splicing parameters are determined, the two three-dimensional plots to be adjusted at the splicing location are adjusted according to the splicing parameters. Among them, the plot thickness difference in the splicing parameters can be used to adjust the two three-dimensional plots to be adjusted in the vertical direction. Specifically, the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted can be determined in the two three-dimensional plots to be adjusted, and the plot thickness of the first three-dimensional plot to be adjusted is greater than the plot thickness of the second three-dimensional plot to be adjusted. The plot thickness difference is used to reduce the plot thickness of the first three-dimensional plot to be adjusted, and the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted are controlled to be in the same horizontal plane. Alternatively, the plot thickness difference is used to increase the plot thickness of the second three-dimensional plot to be adjusted, and the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted are controlled to be in the same horizontal plane. This process is also the extinction operation of the three-dimensional plot.
[0123] The plot gap data in the splicing parameters can be used to adjust the two three-dimensional plots to be adjusted in the horizontal direction. Specifically, when the plot gap data indicates that there is a third three-dimensional plot to be adjusted with a curved boundary in the two three-dimensional plots to be adjusted, the boundary of the third three-dimensional plot to be adjusted is stretched to control the boundary of the third three-dimensional plot to be adjusted to match the boundary of the fourth three-dimensional plot to be adjusted. Among them, the fourth three-dimensional plot to be adjusted is another three-dimensional plot to be adjusted in the two three-dimensional plots to be adjusted except the third three-dimensional plot to be adjusted, that is, the three-dimensional plot is stretched to bend the boundary of the three-dimensional plot, so that the gap at the splicing disappears and the two three-dimensional plots fit together. This process is also the bending operation of the three-dimensional plot. Alternatively, the gap distance indicated by the plot gap data can be determined, and the third three-dimensional plot to be adjusted is controlled to extend the length indicated by the gap distance to the fourth three-dimensional plot to be adjusted, or the fourth three-dimensional plot to be adjusted is controlled to extend the length indicated by the gap distance to the third three-dimensional plot to be adjusted. That is, the growth of the three-dimensional plot is controlled so that the two three-dimensional plots are connected, the gap at the joint disappears, and the two three-dimensional plots fit together. This process is also the growth operation of the three-dimensional plot. In addition, in order to make the generated map closer to the real scene, a number of protruding growth points will be set on the upper and lower surfaces of the three-dimensional plot, and the shape curves of the growth points will be set in advance. When adjusting the three-dimensional plot, the growth points are controlled to grow protrudingly according to the set shape curves. This process also belongs to the growth operation of the three-dimensional plot. For example, a three-dimensional plot with a bridge can generate protruding ice cones or stones under the bridge through these growth points.
[0124] 206. Generate a map navigation grid of the target map, determine at least one module joint in the map navigation network, and activate and connect at least one module joint.
[0125] In the embodiment of the present application, since the target map currently generated is in the form of modular splicing, it is different from the art drawing walking surface method adopted by the traditional complete map. Therefore, it is necessary to dynamically generate the map navigation grid of the target map based on the program in the development tool, so that the walking path finding of the game character in the target map is smoother. Furthermore, the extension channel of each preset three-dimensional plot is closed by default and needs to be activated to allow the character to pass normally. Therefore, after the map navigation grid of the target map is generated, at least one module splicing is determined in the map navigation network, and at least one module splicing is activated and connected. Among them, at least one module splicing is generated by splicing between three-dimensional plots, that is, the connection between the extension channel and the extension channel. When activated, the properties of the extension channel are set to the activated state.
[0126] 207. Perform illumination processing on the map navigation grid, add illumination to the map navigation grid, and display the added map navigation grid.
[0127] In the embodiment of the present application, since the target map is generated by splicing, there are splicing points between modules. In order to make the splicing point seamless, the map navigation grid is illuminated by a combined light method, and lighting is added to the map navigation grid, and the added map navigation grid is displayed. Specifically, for at least one module splicing point in the map navigation network, at least one module splicing point is illuminated based on the point light mode, and lighting is added to at least one module splicing point. It should be noted that the specific parameters of the point light mode can be determined according to the channel type of the two extended channels at the module splicing point. For the central area of the module in the map navigation grid, the preset lighting information is obtained, and the central area of the module is rendered using the preset lighting information, and lighting is added to the central area of the module. The central area of the module is the central area of the starting three-dimensional plot and at least one splicable three-dimensional plot. Among them, in the development tool, the central area of the module can be directly processed using the baking processing solution of the development tool, so as to ensure the aesthetic effect of the scene of the map navigation grid.
[0128] In summary, the map generation method of this application is as follows:
[0129] See also Figure 2E, set the target generation style, select the starting 3D plot according to the target generation style, select the starting extension channel on the starting 3D plot, and splice in the direction indicated by the starting extension channel. Subsequently, display all splicable 3D plots including the same channel type as the starting extension channel, determine the selected splicable 3D plot, and splice the starting 3D plot with the splicable 3D plot. Detect whether overlap occurs, and if overlap occurs, remind. If no overlap occurs, continue the splicing operation of other selected splicable 3D plots until it is detected that the map attribute of a splicable 3D plot is set to the termination attribute. At this time, if no overlap occurs, adjust the splicing generated by the splicing to obtain the target map, generate the map navigation grid of the target map, and export the map data.
[0130] The method provided in the embodiment of the present application, when a request for map generation is detected, determines the starting three-dimensional plot according to the input target generation style, selects the usable spliced three-dimensional plot according to the starting extension channel of the starting three-dimensional plot, connects the connectable extension channels of the same channel type of different spliced three-dimensional plots, realizes the splicing of the three-dimensional plots, and adjusts the splicing joints to generate the target map. There is no need for developers to produce a large number of complete maps. By adopting a solution of modularizing the maps, a large number of different maps can be combined with a small number of three-dimensional plot resources, thereby reducing the cost of map production, saving the development cycle, and avoiding occupying a large amount of storage resources.
[0131] Further, as Figure 1 In a specific implementation of the method, the present application provides a map generation device, such as Figure 3A As shown, the device includes: a determination module 301, a query module 302 and a splicing module 303, a statistics module 304 and an adjustment module 305.
[0132] The determination module 301 is used to determine the starting three-dimensional land block according to the set target generation style when a request for map generation is detected;
[0133] The query module 302 is used to determine a selected starting extension channel on the starting three-dimensional plot, and based on the starting extension channel, query at least one connectable three-dimensional plot, wherein the at least one connectable three-dimensional plot meets the target generation style and has a connectable extension channel matching the starting extension channel;
[0134] The splicing module 303 is used to establish a connection relationship between the starting extension channel and the connectable extension channel, and to splice the starting three-dimensional plot with the at least one connectable three-dimensional plot;
[0135] The statistical module 304 is used to determine a joint generated by joining the starting three-dimensional land block and the at least one three-dimensional land block that can be joined, and to count the joint parameters of the joint, wherein the joint parameters at least include land block thickness difference and land block gap data;
[0136] The adjustment module 305 is used to adjust the two 3D plots to be adjusted at the joint in the vertical direction according to the plot thickness difference, and to adjust the two 3D plots to be adjusted in the horizontal direction according to the plot gap data to generate a target map.
[0137] In specific application scenarios, such as Figure 3B As shown, the determination module 301 includes: an acquisition unit 3011, a determination unit 3012 and a setting unit 3013.
[0138] The acquisition unit 3011 is used to determine the target generation style set when requesting map generation, and acquire multiple preset three-dimensional plots corresponding to the target generation style;
[0139] The determining unit 3012 is used to determine a selected preset three-dimensional plot from the plurality of preset three-dimensional plots;
[0140] The setting unit 3013 is used to set the map attributes of the selected preset three-dimensional land parcel as the starting attributes, and use the set preset three-dimensional land parcel as the starting three-dimensional land parcel.
[0141] In specific application scenarios, such as Figure 3C As shown, the query module 302 includes: an acquisition unit 3021, a first determination unit 3022, a query unit 3023 and a second determination unit 3024.
[0142] The acquisition unit 3021 is used to acquire at least one candidate preset three-dimensional land parcel from a plurality of preset three-dimensional land parcels corresponding to the target generation style, wherein the at least one candidate preset three-dimensional land parcel is a preset three-dimensional land parcel among the plurality of preset three-dimensional land parcels except the starting three-dimensional land parcel;
[0143] The first determining unit 3022 is used to determine the starting channel type of the starting extension channel;
[0144] The query unit 3023 is used to query, for each candidate preset three-dimensional land parcel in the at least one candidate preset three-dimensional land parcel, a channel type corresponding to an extended channel included in the candidate preset three-dimensional land parcel;
[0145] The second determining unit 3024 is configured to, when it is determined through query that the candidate preset three-dimensional land parcel includes a connectable and extendable channel whose channel type is consistent with the type of the starting channel, use the candidate preset three-dimensional land parcel as the connectable three-dimensional land parcel, and continue to query the at least one candidate preset three-dimensional land parcel until the query of the at least one candidate preset three-dimensional land parcel is completed, thereby obtaining the at least one connectable three-dimensional land parcel;
[0146] The query unit 3023 is also used to skip the candidate preset three-dimensional plot when the query determines that the candidate preset three-dimensional plot does not include a connectable and extendable channel whose channel type is consistent with the starting channel type, and continue to query the at least one candidate preset three-dimensional plot until the at least one candidate preset three-dimensional plot is queried and the at least one splicable three-dimensional plot is obtained.
[0147] In specific application scenarios, such as Figure 3D As shown, the splicing module 303 includes: a first detection unit 3031 , a determination unit 3032 and a control unit 3033 .
[0148] The first detection unit 3031 is used to detect a trigger operation and determine a target spliceable 3D plot selected by the trigger operation in the at least one spliceable 3D plot;
[0149] The determining unit 3032 is used to determine, in the target connectable three-dimensional land parcel, a connectable extension channel whose channel type is consistent with the starting extension channel;
[0150] The control unit 3033 is used to move the target connectable three-dimensional land parcel, connect the connectable extension channel with the starting extension channel, and control the target connectable three-dimensional land parcel to be connected with the starting three-dimensional land parcel;
[0151] The first detection unit 3031 is further configured to continue detecting a next trigger operation and executing the splicing of the splicable three-dimensional land parcel selected by the next trigger operation until it is detected that a trigger operation occurs to set the map attribute of the selected splicable three-dimensional land parcel to a termination attribute.
[0152] In specific application scenarios, such as Figure 3E As shown, the splicing module 303 further includes: a second detection unit 3034 and a generation unit 3035.
[0153] The second detection unit 3034 is used to detect whether there is an overlapping part between the target splicable three-dimensional land block and the starting three-dimensional land block after splicing;
[0154] The generating unit 3035 is used to generate and display a production failure reminder when an overlapping portion is detected;
[0155] The second detection unit 3034 is further configured to, when it is detected that no overlapping part exists, continue to detect the next trigger operation, execute the splicing of the splicable three-dimensional land blocks selected by the next trigger operation, and detect whether there is an overlapping part after the splicing is completed.
[0156] In specific application scenarios, such as Figure 3F As shown, the device also includes: a generating module 306 , a processing module 307 and a display module 308 .
[0157] The generating module 306 is used to generate a map navigation grid of the target map, determine at least one module splicing point in the map navigation network, and activate and connect the at least one module splicing point, wherein the at least one module splicing point is generated by splicing three-dimensional plots;
[0158] The processing module 307 is used to perform illumination processing on the map navigation grid and add illumination to the map navigation grid;
[0159] The display module 308 is used to display the added map navigation grid.
[0160] In a specific application scenario, the processing module 307 is used to perform illumination processing on the at least one module joint in the map navigation network based on the point light mode to add illumination to the at least one module joint; for the module center area in the map navigation grid, obtain preset illumination information, use the preset illumination information to render the module center area, and add illumination to the module center area, wherein the module center area is the center area of the starting three-dimensional plot and the at least one connectable three-dimensional plot.
[0161] In a specific application scenario, the adjustment module 305 is used to determine a first three-dimensional plot to be adjusted and a second three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted, and use the plot thickness difference to reduce the plot thickness of the first three-dimensional plot to be adjusted, and control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be in the same horizontal plane; or, use the plot thickness difference to increase the plot thickness of the second three-dimensional plot to be adjusted, and control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be in the same horizontal plane; wherein the plot thickness of the first three-dimensional plot to be adjusted is greater than the plot thickness of the second three-dimensional plot to be adjusted.
[0162] In a specific application scenario, the adjustment module 305 is used to stretch the boundary of the third three-dimensional plot to be adjusted, and control the boundary of the third three-dimensional plot to be adjusted to match the boundary of the fourth three-dimensional plot to be adjusted when the plot gap data indicates that there is a third three-dimensional plot to be adjusted with a curved boundary between the two three-dimensional plots to be adjusted, and the fourth three-dimensional plot to be adjusted is another three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted except the third three-dimensional plot to be adjusted; and / or determine the gap distance indicated by the plot gap data, control the third three-dimensional plot to be adjusted to extend to the fourth three-dimensional plot to be adjusted by the length indicated by the gap distance, or control the fourth three-dimensional plot to be adjusted to extend to the third three-dimensional plot to be adjusted by the length indicated by the gap distance.
[0163] The device provided in the embodiment of the present application, when detecting a request to generate a map, determines a starting three-dimensional plot according to an input target generation style, selects usable splicable three-dimensional plots according to a starting extension channel of the starting three-dimensional plot, connects connectable extension channels of the same channel type of different splicable three-dimensional plots, realizes the splicing of the three-dimensional plots, and adjusts the splicing joints produced by the splicing to generate a target map. There is no need for developers to produce a large number of complete maps. By adopting a solution of modularizing the maps, a large number of different maps can be combined with a small amount of three-dimensional plot resources, thereby reducing the cost of map production, saving the development cycle, and avoiding occupying a large amount of storage resources.
[0164] It should be noted that for other corresponding descriptions of the functional units involved in the map generation device provided in the embodiment of the present application, reference can be made to Figure 1 and Figure 2A The corresponding description in will not be repeated here.
[0165] In an exemplary embodiment, see Figure 4 , a device is also provided, the device 400 includes a communication bus, a processor, a memory and a communication interface, and may also include an input and output interface and a display device, wherein each functional unit can communicate with each other through the bus. The memory stores a computer program, and the processor is used to execute the program stored in the memory and execute the map generation method in the above embodiment.
[0166] A computer-readable storage medium stores a computer program, which implements the steps of the map generation method when executed by a processor.
[0167] Through the description of the above implementation methods, those skilled in the art can clearly understand that the present application can be implemented by hardware, or by means of software plus a necessary general hardware platform. Based on such an understanding, the technical solution of the present application can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a USB flash drive, a mobile hard disk, etc.), including a number of instructions for enabling a computer device (which can be a personal computer, a server, or a network device, etc.) to execute the methods described in each implementation scenario of the present application.
[0168] Those skilled in the art will appreciate that the accompanying drawings are merely schematic diagrams of a preferred implementation scenario, and the modules or processes in the accompanying drawings are not necessarily required for implementing the present application.
[0169] Those skilled in the art will appreciate that the modules in the device in the implementation scenario can be distributed in the device in the implementation scenario according to the implementation scenario description, or can be changed accordingly and located in one or more devices different from the implementation scenario. The modules in the above implementation scenario can be combined into one module, or can be further split into multiple sub-modules.
[0170] The above application serial numbers are for description only and do not represent the advantages or disadvantages of the implementation scenarios.
[0171] The above disclosure only discloses several specific implementation scenarios of the present application. However, the present application is not limited thereto, and any changes that can be conceived by technicians in this field should fall within the scope of protection of the present application.
Claims
1. A method for generating a map, characterized in that, comprising: when detecting a request to generate a map, determining a starting three-dimensional plot according to a set target generation style; determining a selected starting extension channel on the starting three-dimensional plot, and based on the starting extension channel, querying at least one spliceable three-dimensional plot, where the at least one spliceable three-dimensional plot conforms to the target generation style and there is a connectable extension channel matching the starting extension channel; establishing a connection relationship between the starting extension channel and the connectable extension channel, and splicing the starting three-dimensional plot and the at least one spliceable three-dimensional plot; determining a splicing location generated by splicing the starting three-dimensional plot and the at least one spliceable three-dimensional plot, and counting splicing parameters at the splicing location, where the splicing parameters at least include a plot thickness difference and plot gap data; adjusting the two three-dimensional plots to be adjusted in the vertical direction according to the plot thickness difference, and adjusting the two three-dimensional plots to be adjusted in the horizontal direction according to the plot gap data; determining at least one growth point on the two three-dimensional plots to be adjusted, and performing a growth operation on the two three-dimensional plots to be adjusted according to the contour curve of the at least one growth point to generate a target map.
2. The method according to claim 1, characterized in that, the querying at least one spliceable three-dimensional plot based on the starting extension channel includes: obtaining at least one candidate preset three-dimensional plot from a plurality of preset three-dimensional plots corresponding to the target generation style, where the at least one candidate preset three-dimensional plot is a preset three-dimensional plot other than the starting three-dimensional plot among the plurality of preset three-dimensional plots; determining the starting channel type of the starting extension channel; for each candidate preset three-dimensional plot among the at least one candidate preset three-dimensional plots, querying the channel type corresponding to the extension channel included in the candidate preset three-dimensional plot; when it is determined by querying that the candidate preset three-dimensional plot includes a connectable extension channel with a channel type consistent with the starting channel type, taking the candidate preset three-dimensional plot as the spliceable three-dimensional plot, and continuing to query the at least one candidate preset three-dimensional plot until all of the at least one candidate preset three-dimensional plots have been queried to obtain the at least one spliceable three-dimensional plot; when it is determined by querying that the candidate preset three-dimensional plot does not include a connectable extension channel with a channel type consistent with the starting channel type, skipping the candidate preset three-dimensional plot, and continuing to query the at least one candidate preset three-dimensional plot until all of the at least one candidate preset three-dimensional plots have been queried to obtain the at least one spliceable three-dimensional plot.
3. The method according to claim 1, characterized in that, the querying at least one spliceable three-dimensional plot based on the starting extension channel includes: activating the starting extension channel so that a development tool extracts the at least one spliceable three-dimensional plot having a connectable extension channel matching the activated starting extension channel.
4. The method according to claim 1, characterized in that, Establishing the connection relationship between the starting extension channel and the connectable extension channel, and splicing the starting three-dimensional plot and the at least one spliceable three-dimensional plot includes: Detecting a trigger operation, and determining a target spliceable three-dimensional plot selected by the trigger operation among the at least one spliceable three-dimensional plot; Determining a connectable extension channel in the target spliceable three-dimensional plot whose channel type is the same as that of the starting extension channel; Moving the target spliceable three-dimensional plot to connect the connectable extension channel with the starting extension channel, and controlling the splicing of the target spliceable three-dimensional plot and the starting three-dimensional plot; Continuing to detect the next trigger operation and performing the splicing of the spliceable three-dimensional plot selected by the next trigger operation until it is detected that the map attribute of the selected spliceable three-dimensional plot set by the occurring trigger operation is the termination attribute.
5. The method according to claim 4, wherein, the method further includes: Detecting whether there is an overlapping part after the target spliceable three-dimensional plot and the starting three-dimensional plot are spliced. When it is detected that there is an overlapping part, generating and displaying a production failure reminder, and when it is detected that there is no overlapping part, continuing to detect the next trigger operation, performing the splicing of the spliceable three-dimensional plot selected by the next trigger operation, and detecting whether there is an overlapping part after the splicing is completed; or, When it is detected that a request is made to rotate any one of the at least one spliceable three-dimensional plot, rotating and replacing the spliceable three-dimensional plot, and performing splicing based on the selected connectable extension channel in the rotated spliceable three-dimensional plot.
6. The method according to claim 1, wherein, the method further includes: Generating a map navigation grid of the target map, determining at least one module splicing location in the map navigation grid, and activating and connecting the at least one module splicing location, where the at least one module splicing location is generated by splicing between three-dimensional plots; For the at least one module splicing location in the map navigation network, performing lighting processing on the at least one module splicing location based on the point light mode to increase the lighting for the at least one module splicing location; For the module center area in the map navigation grid, obtaining preset lighting information, and rendering the module center area with the preset lighting information to increase the lighting for the module center area, where the module center area is the center area of the starting three-dimensional plot and the at least one spliceable three-dimensional plot; Displaying the map navigation grid with the increased lighting.
7. The method according to claim 1, wherein, the vertically adjusting the two to-be-adjusted three-dimensional plots that generate the splicing location according to the plot thickness difference includes: Determining a first to-be-adjusted three-dimensional plot and a second to-be-adjusted three-dimensional plot among the two to-be-adjusted three-dimensional plots, reducing the plot thickness of the first to-be-adjusted three-dimensional plot by using the plot thickness difference, and controlling the plot surfaces of the first to-be-adjusted three-dimensional plot and the second to-be-adjusted three-dimensional plot to be on the same horizontal plane; or, Increase the plot thickness of the second three-dimensional plot to be adjusted by using the plot thickness difference between the plots, and control the plot surfaces of the first three-dimensional plot to be adjusted and the second three-dimensional plot to be adjusted to be on the same horizontal plane; Among them, the plot thickness of the first three-dimensional plot to be adjusted is greater than the plot thickness of the second three-dimensional plot to be adjusted.
8. The method according to claim 1, characterized in that, The horizontal adjustment of the two three-dimensional plots to be adjusted according to the plot gap data includes: When the plot gap data indicates that there is a third three-dimensional plot to be adjusted with a curved boundary among the two three-dimensional plots to be adjusted, stretch the boundary of the third three-dimensional plot to be adjusted, and control the boundary of the third three-dimensional plot to be adjusted to match the boundary of the fourth three-dimensional plot to be adjusted, and the fourth three-dimensional plot to be adjusted is another three-dimensional plot to be adjusted except the third three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted; and / or, Determine the gap distance indicated by the plot gap data, and control the third three-dimensional plot to be adjusted to extend the length indicated by the gap distance towards the fourth three-dimensional plot to be adjusted or control the fourth three-dimensional plot to be adjusted to extend the length indicated by the gap distance towards the third three-dimensional plot to be adjusted.
9. The method according to claim 1, characterized in that, The step of determining at least one growth point on the two three-dimensional plots to be adjusted and performing a growth operation on the two three-dimensional plots to be adjusted according to the outer contour curve of the at least one growth point includes: For each three-dimensional plot to be adjusted among the two three-dimensional plots to be adjusted, determine at least one growth point on the three-dimensional plot to be adjusted, and the at least one growth point is set on the upper and lower surfaces of the three-dimensional plot to be adjusted and is pre-set with an outer contour curve; According to the outer contour curve of the at least one growth point, control the at least one growth point to make a protruding growth according to the set outer contour curve, and complete the growth operation performed on the three-dimensional plot to be adjusted.
10. A map generation device, characterized in that, comprising: A determination module, configured to determine a starting three-dimensional plot according to a set target generation style when a request to generate a map is detected; A query module, configured to determine a selected starting extension channel on the starting three-dimensional plot, and query at least one spliceable three-dimensional plot based on the starting extension channel, and the at least one spliceable three-dimensional plot conforms to the target generation style and has a connectable extension channel that matches the starting extension channel; A splicing module, configured to establish a connection relationship between the starting extension channel and the connectable extension channel, and splice the starting three-dimensional plot and the at least one spliceable three-dimensional plot; A statistics module, configured to determine the splicing location generated by splicing the starting three-dimensional plot and the at least one spliceable three-dimensional plot, and count the splicing parameters of the splicing location, and the splicing parameters at least include the plot thickness difference and the plot gap data; An adjustment module, configured to perform vertical adjustment on two to-be-adjusted three-dimensional plots generating the joint according to the thickness difference of the plots, and perform horizontal adjustment on the two to-be-adjusted three-dimensional plots according to the plot gap data; The adjustment module is further configured to determine at least one growth point on the two to-be-adjusted three-dimensional plots, and perform a growth operation on the two to-be-adjusted three-dimensional plots according to the contour curve of the at least one growth point to generate a target map.
11. A computer device, comprising a memory and a processor, the memory storing a computer program, wherein, when the processor executes the computer program, the steps of the method according to any one of claims 1 to 9 are implemented.
12. A computer-readable storage medium, having a computer program stored thereon, wherein, when the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 9 are implemented.
Citation Information
Patent Citations
Image blocking method and device, electronic equipment and storage medium
CN110389732A
Image splicing method and device and scanning system
CN110934603A