A method and system for downloading 3D game resources on demand

The on-demand downloading system for 3D game resources addresses the issue of large data volumes by packaging resources into update packages and generating dependency data, enabling efficient, minimal initial downloads and reducing broadband usage.

CN115048115BActive Publication Date: 2024-12-27GUIZHOU BOYI MUTUAL ENTERTAINMENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202210681764.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-06-15
Publication Date
2024-12-27
Estimated Expiration
2042-06-15

AI Technical Summary

Technical Problem

The large amount of game resource data required for 3D games necessitates a significant download time and broadband traffic consumption, deterring players and overburdening servers, especially during peak usage.

Method used

A method and system for on-demand downloading of 3D game resources, involving packaging resources into update packages and generating resource dependency and index data, allowing incremental downloads based on player position and game requirements.

Benefits of technology

Reduces the entry threshold for players by minimizing initial download requirements and conserves broadband traffic by only downloading necessary resources on demand.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115048115B_ABST
    Figure CN115048115B_ABST
Patent Text Reader

Abstract

The present invention provides a method and system for downloading 3D game resources on demand, which provides a data source that can be downloaded on demand for the client by packaging game resources into update packages in the form of update packages and generating resource dependency information and resource index data. By packaging resources that must be present when entering the game and other resources that can be downloaded when needed into different update packages, it is achieved that only the smallest installation package needs to be downloaded to enter the game when installing the game. By creating index information for resources and storing it in a database, it is possible to quickly locate whether the required resources need to be downloaded and the game packages and resource packages that need to be downloaded during the game. By downloading game resources as needed during the game, the problem of needing to download a large amount of resources before entering the game is solved, which greatly reduces the threshold for players to enter the game experience and also saves a large amount of broadband traffic.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the field of game technology applications, and in particular relates to a method and system for on-demand downloading of 3D game resources. Background Art

[0002] As the production level of 3D games continues to improve, the requirements for the quality of art resources and the complexity of game scenes are getting higher and higher. The more complex the game scene, the greater the demand for art resources; the higher the quality of art resources, the more model vertices and the larger the texture. To make a 3D game with excellent graphics, the amount of art resources can easily reach tens of GB or even hundreds of GB. Faced with such a huge amount of game resources, there are many disadvantages in the way that the entire game needs to be downloaded before the game player enters the game world. Although the download may be completed within an hour at the current network speed, many new players are reluctant to spend time downloading such a large amount of game data before experiencing the game; in addition, the more data the game player downloads, the higher the traffic cost required to operate the game. In order to solve the problem caused by the large amount of game resources, the game development team usually packages the game resources into independent resource packages according to the scene, and the basic data required to enter the game is packaged separately. When the player installs the game, as long as the basic data package has been downloaded, he can experience the game, and then while the player is experiencing the game, other game scene resources will continue to be downloaded in the background. However, there are many problems with this. First, if you are an old player, after downloading the basic game data, you must wait for all the resources required for the current scene to be downloaded before entering the non-novice map; the background download program will continue to download game resources until all the resources of the entire game are downloaded, which will eventually consume a lot of broadband traffic, especially in the early stage of the service, when there are many game players, which puts a lot of pressure on the download server. The present invention provides a method and system for on-demand downloading of 3D game resources to solve the problem that when the amount of game resource data is large, players need to consume a lot of broadband download traffic to enter the game experience. Summary of the invention

[0003] The technical problem solved by the present invention is that: when the amount of game resource data is large, players can enter the game world to experience the game without downloading a large amount of game resource data, and game resources of game functions that players have not experienced and game scenes that they have not entered will not be downloaded, thereby greatly reducing the threshold for game players to enter the game experience and saving a large amount of broadband download traffic. The specific solution is as follows:

[0004] A method for downloading 3D game resources on demand, comprising the following steps:

[0005] S1: Before entering the game, the resource update package production module packages the newly added or changed game resources into a resource update package, generates corresponding resource index update data and updates it to the local resource index database, and uploads the resource update package and source index update data to the CDN download server;

[0006] S2: After entering the game, the resource dependency generation module generates a list of resources that need to be loaded according to the player's position;

[0007] S3: The resource index management module traverses the resource list generated by the resource dependency generation module, and searches the resource index database for the corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated.

[0008] S4: After the resource download module downloads the game resources that do not exist in the local resource index database or are newly updated from the CDN server, the resource index database is updated;

[0009] S5: The resource loading module loads the game resources in the updated resource index database, renders them, and feeds back to the player's current position.

[0010] Furthermore, step S1 is specifically as follows:

