Why should texture size be less than power of 2?

Hi!
I just read in the packagerforiphone_devguide.pdf
Make bitmaps in sizes that are close to, but less than, 2^n by 2^m bits. The dimensions do not have to be power of 2,
but they should be close to a power of 2, without being larger. For example, a 31-by-15–pixel image renders faster
than a 33-by-17–pixel image. (31 and 15 are just less than powers of 2: 32 and 16.) Such images also use memory
more efficiently.
can someone explain me this? As Gamedeveloper i'm used to have power of 2 textures. why should they be smaller than power of 2 instead of exactly power of 2?

I have read that too, and it doesn't make sense. The article would have been a lot clearer if they had used 32x16 as the second example, instead of 33x17. Like you, I would almost expect advice that said to not exceed a power of 2, but it does't seem right to say that the exact power of 2 isn't recommended either.
Hey, I just found an earlier passage that pretty well states that we're right, on page 34:
"The GPU uses memory allocations that are powers of 2 for each dimension of the bitmap image. For example, the GPU can reserve memory in 512 x 1024 or 8 x 32 sizes. So a 9 x 15-pixel image takes up the same amount of memory as a 16 x 16-pixel image. For cached display objects, you may want to use dimensions that are close to powers of 2 (but not more) in each direction. For example, it is more efficient to use a 32 x 16-pixel display object than a 33 x 17-pixel display object."
So there you go, a 32x16 bitmap does use less memory than a 33x17 bitmap.
I think, or hope, that the later part was just making the point that you don't have to use exact powers of 2, but in doing so you want to not go over the power of 2. Hence using examples of 31x15 and 33x17. They didn't use 32x16 as an example because those are powers of 2, which wasn't what was being illustrated.

