Difference between revisions of "Unit Framebuffer"

From Ultibo.org
Jump to: navigation, search
Line 371: Line 371:
 
! '''Note'''
 
! '''Note'''
 
| Color must be specified in the correct format for the framebuffer. The default method assumes that framebuffer memory is DMA coherent and does not require cache invalidation after a DMA write.
 
| Color must be specified in the correct format for the framebuffer. The default method assumes that framebuffer memory is DMA coherent and does not require cache invalidation after a DMA write.
 +
|-
 +
|}
 +
</div></div>
 +
<br />
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function FramebufferDeviceGetLine(Framebuffer:PFramebufferDevice; Y:LongWord):Pointer;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the address of the start of a row in framebuffer memory</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Framebuffer'''
 +
| The framebuffer device to get the start address from
 +
|-
 +
! '''Y'''
 +
| The row to get the start address of
 +
|-
 +
! '''Return'''
 +
| Pointer to the start address of the row or nil on failure
 +
|-
 +
|}
 +
</div></div>
 +
<br />
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function FramebufferDeviceGetPoint(Framebuffer:PFramebufferDevice; X,Y:LongWord):Pointer;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Get the address of the specified row and column in framebuffer memory</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Framebuffer'''
 +
| The framebuffer device to get the address from
 +
|-
 +
! '''X'''
 +
| The column to get the start address of
 +
|-
 +
! '''Y'''
 +
| The row to get the start address of
 +
|-
 +
! '''Return'''
 +
| Pointer to the address of the row and column or nil on failure
 +
|-
 +
|}
 +
</div></div>
 +
<br />
 +
<div class="toccolours mw-collapsible mw-collapsed" style="border: 1; font-family: arial; padding-top: 0px; padding-bottom: 15px;">
 +
<pre style="border: 0; padding-bottom:0px;">function FramebufferDeviceSetBacklight(Framebuffer:PFramebufferDevice; Brightness:LongWord):LongWord;</pre>
 +
<div style="font-size: 14px; padding-left: 12px;">'''Description:''' Set the brightness of the backlight of a framebuffer device</div>
 +
<div class="mw-collapsible-content" style="text-align: left; padding-left: 5px;">
 +
{| class="wikitable" style="font-size: 14px; background: white;"
 +
|-
 +
! '''Framebuffer'''
 +
| The framebuffer device to set the backlight
 +
|-
 +
! '''Brightness'''
 +
| The brightness value to set (Normally 0 to 100)
 +
|-
 +
! '''Return'''
 +
| ERROR_SUCCESS if completed or another error code on failure
 +
|-
 +
! '''Note'''
 +
| Not all framebuffer devices support set backlight, returns ERROR_CALL_NOT_IMPLEMENTED if not supported. Devices that support set backlight should set the flag FRAMEBUFFER_FLAG_BACKLIGHT.
 
|-
 
|-
 
|}
 
|}

Revision as of 00:17, 7 October 2016

Return to Unit Reference


Description


To be documented

Constants


To be documented

Type definitions


To be documented

Public variables


To be documented

Function declarations



Initialization functions

[Expand]
procedure FramebufferInit;
Description: To be documented


Framebuffer functions

[Expand]
function FramebufferDeviceAllocate(Framebuffer:PFramebufferDevice; Properties:PFramebufferProperties):LongWord;
Description: Allocate and enable a framebuffer device using supplied properties or defaults


[Expand]
function FramebufferDeviceRelease(Framebuffer:PFramebufferDevice):LongWord;
Description: Disable and release a framebuffer device


[Expand]
function FramebufferDeviceBlank(Framebuffer:PFramebufferDevice; Blank:Boolean):LongWord;
Description: Blank (Turn off) the display of a framebuffer device


[Expand]
function FramebufferDeviceRead(Framebuffer:PFramebufferDevice; X,Y:LongWord; Buffer:Pointer; Len,Flags:LongWord):LongWord;
Description: Read one or more pixels from framebuffer device memory to a supplied buffer


[Expand]
function FramebufferDeviceWrite(Framebuffer:PFramebufferDevice; X,Y:LongWord; Buffer:Pointer; Len,Flags:LongWord):LongWord;
Description: Write one or more pixels to framebuffer device memory from a supplied buffer


[Expand]
function FramebufferDeviceMark(Framebuffer:PFramebufferDevice; X,Y,Width,Height,Flags:LongWord):LongWord;
Description: Mark a region written to the framebuffer and signal the device to take any neccessary actions


[Expand]
function FramebufferDeviceCommit(Framebuffer:PFramebufferDevice; Address,Size,Flags:LongWord):LongWord;
Description: Commit a region written to the framebuffer and signal the device to take any neccessary actions