[0011] First, the game resource update package production module packages the newly added or changed game resources in each game version offline into an encrypted binary data file, and then the game resource update package production module traverses all resources in the binary data file to generate a game resource update package containing a general table of all resource files; then it traverses all the generated game resource update packages and generates a resource file sub-table in the game resource update package; finally, data items that exist in the sub-table and whose resources have not changed are removed from the general table to obtain an update table for newly added or changed files, and the resource files listed in the update table are packaged into one or more resource packages as needed, and a corresponding resource list file is provided for each resource package, corresponding resource index update data is generated, and updated to the local resource index database; the resource update package and source index update data are uploaded to the CDN download server.

[0012] Furthermore, the resource list file includes the file name of the resource in the data packet and the starting position and size of the resource packet in which the resource is located.

[0013] Furthermore, step 2 is specifically as follows:

[0014] After entering the game, the resource dependency generation module obtains the model material data, mesh data, animation data in the game according to the player's position, and the material data depends on the texture data and shader program data, and generates a list of resources that need to be loaded currently.

[0015] Furthermore, step S3 is specifically as follows:

[0016] The resource index management module traverses the resource list generated by the resource dependency generation module and creates a resource update package. After creating the resource update package, the resource index management module will scan all resources in all resource packages in version order, and store the resource package and the starting position and size in the resource package in the index database with the index as the primary key; if there is no corresponding game resource update package, the required resources will be downloaded from the CDN server. If the game resource update package is expired, it will be downloaded from the CDN server and a new game resource update package will be generated.

[0017] Furthermore, if the resource index management module indexes an updated resource file, the index information of the new resource will be updated in the database. The database version number will be increased each time the resource index database is updated. Each time the game client is started, it will check whether the index database version matches the server. If they do not match, each version needs to be updated in turn, and the corresponding version updated data will be updated to the local resource index database.

[0018] Furthermore, step S4 is specifically as follows:

[0019] When the resource index management module finds that the local resource does not exist or has expired after querying the resource index database, it requests the CDN server to download the resource. The resource download module downloads the game resource that does not exist in the local resource database from the CDN server and caches it in the local resource database. After the resource is downloaded, a hash check is performed on it. If successful, the resource in the cache is moved to the local data packet and the index database is updated.

[0020] Furthermore, step S5 is specifically as follows:

[0021] The resource loading module adds the required resource index to the loading queue according to the resource index of the game object itself, and calls back the callback function after the related resource loading is completed. If the required resource does not exist locally, the resource download module is called to download the resource first. After the local resource is ready, the resource itself and its dependent resources are loaded in the background. Rendering begins after all the required resources are loaded, and feedback is given to the player's current position after rendering is completed.

[0022] The present invention provides a system for downloading 3D game resources on demand, including a resource update package production module, a resource dependency relationship generation module, a resource index management module, a resource download module and a resource loading module;

[0023] The resource update package production module is used to package the newly added or changed resources of the game into a resource update package, and generate corresponding resource index update data to update the local resource index database; and upload the resource update package and source index update data to the CDN download server;

[0024] The resource dependency generation module is used to generate a list of resources that currently need to be loaded according to the player's position;

[0025] The resource index management module is used to traverse the resource list generated by the resource dependency generation module, and search the resource index database for a corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated.

[0026] The resource download module is used to update the resource index database after downloading the game resources that do not exist in the local resource index database or are newly updated from the CDN server;

[0027] The resource loading module is used to load the game resources in the updated resource index database, render them, and feed them back to the player's current position.

[0028] The beneficial effects of the present invention are:

[0029] The method and system of the present invention are used to package game resources into update packages in the form of update packages and generate resource dependency information and resource index data to provide a data source that can be downloaded on demand for the client. The resource update package and resource index data are both incrementally downloaded to meet the minimum data download requirements. Each resource generates the required dependent resource relationship information to speed up the download and loading process of the resource. By packaging the resources that must be present when entering the game and other resources that can be downloaded when needed into different update packages, it is achieved that only the smallest installation package needs to be downloaded to enter the game when installing the game. By creating index information for the resources and storing it in a database, it is possible to quickly locate whether the required resources need to be downloaded and the game packages and resource packages that need to be downloaded during the game. By downloading game resources as needed during the game, the problem of needing to download a large amount of resources before entering the game is solved, which greatly reduces the threshold for players to enter the game experience and also saves a lot of broadband traffic. BRIEF DESCRIPTION OF THE DRAWINGS

[0030] Figure 1 The present invention is a flow chart of a method for on-demand downloading of 3D game resources. DETAILED DESCRIPTION

[0031] The technical solutions in the embodiments of the present invention will be described clearly and completely below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are only part of the embodiments of the present invention, rather than all the embodiments.

[0032] The present invention also provides a system for downloading 3D game resources on demand, including a resource update package production module, a resource dependency relationship generation module, a resource index management module, a resource download module and a resource loading module;

[0033] The resource update package production module is used to package the newly added or changed resources of the game into a resource update package, and generate the corresponding resource index update data to update the local resource index database; and upload the resource update package and source index update data to the CDN download server; the resource dependency generation module is used to generate a list of resources that need to be loaded according to the player's position;

