ABSTRACT

Streams and channels can be combined in any way to yield larger streams. Textures are represented by shading (Sh) in a very similar way to streams. Since Sh supports texture and stream objects that can contain large amounts of data, it is important to manage these objects efficiently. The key component of the stream and texture memory management system is the ShMemory class. It represents memory abstractly. Rather than correspond ing to a particular chunk of physical memory, it represents some amount of informationthat may be stored in more than one place. The ShTextureTraits object contains trait information such as filtering, wrap ping, and interpolation modes. Memory objects store reference-counted pointers to their storages. The stream interface present in Sh at the time of writing is very basic. There are many ways in which it can be improved to allow more flexible general-purpose programming.