Similar Messages

  • Lines size to less than 0,29cm?

    It is possible to reduce the lines size to less than 0,29cm?

    I don't know what the minimum is in centimeters but 0,29 sounds pretty close.
    What is your goal? Why do you need/want it smaller?

  • Should Component Ids  be less than 7 characters?

    Hi,
    When I name the ids of various ADF Faces components more then 7 characters, the jdev compiler shoots out warning messages that component Ids should be less than 7 for optimal performance.
    Is this correct? What implications does it have if all the component Ids are less than 7 characters long?
    regards,
    Ansuman

    Simon is correct on all counts.
    The choice of 7 as the upper limit is fairly arbitrary. We were running into cases internally where ADF Faces users were choosing very long/descriptive (15-20 character) ids for naming containers. This ended up showing up during server-side profiling, and also resulted page content size bloat, especially for ids of root naming containers like page templates which appear everywhere. The audit rule was added to help clue folks in to the fact that there are consequences when choosing long ids.
    Personally, if I were designing a page, I would always choose very short (eg. 1-2 characters) ids for my naming containers (and relatively short ids for anything that is going to be stamped repeatedly).
    BTW, the audit rules are configurable. If you happen to be unhappy with a particular audit rule, you can disable it. See Preferences->Audit->Profiles->Rules->ADF Faces->Check for long ids on naming containers. And of course, you can also add your own audit rules to reflect your preferred coding standards.
    Andy

  • Why Does FIOS Quantum Offer Less than Comcast Xfinity?

    It is coming time for my FIOS contract to be renewed and I am having a hard time justifying renewing it.  FIOS Quantum was a huge disappointment for us because:
    1. The Remote control lag is terrible, even trying all the reboots etc. IR remotes have been around for ages, this should work, AND it's ridiculous to have to shutdown and reboot all the set top boxes to fix a memory leak at this stage of programming.
    2. Althoough the VMS1100 has eSATA ports, they are not enabled.  You cannot export shows to a computer or an external hard drive, both of which I could do with TiVo.
    3. ALthough FIOS has an app for my iPad, all I can do is "see" and set up recordings, I can't watch anything from my DVR on my iPad or a Windows PC, AND the FIOS app ONLY works when it's on the same WiFi Network as the DVR, it doesn't;t work over the Internet. 
    In theory at least Comcast Xfinity does all of the above.
    So my question is, why should I stick with FIOS?  I hve read the forums for months and there is no word from Verizon that they acknowledge these deficits to Xfinity, much less that they have any plans to address these shortfalls in the future.
    Without the hope that Verizon is addressing their shortcomings, maybe it is time to move on to what seems to be the better wide area connected service.

    I agree. They have stolen more of my life then that even.

  • Should I settle for less than what I am paying for...

    A couple of months ago I upgraded to BT Infinity 1 Unlimited. The package was for speed of between 25 mb to 35mb.
    As I was only getting on average 15 to 16 mb  on one occasion 12.8mb. I rang and BT who sent an engineer out. On checking the HD box the engineer made improvements at the box. and now sometimes I get between19mb to 21mb. The engineer said that as the box is 436 metres away from my house I would never be able to get even the lowest speed of 25 mbps.
    I have just run the BTW TEST which reads as follows
    Download speed 20.90
    MAX 22.9
    For your connection the acceptable range of speeds is 16.3mhps--22.9mhps.
    Upload speed during test 3.75mbps
    Upstream rate IP profile for your line is 10mbps.
    Do you think I should settle for less than what I am paying for.
    Solved!
    Go to Solution.

    Thanks for your reply,
    I have been with bt for over 40 years and have great service from them. I know a lot of other users have bigger problems.
    It was just that the advert on line said 25 to 35 mhps and I was hopeing that I would not have to keep watching the little circle going round and round before opening a page.
    I buy and sell racecards on ebay and most times bid on things in the last few seconds and slow turning of the pages does  not help.  , 

  • Why should i use JSF rather than Struts?

    What makes JSF useful than Struts? In my project I am using like
    <h:commandButton action="#{loginbean.execute}" actionListener="#{loginbean.handleEvent}" ..../>
    In the above commandButton as you can see that i am not exposing the beanName. However i am exposing the beanMethod which are execute and handleEvent. Is there any other way to hide the name of the method because
    From what i understand is Presentation Layer should be shielded from whatever is going on in the backend. So, this doesn't do good right?
    Please suggest.
    How does Component and Renderers help. I am using encodeEnd() method in Renderer to render what the input or the output should look like. Do we need to switch to JSF from Struts just because of this... I don't see how and why components and renderers could help me..

    srikanthradix wrote:
    What makes JSF useful than Struts? In my project I am using like
    <h:commandButton action="#{loginbean.execute}" actionListener="#{loginbean.handleEvent}" ..../>
    In the above commandButton as you can see that i am not exposing the beanName. However i am exposing the beanMethod which are execute and handleEvent. Is there any other way to hide the name of the method because
    From what i understand is Presentation Layer should be shielded from whatever is going on in the backend.You can use "binding" and define everything in Java code if you want. You can rename your method to reflect what you want to see in the front end if you want. You can use JSFTemplating to use handlers which can be mapped to any name you want to see and do not have to match the method name of the java class (although I suspect this is the opposite direction from what you are suggesting you want).
    EL in jsf (i.e. #{bean.login}) is meant to do the mapping in JSF pages rather than externalize this in a separate file and force the page developer to edit multiple files for simple tasks. Although in some cases navigation is broken out into a separate file (i.e. faces-config.xml file using the default NavigationHandler navigation rules), this can also be done inline. It's a different way of doing development and has its pros and cons (easier, but mixes up presentation and controller somewhat). That said... JSF is very flexible, it CAN externalize any of this information, it just requires you to provide a different ViewHandler information that allows you to enter the data the way you like to see it (imo, you won't realize any benefit from the separation, though -- I used to think it was worth doing but have changed my opinion).
    So, this doesn't do good right?Perhaps in theory... but in practice, I don't think it really has a drawback. One caveat, I like how I implemented event handling in JSFTemplating as opposed to action/actionListener attributes which are not configurable and are more opaque than I prefer. My parameterized handlers allow for better code-reuse, but arguably mix up presentation and controller code even more (depending on how they're used).
    Please suggest.
    How does Component and Renderers help. I am using encodeEnd() method in Renderer to render what the input or the output should look like. Do we need to switch to JSF from Struts just because of this... I don't see how and why components and renderers could help me..The idea of a component helps tremendously as someone else can create a component for you and you can benefit from it. There are many great component sets available on the market (for free and for purchase). For example: Woodstock (which has drag/drop support inside NetBeans), RichFaces, IceFaces, Tomahawk, Scales, etc.
    Renderers allow you to cleanly separate the presentation of a component with the data of the component. You can then switch out the presentation to support multiple markups (i.e. client devices). In addition, JSF's rich lifecycle provide logical places for certain types of operations to occur, the renderers participate in this so that they are performing their tasks at a well defined time. And finally, many different components may re-use the same renderer, or a single component may use one of several renderers. The separation of data and display (model and view) makes this very clean.
    JSF is not Struts. If you expect it to be struts, you may be disappointed (or if you expect struts to be JSF, you'll be disappointed). JSF has a lot to offer (as does struts), you have to decide what is important to you and your organization. Some things to consider wrt to JSF: very strong vendor support; many large set of components to choose from; multiple standards-based tools to choose from; very flexible (most parts of the framework are pluggable); active growing development community; component-based model which encapsulates complexity for things like Ajax, pagination, and other things (often complicated in a non-component architecture); good integration with other frameworks.
    I don't know if this makes your decision any easier, but hopefully it helps clarify how you should be viewing JSF & Struts.
    Good luck!
    Ken Paulsen
    https://jsftemplating.dev.java.net

  • Why is the render quality less than the source files

    I am setting render quality at Best, Full 1920 x 1080.   The movie quality in either a quick time or windows media player file is terrible.  These same files export at good quality at school with the same settings.  Why am I getting poor image quality on my PC at home?

    The first image is a screen shot of the original footage taken in AE.  The second image is the exported qucktime.  The quick time is at half size and the AE is 50%.  The source files are a qucktime output of a frame by frame animation I created in AE.  I have tried rendering both interlaced and progressive.  My instructor had me drop the source files onto the "Create a new composition" icon  at the bottom of the project window so AE would interpret the sourcefiles correctly to be exported back to Final Cut Pro. The format options are set to no compression.  I don't know how to tell what codec I am rendering to.
    My instructor isn't any help since I am working on a PC.  He only knows Mac.

  • Archived redo log size more less than online redo logs

    Hi,
    My database size around 27 GB and redo logs sizes are 50M. But archive log size 11M or 13M, and logs are switching every 5-10min. Why?
    Regards
    Azer Imamaliyev

    Azer_OCA11g wrote:
    1) Almost all archive logs sizes are 11 or 13M.. But sometimes 30, 37M.
    2)
    select to_char(completion_time, 'dd.mm.yyyy HH24:MI:SS')
    from v$archived_log
    order by completion_time desc;
    10.02.2012 11:00:26
    10.02.2012 10:50:23
    10.02.2012 10:40:05
    10.02.2012 10:29:34
    10.02.2012 10:28:26
    10.02.2012 10:18:07
    10.02.2012 10:05:04
    10.02.2012 09:55:03
    10.02.2012 09:40:54
    10.02.2012 09:28:06
    10.02.2012 09:13:44
    10.02.2012 09:00:17
    10.02.2012 08:45:04
    10.02.2012 08:25:04
    10.02.2012 08:07:12
    10.02.2012 07:50:06
    10.02.2012 07:25:05
    10.02.2012 07:04:50
    10.02.2012 06:45:04
    10.02.2012 06:20:04
    10.02.2012 06:00:12
    3) There arent any serious change at DB level.. almost these messages show in alert log since creating DB..Two simple thoughts:
    1) Are you running with archive log compression - add the "compressed" column to the query above to see if the archived log files are compressed
    2) The difference may simply be a reflection of the number and sizes of the public and private redo threads you have enabled - when anticipating a log file switch Oracle leaves enough space to cater for threads that need to be flushed into the log file, and then doesn't necessarily have to use it.
    Here's a query (if you can run as SYS) to show you your allocation of public and private threads
    select
         PTR_KCRF_PVT_STRAND           ,
         FIRST_BUF_KCRFA               ,
         LAST_BUF_KCRFA                ,
         TOTAL_BUFS_KCRFA              ,
         STRAND_SIZE_KCRFA             ,
         indx
    from
         x$kcrfstrand
    ;Regards
    Jonathan Lewis
    http://jonathanlewis.wordpress.com
    Author: <b><em>Oracle Core</em></b>

  • ORA-21560: while size is less than 1 GB for a CLOB variable

    Hi ,
    I use "DBMS_XSLPROCESSOR.CLOB2FILE' to write data from a CLOB variable (Oracle 10g) to TXT file in unix. I assumed that
    the clob can collect data of around 4 gb , but it is throwing the "Out of Range" error if the size exceeds
    22502381 bytes, which is not at all sufficient to my requirement. I want to collect around 3GB in the variable.
    Is it possible ? Please help
    2008-12-22 11:08 Error Occurred
    ORA-21560: argument 2 is null, invalid, or out of range
    Declare
    Xfile CLOB ;
    v_buffer VARCHAR2(32767);
    v_eol VARCHAR2(2);
    v_eollen PLS_INTEGER;
    c_maxline CONSTANT PLS_INTEGER := 32767;
    v_lines PLS_INTEGER := 0;
    v_dir          VARCHAR2(1000) := 'XXX/YYY' ;
    v_data_string VARCHAR2(32767) ;
    x integer ;
    Begin
    v_eol := CASE
    WHEN DBMS_UTILITY.PORT_STRING LIKE 'IBMPC%'
    THEN CHR(13)||CHR(10)
    ELSE CHR(10)
    END;
    v_eollen := LENGTH(v_eol);
    DBMS_LOB.CREATETEMPORARY(Xfile, TRUE);
    FOR r in ( Select desc1||'~'||desc2||.....desc30 AS csv from desc_t )
    Loop
    IF LENGTH(v_buffer) + v_eollen + LENGTH(r.csv) <= c_maxline THEN
    v_buffer := v_buffer || v_eol || r.csv;
    ELSE
    IF v_buffer IS NOT NULL THEN
    DBMS_LOB.WRITEAPPEND(
    v_file, LENGTH(v_buffer) + v_eollen, v_buffer || v_eol
    END IF;
    v_buffer := r.csv;
    END IF;
    v_lines := v_lines + 1;
    END LOOP;
    IF LENGTH(v_buffer) > 0 THEN
    DBMS_LOB.WRITEAPPEND(
    v_file, LENGTH(v_buffer) + v_eollen, v_buffer || v_eol
    END IF;
    DBMS_XSLPROCESSOR.CLOB2FILE(Xfile, v_dir, 'V_DESC,TXT');
    DBMS_LOB.FREETEMPORARY(v_file);
    Exception
    When Others Then
    dbms_output.put_line('Error '||v_lines||' --'||SQLERRM) ;
    dbms_output.put_line('Error '||dbms_lob.getlength(Xfile)) ;
    End ;
    Thanks

    Well, ORA-21560 could indicate file opening issue. Check the file name 'V_DESC,TXT'. Most likely your UNIX either does not allow commas in file name or requires them to be escaped. And anyway, I believe it is a typo and you meant 'V_DESC.TXT'.
    SY.

  • Why does my macbook pro, less than a year old, not show airplay

    My new apple tv does not work with my new macbook pro.  No silly box/triangle icon shows up on the operating system.  I cannot use airplay.  No help anywhere.  No documentation.  No diagnostics.  Just fail. Fail. FAIL.  Now my Apple TV will not upgrade...it tries and FAILS.

    AirPlay Mirroring requires a second-generation Apple TV or later, OS X 10.8 or better and is supported on the following Mac models: iMac (Mid 2011 or newer), Mac mini (Mid 2011 or newer), MacBook Air (Mid 2011 or newer), and MacBook Pro (Early 2011 or newer). It also requires the computer to be using wi-fi.

  • Creating Custom Page Size less than one inch

    I currently have Acrobat 6 on Windows XP, and it appears that I cannot set a custom page size less than one inch (Using Printer Preferences). Is there another method I can use to create a PDF from Publisher that has a page size less than one inch? If not, would updating to Acrobat 9 allow me to print to a custom page size of less than one inch?

    Thanks Peggy,
    I tried deleting the preference file and restarting Pages but I still have the same problem with the custom page size. When I start Pages I am presented with a bunch of templates so I choose Blank then I go through my procedure to select the custom page size that I created and always end up back at an A4 document.
    I have used the demo version of Stone Create to do what I needed to do with the small page size (ie. create a small ad) but it is a pain that I paid for Pages and now will need to buy something like Stone Create to do what I need. Although, that said, having used Stone Create for this little ad I must say that for the price it seems like a pretty decent program that will do a whole lot of the desktop publishing type of functions without the rather steep prices of the Adobe products. I kind of wish I had bought this program instead of Pages now.
    Cheers,
    Graham

  • GRN Qty should be less than Sub contracting Challan Qty

    Hi Friends,
    When we put Sub Contract Challn at the time of receving Sub Contract material MIGO, system should pick up challn Quty, or System should accept less qty than Challan Qty.
    Can we do the same ?
    Please help me.
    Thanks in Advance
    Yogesh

    HI,
    Yes GRN Qty should be same or less  than Sub contracting Challan Qty, system will allow you do the reconcilation with J1ifq or if the challan qty less then GRN quantity at the time system wont allow you to do the reconcilation
    Regards
    Pramod

  • Why is actual memory less than specifi

    Hello
    I own a Creative Muvo TX FM (256MB) and I was just wondering why the actual memory is less than 256MB. For instance I see this in other players and in my own I have only 243.5MB.
    Also, is changing the format from FAT to FAT32 going to change this "practical amount"?
    Thanks in advance for you help/advice!
    Jacob

    Also, remember that when you are looking at actual space on the player, in the "industry", a mega-byte (MB) is ,000 kilo-bytes (KB) and not ,024.
    And yes, the operating system is going to also chew some space.

  • After system copy new system size is leeer than old system

    Hii,
    Our client system is upgrading now. So Production BW system copy is done to new system.
    New system size is lesser than the Production system.
    Could any one let me know why this was happen. All the available in production BW is availalable in New system then also the new system size is less.
    Regards,
    sharma.

    Usually when you delete data from a table , the table space will not get released- you will have to run a reorg on the database so that the additional space gets released.... if you do the same on the production system then the spaces should get aligned.  Also run BRCONNECT on the copy as well so that everything is in line.
    Arun

  • How to configure an image to specific parameters.  Needed: no more than 1200 pixels on long side   jpeg format   no less than 5 mb.  Image will be viewed on large standup screen.(original image is 22 mb)

    I often have requests for images to be sent within certain parameters:  such as "no longer than 1200 pixels on longest side + jpeg format + file size no less than 5 mb."  Images will be viewed on a large stand up screen.  My original image sizes are usually around 22 mb.  When I use Export and specify 1200 pixels (quality setting is all the way over to 12), Save the file to a folder on the desktop, and then open the image in Preview, Inspector shows that the file size is now 233 KB.  How do I meet all specifications without reducing the image size so drastically?
    Thank you.

    . Pardon, it reduced it down to 833 KB, not 233 (I mixed it up with another image) from the Original image of 22 MB, RAW.  Should it reduce it down that much??
    That will depend on the amount of of detail in your jpeg. Given a certain pixels size and level of quality, a jpeg with many details will require a larger filesize than a jpeg with large plain regions of constant color.
    Is 833 KB a big enough file size to view on a big screen?
    The file size is really unimportant for the quality. What will count is the pixel size and jpeg quality you set. What is the pixel size of the large screen? That should match the pixel size you are using in your export preset. 1200 longest dimension is extremely unlikely for a large screen. Even the 17" display of my MacBook Pro has a larger pixelsize of 1920x1200.
    I am sharing William Lloyd's doubts, that the specifications you were given are correct.  I'd try to export with a larger pixelsize and a high jpeg quality - perhaps 10.
    If you export with 10 Megapixel  and a good jpeg quality, you will probably get a 5MB file, not that the size should matter.

Maybe you are looking for

  • IDOC Scenario: Filling ED40 in XI to SAP automatically or not

    Hello, I was trying to let XI fill the ED40 data of my IDOC and set the flag in receiver channel, that he should not take these information from payload. It seems he took wrong data. So from where he take these information? I disabled the ED40 segmen

  • Garageband version 10.0.2 vs. version 6.0.5?

    This is more of an opinion survey than anything. Just wondering how other Garageband users are finding the new version so far (version 10.0.2)? I've mostly stuck to the old one (version 6.0.5), since I know how to do everything I need to do with it.

  • Duplicate Apps. when upgrading.

    When I upgraded from 10.2 to 10.4, I copied my home folder to another hard-drive. I was not sure how the upgrade was going to change my current files. Well I new to computers and didn't want to lose anything. While I did not lose anything my extra ha

  • Finding the Sprite number if we give the member name

    Hi every one I want to find the spritenum based on the member name supplied for example i have a text field the member name of this field is "txtFirstName" Now if i want to find the sprite num through code then how should i go about it. I couldn't th

  • Premiere pro cc 2014 just abruptly shut down and now will not open my project please help...

    I am trying to open a project file that just abruptly shut down - "serious error occurred" and now my project will not open at all.  I have no idea what to do other than start over completely!!  Multi cam mix with camera over 1 and 15 minutes of vide