[Expand]
function FramebufferDeviceGetRect(Framebuffer:PFramebufferDevice; X,Y:LongWord; Buffer:Pointer; Width,Height,Skip,Flags:LongWord):LongWord;
Description: Get a rectangular area of pixels from framebuffer memory to a supplied buffer


[Expand]
function FramebufferDevicePutRect(Framebuffer:PFramebufferDevice; X,Y:LongWord;Buffer:Pointer; Width,Height,Skip,Flags:LongWord):LongWord;
Description: Put a rectangular area of pixels from a supplied buffer to framebuffer memory


[Expand]
function FramebufferDeviceCopyRect(Framebuffer:PFramebufferDevice; X1,Y1,X2,Y2,Width,Height,Flags:LongWord):LongWord;
Description: Copy a rectangular area of pixels within framebuffer memory


[Expand]
function FramebufferDeviceFillRect(Framebuffer:PFramebufferDevice; X,Y,Width,Height,Color,Flags:LongWord):LongWord;
Description: Fill a rectangular area of pixels within framebuffer memory


[Expand]
function FramebufferDeviceGetLine(Framebuffer:PFramebufferDevice; Y:LongWord):Pointer;
Description: Get the address of the start of a row in framebuffer memory


[Expand]
function FramebufferDeviceGetPoint(Framebuffer:PFramebufferDevice; X,Y:LongWord):Pointer;
Description: Get the address of the specified row and column in framebuffer memory


[Expand]
function FramebufferDeviceSetBacklight(Framebuffer:PFramebufferDevice; Brightness:LongWord):LongWord;
Description: Set the brightness of the backlight of a framebuffer device


[Expand]
function FramebufferDeviceGetProperties(Framebuffer:PFramebufferDevice; Properties:PFramebufferProperties):LongWord;
Description: Get the current properties from a framebuffer device


[Expand]
function FramebufferDeviceSetProperties(Framebuffer:PFramebufferDevice; Properties:PFramebufferProperties):LongWord;
Description: Set the current properties for a framebuffer device


[Expand]
function FramebufferDeviceCheckFlag(Framebuffer:PFramebufferDevice; Flag:LongWord):Boolean;
Description: To be documented


[Expand]
function FramebufferDeviceGetFormat(Framebuffer:PFramebufferDevice):LongWord;
Description: To be documented


[Expand]
function FramebufferDeviceCreate:PFramebufferDevice;
Description: Create a new Framebuffer entry


[Expand]
function FramebufferDeviceCreateEx(Size:LongWord):PFramebufferDevice;
Description: Create a new Framebuffer entry


[Expand]
function FramebufferDeviceDestroy(Framebuffer:PFramebufferDevice):LongWord;
Description: Destroy an existing Framebuffer entry


[Expand]
function FramebufferDeviceRegister(Framebuffer:PFramebufferDevice):LongWord;
Description: Register a new Framebuffer in the Framebuffer table


[Expand]
function FramebufferDeviceDeregister(Framebuffer:PFramebufferDevice):LongWord;
Description: Deregister a Framebuffer from the Framebuffer table


[Expand]
function FramebufferDeviceFind(FramebufferId:LongWord):PFramebufferDevice;
Description: To be documented


[Expand]
function FramebufferDeviceFindByName(const Name:String):PFramebufferDevice; inline;
Description: To be documented


[Expand]
function FramebufferDeviceFindByDescription(const Description:String):PFramebufferDevice; inline;
Description: To be documented


[Expand]
function FramebufferDeviceEnumerate(Callback:TFramebufferEnumerate; Data:Pointer):LongWord;
Description: To be documented


[Expand]
function FramebufferDeviceNotification(Framebuffer:PFramebufferDevice; Callback:TFramebufferNotification; Data:Pointer; Notification,Flags:LongWord):LongWord;
Description: To be documented


RTL framebuffer functions

[Expand]
function SysFramebufferAvailable:Boolean;
Description: Check if a framebuffer device is available


Framebuffer helper functions

[Expand]
function FramebufferDeviceGetCount:LongWord; inline;
Description: Get the current framebuffer device count


[Expand]
function FramebufferDeviceGetDefault:PFramebufferDevice; inline;
Description: Get the current default framebuffer device


[Expand]
function FramebufferDeviceSetDefault(Framebuffer:PFramebufferDevice):LongWord;
Description: Set the current default framebuffer device


[Expand]
function FramebufferDeviceCheck(Framebuffer:PFramebufferDevice):PFramebufferDevice;
Description: Check if the supplied Framebuffer device is in the Framebuffer table


[Expand]
function FramebufferDeviceSwap(Value:LongWord):LongWord; inline;
Description: To be documented


Return to Unit Reference