intel_options.c revision 03b705cf
103b705cfSriastradh#ifdef HAVE_CONFIG_H 203b705cfSriastradh#include "config.h" 303b705cfSriastradh#endif 403b705cfSriastradh 503b705cfSriastradh#include "intel_options.h" 603b705cfSriastradh 703b705cfSriastradhconst OptionInfoRec intel_options[] = { 803b705cfSriastradh {OPTION_ACCEL_DISABLE, "NoAccel", OPTV_BOOLEAN, {0}, 0}, 903b705cfSriastradh {OPTION_ACCEL_METHOD, "AccelMethod", OPTV_STRING, {0}, 0}, 1003b705cfSriastradh {OPTION_BACKLIGHT, "Backlight", OPTV_STRING, {0}, 0}, 1103b705cfSriastradh {OPTION_DRI, "DRI", OPTV_STRING, {0}, 0}, 1203b705cfSriastradh {OPTION_COLOR_KEY, "ColorKey", OPTV_INTEGER, {0}, 0}, 1303b705cfSriastradh {OPTION_VIDEO_KEY, "VideoKey", OPTV_INTEGER, {0}, 0}, 1403b705cfSriastradh {OPTION_TILING_2D, "Tiling", OPTV_BOOLEAN, {0}, 1}, 1503b705cfSriastradh {OPTION_TILING_FB, "LinearFramebuffer", OPTV_BOOLEAN, {0}, 0}, 1603b705cfSriastradh {OPTION_SWAPBUFFERS_WAIT, "SwapbuffersWait", OPTV_BOOLEAN, {0}, 1}, 1703b705cfSriastradh {OPTION_TRIPLE_BUFFER, "TripleBuffer", OPTV_BOOLEAN, {0}, 1}, 1803b705cfSriastradh {OPTION_PREFER_OVERLAY, "XvPreferOverlay", OPTV_BOOLEAN, {0}, 0}, 1903b705cfSriastradh {OPTION_HOTPLUG, "HotPlug", OPTV_BOOLEAN, {0}, 1}, 2003b705cfSriastradh {OPTION_REPROBE, "ReprobeOutputs", OPTV_BOOLEAN, {0}, 0}, 2103b705cfSriastradh#ifdef INTEL_XVMC 2203b705cfSriastradh {OPTION_XVMC, "XvMC", OPTV_BOOLEAN, {0}, 1}, 2303b705cfSriastradh#endif 2403b705cfSriastradh#ifdef USE_SNA 2503b705cfSriastradh {OPTION_ZAPHOD, "ZaphodHeads", OPTV_STRING, {0}, 0}, 2603b705cfSriastradh {OPTION_TEAR_FREE, "TearFree", OPTV_BOOLEAN, {0}, 0}, 2703b705cfSriastradh {OPTION_CRTC_PIXMAPS, "PerCrtcPixmaps", OPTV_BOOLEAN, {0}, 0}, 2803b705cfSriastradh#endif 2903b705cfSriastradh#ifdef USE_UXA 3003b705cfSriastradh {OPTION_FALLBACKDEBUG, "FallbackDebug",OPTV_BOOLEAN, {0}, 0}, 3103b705cfSriastradh {OPTION_DEBUG_FLUSH_BATCHES, "DebugFlushBatches", OPTV_BOOLEAN, {0}, 0}, 3203b705cfSriastradh {OPTION_DEBUG_FLUSH_CACHES, "DebugFlushCaches", OPTV_BOOLEAN, {0}, 0}, 3303b705cfSriastradh {OPTION_DEBUG_WAIT, "DebugWait", OPTV_BOOLEAN, {0}, 0}, 3403b705cfSriastradh {OPTION_BUFFER_CACHE, "BufferCache", OPTV_BOOLEAN, {0}, 1}, 3503b705cfSriastradh#endif 3603b705cfSriastradh {-1, NULL, OPTV_NONE, {0}, 0} 3703b705cfSriastradh}; 3803b705cfSriastradh 3903b705cfSriastradhOptionInfoPtr intel_options_get(ScrnInfoPtr scrn) 4003b705cfSriastradh{ 4103b705cfSriastradh OptionInfoPtr options; 4203b705cfSriastradh 4303b705cfSriastradh xf86CollectOptions(scrn, NULL); 4403b705cfSriastradh if (!(options = malloc(sizeof(intel_options)))) 4503b705cfSriastradh return NULL; 4603b705cfSriastradh 4703b705cfSriastradh memcpy(options, intel_options, sizeof(intel_options)); 4803b705cfSriastradh xf86ProcessOptions(scrn->scrnIndex, scrn->options, options); 4903b705cfSriastradh 5003b705cfSriastradh return options; 5103b705cfSriastradh} 52