vbeModes.h revision 65fea56f17cd614bc8908264df980a62e1931468
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Copyright © 2002 David Dawes
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Permission is hereby granted, free of charge, to any person obtaining a
65fea56f17cd614bc8908264df980a62e1931468vboxsync * copy of this software and associated documentation files (the "Software"),
65fea56f17cd614bc8908264df980a62e1931468vboxsync * to deal in the Software without restriction, including without limitation
65fea56f17cd614bc8908264df980a62e1931468vboxsync * the rights to use, copy, modify, merge, publish, distribute, sublicense,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * and/or sell copies of the Software, and to permit persons to whom the
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Software is furnished to do so, subject to the following conditions:
65fea56f17cd614bc8908264df980a62e1931468vboxsync * The above copyright notice and this permission notice shall be included in
65fea56f17cd614bc8908264df980a62e1931468vboxsync * all copies or substantial portions of the Software.
65fea56f17cd614bc8908264df980a62e1931468vboxsync * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
65fea56f17cd614bc8908264df980a62e1931468vboxsync * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
65fea56f17cd614bc8908264df980a62e1931468vboxsync * THE AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY,
65fea56f17cd614bc8908264df980a62e1931468vboxsync * WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF
65fea56f17cd614bc8908264df980a62e1931468vboxsync * OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
65fea56f17cd614bc8908264df980a62e1931468vboxsync * SOFTWARE.
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Except as contained in this notice, the name of the author(s) shall
65fea56f17cd614bc8908264df980a62e1931468vboxsync * not be used in advertising or otherwise to promote the sale, use or other
65fea56f17cd614bc8908264df980a62e1931468vboxsync * dealings in this Software without prior written authorization from
65fea56f17cd614bc8908264df980a62e1931468vboxsync * the author(s).
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Authors: David Dawes <dawes@xfree86.org>
65fea56f17cd614bc8908264df980a62e1931468vboxsync * This is intended to be stored in the DisplayModeRec's private area.
65fea56f17cd614bc8908264df980a62e1931468vboxsync * It includes all the information necessary to VBE information.
65fea56f17cd614bc8908264df980a62e1931468vboxsynctypedef struct _VbeModeInfoData {
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_SUPPORTED(m) (((m)->ModeAttributes & 0x01) != 0)
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_COLOR(m) (((m)->ModeAttributes & 0x08) != 0)
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_GRAPHICS(m) (((m)->ModeAttributes & 0x10) != 0)
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_VGA(m) (((m)->ModeAttributes & 0x40) == 0)
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_LINEAR(m) (((m)->ModeAttributes & 0x80) != 0 && \
65fea56f17cd614bc8908264df980a62e1931468vboxsync#define VBE_MODE_USABLE(m, f) (VBE_MODE_SUPPORTED(m) || \
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT int VBEFindSupportedDepths(vbeInfoPtr pVbe, VbeInfoBlock * vbe,
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT DisplayModePtr VBEGetModePool(ScrnInfoPtr pScrn,
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT void VBESetModeNames(DisplayModePtr pMode);
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT void VBESetModeParameters(ScrnInfoPtr pScrn, vbeInfoPtr pVbe);
65fea56f17cd614bc8908264df980a62e1931468vboxsync * Note: These are alternatives to the standard helpers. They should
65fea56f17cd614bc8908264df980a62e1931468vboxsync * usually just wrap the standard helpers.
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT int VBEValidateModes(ScrnInfoPtr scrp,
65fea56f17cd614bc8908264df980a62e1931468vboxsyncextern _X_EXPORT void VBEPrintModes(ScrnInfoPtr scrp);
65fea56f17cd614bc8908264df980a62e1931468vboxsync#endif /* VBE_MODES_H */