Improved texture memory utilization on Impacts
Guy Russell (guyr++at++thoth.engr.sgi.com)
Fri, 19 Jul 1996 11:13:05 -0700
I have created a new version of the pfuDownload functions specifically
for the Impact hardware. The new version of tex.c in libpfutil optimizes
texture packing on Impacts. The same code should run on other SGI platforms
without any change. I have made the source code for this improvement available
on the Performer ftp site. It is located at
/usr/people/ftp/pub/Performer/src/pf2.0 and is called
libpfutil.impact_texture.Z. It is a compressed tar file of tex.c. Recompile
libpfutil with this tex.c to get the improvements. Also, verify that you call
pfuMakeTexList or pfuMakeSceneTexList prior to calling pfuDownloadTexList. If
you have your own versions of these functions, then you should consider adding
the functionality in these functions to your versions.
There are two improvements for Impact texture downloads. The first
improvement sorts textures by the number of components and then downloads them
such that the four component textures are loaded first, then the three
component, then the two component, and finally the single component. This
method allows single component textures to occupy the same pages, but in a
different TRAM as three component textures. Note, this method will only help
if you have 4 TRAMs. In the past, it was possible for a single component
texture and a three component texture to thrash when they were not loaded in
the correct order. This method will pack textures as efficiently as possible
on Impact graphics. We have seen dramatic improvements in texture memory usage
for applications that use single and three component textures. The second
improvement is a better metric for texture memory usage on Impacts. Impact
texture memory is organized into 256 pages of one or four components depending
on whether the texture option has been installed. The total amount of memory
will add up to 1 or 4 MB, but the number of pages used is more important in
understanding if your application's textures will all fit without paging. The
new download code will keep track of how many pages of texture memory have been
downloaded. If your app is using more than 256 pages than you will potentially
have to page textures from main meory to the TRAMs during realtime. Also, the
number of pages for each individual texture is printed out, so you can get an
idea of which textures are using up your pages. The totalizing function is
only valid if you ensure the proper sorting of textures prior to download, but
the individual texture page usage will be valid either way.
Please feel free to email me if there are any questions.
Guy
--
Guy Russell
Member of the Technical Staff Silicon Graphics Inc.
Email:guyr++at++engr.sgi.com 2011 N. Shoreline Blvd. M/S 2U-923
Phone:(415)933-6113 Mountain View CA 94043
=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
Submissions: info-performer++at++sgi.com
Admin. requests: info-performer-request++at++sgi.com
This archive was generated by hypermail 2.0b2
on Mon Aug 10 1998 - 17:53:12 PDT