How to compress art resources in mobile games?

Source: Internet
Author: User
Keywords Mobile Internet share the Internet
Tags .mall animation development game games high how to internet

If only to compress the angle of the art resources, I know the means are as follows three kinds:

1, the use of the network to provide a common compression tool (low compression efficiency).

2, for the project development of specialized compression tools (can increase the compression ratio, but need to have a perennial study of various tools of the specialized beings).

3. Modify the suffix name of the art picture in the resource. The name of the art suffix is jpg, PNG, BMP and so on. At present, most of the game's picture resources are processed in PNG format, mainly because of small size, lossless compression and other advantages.

4. Convert audio format. Audio compression methods are MP3, WAV, OGG, WMA, RA and so on, which ogg the most provincial resources, but sometimes there will be no sound playback, especially when the sound playback time is too short. For comprehensive performance considerations (compression ratio, sound quality, hardware support, etc.) ogg>mp3>wav>wma.

We're looking for two points.

1 is the external performance to reduce the size of the installation package, reducing the user's resistance to download.

2 is internal performance to reduce memory use, improve game fluency, to prevent memory overload caused the game to crash.

What needs to be explained here is that actually compressing does not reduce the resources that are used in the program's stored runs. We all know the use of zip and other compression software principles. Similarly, when a program calls a resource that has been compressed, it needs to be unpacked and put into memory to run, and the compression tool does not really solve the underlying problem effectively. How to solve the root cause, I would like to put forward my opinion on the basis of the first reply:

1, as far as possible to reduce the art to the whole picture of the way to cut the map. Programmers know that when using art Chettu, the program uses unique tools to integrate resources into 1024x1024 images to facilitate program invocation of resources. The larger the picture, the greater the gap between the two pictures, plus the size of the picture itself, which is a waste of resources. At present, only in the game hall and other limited interface, in order to pursue the performance of the GUI to use the whole picture as a background.

2, re-use small pieces of resources (16x16 or 8x8), so that the program to the way the puzzle to show the art effect. Although this increases the workload of the program, but can save a lot of art resources. Of course, this is a way to choose. In addition, you can also allow the program to specifically design a set of tools (such as nine Sudoku) way to save code word time. In addition, the number of pictures has its limit, so the puzzle can not be too small.

3, in the performance of dynamic effects, try to use the way the program is implemented to avoid excessive use of art resources (such as frame animation, such as performance). You can refer to the use of particle effects.

Other ways to conserve resources are basically the same as Li's, and there are a few reminders.

1, scaling more for a single color of the picture resources, otherwise it will make the picture blurred, produce sawtooth.

2, other cycle, cutting, flip all need to implement the program, 10K the following resources need not use the effect, good steel used in the blade.

3, the skeleton animation in the special effects performance of the real section J Province resources, but to be clear, the skeleton itself is a huge resource demand.

4, when you must use frame animation, try not to exceed 8 frames, capacity not exceeding 1M. Otherwise, we propose to redesign the performance of special effects, as far as possible the best cost-effective way to design dynamic effects.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.