What size can textures be?
2012-08-07 17:58
183 查看
转之:http://www.cocos2d-iphone.org/wiki/doku.php/faq
There are two cases to consider, non compressed textures and PVRTC compressed textures.
For non compressed textures the textures must have power of two dimensions less than or equal to 2048 in 3rd gen devices (or newer) and 1024 in older devices.
So 16×256 is okay, 512×512 is okay but 240×320 is not.
You can still use an image that does not follow these rules but beware that it will be stored in a texture with power of two dimensions. So loading a 240×320 image will result in a 256×512 texture being created.
On newer platforms (such as iPhone 3GS) a maximum texture size of 2048×2048 is supported. Note that the maximum texture size for the iPhone 3G and lower is 1024 x 1024.
For PVRTC compressed textures the texture must have power of two dimensions and must also be square e.g 4×4, 32×32, 256×256, 1024×1024. The image that is loaded into the compressed texture is in a special format that closely matches the format stored on the
GPU - consequently the image must also be a square with power of two dimensions. If you are using PVRTC compressed textures and your texture appears as solid white then one possible cause is that the image you are loading does not have square dimensions.
There are two cases to consider, non compressed textures and PVRTC compressed textures.
For non compressed textures the textures must have power of two dimensions less than or equal to 2048 in 3rd gen devices (or newer) and 1024 in older devices.
So 16×256 is okay, 512×512 is okay but 240×320 is not.
You can still use an image that does not follow these rules but beware that it will be stored in a texture with power of two dimensions. So loading a 240×320 image will result in a 256×512 texture being created.
On newer platforms (such as iPhone 3GS) a maximum texture size of 2048×2048 is supported. Note that the maximum texture size for the iPhone 3G and lower is 1024 x 1024.
For PVRTC compressed textures the texture must have power of two dimensions and must also be square e.g 4×4, 32×32, 256×256, 1024×1024. The image that is loaded into the compressed texture is in a special format that closely matches the format stored on the
GPU - consequently the image must also be a square with power of two dimensions. If you are using PVRTC compressed textures and your texture appears as solid white then one possible cause is that the image you are loading does not have square dimensions.
相关文章推荐
- It is said that wars in the 21st century will be fought over water. Do you agree? What do you think can be done now to alleviate
- 托福写作5-what is the most important characteristic that a person can have to be successful in life
- What Operating Systems can be imaged with FOG?
- Oracle 安装报SGA size can not be greater than maximum shared memory segment size(0)以及内核参数讲解
- C++ what operator can be overloaded?
- What is Viewstate? Can any object be stored in a Viewstate? (整理)
- What SurfaceFlinger is doing when Buffer of Layers can not be dequeued
- Win32 GDI - Practice (II) What can be called Closed Path?
- How Can the Packet Size Be Greater than the MTU?
- npm 报错 : npm ERR! Maximum call stack size exceeded npm ERR! A complete log of this run can be found
- what energy function can be minimized by graph cuts
- Oracle安装报错:SGA size can not be greater than maximum shared memeory segment size
- i cant see what would be like tomorrow
- What can I learn right now in just 10 minutes that could be useful for the rest of my life?
- Oracle 安装报SGA size can not be greater than maximum shared memory segment size(0)
- What you can change will be cheap ghd online
- What can I learn right now in just 10 minutes that could be useful for the rest of my life?
- Think about what can be improved, not what the problem is
- Unity3d报奇怪的错误CompareBaseObjectsInternal can only be called from the main thread.
- When and why vgs command can change metadata and incur old metadata to be backed up?