pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
NAME
pfQueryFeature, pfMQueryFeature, pfFeature - Graphics feature
availability routines
FUNCTION SPECIFICATION
#include <Performer/pr.h>
int pfQueryFeature(int which, int *dst);
int pfMQueryFeature(int *which, int *dst);
void pfFeature(int which, int val);
DESCRIPTION
OpenGL Performer make runtime determinations regarding the existence and
relative speed of certain graphics features for the underlying graphics
library (OpenGL) on the current hardware configuration. These functions
provide the ability to both query these results, and to override the
existence of a given feature. OpenGL Performer makes use of the
following useful routines in determining its information: getgdesc(3g),
XGetVisualInfo(3X11), glGetString(3g), glXQueryExtensionsString(3g), and
getinvent(3).
pfQueryFeature takes a PFQFTR_ token and returns in dst a token that
indicates whether or not that feature exists and whether the feature is
reasonable to use in a real-time application. The return value is the
number of bytes successfully written. The tokens are documented below
and special note is made where performance is commonly an issue. These
pfQueryFeature return values will be one of:
PFQFTR_FALSE
indicates that the feature is not available on the current
hardware configuration.
PFQFTR_TRUE
indicates that the feature is available on the current hardware
configuration.
PFQFTR_FAST
indicates that the feature is reasonable for real-time on the
current hardware configuration.
The pfQueryFeature tokens must be one of:
PFQFTR_VSYNC
queries the status of the graphics video clock. See the
pfInitVClock man page for more information.
PFQFTR_VSYNC_SET
queries the write-ability of the graphics video clock. See the
pfInitVClock man page for more information.
Page 1
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFQFTR_GANGDRAW
queries the availability of "gang" swapbuffers where multiple
graphics pipelines may be forced to swap framebuffers
simultaneously. See the pfChannel::setShare man page for more
information.
PFQFTR_HYPERPIPE
queries the support for hyperpipe hardware. See the pfHyperpipe
man page for more information.
PFQFTR_STEREO_IN_WINDOW
queries the support for doing stereo with multiple buffers in a
single window. See the OpenGL glDrawBufferMode(3g) man pages
for more information.
PFQFTR_PBUFFER
queries the support for OpenGL pbuffer drawables for off-screen
rendering. See the OpenGL/X glXCreateGLXPbufferSGIX(3g) man
page for more information on pbuffers.
PFQFTR_MULTISAMPLE
queries the support and relative performance of multisampled
antialiasing. See the pfAntialias man page for more
information.
PFQFTR_MULTISAMPLE_TRANSP
queries the support and relative performance of multisampled
transparency. See the pfTransparency man page for more
information.
PFQFTR_MULTISAMPLE_ROUND_POINTS
queries the support and relative performance of round
multisampled light points.
PFQFTR_MULTISAMPLE_STENCIL
queries the support and relative performance of multisampled
stencil.
PFQFTR_COLOR_ABGR
queries the support and relative performance of image data in
the ABGR format. This format may be slow or unsupported in
some OpenGL implementations. This is relevant to the OpenGL
glDrawPixels(3g) command.
PFQFTR_DISPLACE_POLYGON
queries the support for polygon displacement in screen Z used
for doing decals. See the pfDecal man page for more
information.
PFQFTR_POLYMODE
queries the support for polygon fill modes. See the OpenGL
glPolygonMode(3g) man pages for more information.
Page 2
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFQFTR_TRANSPARENCY
queries the support for and relative performance of
transparency.
PFQFTR_AALINES
queries the support for and relative performance of antialiased
lines.
PFQFTR_AAPOINTS
queries the support for and relative performance of antialiased
points.
PFQFTR_FOG_SPLINE
queries the support for spline fog. See the pfFog man page for
more information.
PFQFTR_FOG_LAYERED
queries the support for layered fog using special OpenGL
extensions.
PFQFTR_ALPHA_FUNC
queries the support for alpha functions. See the pfAlphaFunc
man page and the OpenGL glBlendFunc(3g) man pages for more
information.
PFQFTR_ALPHA_FUNC_COMPARE_REF
queries the support for comparative alpha functions. See the
pfAlphaFunc man page for more information.
PFQFTR_BLENDCOLOR
queries the support for specification of a blend color to use
with alpha functions. Refer to the OpenGL extension
glBlendColor(3g) for more information.
PFQFTR_BLEND_FUNC_SUBTRACT
queries the support for additional differencing alpha blending
functions.
PFQFTR_BLEND_FUNC_MINMAX
queries the support for additional min/max alpha blending
functions.
PFQFTR_GLSPRITE
queries the existence of GL support for sprites (billboards).
This can mean faster billboard drawing and also allows for
correct rendering of billboards in GL display lists. See the
pfSprite and pfBillboard man pages for more information.
PFQFTR_DVR
queries the support for dynamic video resizing, useful for load
management of fill limited applications. See the
pfPipeVideoChannel man page for more information.
Page 3
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFQFTR_TEXTURE
queries the support and relative performance of texture
mapping.
PFQFTR_TEXTURE_16BIT_IFMTS
queries the support and relative performance of 16-bit texel
formats. These formats take up less texture memory and can
provide a significant performance improvement at the cost of
some loss of image quality. See the pfTexFormat man page for
more information.
PFQFTR_TEXTURE_SUBTEXTURE
queries the support for dynamic loading of parts or all of
textures after the texture has been defined.
PFQFTR_TEXTURE_TRILINEAR
queries the support for trilinear MIPmapping for minification
filtering of texture maps.
PFQFTR_TEXTURE_DETAIL
queries the support for detailing of magnified texture maps.
See the pfTexFilter and pfTexDetail man pages for more
information.
PFQFTR_TEXTURE_SHARPEN
queries the support for sharpening of magnified texture maps.
See the pfTexFilter man page for more information.
PFQFTR_TEXTURE_3D
queries the support for three-dimensional textures.
PFQFTR_TEXTURE_5551
queries whether graphics hardware supports the 5551 texture
format (PFTEX_UNSIGNED_SHORT_5_5_5_1).
PFQFTR_TEXTURE_PROJECTIVE
queries the support for projected textures (lights). Projected
shadows also need the TEXTURE_SHADOW feature.
PFQFTR_TEXTURE_MINFILTER_BILINEAR_CMP
queries the support for special bilinear LEQUAL/GEQUAL
minification filters for doing real-time shadows.
PPFQFTR_TEXTURE_SHADOW queries the support for shadow texture
extension.
PPFQFTR_SHADOW_AMBIENT
queries support for the shadow ambient color. This corresponds
to the PFLS_INTENSITY value on a pfLightSource.
PFQFTR_TEXTURE_CLIPMAP
queries the support of clipmapping, or virtual MIPmapping, for
the minification filtering of very large textures.
Page 4
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFQFTR_TEXTURE_LOD_RANGE
queries the support of texture LOD range control for selecting
which texture levels are to be used.
PFQFTR_TEXTURE_LOD_BIAS
queries the support of texture LOD bias control.
PFQFTR_READ_MSDEPTH_BUFFER
queries the support for reading the multisample depth buffer.
PFQFTR_COPY_MSDEPTH_BUFFER
queries the support for copying to/from the multisample depth
buffer.
PFQFTR_READ_TEXTURE_MEMORY
queries the support for reading texture memory.
PFQFTR_COPY_TEXTURE_MEMORY
queries the support for copying to/from texture memory.
PFQFTR_MTL_CMODE
queries the support and speed of material color mode. On most
graphics platforms, this mode yields significant performance
improvements for management of multiple materials. However, on
some older low-end platforms, it can have additional cost and
should not be used if multiple materials are not in used.
PFQFTR_LIGHT_ATTENUATION
queries the support for light attenuation on the light. This
is OpenGL style light attenuation. See the OpenGL
glLightModel(3g) man page for more information.
PFQFTR_LIGHT_CLR_SPECULAR
queries the support for specular color components on lights.
This is only supported in OpenGL. See the OpenGL glLight(3g)
man page for more information.
PFQFTR_CALLIGRAPHIC
queries the support for calligraphic support. This is to know
if the Graphic Pipe Z buffer can be used for calligraphics
light points, but it doesn't tell you if a board is connected
to the system.
PFQFTR_DECAL_PLANE
queries the support for decal reference planes for use with
pfLayers and pfDecal geometry.
PFQFTR_PIPE_STATS
queries the hardware support for graphics pipeline statistics.
The InfiniteReality graphics subsystem supports time stamps in
the graphics pipeline.
Page 5
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFQFTR_TEXTURE_ANISOTROPIC
queries the hardware support for anisotropic texture filtering.
PFQFTR_STIPPLE
queries the hardware for stipple pattern support. All OpenGL
platforms provide this feature, but it is a huge performance
hit on some. Performer will return PFQFTR_FAST on platforms
where this feature is known to be cheap and PFQFTR_TRUE
otherwise.
PFQFTR_REGISTER_COMBINERS
queries the hardware support for support of the
GL_NV_register_combiners extension
pfMQueryFeature takes an NULL-terminated array of query tokens and a
destination buffer and will do multiple queries. The return value is the
number of bytes successfully written. This routine is more efficient
than pfQueryFeature if multiple queries are desired.
pfFeature takes a PFFTR_ token which and a boolean value val and allows
the overriding of OpenGL Performer's determination of the existence of
certain features. This can force OpenGL Performer to use, or to stop
using, a specific feature. This is useful for running on new graphics
platforms that may have considerations that OpenGL Performer did not
predict, or for making one machine behave like another for a specific
feature. Note that if a particular feature is forced on and it happens
to require hardware support that does not exist, the program may not run.
The features that may be set are:
PFFTR_VSYNC
PFFTR_VSYNC_SET
PFFTR_MULTISAMPLE
PFFTR_MULTISAMPLE_ROUND_POINT
PFFTR_ALPHA_FUNC_ALL
PFFTR_DISPLACE_POLYGON
PFFTR_POLYMODE
PFFTR_FOG_SPLINE
PFFTR_FOG_LAYERED
PFFTR_GANGDRAW
Page 6
pfFeature(3pf) OpenGL Performer 3.2.2 libpr C++ Reference Pages
PFFTR_HYPERPIPE
PFFTR_PBUFFER
PFFTR_DVR
PFFTR_FAST_TRANSPARENCY
PFFTR_FAST_AALINES
PFFTR_FAST_AAPOINTS
PFFTR_TEXTURE_FAST
PFFTR_TEXTURE_16BIT_IFMTS
PFFTR_TEXTURE_SUBTEXTURE
PFFTR_TEXTURE_3D
PFFTR_TEXTURE_5551
PFFTR_TEXTURE_DETAIL
PFFTR_TEXTURE_SHARPEN
PFFTR_TEXTURE_OBJECT
PFFTR_TEXTURE_PROJECTIVE
PFFTR_TEXTURE_TRILINEAR
PFFTR_TEXTURE_CLIPMAP
PFFTR_DECAL_PLANE
PFFTR_PIPE_STATS
PFFTR_STIPPLE
PFFTR_REGISTER_COMBINERS
NOTES
pfWindow::query can be used to query the configuration parameters of a
given pfWindow. pfQuerySys can be used to query the specific
configuration parameters of the current hardware configuration.
SEE ALSO
getgdesc, XGetVisualInfo, glGetString, glXQueryExtensionsString,
getinvent
Page 7