Log in or register to post comments

Textures with seperate U,V origins

June 11, 2012 - 6:52am #1

The polygon textures of my object (each face) have got seperate 0,0 (U,V coordinate) origins, would I be able to load and replace the teapot with this object? - That is would my object texture coordinates data be compactible?
Is there a limit to texture size that can be loaded? If so whats the size limit?

Many thanks

Re: Textures with seperate U,V origins

June 12, 2012 - 12:10am #6

http://stackoverflow.com/questions/9570062/samsung-galaxy-s2-opengl-es-2-0-problems

The SGS2 uses the ARM Mali400MP - the specs for which are here:

http://www.arm.com/products/multimedia/mali-graphics-hardware/mali-400-mp.php

and the OpenGL ES development guide for this is under the resources Tab.

Surprisingly it does not state how much texture memory there is, but maybe it might be hidden somewhere within the SGS2 specs?

It does say that it supports ETC compression, so what you wish to do may be possible...

Whether it is possible to merge all your textures depends on what you are using to model the 3D object. This is a popular strategy with many applications i.e. games because it keeps the texture within the cache - thus avoiding any state changes and increasing performance.

The other issue you may face is that say you only have 16Mb of texture memory how can you accommodate all 67Mb of textures. Compression and texture reduction will get you so far, but then you need a strategy optimise use of this.

HTH

N

Re: Textures with seperate U,V origins

June 11, 2012 - 1:55pm #5

Many Thanks N
I am using samsung galaxy sII which runs on android OS, do you know max for android phone? - I have 168 polygons each with 433 x 500 texture. each is roughly 400kb which adds to 67.2MB

Drawing each polygon as a seperate object might be a highly inefficient if there are very many polygons, is there a better option - is it possible to merge these textures so their coordinate system has one 0,0 origin?

Thanks

Re: Textures with seperate U,V origins

June 11, 2012 - 1:36pm #4

Hi aero_dyn

"Is there a limit to texture size that can be loaded? If so whats the size limit?"

That depends on the device. e.g. on ios on earlier devices maximum recommended texture size was 1024*1024 pixels and iPhone 4 + later is 2048*2048 to my knowledge. Which device are you using?

As for your other question, perhaps I have not properly understood? It sounds like each polygon has its own texture coordinates and therefore probably needs to be drawn independently, as though it were its own independent model.

In this case you are probably right in that it is most likely to be incompatible with the teapot example, because where you have a vertex that is shared between polygons it would need to be specified in the Vertex Array as many times as as it is shared - each pertaining to the UV coordinates in your question.

HTH

N

Re: Textures with seperate U,V origins

June 11, 2012 - 1:24pm #3

There are many posts on textures and i have checked lots of them they don't solve the query and problem i have. Neither has the above answer.

I am asking what if textures have seperate (0,0) U,V origins. From the data i observed it seems that no matter how many textures there is only one (0,0) origin, but i am not sure. And also I dont know maximum size that can be used without a crash.

If there are already answer to this question, please help by placing a link to it in your answer

thanks alot

Re: Textures with seperate U,V origins

June 11, 2012 - 11:11am #2

Hi aero_dyn

There are quite a few recent posts in this forum about replacing the teapot, together with some sample code. It's probably worth checking these out.

Essentially, whatever tool / utility you use to crank out the 3d model should also contain the UV coordinates.

N

Log in or register to post comments