[0034] The resource index management module is used to traverse the resource list generated by the resource dependency generation module, and search the resource index database for the corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated.

[0035] The resource download module is used to update the resource index database after downloading the game resources that do not exist or are updated in the local resource index database from the CDN server;

[0036] The resource loading module is used to load the game resources in the updated resource index database, render them, and feed them back to the player's current position.

[0037] like Figure 1 As shown, the present invention also provides a method for on-demand downloading of 3D game resources, comprising the following steps:

[0038] S1: Before entering the game, the resource update package production module packages the newly added or changed game resources into a resource update package, generates corresponding resource index update data and updates it to the local resource index database, and uploads the resource update package and source index update data to the CDN download server;

[0039] S2: After entering the game, the resource dependency generation module generates a list of resources that need to be loaded according to the player's position;

[0040] S3: The resource index management module traverses the resource list generated by the resource dependency generation module, and searches the resource index database for the corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated.

[0041] S4: After the resource download module downloads the game resources that do not exist in the local resource index database or are newly updated from the CDN server, the resource index database is updated;

[0042] S5: The resource loading module loads the game resources in the updated resource index database, renders them, and feeds back to the player's current position.

[0043] In the above, step S1 is specifically as follows:

[0044] First, the game resource update package production module packages the newly added or changed game resources in each game version offline into an encrypted binary data file, and then the game resource update package production module traverses all resources in the binary data file to generate a game resource update package containing a general table of all resource files; then it traverses all the generated game resource update packages and generates a resource file sub-table in the game resource update package; finally, data items that exist in the sub-table and whose resources have not changed are removed from the general table to obtain an update table for newly added or changed files, and the resource files listed in the update table are packaged into one or more resource packages as needed, and a corresponding resource list file is provided for each resource package, corresponding resource index update data is generated, and updated to the local resource index database; the resource update package and source index update data are uploaded to the CDN download server.

[0045] In the above, the resource list file contains the file name of the resource in the data package and the starting position and size of the resource package.

[0046] In the above, step 2 is specifically as follows:

[0047] After entering the game, the resource dependency generation module obtains the model material data, mesh data, animation data in the game according to the player's position, and the material data depends on the texture data and shader program data, and generates a list of resources that need to be loaded currently.

[0048] In the above, step S3 is specifically:

[0049] The resource index management module traverses the resource list generated by the resource dependency generation module and creates a resource update package. After creating the resource update package, the resource index management module will scan all resources in all resource packages in version order, and store the resource package and the starting position and size in the resource package in the index database with the index as the primary key; if there is no corresponding game resource update package, the required resources will be downloaded from the CDN server. If the game resource update package is expired, it will be downloaded from the CDN server and a new game resource update package will be generated.

[0050] In the above, if the resource index management module indexes an updated resource file, the index information of the new resource will be updated in the database. Each time the resource index database is updated, the database version number will be increased. Each time the game client is started, it checks whether the index database version matches the server. If they do not match, each version needs to be updated in turn, and the corresponding version updated data is updated to the local resource index database.

[0051] In the above, step S4 is specifically as follows:

[0052] When the resource index management module finds that the local resource does not exist or has expired after querying the resource index database, it requests the CDN server to download the resource. The resource download module downloads the game resource that does not exist in the local resource database from the CDN server and caches it in the local resource database. After the resource is downloaded, a hash check is performed on it. If successful, the resource in the cache is moved to the local data packet and the index database is updated.

[0053] In the above, step S5 is specifically as follows:

[0054] The resource loading module adds the required resource index to the loading queue according to the resource index of the game object itself, and calls back the callback function after the related resource loading is completed. If the required resource does not exist locally, the resource download module is called to download the resource first. After the local resource is ready, the resource itself and its dependent resources are loaded in the background. Rendering begins after all the required resources are loaded, and feedback is given to the player's current position after rendering is completed.

[0055] The method and system of the present invention are used to package game resources into update packages in the form of update packages and generate resource dependency information and resource index data to provide a data source that can be downloaded on demand for the client. The resource update package and resource index data are both incrementally downloaded to meet the minimum data download requirements. Each resource generates the required dependent resource relationship information to speed up the download and loading process of the resource. By packaging the resources that must be present when entering the game and other resources that can be downloaded when needed into different update packages, it is achieved that only the smallest installation package needs to be downloaded to enter the game when installing the game. By creating index information for the resources and storing it in a database, it is possible to quickly locate whether the required resources need to be downloaded and the game packages and resource packages that need to be downloaded during the game. By downloading game resources as needed during the game, the problem of needing to download a large amount of resources before entering the game is solved, which greatly reduces the threshold for players to enter the game experience and also saves a lot of broadband traffic.

