home *** CD-ROM | disk | FTP | other *** search
/ NeXTSTEP 3.2 (Developer) / NS_dev_3.2.iso / NextDeveloper / Headers / driverkit / IOFrameBufferDisplay.h < prev    next >
Text File  |  1993-08-06  |  3KB  |  99 lines

  1. /*     Copyright (c) 1992 NeXT Computer, Inc.  All rights reserved. 
  2.  *
  3.  * IOFrameBufferDisplay.h - Standard frame buffer display driver class.
  4.  *
  5.  *
  6.  * HISTORY
  7.  * 01 Sep 92    Joe Pasqua
  8.  *      Created. 
  9.  */
  10.  
  11. /* Notes:
  12.  * This module defines an abstract superclass for "standard" (linear)
  13.  * framebuffers.
  14.  */
  15.  
  16. #ifndef __IOFRAMEBUFFERDISPLAY_H__
  17. #define __IOFRAMEBUFFERDISPLAY_H__
  18.  
  19. #import <driverkit/IODisplay.h>
  20.  
  21. @interface IOFrameBufferDisplay:IODisplay
  22. {
  23. @private
  24.     void *priv;
  25.     /* Mapping tables used in cursor drawing to 5-5-5 displays. */
  26.     unsigned char *_bm34To35SampleTable;
  27.     unsigned char *_bm35To34SampleTable;
  28.  
  29.     /* Reserved for future expansion. */
  30.     int _IOFrameBufferDisplay_reserved[8];
  31. }
  32.  
  33. /* Put the display into linear framebuffer mode. This typically happens
  34.  * when the window server starts running. This method is implemented by
  35.  * subclasses in a device specific way.
  36.  */
  37. - (void)enterLinearMode;
  38.  
  39. /* Get the device out of whatever advanced linear mode it was using and back
  40.  * into a state where it can be used as a standard VGA device. This method
  41.  * is implemented by subclasses in a device specific way.
  42.  */
  43. - (void)revertToVGAMode;
  44.  
  45. /* Look up the physical memory location for this device instance and map
  46.  * it into VM for use by the device driver. If problems occur, the method
  47.  * returns (vm_address_t)0. If `addr' is not 0, then it is used as the
  48.  * physical memory address and `length' is used as the length.
  49.  */
  50. - (vm_address_t)mapFrameBufferAtPhysicalAddress:(unsigned int)addr
  51.      length:(int)length;
  52.  
  53. /* Choose a mode from the list `modeList' (containing `count' modes) based
  54.  * on the value of the `DisplayMode' key in the device's config table.  If
  55.  * `isValid' is nonzero, each element specifies whether or not the
  56.  * corresponding mode is valid.
  57.  */
  58. - (int)selectMode:(const IODisplayInfo *)modeList count:(int)count
  59.     valid:(const BOOL *)isValid;
  60.  
  61. /* Equivalent to the above with `isValid' set to zero.
  62.  */
  63. - (int)selectMode:(const IODisplayInfo *)modeList count:(int)count;
  64.  
  65. /* IODevice methods reimplemented by this class. */
  66.  
  67. + (BOOL)probe:deviceDescription;
  68.  
  69. - initFromDeviceDescription:deviceDescription;
  70.  
  71. - (IOReturn)getIntValues        : (unsigned *)parameterArray
  72.                forParameter : (IOParameterName)parameterName
  73.                       count : (unsigned *)count;    // in/out
  74.  
  75. - (IOReturn)setIntValues        : (unsigned *)parameterArray
  76.                forParameter : (IOParameterName)parameterName
  77.                       count : (unsigned)count;
  78.  
  79. - (IOReturn)setCharValues        : (unsigned char *)parameterArray
  80.                forParameter : (IOParameterName)parameterName
  81.                       count : (unsigned)count;
  82.  
  83. - setTransferTable:(const unsigned int *)table count:(int)count;
  84.  
  85. /* 'IOScreenEvents' protocol methods reimplemented by this class. */
  86.  
  87. - hideCursor: (int)token;
  88.  
  89. - moveCursor:(Point*)cursorLoc frame:(int)frame token:(int)t;
  90.  
  91. - showCursor:(Point*)cursorLoc frame:(int)frame token:(int)t;
  92.  
  93. /* NOTE: Subclasses must override setBrightness and implement appropriately. */
  94. - setBrightness:(int)level token:(int)t;
  95.  
  96. @end
  97.  
  98. #endif    /* __IOFRAMEBUFFERDISPLAY_H__ */
  99.