[0056] It will be apparent to those skilled in the art that the invention is not limited to the details of the exemplary embodiments described above and that the invention can be implemented in other specific forms without departing from the spirit or essential features of the invention. Therefore, the embodiments should be considered exemplary and non-limiting in all respects, and the scope of the invention is defined by the appended claims rather than the foregoing description, and it is intended that all variations falling within the meaning and scope of the equivalent elements of the claims be included in the invention. Any reference numeral in a claim should not be considered as limiting the claim to which it relates.

Claims

1. A method for downloading 3D game resources on demand, characterized in that: The following steps are involved: S1: Before entering the game, the resource update package production module packages the newly added or changed game resources into a resource update package, generates corresponding resource index update data and updates it to the local resource index database, and uploads the resource update package and source index update data to the CDN download server; specifically: first, the game resource update package production module packages the newly added or changed game resources in each game version offline into an encrypted binary data file, and then the game resource update package production module traverses all resources in the binary data file to generate a game resource update package containing a general table of all resource files; then traverses all the generated game resource update packages, and generates a resource file sub-table in the game resource update package; finally, removes the data items that exist in the sub-table and whose resources have not changed from the general table, obtains the update table of the newly added or changed files, and packages the resource files listed in the update table into one or more resource packages as needed, and provides a corresponding resource list file for each resource package, generates corresponding resource index update data, and updates it to the local resource index database; uploads the resource update package and source index update data to the CDN download server; S2: After entering the game, the resource dependency generation module generates a list of resources that need to be loaded according to the player's position; S3: The resource index management module traverses the resource list generated by the resource dependency generation module, and searches the resource index database for the corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated. The resource index management module traverses the resource list generated by the resource dependency generation module and creates a resource update package. After creating the resource update package, the resource index management module will scan all resources in all resource packages in version order, and store the resource package and the starting position and size in the resource package into the index database with the index as the primary key; If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated; If the resource index management module indexes an updated resource file, it will update the database with the index information of the new resource. Each time the resource index database is updated, the database version number will be increased. Each time the game client is started, it will check whether the index database version matches the server version. If they do not match, each version needs to be updated in turn, and the corresponding version updated data will be updated to the local resource index database. S4: After the resource download module downloads the game resources that do not exist in the local resource index database or are newly updated from the CDN server, the resource index database is updated; S5: The resource loading module loads the game resources in the updated resource index database, renders them, and feeds back to the player's current position.

2. The method for on-demand downloading of 3D game resources according to claim 1, characterized in that: The resource list file includes the file name of the resource in the data packet and the starting position and size of the resource packet.

3. The method for on-demand downloading of 3D game resources according to claim 1, characterized in that: Step S2 is specifically as follows: After entering the game, the resource dependency generation module obtains the model material data, mesh data, animation data in the game according to the player's position, and the material data-dependent texture data and shader program data, and generates a list of resources that currently need to be loaded.

4. The method for downloading 3D game resources on demand according to claim 1, characterized in that: Step S4 is specifically as follows: When the resource index management module finds that the local resource does not exist or has expired after querying the resource index database, it requests the CDN server to download the resource. The resource download module downloads the game resource that does not exist in the local resource database from the CDN server and caches it in the local resource database. After the resource is downloaded, a hash check is performed on it. If successful, the resource in the cache is moved to the local data packet and the index database is updated.

5. The method for downloading 3D game resources on demand according to claim 1, characterized in that: Step S5 is specifically as follows: The resource loading module adds the required resource index to the loading queue according to the resource index of the game object itself, and calls back the callback function after the related resource loading is completed. If the required resource does not exist locally, the resource download module is called to download the resource first. After the local resource is ready, the resource itself and its dependent resources are loaded in the background. Rendering begins after all the required resources are loaded, and feedback is given to the player's current position after rendering is completed.

6. A system for executing the method for on-demand downloading of 3D game resources according to any one of claims 1 to 5, characterized in that: It includes a resource update package making module, a resource dependency relationship generating module, a resource index management module, a resource downloading module and a resource loading module; The resource update package making module is used to package the newly added or changed resources of the game into a resource update package, and generate corresponding resource index update data to update the local resource index database; And upload the resource update package and source index update data to the CDN download server; The resource dependency generation module is used to generate a list of resources that currently need to be loaded according to the player's position; The resource index management module is used to traverse the resource list generated by the resource dependency generation module, and search the resource index database for a corresponding game resource update package according to the generated resource list. If the corresponding game resource update package does not exist, the required resources are downloaded from the CDN server. If the game resource update package is expired, a new game resource update package is downloaded from the CDN server and generated. The resource download module is used to update the resource index database after downloading the game resources that do not exist or are newly updated in the local resource index database from the CDN server; The resource loading module is used to load the game resources in the updated resource index database, render them, and feed them back to the player's current position.