convert.h | convert.h | |||
---|---|---|---|---|
skipping to change at line 78 | skipping to change at line 78 | |||
(((b)&0xF0) >> 4) ) | (((b)&0xF0) >> 4) ) | |||
#define PIXEL_RGB16(r,g,b) ( (((r)&0xF8) << 8) | \ | #define PIXEL_RGB16(r,g,b) ( (((r)&0xF8) << 8) | \ | |||
(((g)&0xFC) << 3) | \ | (((g)&0xFC) << 3) | \ | |||
(((b)&0xF8) >> 3) ) | (((b)&0xF8) >> 3) ) | |||
#define PIXEL_RGB18(r,g,b) ( (((r)&0xFC) << 10) | \ | #define PIXEL_RGB18(r,g,b) ( (((r)&0xFC) << 10) | \ | |||
(((g)&0xFC) << 4) | \ | (((g)&0xFC) << 4) | \ | |||
(((b)&0xFC) >> 2) ) | (((b)&0xFC) >> 2) ) | |||
#define PIXEL_RGB32(r,g,b) ( (0xff << 24) | \ | #define PIXEL_RGB32(r,g,b) ( ((r) << 16) | \ | |||
((r) << 16) | \ | ((g) << 8) | \ | |||
((g) << 8) | \ | ||||
(b) ) | (b) ) | |||
#define PIXEL_ARGB(a,r,g,b) ( ((a) << 24) | \ | #define PIXEL_ARGB(a,r,g,b) ( ((a) << 24) | \ | |||
((r) << 16) | \ | ((r) << 16) | \ | |||
((g) << 8) | \ | ((g) << 8) | \ | |||
(b) ) | (b) ) | |||
#define PIXEL_ARGB1666(a,r,g,b) ( (((a)&0x80) << 11) | \ | #define PIXEL_ARGB1666(a,r,g,b) ( (((a)&0x80) << 11) | \ | |||
(((r)&0xFC) << 10) | \ | (((r)&0xFC) << 10) | \ | |||
(((g)&0xFC) << 4) | \ | (((g)&0xFC) << 4) | \ | |||
skipping to change at line 451 | skipping to change at line 450 | |||
void dfb_convert_to_rgb32( DFBSurfacePixelFormat format, | void dfb_convert_to_rgb32( DFBSurfacePixelFormat format, | |||
void *src, | void *src, | |||
int spitch, | int spitch, | |||
int surface_height, | int surface_height, | |||
u32 *dst, | u32 *dst, | |||
int dpitch, | int dpitch, | |||
int width, | int width, | |||
int height ); | int height ); | |||
void dfb_convert_to_rgb24( DFBSurfacePixelFormat format, | ||||
void *src, | ||||
int spitch, | ||||
int surface_height, | ||||
u8 *dst, | ||||
int dpitch, | ||||
int width, | ||||
int height ); | ||||
void dfb_convert_to_a8( DFBSurfacePixelFormat format, | ||||
void *src, | ||||
int spitch, | ||||
int surface_height, | ||||
u8 *dst, | ||||
int dpitch, | ||||
int width, | ||||
int height ); | ||||
void dfb_convert_to_a4( DFBSurfacePixelFormat format, | void dfb_convert_to_a4( DFBSurfacePixelFormat format, | |||
void *src, | void *src, | |||
int spitch, | int spitch, | |||
int surface_height, | int surface_height, | |||
u8 *dst, | u8 *dst, | |||
int dpitch, | int dpitch, | |||
int width, | int width, | |||
int height ); | int height ); | |||
void dfb_convert_to_yuy2( DFBSurfacePixelFormat format, | void dfb_convert_to_yuy2( DFBSurfacePixelFormat format, | |||
End of changes. 2 change blocks. | ||||
3 lines changed or deleted | 20 lines changed or added | |||
core_parts.h | core_parts.h | |||
---|---|---|---|---|
skipping to change at line 48 | skipping to change at line 48 | |||
#include <core/coredefs.h> | #include <core/coredefs.h> | |||
typedef DFBResult (*CoreInitialize)( CoreDFB *core, | typedef DFBResult (*CoreInitialize)( CoreDFB *core, | |||
void *data_local, | void *data_local, | |||
void *data_shared ); | void *data_shared ); | |||
typedef DFBResult (*CoreJoin) ( CoreDFB *core, | typedef DFBResult (*CoreJoin) ( CoreDFB *core, | |||
void *data_local, | void *data_local, | |||
void *data_shared ); | void *data_shared ); | |||
typedef DFBResult (*CoreShutdown) ( void *data_local, | typedef DFBResult (*CoreShutdown) ( CoreDFB *core, | |||
bool emergency ); | bool emergency ); | |||
typedef DFBResult (*CoreLeave) ( void *data_local, | typedef DFBResult (*CoreLeave) ( CoreDFB *core, | |||
bool emergency ); | bool emergency ); | |||
typedef DFBResult (*CoreSuspend) ( void *data_local ); | typedef DFBResult (*CoreSuspend) ( CoreDFB *core ); | |||
typedef DFBResult (*CoreResume) ( void *data_local ); | typedef DFBResult (*CoreResume) ( CoreDFB *core ); | |||
typedef struct { | typedef struct { | |||
const char *name; | const char *name; | |||
int size_local; | int size_local; | |||
int size_shared; | int size_shared; | |||
CoreInitialize Initialize; | CoreInitialize Initialize; | |||
CoreJoin Join; | CoreJoin Join; | |||
CoreShutdown Shutdown; | CoreShutdown Shutdown; | |||
skipping to change at line 94 | skipping to change at line 94 | |||
CorePart *core_part, | CorePart *core_part, | |||
bool emergency ); | bool emergency ); | |||
DFBResult dfb_core_part_leave ( CoreDFB *core, | DFBResult dfb_core_part_leave ( CoreDFB *core, | |||
CorePart *core_part, | CorePart *core_part, | |||
bool emergency ); | bool emergency ); | |||
#define DFB_CORE_PART(part,Type) \ | #define DFB_CORE_PART(part,Type) \ | |||
\ | \ | |||
static DFBResult dfb_##part##_initialize( CoreDFB *core, \ | static DFBResult dfb_##part##_initialize( CoreDFB *core, \ | |||
DFB##Type *local, \ | DFB##Type *data, \ | |||
DFB##Type##Shared *shared ); \ | DFB##Type##Shared *shared ); \ | |||
\ | \ | |||
static DFBResult dfb_##part##_join ( CoreDFB *core, \ | static DFBResult dfb_##part##_join ( CoreDFB *core, \ | |||
DFB##Type *local, \ | DFB##Type *data, \ | |||
DFB##Type##Shared *shared ); \ | DFB##Type##Shared *shared ); \ | |||
\ | \ | |||
static DFBResult dfb_##part##_shutdown ( DFB##Type *local, \ | static DFBResult dfb_##part##_shutdown ( DFB##Type *data, \ | |||
bool emergency ); \ | bool emergency ); \ | |||
\ | \ | |||
static DFBResult dfb_##part##_leave ( DFB##Type *local, \ | static DFBResult dfb_##part##_leave ( DFB##Type *local, \ | |||
bool emergency ); \ | bool emergency ); \ | |||
\ | \ | |||
static DFBResult dfb_##part##_suspend ( DFB##Type *local ); \ | static DFBResult dfb_##part##_suspend ( DFB##Type *local ); \ | |||
\ | \ | |||
static DFBResult dfb_##part##_resume ( DFB##Type *local ); \ | static DFBResult dfb_##part##_resume ( DFB##Type *local ); \ | |||
\ | \ | |||
CorePart dfb_##part = { \ | CorePart dfb_##part = { \ | |||
.name = #part, \ | #part, \ | |||
\ | \ | |||
.size_local = sizeof(DFB##Type), | sizeof(DFB##Type), | |||
\ | \ | |||
.size_shared = sizeof(DFB##Type##Shared), | sizeof(DFB##Type##Shared), | |||
\ | \ | |||
\ | \ | |||
.Initialize = (void*)dfb_##part##_initialize, | (void*)dfb_##part##_initialize, | |||
\ | \ | |||
.Join = (void*)dfb_##part##_join, | (void*)dfb_##part##_join, | |||
\ | \ | |||
.Shutdown = (void*)dfb_##part##_shutdown, | (void*)dfb_##part##_shutdown, | |||
\ | \ | |||
.Leave = (void*)dfb_##part##_leave, | (void*)dfb_##part##_leave, | |||
\ | \ | |||
.Suspend = (void*)dfb_##part##_suspend, | (void*)dfb_##part##_suspend, | |||
\ | \ | |||
.Resume = (void*)dfb_##part##_resume, | (void*)dfb_##part##_resume | |||
\ | \ | |||
} | } | |||
#endif | #endif | |||
End of changes. 10 change blocks. | ||||
24 lines changed or deleted | 24 lines changed or added | |||
core_system.h | core_system.h | |||
---|---|---|---|---|
skipping to change at line 50 | skipping to change at line 50 | |||
static DFBResult | static DFBResult | |||
system_join( CoreDFB *core, void **data ); | system_join( CoreDFB *core, void **data ); | |||
static DFBResult | static DFBResult | |||
system_shutdown( bool emergency ); | system_shutdown( bool emergency ); | |||
static DFBResult | static DFBResult | |||
system_leave( bool emergency ); | system_leave( bool emergency ); | |||
static DFBResult | static DFBResult | |||
system_suspend( void ); | system_suspend(); | |||
static DFBResult | static DFBResult | |||
system_resume( void ); | system_resume(); | |||
static VideoMode* | static VideoMode* | |||
system_get_modes( void ); | system_get_modes(); | |||
static VideoMode* | static VideoMode* | |||
system_get_current_mode( void ); | system_get_current_mode(); | |||
static DFBResult | static DFBResult | |||
system_thread_init( void ); | system_thread_init(); | |||
static bool | static bool | |||
system_input_filter( CoreInputDevice *device, | system_input_filter( CoreInputDevice *device, | |||
DFBInputEvent *event ); | DFBInputEvent *event ); | |||
static volatile void* | static volatile void* | |||
system_map_mmio( unsigned int offset, | system_map_mmio( unsigned int offset, | |||
int length ); | int length ); | |||
static void | static void | |||
system_unmap_mmio( volatile void *addr, | system_unmap_mmio( volatile void *addr, | |||
int length ); | int length ); | |||
static int | static int | |||
system_get_accelerator( void ); | system_get_accelerator(); | |||
static unsigned long | static unsigned long | |||
system_video_memory_physical( unsigned int offset ); | system_video_memory_physical( unsigned int offset ); | |||
static void* | static void* | |||
system_video_memory_virtual( unsigned int offset ); | system_video_memory_virtual( unsigned int offset ); | |||
static unsigned int | static unsigned int | |||
system_videoram_length( void ); | system_videoram_length(); | |||
static unsigned long | static unsigned long | |||
system_aux_memory_physical( unsigned int offset ); | system_aux_memory_physical( unsigned int offset ); | |||
static void* | static void* | |||
system_aux_memory_virtual( unsigned int offset ); | system_aux_memory_virtual( unsigned int offset ); | |||
static unsigned int | static unsigned int | |||
system_auxram_length( void ); | system_auxram_length(); | |||
static void | static void | |||
system_get_busid( int *ret_bus, int *ret_dev, int *ret_func ); | system_get_busid(); | |||
static void | static void | |||
system_get_deviceid( unsigned int *ret_vendor_id, unsigned int *ret_device_ id ); | system_get_deviceid(); | |||
static CoreSystemFuncs system_funcs = { | static CoreSystemFuncs system_funcs = { | |||
.GetSystemInfo = system_get_info, | .GetSystemInfo = system_get_info, | |||
.Initialize = system_initialize, | .Initialize = system_initialize, | |||
.Join = system_join, | .Join = system_join, | |||
.Shutdown = system_shutdown, | .Shutdown = system_shutdown, | |||
.Leave = system_leave, | .Leave = system_leave, | |||
.Suspend = system_suspend, | .Suspend = system_suspend, | |||
.Resume = system_resume, | .Resume = system_resume, | |||
.GetModes = system_get_modes, | .GetModes = system_get_modes, | |||
skipping to change at line 128 | skipping to change at line 128 | |||
.VideoMemoryPhysical = system_video_memory_physical, | .VideoMemoryPhysical = system_video_memory_physical, | |||
.VideoMemoryVirtual = system_video_memory_virtual, | .VideoMemoryVirtual = system_video_memory_virtual, | |||
.VideoRamLength = system_videoram_length, | .VideoRamLength = system_videoram_length, | |||
.AuxMemoryPhysical = system_aux_memory_physical, | .AuxMemoryPhysical = system_aux_memory_physical, | |||
.AuxMemoryVirtual = system_aux_memory_virtual, | .AuxMemoryVirtual = system_aux_memory_virtual, | |||
.AuxRamLength = system_auxram_length, | .AuxRamLength = system_auxram_length, | |||
.GetBusID = system_get_busid, | .GetBusID = system_get_busid, | |||
.GetDeviceID = system_get_deviceid | .GetDeviceID = system_get_deviceid | |||
}; | }; | |||
#define DFB_CORE_SYSTEM(shortname) \ | #define DFB_CORE_SYSTEM(shortname) \ | |||
__attribute__((constructor)) void directfb_##shortname( void ); \ | __attribute__((constructor)) void directfb_##shortname(); \ | |||
\ | \ | |||
void \ | void \ | |||
directfb_##shortname( void ) \ | directfb_##shortname() \ | |||
{ \ | { \ | |||
direct_modules_register( &dfb_core_systems, \ | direct_modules_register( &dfb_core_systems, \ | |||
DFB_CORE_SYSTEM_ABI_VERSION, \ | DFB_CORE_SYSTEM_ABI_VERSION, \ | |||
#shortname, &system_funcs ); \ | #shortname, &system_funcs ); \ | |||
} | } | |||
#endif | #endif | |||
End of changes. 11 change blocks. | ||||
19 lines changed or deleted | 19 lines changed or added | |||
coredefs.h | coredefs.h | |||
---|---|---|---|---|
skipping to change at line 36 | skipping to change at line 36 | |||
Boston, MA 02111-1307, USA. | Boston, MA 02111-1307, USA. | |||
*/ | */ | |||
#ifndef __CORE__COREDEFS_H__ | #ifndef __CORE__COREDEFS_H__ | |||
#define __CORE__COREDEFS_H__ | #define __CORE__COREDEFS_H__ | |||
#ifdef PIC | #ifdef PIC | |||
#define DFB_DYNAMIC_LINKING | #define DFB_DYNAMIC_LINKING | |||
#endif | #endif | |||
#define MAX_INPUTDEVICES 16 | #define MAX_INPUTDEVICES 16 | |||
#define MAX_LAYERS 16 | #define MAX_LAYERS 16 | |||
#define MAX_SCREENS 4 | #define MAX_SCREENS 4 | |||
#define MAX_INPUT_GLOBALS 8 | #define MAX_INPUT_GLOBALS 8 | |||
#define MAX_SURFACE_BUFFERS 6 | #define MAX_SURFACE_BUFFERS 6 | |||
#define MAX_SURFACE_POOLS 6 | #define MAX_SURFACE_POOLS 8 | |||
#define MAX_SURFACE_POOL_BRIDGES 4 | ||||
#endif | #endif | |||
End of changes. 3 change blocks. | ||||
6 lines changed or deleted | 7 lines changed or added | |||
coretypes.h | coretypes.h | |||
---|---|---|---|---|
skipping to change at line 67 | skipping to change at line 67 | |||
typedef struct __DFB_CoreScreen CoreScreen; | typedef struct __DFB_CoreScreen CoreScreen; | |||
typedef struct __DFB_CoreInputDevice CoreInputDevice; | typedef struct __DFB_CoreInputDevice CoreInputDevice; | |||
typedef struct __DFB_CoreLayer CoreLayer; | typedef struct __DFB_CoreLayer CoreLayer; | |||
typedef struct __DFB_CoreLayerContext CoreLayerContext; | typedef struct __DFB_CoreLayerContext CoreLayerContext; | |||
typedef struct __DFB_CoreLayerRegion CoreLayerRegion; | typedef struct __DFB_CoreLayerRegion CoreLayerRegion; | |||
typedef struct __DFB_CoreLayerRegionConfig CoreLayerRegionConfig; | typedef struct __DFB_CoreLayerRegionConfig CoreLayerRegionConfig; | |||
typedef struct __DFB_CoreSurface CoreSurface; | typedef struct __DFB_CoreSurface CoreSurface; | |||
typedef struct __DFB_CoreSurfaceAccessor CoreSurfaceAccessor; | ||||
typedef struct __DFB_CoreSurfaceAllocation CoreSurfaceAllocation; | typedef struct __DFB_CoreSurfaceAllocation CoreSurfaceAllocation; | |||
typedef struct __DFB_CoreSurfaceBuffer CoreSurfaceBuffer; | typedef struct __DFB_CoreSurfaceBuffer CoreSurfaceBuffer; | |||
typedef struct __DFB_CoreSurfaceBufferLock CoreSurfaceBufferLock; | typedef struct __DFB_CoreSurfaceBufferLock CoreSurfaceBufferLock; | |||
typedef struct __DFB_CoreSurfacePool CoreSurfacePool; | typedef struct __DFB_CoreSurfacePool CoreSurfacePool; | |||
typedef struct __DFB_CoreSurfacePoolBridge CoreSurfacePoolBridge; | ||||
typedef struct __DFB_CoreSurfacePoolTransfer CoreSurfacePoolTransfer; | ||||
typedef struct __DFB_CoreWindow CoreWindow; | typedef struct __DFB_CoreWindow CoreWindow; | |||
typedef struct __DFB_CoreWindowConfig CoreWindowConfig; | typedef struct __DFB_CoreWindowConfig CoreWindowConfig; | |||
typedef struct __DFB_CoreWindowStack CoreWindowStack; | typedef struct __DFB_CoreWindowStack CoreWindowStack; | |||
typedef unsigned int CoreSurfacePoolID; | typedef unsigned int CoreSurfacePoolID; | |||
typedef unsigned int CoreSurfacePoolBridgeID; | ||||
#endif | #endif | |||
End of changes. 3 change blocks. | ||||
0 lines changed or deleted | 4 lines changed or added | |||
directfb.h | directfb.h | |||
---|---|---|---|---|
skipping to change at line 599 | skipping to change at line 599 | |||
and eventually the second one | and eventually the second one | |||
for the back buffer. */ | for the back buffer. */ | |||
DSDESC_PALETTE = 0x00000020, /* Initialize the surfaces palette | DSDESC_PALETTE = 0x00000020, /* Initialize the surfaces palette | |||
with the entries specified in th e | with the entries specified in th e | |||
description. */ | description. */ | |||
DSDESC_RESOURCE_ID = 0x00000100, /* user defined resource id for gen eral purpose | DSDESC_RESOURCE_ID = 0x00000100, /* user defined resource id for gen eral purpose | |||
surfaces is specified, or resour ce id of window, | surfaces is specified, or resour ce id of window, | |||
layer, user is returned */ | layer, user is returned */ | |||
DSDESC_ALL = 0x0000013F /* all of these */ | DSDESC_HINTS = 0x00000200, /* Flags for optimized allocation a | |||
nd pixel format selection are set. | ||||
See also DFBSurfaceHintFlags. */ | ||||
DSDESC_ALL = 0x0000033F /* all of these */ | ||||
} DFBSurfaceDescriptionFlags; | } DFBSurfaceDescriptionFlags; | |||
/* | /* | |||
* Flags defining which fields of a DFBPaletteDescription are valid. | * Flags defining which fields of a DFBPaletteDescription are valid. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DPDESC_CAPS = 0x00000001, /* Specify palette capabilities. */ | DPDESC_CAPS = 0x00000001, /* Specify palette capabilities. */ | |||
DPDESC_SIZE = 0x00000002, /* Specify number of entries. */ | DPDESC_SIZE = 0x00000002, /* Specify number of entries. */ | |||
DPDESC_ENTRIES = 0x00000004 /* Initialize the palette with the | DPDESC_ENTRIES = 0x00000004 /* Initialize the palette with the | |||
entries specified in the | entries specified in the | |||
skipping to change at line 649 | skipping to change at line 652 | |||
useful for surfaces that need a guaranteed space in | useful for surfaces that need a guaranteed space in | |||
video memory after resizing. */ | video memory after resizing. */ | |||
DSCAPS_TRIPLE = 0x00000200, /* Surface is triple buffered. */ | DSCAPS_TRIPLE = 0x00000200, /* Surface is triple buffered. */ | |||
DSCAPS_PREMULTIPLIED = 0x00001000, /* Surface stores data with premul tiplied alpha. */ | DSCAPS_PREMULTIPLIED = 0x00001000, /* Surface stores data with premul tiplied alpha. */ | |||
DSCAPS_DEPTH = 0x00010000, /* A depth buffer is allocated. */ | DSCAPS_DEPTH = 0x00010000, /* A depth buffer is allocated. */ | |||
DSCAPS_SHARED = 0x00100000, /* The surface will be accessible among processes. */ | DSCAPS_SHARED = 0x00100000, /* The surface will be accessible among processes. */ | |||
DSCAPS_ALL = 0x001113F7, /* All of these. */ | DSCAPS_ROTATED = 0x01000000, /* The back buffers are allocated | |||
with swapped width/height (unimplemented!). */ | ||||
DSCAPS_ALL = 0x011113F7, /* All of these. */ | ||||
DSCAPS_FLIPPING = DSCAPS_DOUBLE | DSCAPS_TRIPLE /* Surface needs Flip() calls to make | DSCAPS_FLIPPING = DSCAPS_DOUBLE | DSCAPS_TRIPLE /* Surface needs Flip() calls to make | |||
updates/change s visible/usable. */ | updates/change s visible/usable. */ | |||
} DFBSurfaceCapabilities; | } DFBSurfaceCapabilities; | |||
/* | /* | |||
* The palette capabilities. | * The palette capabilities. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DPCAPS_NONE = 0x00000000 /* None of these. */ | DPCAPS_NONE = 0x00000000 /* None of these. */ | |||
skipping to change at line 706 | skipping to change at line 711 | |||
DSBLIT_DEMULTIPLY = 0x00000080, /* divides the color by the al pha before writing the | DSBLIT_DEMULTIPLY = 0x00000080, /* divides the color by the al pha before writing the | |||
data to the destination */ | data to the destination */ | |||
DSBLIT_DEINTERLACE = 0x00000100, /* deinterlaces the source dur ing blitting by reading | DSBLIT_DEINTERLACE = 0x00000100, /* deinterlaces the source dur ing blitting by reading | |||
only one field (every secon d line of full | only one field (every secon d line of full | |||
image) scaling it verticall y by factor two */ | image) scaling it verticall y by factor two */ | |||
DSBLIT_SRC_PREMULTCOLOR = 0x00000200, /* modulates the source color with the color alpha */ | DSBLIT_SRC_PREMULTCOLOR = 0x00000200, /* modulates the source color with the color alpha */ | |||
DSBLIT_XOR = 0x00000400, /* bitwise xor the destination pixels with the | DSBLIT_XOR = 0x00000400, /* bitwise xor the destination pixels with the | |||
source pixels after premult iplication */ | source pixels after premult iplication */ | |||
DSBLIT_INDEX_TRANSLATION = 0x00000800, /* do fast indexed to indexed translation, | DSBLIT_INDEX_TRANSLATION = 0x00000800, /* do fast indexed to indexed translation, | |||
this flag is mutual exclusi ve with all others */ | this flag is mutual exclusi ve with all others */ | |||
DSBLIT_ROTATE90 = 0x00002000, /* rotate the image by 90 degr ee */ | ||||
DSBLIT_ROTATE180 = 0x00001000, /* rotate the image by 180 deg ree */ | DSBLIT_ROTATE180 = 0x00001000, /* rotate the image by 180 deg ree */ | |||
DSBLIT_ROTATE270 = 0x00004000, /* rotate the image by 270 deg ree */ | ||||
DSBLIT_COLORKEY_PROTECT = 0x00010000, /* make sure written pixels do n't match color key (internal only ATM) */ | DSBLIT_COLORKEY_PROTECT = 0x00010000, /* make sure written pixels do n't match color key (internal only ATM) */ | |||
DSBLIT_SRC_MASK_ALPHA = 0x00100000, /* modulate source alpha chann el with alpha channel from source mask, | DSBLIT_SRC_MASK_ALPHA = 0x00100000, /* modulate source alpha chann el with alpha channel from source mask, | |||
see also IDirectFBSurface:: SetSourceMask() */ | see also IDirectFBSurface:: SetSourceMask() */ | |||
DSBLIT_SRC_MASK_COLOR = 0x00200000, /* modulate source color chann els with color channels from source mask, | DSBLIT_SRC_MASK_COLOR = 0x00200000, /* modulate source color chann els with color channels from source mask, | |||
see also IDirectFBSurface:: SetSourceMask() */ | see also IDirectFBSurface:: SetSourceMask() */ | |||
} DFBSurfaceBlittingFlags; | } DFBSurfaceBlittingFlags; | |||
/* | /* | |||
* Options for drawing and blitting operations. Not mandatory for accelerat ion. | * Options for drawing and blitting operations. Not mandatory for accelerat ion. | |||
*/ | */ | |||
skipping to change at line 848 | skipping to change at line 855 | |||
DWDESC_HEIGHT = 0x00000004, /* height field is valid */ | DWDESC_HEIGHT = 0x00000004, /* height field is valid */ | |||
DWDESC_PIXELFORMAT = 0x00000008, /* pixelformat field is valid */ | DWDESC_PIXELFORMAT = 0x00000008, /* pixelformat field is valid */ | |||
DWDESC_POSX = 0x00000010, /* posx field is valid */ | DWDESC_POSX = 0x00000010, /* posx field is valid */ | |||
DWDESC_POSY = 0x00000020, /* posy field is valid */ | DWDESC_POSY = 0x00000020, /* posy field is valid */ | |||
DWDESC_SURFACE_CAPS = 0x00000040, /* Create the window surface with | DWDESC_SURFACE_CAPS = 0x00000040, /* Create the window surface with | |||
special capabilities. */ | special capabilities. */ | |||
DWDESC_PARENT = 0x00000080, /* This window has a parent accordi ng to parent_id field. */ | DWDESC_PARENT = 0x00000080, /* This window has a parent accordi ng to parent_id field. */ | |||
DWDESC_OPTIONS = 0x00000100, /* Initial window options have been set. */ | DWDESC_OPTIONS = 0x00000100, /* Initial window options have been set. */ | |||
DWDESC_STACKING = 0x00000200, /* Initial stacking class has been set. */ | DWDESC_STACKING = 0x00000200, /* Initial stacking class has been set. */ | |||
DWDESC_TOPLEVEL_ID = 0x00000400, /* The top level window is set in t | ||||
oplevel_id field. */ | ||||
DWDESC_RESOURCE_ID = 0x00001000, /* Resource id for window surface c reation has been set. */ | DWDESC_RESOURCE_ID = 0x00001000, /* Resource id for window surface c reation has been set. */ | |||
} DFBWindowDescriptionFlags; | } DFBWindowDescriptionFlags; | |||
/* | /* | |||
* Flags defining which fields of a DFBDataBufferDescription are valid. | * Flags defining which fields of a DFBDataBufferDescription are valid. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DBDESC_FILE = 0x00000001, /* Create a static buffer for the | DBDESC_FILE = 0x00000001, /* Create a static buffer for the | |||
specified filename. */ | specified filename. */ | |||
DBDESC_MEMORY = 0x00000002 /* Create a static buffer for the | DBDESC_MEMORY = 0x00000002 /* Create a static buffer for the | |||
skipping to change at line 881 | skipping to change at line 891 | |||
that is still in preparation. | that is still in preparation. | |||
Normally a window's content can | Normally a window's content can | |||
get visible before an update if | get visible before an update if | |||
there is another reason causing | there is another reason causing | |||
a window stack repaint. */ | a window stack repaint. */ | |||
DWCAPS_INPUTONLY = 0x00000004, /* The window has no surface. | DWCAPS_INPUTONLY = 0x00000004, /* The window has no surface. | |||
You can not draw to it but it | You can not draw to it but it | |||
receives events */ | receives events */ | |||
DWCAPS_NODECORATION = 0x00000008, /* The window won't be decorated. * / | DWCAPS_NODECORATION = 0x00000008, /* The window won't be decorated. * / | |||
DWCAPS_COLOR = 0x00000020, /* The window has no buffer; | DWCAPS_SUBWINDOW = 0x00000010, /* Not a top level window. */ | |||
it consumes no backing store. | ||||
It is filled with a constant col | ||||
or | ||||
and it receives events */ | ||||
DWCAPS_NOFOCUS = 0x00000100, /* Window will never get focus or r eceive key events, unless it grabs them. */ | DWCAPS_NOFOCUS = 0x00000100, /* Window will never get focus or r eceive key events, unless it grabs them. */ | |||
DWCAPS_ALL = 0x0000012F /* All of these. */ | DWCAPS_ALL = 0x0000011F /* All of these. */ | |||
} DFBWindowCapabilities; | } DFBWindowCapabilities; | |||
/* | /* | |||
* Flags controlling the appearance and behaviour of the window. | * Flags controlling the appearance and behaviour of the window. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DWOP_NONE = 0x00000000, /* none of these */ | DWOP_NONE = 0x00000000, /* none of these */ | |||
DWOP_COLORKEYING = 0x00000001, /* enable color key */ | DWOP_COLORKEYING = 0x00000001, /* enable color key */ | |||
DWOP_ALPHACHANNEL = 0x00000002, /* enable alpha blending using the | DWOP_ALPHACHANNEL = 0x00000002, /* enable alpha blending using the | |||
window's alpha channel */ | window's alpha channel */ | |||
skipping to change at line 920 | skipping to change at line 927 | |||
DWOP_GHOST = 0x00001000, /* never get focus or input, | DWOP_GHOST = 0x00001000, /* never get focus or input, | |||
clicks will go through, | clicks will go through, | |||
implies DWOP_KEEP... */ | implies DWOP_KEEP... */ | |||
DWOP_INDESTRUCTIBLE = 0x00002000, /* window can't be destroyed | DWOP_INDESTRUCTIBLE = 0x00002000, /* window can't be destroyed | |||
by internal shortcut */ | by internal shortcut */ | |||
DWOP_SCALE = 0x00010000, /* Surface won't be changed if wind ow size on screen changes. The surface | DWOP_SCALE = 0x00010000, /* Surface won't be changed if wind ow size on screen changes. The surface | |||
can be resized separately using IDirectFBWindow::ResizeSurface(). */ | can be resized separately using IDirectFBWindow::ResizeSurface(). */ | |||
DWOP_KEEP_ABOVE = 0x00100000, /* Keep window above parent window. */ | DWOP_KEEP_ABOVE = 0x00100000, /* Keep window above parent window. */ | |||
DWOP_KEEP_UNDER = 0x00200000, /* Keep window under parent window. */ | DWOP_KEEP_UNDER = 0x00200000, /* Keep window under parent window. */ | |||
DWOP_FOLLOW_BOUNDS = 0x00400000, /* Follow window bounds from parent . */ | ||||
DWOP_ALL = 0x0031307F /* all possible options */ | DWOP_ALL = 0x0071307F /* all possible options */ | |||
} DFBWindowOptions; | } DFBWindowOptions; | |||
/* | /* | |||
* The stacking class restricts the stacking order of windows. | * The stacking class restricts the stacking order of windows. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DWSC_MIDDLE = 0x00000000, /* This is the default stacking | DWSC_MIDDLE = 0x00000000, /* This is the default stacking | |||
class of new windows. */ | class of new windows. */ | |||
DWSC_UPPER = 0x00000001, /* Window is always above windows | DWSC_UPPER = 0x00000001, /* Window is always above windows | |||
in the middle stacking class. | in the middle stacking class. | |||
skipping to change at line 1163 | skipping to change at line 1171 | |||
#define DFB_PLANE_MULTIPLY(fmt,height) ((((((fmt) & 0x3C000000) >> 26) + 4 ) * (height)) >> 2) | #define DFB_PLANE_MULTIPLY(fmt,height) ((((((fmt) & 0x3C000000) >> 26) + 4 ) * (height)) >> 2) | |||
#define DFB_PIXELFORMAT_IS_INDEXED(fmt) (((fmt) & 0x40000000) != 0) | #define DFB_PIXELFORMAT_IS_INDEXED(fmt) (((fmt) & 0x40000000) != 0) | |||
#define DFB_PLANAR_PIXELFORMAT(fmt) (((fmt) & 0x3C000000) != 0) | #define DFB_PLANAR_PIXELFORMAT(fmt) (((fmt) & 0x3C000000) != 0) | |||
#define DFB_PIXELFORMAT_INV_ALPHA(fmt) (((fmt) & 0x80000000) != 0) | #define DFB_PIXELFORMAT_INV_ALPHA(fmt) (((fmt) & 0x80000000) != 0) | |||
/* | /* | |||
* Hint flags for optimized allocation, format selection etc. | ||||
*/ | ||||
typedef enum { | ||||
DSHF_NONE = 0x00000000, | ||||
DSHF_LAYER = 0x00000001, /* Surface optimized for | ||||
display layer usage */ | ||||
DSHF_WINDOW = 0x00000002, /* Surface optimized for | ||||
being a window buffer */ | ||||
DSHF_CURSOR = 0x00000004, /* Surface optimized for | ||||
usage as a cursor shape */ | ||||
DSHF_FONT = 0x00000008, /* Surface optimized for | ||||
text rendering */ | ||||
DSHF_ALL = 0x0000000F | ||||
} DFBSurfaceHintFlags; | ||||
/* | ||||
* Description of the surface that is to be created. | * Description of the surface that is to be created. | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
DFBSurfaceDescriptionFlags flags; /* field validation */ | DFBSurfaceDescriptionFlags flags; /* field validation */ | |||
DFBSurfaceCapabilities caps; /* capabilities */ | DFBSurfaceCapabilities caps; /* capabilities */ | |||
int width; /* pixel width */ | int width; /* pixel width */ | |||
int height; /* pixel height */ | int height; /* pixel height */ | |||
DFBSurfacePixelFormat pixelformat; /* pixel format */ | DFBSurfacePixelFormat pixelformat; /* pixel format */ | |||
skipping to change at line 1185 | skipping to change at line 1207 | |||
int pitch; /* pitch of buffer */ | int pitch; /* pitch of buffer */ | |||
} preallocated[2]; | } preallocated[2]; | |||
struct { | struct { | |||
const DFBColor *entries; | const DFBColor *entries; | |||
unsigned int size; | unsigned int size; | |||
} palette; /* initial palette */ | } palette; /* initial palette */ | |||
unsigned long resource_id; /* universal resourc e id, either user specified for general | unsigned long resource_id; /* universal resourc e id, either user specified for general | |||
purpose surfaces or id of layer or window */ | purpose surfaces or id of layer or window */ | |||
DFBSurfaceHintFlags hints; /* usage hints for opt | ||||
imized allocation, format selection etc. */ | ||||
} DFBSurfaceDescription; | } DFBSurfaceDescription; | |||
/* | /* | |||
* Description of the palette that is to be created. | * Description of the palette that is to be created. | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
DFBPaletteDescriptionFlags flags; /* Validation of field s. */ | DFBPaletteDescriptionFlags flags; /* Validation of field s. */ | |||
DFBPaletteCapabilities caps; /* Palette capabilitie s. */ | DFBPaletteCapabilities caps; /* Palette capabilitie s. */ | |||
unsigned int size; /* Number of entries. */ | unsigned int size; /* Number of entries. */ | |||
skipping to change at line 1359 | skipping to change at line 1383 | |||
int height; /* pixel height */ | int height; /* pixel height */ | |||
DFBSurfacePixelFormat pixelformat; /* pixel format */ | DFBSurfacePixelFormat pixelformat; /* pixel format */ | |||
int posx; /* distance from left layer border */ | int posx; /* distance from left layer border */ | |||
int posy; /* distance from uppe r layer border */ | int posy; /* distance from uppe r layer border */ | |||
DFBSurfaceCapabilities surface_caps; /* pixel format */ | DFBSurfaceCapabilities surface_caps; /* pixel format */ | |||
DFBWindowID parent_id; /* window id of paren t window */ | DFBWindowID parent_id; /* window id of paren t window */ | |||
DFBWindowOptions options; /* initial window opt ions */ | DFBWindowOptions options; /* initial window opt ions */ | |||
DFBWindowStackingClass stacking; /* initial stacking c lass */ | DFBWindowStackingClass stacking; /* initial stacking c lass */ | |||
unsigned long resource_id; /* resource id used t o create the window surface */ | unsigned long resource_id; /* resource id used t o create the window surface */ | |||
DFBWindowID toplevel_id; /* top level window, | ||||
if != 0 window will be a sub window */ | ||||
} DFBWindowDescription; | } DFBWindowDescription; | |||
/* | /* | |||
* Description of a data buffer that is to be created. | * Description of a data buffer that is to be created. | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
DFBDataBufferDescriptionFlags flags; /* field validation */ | DFBDataBufferDescriptionFlags flags; /* field validation */ | |||
const char *file; /* for file based data buffers */ | const char *file; /* for file based data buffers */ | |||
skipping to change at line 2999 | skipping to change at line 3025 | |||
DFBBoolean exclusive | DFBBoolean exclusive | |||
); | ); | |||
/** Rotation **/ | /** Rotation **/ | |||
/* | /* | |||
* Set the rotation of data within the layer. | * Set the rotation of data within the layer. | |||
* | * | |||
* Only available in exclusive or administrative mode. | * Only available in exclusive or administrative mode. | |||
* | * | |||
* Any <b>rotation</b> other than 0 or 180 is not supported yet. | * Any <b>rotation</b> other than 0, 90, 180 or 270 is not supported. | |||
* | * | |||
* No layer hardware feature usage, only rotated blitting yet. | * No layer hardware feature usage, only rotated blitting is used. | |||
*/ | */ | |||
DFBResult (*SetRotation) ( | DFBResult (*SetRotation) ( | |||
IDirectFBDisplayLayer *thiz, | IDirectFBDisplayLayer *thiz, | |||
int rotation | int rotation | |||
); | ); | |||
/* | ||||
* Get the rotation of data within the layer. | ||||
*/ | ||||
DFBResult (*GetRotation) ( | ||||
IDirectFBDisplayLayer *thiz, | ||||
int *ret_rotation | ||||
); | ||||
) | ) | |||
/* | /* | |||
* Flipping flags controlling the behaviour of IDirectFBSurface::Flip(). | * Flipping flags controlling the behaviour of IDirectFBSurface::Flip(). | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DSFLIP_NONE = 0x00000000, /* None of these. */ | DSFLIP_NONE = 0x00000000, /* None of these. */ | |||
DSFLIP_WAIT = 0x00000001, /* Flip() returns upon vertical syn c. Flipping is still done | DSFLIP_WAIT = 0x00000001, /* Flip() returns upon vertical syn c. Flipping is still done | |||
immediately unless DSFLIP_ONSYNC is specified, too. */ | immediately unless DSFLIP_ONSYNC is specified, too. */ | |||
DSFLIP_BLIT = 0x00000002, /* Copy from back buffer to front b uffer rather than | DSFLIP_BLIT = 0x00000002, /* Copy from back buffer to front b uffer rather than | |||
just swapping these buffers. Thi s behaviour is enforced | just swapping these buffers. Thi s behaviour is enforced | |||
if the region passed to Flip() i s not NULL or if the | if the region passed to Flip() i s not NULL or if the | |||
surface being flipped is a sub s urface. */ | surface being flipped is a sub s urface. */ | |||
DSFLIP_ONSYNC = 0x00000004, /* Do the actual flipping upon the next vertical sync. | DSFLIP_ONSYNC = 0x00000004, /* Do the actual flipping upon the next vertical sync. | |||
The Flip() method will still ret urn immediately unless | The Flip() method will still ret urn immediately unless | |||
DSFLIP_WAIT is specified, too. * / | DSFLIP_WAIT is specified, too. * / | |||
DSFLIP_PIPELINE = 0x00000008, | DSFLIP_PIPELINE = 0x00000008, | |||
DSFLIP_ONCE = 0x00000010, | ||||
DSFLIP_WAITFORSYNC = DSFLIP_WAIT | DSFLIP_ONSYNC | DSFLIP_WAITFORSYNC = DSFLIP_WAIT | DSFLIP_ONSYNC | |||
} DFBSurfaceFlipFlags; | } DFBSurfaceFlipFlags; | |||
/* | /* | |||
* Flags controlling the text layout. | * Flags controlling the text layout. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DSTF_LEFT = 0x00000000, /* left aligned */ | DSTF_LEFT = 0x00000000, /* left aligned */ | |||
DSTF_CENTER = 0x00000001, /* horizontally centered */ | DSTF_CENTER = 0x00000001, /* horizontally centered */ | |||
DSTF_RIGHT = 0x00000002, /* right aligned */ | DSTF_RIGHT = 0x00000002, /* right aligned */ | |||
skipping to change at line 3084 | skipping to change at line 3116 | |||
DSPD_SRC_OVER = 3, /* fs: 1.0 fd: 1.0-sa */ | DSPD_SRC_OVER = 3, /* fs: 1.0 fd: 1.0-sa */ | |||
DSPD_DST_OVER = 4, /* fs: 1.0-da fd: 1.0 */ | DSPD_DST_OVER = 4, /* fs: 1.0-da fd: 1.0 */ | |||
DSPD_SRC_IN = 5, /* fs: da fd: 0.0 */ | DSPD_SRC_IN = 5, /* fs: da fd: 0.0 */ | |||
DSPD_DST_IN = 6, /* fs: 0.0 fd: sa */ | DSPD_DST_IN = 6, /* fs: 0.0 fd: sa */ | |||
DSPD_SRC_OUT = 7, /* fs: 1.0-da fd: 0.0 */ | DSPD_SRC_OUT = 7, /* fs: 1.0-da fd: 0.0 */ | |||
DSPD_DST_OUT = 8, /* fs: 0.0 fd: 1.0-sa */ | DSPD_DST_OUT = 8, /* fs: 0.0 fd: 1.0-sa */ | |||
DSPD_SRC_ATOP = 9, /* fs: da fd: 1.0-sa */ | DSPD_SRC_ATOP = 9, /* fs: da fd: 1.0-sa */ | |||
DSPD_DST_ATOP = 10, /* fs: 1.0-da fd: sa */ | DSPD_DST_ATOP = 10, /* fs: 1.0-da fd: sa */ | |||
DSPD_ADD = 11, /* fs: 1.0 fd: 1.0 */ | DSPD_ADD = 11, /* fs: 1.0 fd: 1.0 */ | |||
DSPD_XOR = 12, /* fs: 1.0-da fd: 1.0-sa */ | DSPD_XOR = 12, /* fs: 1.0-da fd: 1.0-sa */ | |||
DSPD_DST = 13, /* fs: 0.0 fd: 1.0 */ | ||||
} DFBSurfacePorterDuffRule; | } DFBSurfacePorterDuffRule; | |||
/* | /* | |||
* Blend functions to use for source and destination blending | * Blend functions to use for source and destination blending | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
/* | DSBF_UNKNOWN = 0, /* */ | |||
* pixel color = sc * cf[sf] + dc * cf[df] | DSBF_ZERO = 1, /* */ | |||
* pixel alpha = sa * af[sf] + da * af[df] | DSBF_ONE = 2, /* */ | |||
* sc = source color | DSBF_SRCCOLOR = 3, /* */ | |||
* sa = source alpha | DSBF_INVSRCCOLOR = 4, /* */ | |||
* dc = destination color | DSBF_SRCALPHA = 5, /* */ | |||
* da = destination alpha | DSBF_INVSRCALPHA = 6, /* */ | |||
* sf = source blend function | DSBF_DESTALPHA = 7, /* */ | |||
* df = destination blend function | DSBF_INVDESTALPHA = 8, /* */ | |||
* cf[x] = color factor for blend function x | DSBF_DESTCOLOR = 9, /* */ | |||
* af[x] = alpha factor for blend function x | DSBF_INVDESTCOLOR = 10, /* */ | |||
*/ | DSBF_SRCALPHASAT = 11 /* */ | |||
DSBF_UNKNOWN = 0, /* */ | ||||
DSBF_ZERO = 1, /* cf: 0 af: 0 */ | ||||
DSBF_ONE = 2, /* cf: 1 af: 1 */ | ||||
DSBF_SRCCOLOR = 3, /* cf: sc af: sa */ | ||||
DSBF_INVSRCCOLOR = 4, /* cf: 1-sc af: 1-sa */ | ||||
DSBF_SRCALPHA = 5, /* cf: sa af: sa */ | ||||
DSBF_INVSRCALPHA = 6, /* cf: 1-sa af: 1-sa */ | ||||
DSBF_DESTALPHA = 7, /* cf: da af: da */ | ||||
DSBF_INVDESTALPHA = 8, /* cf: 1-da af: 1-da */ | ||||
DSBF_DESTCOLOR = 9, /* cf: dc af: da */ | ||||
DSBF_INVDESTCOLOR = 10, /* cf: 1-dc af: 1-da */ | ||||
DSBF_SRCALPHASAT = 11, /* cf: min(sa, 1-da) af: 1 */ | ||||
} DFBSurfaceBlendFunction; | } DFBSurfaceBlendFunction; | |||
/* | /* | |||
* Transformed vertex of a textured triangle. | * Transformed vertex of a textured triangle. | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
float x; /* Destination X coordinate (in pixels) */ | float x; /* Destination X coordinate (in pixels) */ | |||
float y; /* Destination Y coordinate (in pixels) */ | float y; /* Destination Y coordinate (in pixels) */ | |||
float z; /* Z coordinate */ | float z; /* Z coordinate */ | |||
float w; /* W coordinate */ | float w; /* W coordinate */ | |||
skipping to change at line 3905 | skipping to change at line 3924 | |||
/** Lightweight helpers **/ | /** Lightweight helpers **/ | |||
/* | /* | |||
* Make this a sub surface or adjust the rectangle of this sub surface . | * Make this a sub surface or adjust the rectangle of this sub surface . | |||
*/ | */ | |||
DFBResult (*MakeSubSurface) ( | DFBResult (*MakeSubSurface) ( | |||
IDirectFBSurface *thiz, | IDirectFBSurface *thiz, | |||
IDirectFBSurface *from, | IDirectFBSurface *from, | |||
const DFBRectangle *rect | const DFBRectangle *rect | |||
); | ); | |||
/** Direct Write/Read **/ | ||||
/* | ||||
* Write to the surface without the need for (Un)Lock. | ||||
* | ||||
* <b>rect</b> defines the area inside the surface. | ||||
* <br><b>ptr</b> and <b>pitch</b> specify the source. | ||||
* <br>The format of the surface and the source data must be the same. | ||||
*/ | ||||
DFBResult (*Write) ( | ||||
IDirectFBSurface *thiz, | ||||
const DFBRectangle *rect, | ||||
const void *ptr, | ||||
int pitch | ||||
); | ||||
/* | ||||
* Read from the surface without the need for (Un)Lock. | ||||
* | ||||
* <b>rect</b> defines the area inside the surface to be read. | ||||
* <br><b>ptr</b> and <b>pitch</b> specify the destination. | ||||
* <br>The destination data will have the same format as the surface. | ||||
*/ | ||||
DFBResult (*Read) ( | ||||
IDirectFBSurface *thiz, | ||||
const DFBRectangle *rect, | ||||
void *ptr, | ||||
int pitch | ||||
); | ||||
) | ) | |||
/******************** | /******************** | |||
* IDirectFBPalette * | * IDirectFBPalette * | |||
********************/ | ********************/ | |||
/* | /* | |||
* <i>No summary yet...</i> | * <i>No summary yet...</i> | |||
*/ | */ | |||
DEFINE_INTERFACE( IDirectFBPalette, | DEFINE_INTERFACE( IDirectFBPalette, | |||
skipping to change at line 4393 | skipping to change at line 4382 | |||
DWET_ALL = 0x003F033F /* all event types */ | DWET_ALL = 0x003F033F /* all event types */ | |||
} DFBWindowEventType; | } DFBWindowEventType; | |||
/* | /* | |||
* Flags for a window event. | * Flags for a window event. | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DWEF_NONE = 0x00000000, /* none of these */ | DWEF_NONE = 0x00000000, /* none of these */ | |||
DWEF_RETURNED = 0x00000001, /* This is a returned event, e.g. u nconsumed key. */ | DWEF_RETURNED = 0x00000001, /* This is a returned event, e.g. u nconsumed key. */ | |||
DWEF_REPEAT = 0x00000010, /* repeat event, e.g. repeating key */ | ||||
DWEF_ALL = 0x00000011 /* all of these */ | DWEF_ALL = 0x00000001 /* all of these */ | |||
} DFBWindowEventFlags; | } DFBWindowEventFlags; | |||
/* | /* | |||
* Video Provider Event Types - can also be used as flags for event filters . | * Video Provider Event Types - can also be used as flags for event filters . | |||
*/ | */ | |||
typedef enum { | typedef enum { | |||
DVPET_NONE = 0x00000000, | DVPET_NONE = 0x00000000, | |||
DVPET_STARTED = 0x00000001, /* The video provider has started the playback */ | DVPET_STARTED = 0x00000001, /* The video provider has started the playback */ | |||
DVPET_STOPPED = 0x00000002, /* The video provider has stopped the playback */ | DVPET_STOPPED = 0x00000002, /* The video provider has stopped the playback */ | |||
DVPET_SPEEDCHANGE = 0x00000004, /* A speed change has occured */ | DVPET_SPEEDCHANGE = 0x00000004, /* A speed change has occured */ | |||
skipping to change at line 4428 | skipping to change at line 4416 | |||
DVPET_ALL = 0x00007FFF /* All event types */ | DVPET_ALL = 0x00007FFF /* All event types */ | |||
} DFBVideoProviderEventType; | } DFBVideoProviderEventType; | |||
/* | /* | |||
* Event from the windowing system. | * Event from the windowing system. | |||
*/ | */ | |||
typedef struct { | typedef struct { | |||
DFBEventClass clazz; /* clazz of event */ | DFBEventClass clazz; /* clazz of event */ | |||
DFBWindowEventType type; /* type of event */ | DFBWindowEventType type; /* type of event */ | |||
/* used by DWET_KEYDOWN, DWET_KEYUP */ | ||||
DFBWindowEventFlags flags; /* event flags */ | DFBWindowEventFlags flags; /* event flags */ | |||
DFBWindowID window_id; /* source of event */ | DFBWindowID window_id; /* source of event */ | |||
/* used by DWET_MOVE, DWET_MOTION, DWET_BUTTONDOWN, DWET_BUTTONUP, | /* used by DWET_MOVE, DWET_MOTION, DWET_BUTTONDOWN, DWET_BUTTONUP, | |||
DWET_ENTER, DWET_LEAVE */ | DWET_ENTER, DWET_LEAVE */ | |||
int x; /* x position of window | int x; /* x position of window | |||
or coordinate within | or coordinate within | |||
window */ | window */ | |||
int y; /* y position of window | int y; /* y position of window | |||
skipping to change at line 4778 | skipping to change at line 4764 | |||
/* | /* | |||
* Get the size of the window in pixels. | * Get the size of the window in pixels. | |||
*/ | */ | |||
DFBResult (*GetSize) ( | DFBResult (*GetSize) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
int *ret_width, | int *ret_width, | |||
int *ret_height | int *ret_height | |||
); | ); | |||
/** Event handling **/ | /** Close & Destroy **/ | |||
/* | ||||
* Send a close message to the window. | ||||
* | ||||
* This function sends a message of type DWET_CLOSE to the window. | ||||
* It does NOT actually close it. | ||||
*/ | ||||
DFBResult (*Close) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Destroys the window and sends a destruction message. | ||||
* | ||||
* This function sends a message of type DWET_DESTROY to | ||||
* the window after removing it from the window stack and | ||||
* freeing its data. Some functions called from this | ||||
* interface will return DFB_DESTROYED after that. | ||||
*/ | ||||
DFBResult (*Destroy) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/** Surface & Scaling **/ | ||||
/* | ||||
* Get an interface to the backing store surface. | ||||
* | ||||
* This surface has to be flipped to make previous drawing | ||||
* commands visible, i.e. to repaint the windowstack for | ||||
* that region. | ||||
*/ | ||||
DFBResult (*GetSurface) ( | ||||
IDirectFBWindow *thiz, | ||||
IDirectFBSurface **ret_surface | ||||
); | ||||
/* | ||||
* Resize the surface of a scalable window. | ||||
* | ||||
* This requires the option DWOP_SCALE. | ||||
* See IDirectFBWindow::SetOptions(). | ||||
*/ | ||||
DFBResult (*ResizeSurface) ( | ||||
IDirectFBWindow *thiz, | ||||
int width, | ||||
int height | ||||
); | ||||
/** Events **/ | ||||
/* | /* | |||
* Create an event buffer for this window and attach it. | * Create an event buffer for this window and attach it. | |||
*/ | */ | |||
DFBResult (*CreateEventBuffer) ( | DFBResult (*CreateEventBuffer) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
IDirectFBEventBuffer **ret_buffer | IDirectFBEventBuffer **ret_buffer | |||
); | ); | |||
/* | /* | |||
skipping to change at line 4829 | skipping to change at line 4865 | |||
* Disable specific events from being sent to the window. | * Disable specific events from being sent to the window. | |||
* | * | |||
* The argument is a mask of events that will be cleared in | * The argument is a mask of events that will be cleared in | |||
* the window's event mask. The default event mask is DWET_ALL. | * the window's event mask. The default event mask is DWET_ALL. | |||
*/ | */ | |||
DFBResult (*DisableEvents) ( | DFBResult (*DisableEvents) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
DFBWindowEventType mask | DFBWindowEventType mask | |||
); | ); | |||
/** Surface handling **/ | /** Options **/ | |||
/* | ||||
* Get an interface to the backing store surface. | ||||
* | ||||
* This surface has to be flipped to make previous drawing | ||||
* commands visible, i.e. to repaint the windowstack for | ||||
* that region. | ||||
*/ | ||||
DFBResult (*GetSurface) ( | ||||
IDirectFBWindow *thiz, | ||||
IDirectFBSurface **ret_surface | ||||
); | ||||
/** Appearance and Behaviour **/ | ||||
/* | ||||
* Set property controlling appearance and behaviour of the window. | ||||
*/ | ||||
DFBResult (*SetProperty) ( | ||||
IDirectFBWindow *thiz, | ||||
const char *key, | ||||
void *value, | ||||
void **ret_old_value | ||||
); | ||||
/* | ||||
* Get property controlling appearance and behaviour of the window. | ||||
*/ | ||||
DFBResult (*GetProperty) ( | ||||
IDirectFBWindow *thiz, | ||||
const char *key, | ||||
void **ret_value | ||||
); | ||||
/* | ||||
* Remove property controlling appearance and behaviour of the window. | ||||
*/ | ||||
DFBResult (*RemoveProperty) ( | ||||
IDirectFBWindow *thiz, | ||||
const char *key, | ||||
void **ret_value | ||||
); | ||||
/* | /* | |||
* Set options controlling appearance and behaviour of the window. | * Set options controlling appearance and behaviour of the window. | |||
*/ | */ | |||
DFBResult (*SetOptions) ( | DFBResult (*SetOptions) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
DFBWindowOptions options | DFBWindowOptions options | |||
); | ); | |||
/* | /* | |||
* Get options controlling appearance and behaviour of the window. | * Get options controlling appearance and behaviour of the window. | |||
*/ | */ | |||
DFBResult (*GetOptions) ( | DFBResult (*GetOptions) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
DFBWindowOptions *ret_options | DFBWindowOptions *ret_options | |||
); | ); | |||
/* | /* | |||
* Set the window color, or colorises the window. | ||||
* | ||||
* In case you specified DWCAPS_COLOR, this sets the window draw color | ||||
. | ||||
* In case you didn't, it colorises the window with this color; this w | ||||
ill darken the window. | ||||
* no DWCAPS_COLOR and an opacity of 0 means: no effect. | ||||
*/ | ||||
DFBResult (*SetColor) ( | ||||
IDirectFBWindow *thiz, | ||||
u8 r, | ||||
u8 g, | ||||
u8 b, | ||||
u8 a | ||||
); | ||||
/* | ||||
* Set the window color key. | * Set the window color key. | |||
* | * | |||
* If a pixel of the window matches this color the | * If a pixel of the window matches this color the | |||
* underlying window or the background is visible at this | * underlying window or the background is visible at this | |||
* point. | * point. | |||
*/ | */ | |||
DFBResult (*SetColorKey) ( | DFBResult (*SetColorKey) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
u8 r, | u8 r, | |||
u8 g, | u8 g, | |||
skipping to change at line 4983 | skipping to change at line 4962 | |||
* | * | |||
* Passing NULL will unbind a set shape and release its surface. | * Passing NULL will unbind a set shape and release its surface. | |||
*/ | */ | |||
DFBResult (*SetCursorShape) ( | DFBResult (*SetCursorShape) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
IDirectFBSurface *shape, | IDirectFBSurface *shape, | |||
int hot_x, | int hot_x, | |||
int hot_y | int hot_y | |||
); | ); | |||
/** Focus handling **/ | ||||
/* | ||||
* Pass the focus to this window. | ||||
*/ | ||||
DFBResult (*RequestFocus) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Grab the keyboard, i.e. all following keyboard events are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabKeyboard) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Ungrab the keyboard, i.e. switch to standard key event | ||||
* dispatching. | ||||
*/ | ||||
DFBResult (*UngrabKeyboard) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Grab the pointer, i.e. all following mouse events are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabPointer) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Ungrab the pointer, i.e. switch to standard mouse event | ||||
* dispatching. | ||||
*/ | ||||
DFBResult (*UngrabPointer) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Grab a specific key, i.e. all following events of this key are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabKey) ( | ||||
IDirectFBWindow *thiz, | ||||
DFBInputDeviceKeySymbol symbol, | ||||
DFBInputDeviceModifierMask modifiers | ||||
); | ||||
/* | ||||
* Ungrab a specific key, i.e. switch to standard key event | ||||
* dispatching. | ||||
*/ | ||||
DFBResult (*UngrabKey) ( | ||||
IDirectFBWindow *thiz, | ||||
DFBInputDeviceKeySymbol symbol, | ||||
DFBInputDeviceModifierMask modifiers | ||||
); | ||||
/** Position and Size **/ | /** Position and Size **/ | |||
/* | /* | |||
* Move the window by the specified distance. | * Move the window by the specified distance. | |||
*/ | */ | |||
DFBResult (*Move) ( | DFBResult (*Move) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
int dx, | int dx, | |||
int dy | int dy | |||
); | ); | |||
skipping to change at line 5073 | skipping to change at line 4991 | |||
/* | /* | |||
* Resize the window. | * Resize the window. | |||
*/ | */ | |||
DFBResult (*Resize) ( | DFBResult (*Resize) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
int width, | int width, | |||
int height | int height | |||
); | ); | |||
/* | ||||
* Set position and size in one step. | ||||
*/ | ||||
DFBResult (*SetBounds) ( | ||||
IDirectFBWindow *thiz, | ||||
int x, | ||||
int y, | ||||
int width, | ||||
int height | ||||
); | ||||
/** Stacking **/ | /** Stacking **/ | |||
/* | /* | |||
* Put the window into a specific stacking class. | * Put the window into a specific stacking class. | |||
*/ | */ | |||
DFBResult (*SetStackingClass) ( | DFBResult (*SetStackingClass) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
DFBWindowStackingClass stacking_class | DFBWindowStackingClass stacking_class | |||
); | ); | |||
skipping to change at line 5127 | skipping to change at line 5056 | |||
); | ); | |||
/* | /* | |||
* Put a window below another window. | * Put a window below another window. | |||
*/ | */ | |||
DFBResult (*PutBelow) ( | DFBResult (*PutBelow) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
IDirectFBWindow *upper | IDirectFBWindow *upper | |||
); | ); | |||
/** Closing **/ | /** Binding **/ | |||
/* | /* | |||
* Send a close message to the window. | * Bind a window at the specified position of this window. | |||
* | * | |||
* This function sends a message of type DWET_CLOSE to the window. | * After binding, bound window will be automatically moved | |||
* It does NOT actually close it. | * when this window moves to a new position.<br> | |||
* Binding the same window to multiple windows is not supported. | ||||
* Subsequent call to Bind() automatically unbounds the bound window | ||||
* before binding it again.<br> | ||||
* To move the bound window to a new position call Bind() again | ||||
* with the new coordinates. | ||||
*/ | */ | |||
DFBResult (*Close) ( | DFBResult (*Bind) ( | |||
IDirectFBWindow *thiz | IDirectFBWindow *thiz, | |||
IDirectFBWindow *window, | ||||
int x, | ||||
int y | ||||
); | ); | |||
/* | /* | |||
* Destroys the window and sends a destruction message. | * Unbind a window from this window. | |||
* | ||||
* This function sends a message of type DWET_DESTROY to | ||||
* the window after removing it from the window stack and | ||||
* freeing its data. Some functions called from this | ||||
* interface will return DFB_DESTROYED after that. | ||||
*/ | */ | |||
DFBResult (*Destroy) ( | DFBResult (*Unbind) ( | |||
IDirectFBWindow *thiz | IDirectFBWindow *thiz, | |||
IDirectFBWindow *window | ||||
); | ); | |||
/** Geometry **/ | /** Focus handling **/ | |||
/* | /* | |||
* Set position and size in one step. | * Pass the focus to this window. | |||
*/ | */ | |||
DFBResult (*SetBounds) ( | DFBResult (*RequestFocus) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz | |||
int x, | ||||
int y, | ||||
int width, | ||||
int height | ||||
); | ); | |||
/** Scaling **/ | /* | |||
* Grab the keyboard, i.e. all following keyboard events are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabKeyboard) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | /* | |||
* Resize the surface of a scalable window. | * Ungrab the keyboard, i.e. switch to standard key event | |||
* | * dispatching. | |||
* This requires the option DWOP_SCALE. | ||||
* See IDirectFBWindow::SetOptions(). | ||||
*/ | */ | |||
DFBResult (*ResizeSurface) ( | DFBResult (*UngrabKeyboard) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz | |||
int width, | ||||
int height | ||||
); | ); | |||
/** Binding **/ | /* | |||
* Grab the pointer, i.e. all following mouse events are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabPointer) ( | ||||
IDirectFBWindow *thiz | ||||
); | ||||
/* | /* | |||
* Bind a window at the specified position of this window. | * Ungrab the pointer, i.e. switch to standard mouse event | |||
* | * dispatching. | |||
* After binding, bound window will be automatically moved | ||||
* when this window moves to a new position.<br> | ||||
* Binding the same window to multiple windows is not supported. | ||||
* Subsequent call to Bind() automatically unbounds the bound window | ||||
* before binding it again.<br> | ||||
* To move the bound window to a new position call Bind() again | ||||
* with the new coordinates. | ||||
*/ | */ | |||
DFBResult (*Bind) ( | DFBResult (*UngrabPointer) ( | |||
IDirectFBWindow *thiz | ||||
); | ||||
/* | ||||
* Grab a specific key, i.e. all following events of this key are | ||||
* sent to this window ignoring the focus. | ||||
*/ | ||||
DFBResult (*GrabKey) ( | ||||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
IDirectFBWindow *window, | DFBInputDeviceKeySymbol symbol, | |||
int x, | DFBInputDeviceModifierMask modifiers | |||
int y | ||||
); | ); | |||
/* | /* | |||
* Unbind a window from this window. | * Ungrab a specific key, i.e. switch to standard key event | |||
* dispatching. | ||||
*/ | */ | |||
DFBResult (*Unbind) ( | DFBResult (*UngrabKey) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
IDirectFBWindow *window | DFBInputDeviceKeySymbol symbol, | |||
DFBInputDeviceModifierMask modifiers | ||||
); | ); | |||
/** Key selection **/ | /** Key selection **/ | |||
/* | /* | |||
* Selects a mode for filtering keys while being focused. | * Selects a mode for filtering keys while being focused. | |||
* | * | |||
* The <b>selection</b> defines whether all, none or a specific set (l ist) of keys is selected. | * The <b>selection</b> defines whether all, none or a specific set (l ist) of keys is selected. | |||
* In case of a specific set, the <b>keys</b> array with <b>num_keys</ b> has to be provided. | * In case of a specific set, the <b>keys</b> array with <b>num_keys</ b> has to be provided. | |||
* | * | |||
skipping to change at line 5266 | skipping to change at line 5205 | |||
/* | /* | |||
* Set destination location of window within its bounds. | * Set destination location of window within its bounds. | |||
* | * | |||
* Default and maximum is to fill whole bounds. | * Default and maximum is to fill whole bounds. | |||
*/ | */ | |||
DFBResult (*SetDstGeometry) ( | DFBResult (*SetDstGeometry) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
const DFBWindowGeometry *geometry | const DFBWindowGeometry *geometry | |||
); | ); | |||
/** Association **/ | /** Properties **/ | |||
/* | /* | |||
* Change the window association. | * Set property controlling appearance and behaviour of the window. | |||
* | ||||
* If <b>window_id</b> is 0, the window will be dissociated. | ||||
*/ | */ | |||
DFBResult (*SetAssociation) ( | DFBResult (*SetProperty) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
DFBWindowID window_id | const char *key, | |||
void *value, | ||||
void **ret_old_value | ||||
); | ); | |||
/** Application ID **/ | /* | |||
* Get property controlling appearance and behaviour of the window. | ||||
*/ | ||||
DFBResult (*GetProperty) ( | ||||
IDirectFBWindow *thiz, | ||||
const char *key, | ||||
void **ret_value | ||||
); | ||||
/* | /* | |||
* Set application ID. | * Remove property controlling appearance and behaviour of the window. | |||
* | ||||
* The usage of the application ID is not imposed by DirectFB | ||||
* and can be used at will by the application. Any change will | ||||
* be notified, and as such, an application manager using SaWMan | ||||
* can be used to act on any change. | ||||
*/ | */ | |||
DFBResult (*SetApplicationID) ( | DFBResult (*RemoveProperty) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
unsigned long application_id | const char *key, | |||
void **ret_value | ||||
); | ); | |||
/* | /* | |||
* Get current application ID. | * Set window rotation. | |||
*/ | */ | |||
DFBResult (*GetApplicationID) ( | DFBResult (*SetRotation) ( | |||
IDirectFBWindow *thiz, | IDirectFBWindow *thiz, | |||
unsigned long *ret_application_id | int rotation | |||
); | ); | |||
) | ) | |||
/* | /* | |||
* Called for each provided text encoding. | * Called for each provided text encoding. | |||
*/ | */ | |||
typedef DFBEnumerationResult (*DFBTextEncodingCallback) ( | typedef DFBEnumerationResult (*DFBTextEncodingCallback) ( | |||
DFBTextEncodingID encoding_id, | DFBTextEncodingID encoding_id, | |||
const char *name, | const char *name, | |||
void *context | void *context | |||
End of changes. 57 change blocks. | ||||
260 lines changed or deleted | 207 lines changed or added | |||
directfb_strings.h | directfb_strings.h | |||
---|---|---|---|---|
skipping to change at line 89 | skipping to change at line 89 | |||
{ DSBLIT_COLORIZE, "COLORIZE" }, \ | { DSBLIT_COLORIZE, "COLORIZE" }, \ | |||
{ DSBLIT_SRC_COLORKEY, "SRC_COLORKEY" }, \ | { DSBLIT_SRC_COLORKEY, "SRC_COLORKEY" }, \ | |||
{ DSBLIT_DST_COLORKEY, "DST_COLORKEY" }, \ | { DSBLIT_DST_COLORKEY, "DST_COLORKEY" }, \ | |||
{ DSBLIT_SRC_PREMULTIPLY, "SRC_PREMULTIPLY" }, \ | { DSBLIT_SRC_PREMULTIPLY, "SRC_PREMULTIPLY" }, \ | |||
{ DSBLIT_DST_PREMULTIPLY, "DST_PREMULTIPLY" }, \ | { DSBLIT_DST_PREMULTIPLY, "DST_PREMULTIPLY" }, \ | |||
{ DSBLIT_DEMULTIPLY, "DEMULTIPLY" }, \ | { DSBLIT_DEMULTIPLY, "DEMULTIPLY" }, \ | |||
{ DSBLIT_DEINTERLACE, "DEINTERLACE" }, \ | { DSBLIT_DEINTERLACE, "DEINTERLACE" }, \ | |||
{ DSBLIT_SRC_PREMULTCOLOR, "SRC_PREMULTCOLOR" }, \ | { DSBLIT_SRC_PREMULTCOLOR, "SRC_PREMULTCOLOR" }, \ | |||
{ DSBLIT_XOR, "XOR" }, \ | { DSBLIT_XOR, "XOR" }, \ | |||
{ DSBLIT_INDEX_TRANSLATION, "INDEX_TRANSLATION" }, \ | { DSBLIT_INDEX_TRANSLATION, "INDEX_TRANSLATION" }, \ | |||
{ DSBLIT_ROTATE90, "ROTATE90" }, \ | ||||
{ DSBLIT_ROTATE180, "ROTATE180" }, \ | { DSBLIT_ROTATE180, "ROTATE180" }, \ | |||
{ DSBLIT_ROTATE270, "ROTATE270" }, \ | ||||
{ DSBLIT_COLORKEY_PROTECT, "COLORKEY_PROTECT" }, \ | { DSBLIT_COLORKEY_PROTECT, "COLORKEY_PROTECT" }, \ | |||
{ DSBLIT_SRC_MASK_ALPHA, "SRC_MASK_ALPHA" }, \ | { DSBLIT_SRC_MASK_ALPHA, "SRC_MASK_ALPHA" }, \ | |||
{ DSBLIT_SRC_MASK_COLOR, "SRC_MASK_COLOR" }, \ | { DSBLIT_SRC_MASK_COLOR, "SRC_MASK_COLOR" }, \ | |||
{ DSBLIT_NOFX, "NOFX" } \ | { DSBLIT_NOFX, "NOFX" } \ | |||
}; | }; | |||
struct DFBSurfaceBlendFunctionName { | struct DFBSurfaceBlendFunctionName { | |||
DFBSurfaceBlendFunction function; | DFBSurfaceBlendFunction function; | |||
const char *name; | const char *name; | |||
}; | }; | |||
skipping to change at line 195 | skipping to change at line 197 | |||
struct DFBWindowCapabilitiesName { | struct DFBWindowCapabilitiesName { | |||
DFBWindowCapabilities capability; | DFBWindowCapabilities capability; | |||
const char *name; | const char *name; | |||
}; | }; | |||
#define DirectFBWindowCapabilitiesNames(Identifier) struct DFBWindowCapabil itiesName Identifier[] = { \ | #define DirectFBWindowCapabilitiesNames(Identifier) struct DFBWindowCapabil itiesName Identifier[] = { \ | |||
{ DWCAPS_ALPHACHANNEL, "ALPHACHANNEL" }, \ | { DWCAPS_ALPHACHANNEL, "ALPHACHANNEL" }, \ | |||
{ DWCAPS_DOUBLEBUFFER, "DOUBLEBUFFER" }, \ | { DWCAPS_DOUBLEBUFFER, "DOUBLEBUFFER" }, \ | |||
{ DWCAPS_INPUTONLY, "INPUTONLY" }, \ | { DWCAPS_INPUTONLY, "INPUTONLY" }, \ | |||
{ DWCAPS_NODECORATION, "NODECORATION" }, \ | { DWCAPS_NODECORATION, "NODECORATION" }, \ | |||
{ DWCAPS_COLOR, "COLOR" }, \ | { DWCAPS_SUBWINDOW, "SUBWINDOW" }, \ | |||
{ DWCAPS_NOFOCUS, "NOFOCUS" }, \ | { DWCAPS_NOFOCUS, "NOFOCUS" }, \ | |||
{ DWCAPS_NONE, "NONE" } \ | { DWCAPS_NONE, "NONE" } \ | |||
}; | }; | |||
struct DFBWindowOptionsName { | struct DFBWindowOptionsName { | |||
DFBWindowOptions option; | DFBWindowOptions option; | |||
const char *name; | const char *name; | |||
}; | }; | |||
#define DirectFBWindowOptionsNames(Identifier) struct DFBWindowOptionsName Identifier[] = { \ | #define DirectFBWindowOptionsNames(Identifier) struct DFBWindowOptionsName Identifier[] = { \ | |||
skipping to change at line 219 | skipping to change at line 221 | |||
{ DWOP_SHAPED, "SHAPED" }, \ | { DWOP_SHAPED, "SHAPED" }, \ | |||
{ DWOP_ALPHACHANNEL, "ALPHACHANNEL" }, \ | { DWOP_ALPHACHANNEL, "ALPHACHANNEL" }, \ | |||
{ DWOP_KEEP_POSITION, "KEEP_POSITION" }, \ | { DWOP_KEEP_POSITION, "KEEP_POSITION" }, \ | |||
{ DWOP_KEEP_SIZE, "KEEP_SIZE" }, \ | { DWOP_KEEP_SIZE, "KEEP_SIZE" }, \ | |||
{ DWOP_KEEP_STACKING, "KEEP_STACKING" }, \ | { DWOP_KEEP_STACKING, "KEEP_STACKING" }, \ | |||
{ DWOP_GHOST, "GHOST" }, \ | { DWOP_GHOST, "GHOST" }, \ | |||
{ DWOP_INDESTRUCTIBLE, "INDESTRUCTIBLE" }, \ | { DWOP_INDESTRUCTIBLE, "INDESTRUCTIBLE" }, \ | |||
{ DWOP_SCALE, "SCALE" }, \ | { DWOP_SCALE, "SCALE" }, \ | |||
{ DWOP_KEEP_ABOVE, "KEEP_ABOVE" }, \ | { DWOP_KEEP_ABOVE, "KEEP_ABOVE" }, \ | |||
{ DWOP_KEEP_UNDER, "KEEP_UNDER" }, \ | { DWOP_KEEP_UNDER, "KEEP_UNDER" }, \ | |||
{ DWOP_FOLLOW_BOUNDS, "FOLLOW_BOUNDS" }, \ | ||||
{ DWOP_NONE, "NONE" } \ | { DWOP_NONE, "NONE" } \ | |||
}; | }; | |||
struct DFBScreenCapabilitiesName { | struct DFBScreenCapabilitiesName { | |||
DFBScreenCapabilities capability; | DFBScreenCapabilities capability; | |||
const char *name; | const char *name; | |||
}; | }; | |||
#define DirectFBScreenCapabilitiesNames(Identifier) struct DFBScreenCapabil itiesName Identifier[] = { \ | #define DirectFBScreenCapabilitiesNames(Identifier) struct DFBScreenCapabil itiesName Identifier[] = { \ | |||
{ DSCCAPS_VSYNC, "VSYNC" }, \ | { DSCCAPS_VSYNC, "VSYNC" }, \ | |||
End of changes. 4 change blocks. | ||||
1 lines changed or deleted | 4 lines changed or added | |||
directfb_util.h | directfb_util.h | |||
---|---|---|---|---|
skipping to change at line 200 | skipping to change at line 200 | |||
D_ASSERT( rect->w > 0 ); | D_ASSERT( rect->w > 0 ); | |||
D_ASSERT( rect->h > 0 ); | D_ASSERT( rect->h > 0 ); | |||
region->x1 = rect->x; | region->x1 = rect->x; | |||
region->y1 = rect->y; | region->y1 = rect->y; | |||
region->x2 = rect->x + rect->w - 1; | region->x2 = rect->x + rect->w - 1; | |||
region->y2 = rect->y + rect->h - 1; | region->y2 = rect->y + rect->h - 1; | |||
} | } | |||
static inline void dfb_region_from_rotated( DFBRegion *region, | ||||
const DFBRegion *from, | ||||
const DFBDimension *size, | ||||
int rotation ) | ||||
{ | ||||
D_ASSERT( region != NULL ); | ||||
DFB_REGION_ASSERT( from ); | ||||
D_ASSERT( size != NULL ); | ||||
D_ASSERT( size->w > 0 ); | ||||
D_ASSERT( size->h > 0 ); | ||||
D_ASSUME( rotation == 0 || rotation == 90 || rotation == 180 || rotati | ||||
on == 270 ); | ||||
switch (rotation) { | ||||
default: | ||||
D_BUG( "invalid rotation %d", rotation ); | ||||
case 0: | ||||
*region = *from; | ||||
break; | ||||
case 90: | ||||
region->x1 = from->y1; | ||||
region->y1 = size->w - from->x2 - 1; | ||||
region->x2 = from->y2; | ||||
region->y2 = size->w - from->x1 - 1; | ||||
break; | ||||
case 180: | ||||
region->x1 = size->w - from->x2 - 1; | ||||
region->y1 = size->h - from->y2 - 1; | ||||
region->x2 = size->w - from->x1 - 1; | ||||
region->y2 = size->h - from->y1 - 1; | ||||
break; | ||||
case 270: | ||||
region->x1 = size->h - from->y2 - 1; | ||||
region->y1 = from->x1; | ||||
region->x2 = size->h - from->y1 - 1; | ||||
region->y2 = from->x2; | ||||
break; | ||||
} | ||||
DFB_REGION_ASSERT( region ); | ||||
} | ||||
static inline void dfb_rectangle_from_rotated( DFBRectangle *rectangl | ||||
e, | ||||
const DFBRectangle *from, | ||||
const DFBDimension *size, | ||||
int rotation | ||||
) | ||||
{ | ||||
D_ASSERT( rectangle != NULL ); | ||||
DFB_RECTANGLE_ASSERT( from ); | ||||
D_ASSERT( size != NULL ); | ||||
D_ASSERT( size->w > 0 ); | ||||
D_ASSERT( size->h > 0 ); | ||||
D_ASSUME( rotation == 0 || rotation == 90 || rotation == 180 || rotati | ||||
on == 270 ); | ||||
switch (rotation) { | ||||
default: | ||||
D_BUG( "invalid rotation %d", rotation ); | ||||
case 0: | ||||
*rectangle = *from; | ||||
break; | ||||
case 90: | ||||
rectangle->x = from->y; | ||||
rectangle->y = size->w - from->x - from->w; | ||||
rectangle->w = from->h; | ||||
rectangle->h = from->w; | ||||
break; | ||||
case 180: | ||||
rectangle->x = size->w - from->x - from->w; | ||||
rectangle->y = size->h - from->y - from->h; | ||||
rectangle->w = from->w; | ||||
rectangle->h = from->h; | ||||
break; | ||||
case 270: | ||||
rectangle->x = size->h - from->y - from->h; | ||||
rectangle->y = from->x; | ||||
rectangle->w = from->h; | ||||
rectangle->h = from->w; | ||||
break; | ||||
} | ||||
DFB_RECTANGLE_ASSERT( rectangle ); | ||||
} | ||||
static inline void dfb_point_from_rotated_region( DFBPoint *point | ||||
, | ||||
const DFBRegion *from, | ||||
const DFBDimension *size, | ||||
int rotat | ||||
ion ) | ||||
{ | ||||
D_ASSERT( point != NULL ); | ||||
DFB_REGION_ASSERT( from ); | ||||
D_ASSERT( size != NULL ); | ||||
D_ASSERT( size->w > 0 ); | ||||
D_ASSERT( size->h > 0 ); | ||||
D_ASSUME( rotation == 0 || rotation == 90 || rotation == 180 || rotati | ||||
on == 270 ); | ||||
switch (rotation) { | ||||
default: | ||||
D_BUG( "invalid rotation %d", rotation ); | ||||
case 0: | ||||
point->x = from->x1; | ||||
point->y = from->y1; | ||||
break; | ||||
case 90: | ||||
point->x = from->y1; | ||||
point->y = size->w - from->x2 - 1; | ||||
break; | ||||
case 180: | ||||
point->x = size->w - from->x2 - 1; | ||||
point->y = size->h - from->y2 - 1; | ||||
break; | ||||
case 270: | ||||
point->x = size->h - from->y2 - 1; | ||||
point->y = from->x1; | ||||
break; | ||||
} | ||||
D_ASSERT( point->x >= 0 ); | ||||
D_ASSERT( point->y >= 0 ); | ||||
D_ASSERT( point->x < size->w ); | ||||
D_ASSERT( point->y < size->h ); | ||||
} | ||||
static inline void dfb_rectangle_translate( DFBRectangle *rect, | static inline void dfb_rectangle_translate( DFBRectangle *rect, | |||
int dx, | int dx, | |||
int dy ) | int dy ) | |||
{ | { | |||
DFB_RECTANGLE_ASSERT( rect ); | DFB_RECTANGLE_ASSERT( rect ); | |||
rect->x += dx; | rect->x += dx; | |||
rect->y += dy; | rect->y += dy; | |||
} | } | |||
skipping to change at line 433 | skipping to change at line 566 | |||
int *ret_bounding ); | int *ret_bounding ); | |||
static inline void | static inline void | |||
dfb_updates_reset( DFBUpdates *updates ) | dfb_updates_reset( DFBUpdates *updates ) | |||
{ | { | |||
D_MAGIC_ASSERT( updates, DFBUpdates ); | D_MAGIC_ASSERT( updates, DFBUpdates ); | |||
updates->num_regions = 0; | updates->num_regions = 0; | |||
} | } | |||
static inline void | ||||
dfb_updates_deinit( DFBUpdates *updates ) | ||||
{ | ||||
D_MAGIC_ASSERT( updates, DFBUpdates ); | ||||
D_MAGIC_CLEAR( updates ); | ||||
} | ||||
#ifdef __cplusplus | #ifdef __cplusplus | |||
} | } | |||
#endif | #endif | |||
#endif | #endif | |||
End of changes. 2 change blocks. | ||||
8 lines changed or deleted | 140 lines changed or added | |||
directfb_version.h | directfb_version.h | |||
---|---|---|---|---|
skipping to change at line 33 | skipping to change at line 33 | |||
You should have received a copy of the GNU Lesser General Public | You should have received a copy of the GNU Lesser General Public | |||
License along with this library; if not, write to the | License along with this library; if not, write to the | |||
Free Software Foundation, Inc., 59 Temple Place - Suite 330, | Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |||
Boston, MA 02111-1307, USA. | Boston, MA 02111-1307, USA. | |||
*/ | */ | |||
#ifndef __DIRECTFB_VERSION_H__ | #ifndef __DIRECTFB_VERSION_H__ | |||
#define __DIRECTFB_VERSION_H__ | #define __DIRECTFB_VERSION_H__ | |||
#define DIRECTFB_MAJOR_VERSION (1) | #define DIRECTFB_MAJOR_VERSION (1) | |||
#define DIRECTFB_MINOR_VERSION (2) | #define DIRECTFB_MINOR_VERSION (3) | |||
#define DIRECTFB_MICRO_VERSION (10) | #define DIRECTFB_MICRO_VERSION (0) | |||
#define DIRECTFB_BINARY_AGE (1) | #define DIRECTFB_BINARY_AGE (0) | |||
#define DIRECTFB_INTERFACE_AGE (1) | #define DIRECTFB_INTERFACE_AGE (0) | |||
#endif /* __DIRECTFB_VERSION_H__ */ | #endif /* __DIRECTFB_VERSION_H__ */ | |||
End of changes. 1 change blocks. | ||||
4 lines changed or deleted | 4 lines changed or added | |||
fbdev.h | fbdev.h | |||
---|---|---|---|---|
skipping to change at line 121 | skipping to change at line 121 | |||
VirtualTerminal *vt; | VirtualTerminal *vt; | |||
AGPDevice *agp; | AGPDevice *agp; | |||
} FBDev; | } FBDev; | |||
/* | /* | |||
* core init function, opens /dev/fb, get fbdev screeninfo | * core init function, opens /dev/fb, get fbdev screeninfo | |||
* disables font acceleration, reads mode list | * disables font acceleration, reads mode list | |||
*/ | */ | |||
DFBResult dfb_fbdev_initialize( void ); | DFBResult dfb_fbdev_initialize(); | |||
DFBResult dfb_fbdev_join( void ); | DFBResult dfb_fbdev_join(); | |||
/* | /* | |||
* deinitializes DirectFB fbdev stuff and restores fbdev settings | * deinitializes DirectFB fbdev stuff and restores fbdev settings | |||
*/ | */ | |||
DFBResult dfb_fbdev_shutdown( bool emergency ); | DFBResult dfb_fbdev_shutdown( bool emergency ); | |||
DFBResult dfb_fbdev_leave ( bool emergency ); | DFBResult dfb_fbdev_leave ( bool emergency ); | |||
const VideoMode *dfb_fbdev_find_mode( int width, | ||||
int height ) | ||||
; | ||||
DFBResult dfb_fbdev_test_mode ( const VideoMode *mode, | DFBResult dfb_fbdev_test_mode ( const VideoMode *mode, | |||
const CoreLayerRegionConfig *config ) ; | const CoreLayerRegionConfig *config ) ; | |||
DFBResult dfb_fbdev_test_mode_simple( const VideoMode *mode ); | DFBResult dfb_fbdev_test_mode_simple( const VideoMode *mode ); | |||
DFBResult dfb_fbdev_set_mode ( const VideoMode *mode, | DFBResult dfb_fbdev_set_mode ( const VideoMode *mode, | |||
CoreSurface *surface, | const CoreSurfaceConfig *config ) | |||
unsigned int xoffset, | ; | |||
unsigned int yoffset | ||||
); | ||||
#endif | #endif | |||
End of changes. 3 change blocks. | ||||
9 lines changed or deleted | 4 lines changed or added | |||
generic.h | generic.h | |||
---|---|---|---|---|
skipping to change at line 101 | skipping to change at line 101 | |||
DFBColor color; | DFBColor color; | |||
/* | /* | |||
* operands | * operands | |||
*/ | */ | |||
void *Aop[3]; | void *Aop[3]; | |||
void *Bop[3]; | void *Bop[3]; | |||
u32 Cop; | u32 Cop; | |||
int Astep; | ||||
int Bstep; | ||||
u8 YCop; | u8 YCop; | |||
u8 CbCop; | u8 CbCop; | |||
u8 CrCop; | u8 CrCop; | |||
int Aop_field; | int Aop_field; | |||
int Bop_field; | int Bop_field; | |||
int AopY; | int AopY; | |||
int BopY; | int BopY; | |||
End of changes. 1 change blocks. | ||||
0 lines changed or deleted | 3 lines changed or added | |||
graphics_driver.h | graphics_driver.h | |||
---|---|---|---|---|
skipping to change at line 75 | skipping to change at line 75 | |||
static GraphicsDriverFuncs driver_funcs = { | static GraphicsDriverFuncs driver_funcs = { | |||
.Probe = driver_probe, | .Probe = driver_probe, | |||
.GetDriverInfo = driver_get_info, | .GetDriverInfo = driver_get_info, | |||
.InitDriver = driver_init_driver, | .InitDriver = driver_init_driver, | |||
.InitDevice = driver_init_device, | .InitDevice = driver_init_device, | |||
.CloseDevice = driver_close_device, | .CloseDevice = driver_close_device, | |||
.CloseDriver = driver_close_driver | .CloseDriver = driver_close_driver | |||
}; | }; | |||
#define DFB_GRAPHICS_DRIVER(shortname) \ | #define DFB_GRAPHICS_DRIVER(shortname) \ | |||
__attribute__((constructor)) void directfb_##shortname( void ); \ | __attribute__((constructor)) void directfb_##shortname(); \ | |||
\ | \ | |||
void \ | void \ | |||
directfb_##shortname( void ) \ | directfb_##shortname() \ | |||
{ \ | { \ | |||
direct_modules_register( &dfb_graphics_drivers, \ | direct_modules_register( &dfb_graphics_drivers, \ | |||
DFB_GRAPHICS_DRIVER_ABI_VERSION, \ | DFB_GRAPHICS_DRIVER_ABI_VERSION, \ | |||
#shortname, &driver_funcs ); \ | #shortname, &driver_funcs ); \ | |||
} | } | |||
#endif | #endif | |||
End of changes. 2 change blocks. | ||||
2 lines changed or deleted | 2 lines changed or added | |||
input_driver.h | input_driver.h | |||
---|---|---|---|---|
skipping to change at line 35 | skipping to change at line 35 | |||
Free Software Foundation, Inc., 59 Temple Place - Suite 330, | Free Software Foundation, Inc., 59 Temple Place - Suite 330, | |||
Boston, MA 02111-1307, USA. | Boston, MA 02111-1307, USA. | |||
*/ | */ | |||
#ifndef __INPUT_DRIVER_H__ | #ifndef __INPUT_DRIVER_H__ | |||
#define __INPUT_DRIVER_H__ | #define __INPUT_DRIVER_H__ | |||
#include <core/input.h> | #include <core/input.h> | |||
static int | static int | |||
driver_get_available( void ); | driver_get_available(); | |||
static void | static void | |||
driver_get_info( InputDriverInfo *info ); | driver_get_info( InputDriverInfo *info ); | |||
static DFBResult | static DFBResult | |||
driver_open_device( CoreInputDevice *device, | driver_open_device( CoreInputDevice *device, | |||
unsigned int number, | unsigned int number, | |||
InputDeviceInfo *info, | InputDeviceInfo *info, | |||
void **driver_data ); | void **driver_data ); | |||
skipping to change at line 75 | skipping to change at line 75 | |||
.OpenDevice = driver_open_device, | .OpenDevice = driver_open_device, | |||
.GetKeymapEntry = driver_get_keymap_entry, | .GetKeymapEntry = driver_get_keymap_entry, | |||
.CloseDevice = driver_close_device, | .CloseDevice = driver_close_device, | |||
#ifdef DFB_INPUTDRIVER_HAS_AXIS_INFO | #ifdef DFB_INPUTDRIVER_HAS_AXIS_INFO | |||
.GetAxisInfo = driver_get_axis_info | .GetAxisInfo = driver_get_axis_info | |||
#endif | #endif | |||
}; | }; | |||
#define DFB_INPUT_DRIVER(shortname) \ | #define DFB_INPUT_DRIVER(shortname) \ | |||
__attribute__((constructor)) void directfb_##shortname##_ctor( void ); | __attribute__((constructor)) void directfb_##shortname(); | |||
\ | \ | |||
__attribute__((destructor)) void directfb_##shortname##_dtor( void ); | ||||
\ | ||||
\ | \ | |||
void \ | void \ | |||
directfb_##shortname##_ctor( void ) \ | directfb_##shortname() \ | |||
{ \ | { \ | |||
direct_modules_register( &dfb_input_modules, DFB_INPUT_DRIVER_ABI_VERS ION, \ | direct_modules_register( &dfb_input_modules, DFB_INPUT_DRIVER_ABI_VERS ION, \ | |||
#shortname, &driver_funcs ); \ | #shortname, &driver_funcs ); \ | |||
} | ||||
\ | ||||
\ | ||||
void | ||||
\ | ||||
directfb_##shortname##_dtor( void ) | ||||
\ | ||||
{ | ||||
\ | ||||
direct_modules_unregister( &dfb_input_modules, #shortname ); | ||||
\ | ||||
} | } | |||
#endif | #endif | |||
End of changes. 4 change blocks. | ||||
18 lines changed or deleted | 4 lines changed or added | |||
interface.h | interface.h | |||
---|---|---|---|---|
skipping to change at line 122 | skipping to change at line 122 | |||
/* | /* | |||
* Called by implementation modules during 'dlopen'ing or at startup if lin ked | * Called by implementation modules during 'dlopen'ing or at startup if lin ked | |||
* into the executable. | * into the executable. | |||
*/ | */ | |||
void DirectRegisterInterface( DirectInterfaceFuncs *funcs ); | void DirectRegisterInterface( DirectInterfaceFuncs *funcs ); | |||
void DirectUnregisterInterface( DirectInterfaceFuncs *funcs ); | void DirectUnregisterInterface( DirectInterfaceFuncs *funcs ); | |||
void direct_print_interface_leaks(void); | void direct_print_interface_leaks(void); | |||
#if DIRECT_BUILD_DEBUGS | #if DIRECT_BUILD_DEBUG || defined(DIRECT_ENABLE_DEBUG) || defined(DIRECT_FO | |||
RCE_DEBUG) | ||||
#if !DIRECT_BUILD_DEBUGS | ||||
#error Building with debug, but library headers suggest that debug is not s | ||||
upported. | ||||
#endif | ||||
void direct_dbg_interface_add ( const char *func, | void direct_dbg_interface_add ( const char *func, | |||
const char *file, | const char *file, | |||
int line, | int line, | |||
const char *what, | const char *what, | |||
const void *interface, | const void *interface, | |||
const char *name ); | const char *name ); | |||
void direct_dbg_interface_remove( const char *func, | void direct_dbg_interface_remove( const char *func, | |||
const char *file, | const char *file, | |||
int line, | int line, | |||
const char *what, | const char *what, | |||
const void *interface ); | const void *interface ); | |||
#endif | ||||
#if DIRECT_BUILD_DEBUG || defined(DIRECT_ENABLE_DEBUG) || defined(DIRECT_FO | ||||
RCE_DEBUG) | ||||
#if !DIRECT_BUILD_DEBUGS | ||||
#error Building with debug, but library headers suggest that debug is not s | ||||
upported. | ||||
#endif | ||||
#define DIRECT_DBG_INTERFACE_ADD direct_dbg_interface_add | #define DIRECT_DBG_INTERFACE_ADD direct_dbg_interface_add | |||
#define DIRECT_DBG_INTERFACE_REMOVE direct_dbg_interface_remove | #define DIRECT_DBG_INTERFACE_REMOVE direct_dbg_interface_remove | |||
#else | #else | |||
#define DIRECT_DBG_INTERFACE_ADD(func,file,line,what,interface,name) do {} while (0) | #define DIRECT_DBG_INTERFACE_ADD(func,file,line,what,interface,name) do {} while (0) | |||
#define DIRECT_DBG_INTERFACE_REMOVE(func,file,line,what,interface) do {} while (0) | #define DIRECT_DBG_INTERFACE_REMOVE(func,file,line,what,interface) do {} while (0) | |||
#endif | #endif | |||
End of changes. 2 change blocks. | ||||
10 lines changed or deleted | 8 lines changed or added | |||
interface_implementation.h | interface_implementation.h | |||
---|---|---|---|---|
skipping to change at line 69 | skipping to change at line 69 | |||
\ | \ | |||
static DirectResult \ | static DirectResult \ | |||
Allocate( void **interface ) \ | Allocate( void **interface ) \ | |||
{ \ | { \ | |||
DIRECT_ALLOCATE_INTERFACE( *interface, type ); \ | DIRECT_ALLOCATE_INTERFACE( *interface, type ); \ | |||
return DR_OK; \ | return DR_OK; \ | |||
} \ | } \ | |||
\ | \ | |||
__attribute__((constructor)) \ | __attribute__((constructor)) \ | |||
void \ | void \ | |||
type##_##impl##_ctor(void); \ | ||||
\ | ||||
__attribute__((constructor)) \ | ||||
void \ | ||||
type##_##impl##_ctor(void) \ | type##_##impl##_ctor(void) \ | |||
{ \ | { \ | |||
DirectRegisterInterface( &interface_funcs ); \ | DirectRegisterInterface( &interface_funcs ); \ | |||
} \ | } \ | |||
\ | \ | |||
__attribute__((destructor)) \ | __attribute__((destructor)) \ | |||
void \ | void \ | |||
type##_##impl##_dtor(void); \ | ||||
\ | ||||
__attribute__((destructor)) \ | ||||
void \ | ||||
type##_##impl##_dtor(void) \ | type##_##impl##_dtor(void) \ | |||
{ \ | { \ | |||
DirectUnregisterInterface( &interface_funcs ); \ | DirectUnregisterInterface( &interface_funcs ); \ | |||
} | } | |||
#endif | #endif | |||
End of changes. 2 change blocks. | ||||
8 lines changed or deleted | 0 lines changed or added | |||
layers.h | layers.h | |||
---|---|---|---|---|
skipping to change at line 127 | skipping to change at line 127 | |||
CLRCF_ALL = 0xB013377F | CLRCF_ALL = 0xB013377F | |||
} CoreLayerRegionConfigFlags; | } CoreLayerRegionConfigFlags; | |||
typedef struct { | typedef struct { | |||
/** Driver Control **/ | /** Driver Control **/ | |||
/* | /* | |||
* Return size of layer data (shared memory). | * Return size of layer data (shared memory). | |||
*/ | */ | |||
int (*LayerDataSize) ( void ); | int (*LayerDataSize) (); | |||
/* | /* | |||
* Return size of region data (shared memory). | * Return size of region data (shared memory). | |||
*/ | */ | |||
int (*RegionDataSize)( void ); | int (*RegionDataSize)(); | |||
/* | /* | |||
* Called once by the master to initialize layer data and reset hardwa re. | * Called once by the master to initialize layer data and reset hardwa re. | |||
* Return layer description, default configuration and color adjustmen t. | * Return layer description, default configuration and color adjustmen t. | |||
*/ | */ | |||
DFBResult (*InitLayer) ( CoreLayer *layer, | DFBResult (*InitLayer) ( CoreLayer *layer, | |||
void *driver_data, | void *driver_data, | |||
void *layer_data, | void *layer_data, | |||
DFBDisplayLayerDescription *description, | DFBDisplayLayerDescription *description, | |||
DFBDisplayLayerConfig *config, | DFBDisplayLayerConfig *config, | |||
skipping to change at line 332 | skipping to change at line 332 | |||
CoreLayer *dfb_layers_replace_primary( CoreGraphicsDevice *device, | CoreLayer *dfb_layers_replace_primary( CoreGraphicsDevice *device, | |||
void *driver_data, | void *driver_data, | |||
DisplayLayerFuncs *funcs ); | DisplayLayerFuncs *funcs ); | |||
typedef DFBEnumerationResult (*DisplayLayerCallback) (CoreLayer *layer, | typedef DFBEnumerationResult (*DisplayLayerCallback) (CoreLayer *layer, | |||
void *ctx); | void *ctx); | |||
void dfb_layers_enumerate( DisplayLayerCallback callback, | void dfb_layers_enumerate( DisplayLayerCallback callback, | |||
void *ctx ); | void *ctx ); | |||
int dfb_layer_num( void ); | int dfb_layer_num(); | |||
CoreLayer *dfb_layer_at( DFBDisplayLayerID id ); | CoreLayer *dfb_layer_at( DFBDisplayLayerID id ); | |||
CoreLayer *dfb_layer_at_translated( DFBDisplayLayerID id ); | CoreLayer *dfb_layer_at_translated( DFBDisplayLayerID id ); | |||
void dfb_layer_get_description( const CoreLayer *layer, | void dfb_layer_get_description( const CoreLayer *layer, | |||
DFBDisplayLayerDescription *desc ); | DFBDisplayLayerDescription *desc ); | |||
CoreScreen *dfb_layer_screen( const CoreLayer *layer ); | CoreScreen *dfb_layer_screen( const CoreLayer *layer ); | |||
CardState *dfb_layer_state( CoreLayer *layer ); | CardState *dfb_layer_state( CoreLayer *layer ); | |||
DFBDisplayLayerID dfb_layer_id( const CoreLayer *layer ); | DFBDisplayLayerID dfb_layer_id( const CoreLayer *layer ); | |||
DFBDisplayLayerID dfb_layer_id_translated( const CoreLayer *layer ); | DFBDisplayLayerID dfb_layer_id_translated( const CoreLayer *layer ); | |||
DFBSurfacePixelFormat dfb_primary_layer_pixelformat( void ); | DFBSurfacePixelFormat dfb_primary_layer_pixelformat(); | |||
#endif | #endif | |||
End of changes. 4 change blocks. | ||||
4 lines changed or deleted | 4 lines changed or added | |||
layers_internal.h | layers_internal.h | |||
---|---|---|---|---|
skipping to change at line 106 | skipping to change at line 106 | |||
typedef enum { | typedef enum { | |||
CLLM_LOCATION, /* Keep normalized area. */ | CLLM_LOCATION, /* Keep normalized area. */ | |||
CLLM_CENTER, /* Center layer after resizing destination area. * / | CLLM_CENTER, /* Center layer after resizing destination area. * / | |||
CLLM_POSITION, /* Keep pixel position, but resize area. */ | CLLM_POSITION, /* Keep pixel position, but resize area. */ | |||
CLLM_RECTANGLE /* Keep pixel based area. */ | CLLM_RECTANGLE /* Keep pixel based area. */ | |||
} CoreLayerLayoutMode; | } CoreLayerLayoutMode; | |||
struct __DFB_CoreLayerContext { | struct __DFB_CoreLayerContext { | |||
FusionObject object; | FusionObject object; | |||
int magic; | ||||
DFBDisplayLayerID layer_id; | DFBDisplayLayerID layer_id; | |||
FusionSkirmish lock; | FusionSkirmish lock; | |||
bool active; /* Is this the active context? */ | bool active; /* Is this the active context? */ | |||
DFBDisplayLayerConfig config; /* Current layer configuration . */ | DFBDisplayLayerConfig config; /* Current layer configuration . */ | |||
int rotation; | int rotation; | |||
FusionVector regions; /* All regions created within | FusionVector regions; /* All regions created within | |||
End of changes. 1 change blocks. | ||||
0 lines changed or deleted | 2 lines changed or added | |||
memcpy.h | memcpy.h | |||
---|---|---|---|---|
skipping to change at line 42 | skipping to change at line 42 | |||
#include <stdlib.h> | #include <stdlib.h> | |||
#include <string.h> | #include <string.h> | |||
void direct_find_best_memcpy( void ); | void direct_find_best_memcpy( void ); | |||
void direct_print_memcpy_routines( void ); | void direct_print_memcpy_routines( void ); | |||
extern void *(*direct_memcpy)( void *to, const void *from, size_t len ); | extern void *(*direct_memcpy)( void *to, const void *from, size_t len ); | |||
static __inline__ void *direct_memmove( void *to, const void *from, size_t len ) | static __inline__ void *direct_memmove( void *to, const void *from, size_t len ) | |||
{ | { | |||
if ((from < to && ((const char*) from + len) < ((char*) to)) || | if ((from < to && ((char*) from + len) < ((char*) to)) || | |||
(((char*) to + len) < ((const char*) from))) | (((char*) to + len) < ((char*) from))) | |||
return direct_memcpy( to, from, len ); | return direct_memcpy( to, from, len ); | |||
else | else | |||
return memmove( to, from, len ); | return memmove( to, from, len ); | |||
} | } | |||
#endif | #endif | |||
End of changes. 1 change blocks. | ||||
2 lines changed or deleted | 2 lines changed or added | |||
modules.h | modules.h | |||
---|---|---|---|---|
skipping to change at line 73 | skipping to change at line 73 | |||
DirectLink *entries; | DirectLink *entries; | |||
DirectModuleEntry *loading; | DirectModuleEntry *loading; | |||
}; | }; | |||
#define DECLARE_MODULE_DIRECTORY(d) \ | #define DECLARE_MODULE_DIRECTORY(d) \ | |||
extern DirectModuleDir d | extern DirectModuleDir d | |||
#define DEFINE_MODULE_DIRECTORY(d,p,n) \ | #define DEFINE_MODULE_DIRECTORY(d,p,n) \ | |||
DirectModuleDir d = { \ | DirectModuleDir d = { \ | |||
.lock = PTHREAD_MUTEX_INITIALIZER, \ | lock: PTHREAD_MUTEX_INITIALIZER, \ | |||
.path = p, \ | path: MODULEDIR"/"p, \ | |||
.abi_version = n, \ | abi_version: n, \ | |||
.entries = NULL, \ | entries: NULL, \ | |||
.loading = NULL, \ | loading: NULL \ | |||
} | } | |||
int direct_modules_explore_directory( DirectModuleDir *directory ); | int direct_modules_explore_directory( DirectModuleDir *directory ); | |||
void direct_modules_register( DirectModuleDir *directory, | void direct_modules_register( DirectModuleDir *directory, | |||
unsigned int abi_version, | unsigned int abi_version, | |||
const char *name, | const char *name, | |||
const void *funcs ); | const void *funcs ); | |||
void direct_modules_unregister( DirectModuleDir *directory, | ||||
const char *name ); | ||||
const void *direct_module_ref ( DirectModuleEntry *module ); | const void *direct_module_ref ( DirectModuleEntry *module ); | |||
void direct_module_unref( DirectModuleEntry *module ); | void direct_module_unref( DirectModuleEntry *module ); | |||
#endif | #endif | |||
End of changes. 2 change blocks. | ||||
8 lines changed or deleted | 5 lines changed or added | |||
surface.h | surface.h | |||
---|---|---|---|---|
skipping to change at line 124 | skipping to change at line 124 | |||
low priority */ | low priority */ | |||
CSP_VIDEOHIGH = 0x00000002, /* try to store in video memory, | CSP_VIDEOHIGH = 0x00000002, /* try to store in video memory, | |||
high priority */ | high priority */ | |||
CSP_VIDEOONLY = 0x00000003 /* always and only | CSP_VIDEOONLY = 0x00000003 /* always and only | |||
store in video memory */ | store in video memory */ | |||
} CoreSurfacePolicy; | } CoreSurfacePolicy; | |||
typedef enum { | typedef enum { | |||
CSAF_NONE = 0x00000000, | CSAF_NONE = 0x00000000, | |||
CSAF_GPU_READ = 0x00000001, /* accelerator can read */ | CSAF_READ = 0x00000001, /* accessor may read */ | |||
CSAF_GPU_WRITE = 0x00000002, /* accelerator can write */ | CSAF_WRITE = 0x00000002, /* accessor may write */ | |||
CSAF_CPU_READ = 0x00000004, /* software can read */ | ||||
CSAF_CPU_WRITE = 0x00000008, /* software can write */ | ||||
CSAF_SHARED = 0x00000010, /* other processes can read/write a s well */ | CSAF_SHARED = 0x00000010, /* other processes can read/write a t the same time (shared mapping) */ | |||
CSAF_ALL = 0x0000001F | CSAF_ALL = 0x00000013 | |||
} CoreSurfaceAccessFlags; | } CoreSurfaceAccessFlags; | |||
typedef enum { | typedef enum { | |||
CSAID_NONE = 0x00000000, /* none or unknown accessor */ | ||||
CSAID_CPU = 0x00000001, /* local processor, where DirectFB | ||||
is running on, could be app or sw fallback */ | ||||
CSAID_GPU = 0x00000002, /* primary accelerator, as in tradi | ||||
tional 'gfxcard' core (ACCEL0) */ | ||||
CSAID_ACCEL0 = 0x00000002, /* accelerators, decoders etc. (CSA | ||||
ID_ACCEL0 + accel_id<0-5>) */ | ||||
CSAID_ACCEL1 = 0x00000003, | ||||
CSAID_ACCEL2 = 0x00000004, | ||||
CSAID_ACCEL3 = 0x00000005, | ||||
CSAID_ACCEL4 = 0x00000006, | ||||
CSAID_ACCEL5 = 0x00000007, | ||||
CSAID_LAYER0 = 0x00000008, /* display layers, registered by la | ||||
yer core (CSAID_LAYER0 + layer_id<0-7>) */ | ||||
CSAID_LAYER1 = 0x00000009, | ||||
CSAID_LAYER2 = 0x0000000a, | ||||
CSAID_LAYER3 = 0x0000000b, | ||||
CSAID_LAYER4 = 0x0000000c, | ||||
CSAID_LAYER5 = 0x0000000d, | ||||
CSAID_LAYER6 = 0x0000000e, | ||||
CSAID_LAYER7 = 0x0000000f, | ||||
_CSAID_NUM = 0x00000010, /* number of statically assigned ID | ||||
s for usage in static arrays */ | ||||
CSAID_ANY = 0x00000100, /* any other accessor needs to be r | ||||
egistered using IDs starting from here */ | ||||
} CoreSurfaceAccessorID; | ||||
typedef enum { | ||||
CSBR_FRONT = 0, | CSBR_FRONT = 0, | |||
CSBR_BACK = 1, | CSBR_BACK = 1, | |||
CSBR_IDLE = 2 | CSBR_IDLE = 2 | |||
} CoreSurfaceBufferRole; | } CoreSurfaceBufferRole; | |||
typedef enum { | typedef enum { | |||
CSSF_NONE = 0x00000000, | CSSF_NONE = 0x00000000, | |||
CSSF_DESTROYED = 0x00000001, /* surface is being or has been des troyed */ | CSSF_DESTROYED = 0x00000001, /* surface is being or has been des troyed */ | |||
skipping to change at line 161 | skipping to change at line 187 | |||
int magic; | int magic; | |||
FusionSkirmish lock; | FusionSkirmish lock; | |||
CoreSurfaceStateFlags state; | CoreSurfaceStateFlags state; | |||
CoreSurfaceConfig config; | CoreSurfaceConfig config; | |||
CoreSurfaceTypeFlags type; | CoreSurfaceTypeFlags type; | |||
unsigned long resource_id; /* layer id, window id, or use r specified */ | unsigned long resource_id; /* layer id, window id, or use r specified */ | |||
int rotation; | ||||
CoreSurfaceNotificationFlags notifications; | CoreSurfaceNotificationFlags notifications; | |||
DirectSerial serial; | DirectSerial serial; | |||
int field; | int field; | |||
u8 alpha_ramp[4]; | u8 alpha_ramp[4]; | |||
CoreSurfaceBuffer *buffers[MAX_SURFACE_BUFFERS]; | CoreSurfaceBuffer *buffers[MAX_SURFACE_BUFFERS]; | |||
int num_buffers; | int num_buffers; | |||
skipping to change at line 224 | skipping to change at line 252 | |||
DFBResult dfb_surface_flip ( CoreSurface *surface , | DFBResult dfb_surface_flip ( CoreSurface *surface , | |||
bool swap ); | bool swap ); | |||
DFBResult dfb_surface_reconfig ( CoreSurface *surface , | DFBResult dfb_surface_reconfig ( CoreSurface *surface , | |||
const CoreSurfaceConfig *config ); | const CoreSurfaceConfig *config ); | |||
DFBResult dfb_surface_destroy_buffers( CoreSurface *surface ); | DFBResult dfb_surface_destroy_buffers( CoreSurface *surface ); | |||
DFBResult dfb_surface_lock_buffer ( CoreSurface *surface , | DFBResult dfb_surface_lock_buffer ( CoreSurface *surface , | |||
CoreSurfaceBufferRole role, | CoreSurfaceBufferRole role, | |||
CoreSurfaceAccessorID accesso r, | ||||
CoreSurfaceAccessFlags access, | CoreSurfaceAccessFlags access, | |||
CoreSurfaceBufferLock *ret_loc k ); | CoreSurfaceBufferLock *ret_loc k ); | |||
DFBResult dfb_surface_unlock_buffer ( CoreSurface *surface , | DFBResult dfb_surface_unlock_buffer ( CoreSurface *surface , | |||
CoreSurfaceBufferLock *lock ); | CoreSurfaceBufferLock *lock ); | |||
DFBResult dfb_surface_read_buffer ( CoreSurface *surface , | DFBResult dfb_surface_read_buffer ( CoreSurface *surface , | |||
CoreSurfaceBufferRole role, | CoreSurfaceBufferRole role, | |||
void *destina tion, | void *destina tion, | |||
int pitch, | int pitch, | |||
End of changes. 6 change blocks. | ||||
6 lines changed or deleted | 41 lines changed or added | |||
surface_buffer.h | surface_buffer.h | |||
---|---|---|---|---|
skipping to change at line 77 | skipping to change at line 77 | |||
/* | /* | |||
* An Allocation of a Surface Buffer | * An Allocation of a Surface Buffer | |||
*/ | */ | |||
struct __DFB_CoreSurfaceAllocation { | struct __DFB_CoreSurfaceAllocation { | |||
int magic; | int magic; | |||
DirectSerial serial; /* Equals serial of buffe r if content is up to date. */ | DirectSerial serial; /* Equals serial of buffe r if content is up to date. */ | |||
CoreSurfaceBuffer *buffer; /* Surface Buffer owning this allocation. */ | CoreSurfaceBuffer *buffer; /* Surface Buffer owning this allocation. */ | |||
CoreSurface *surface; /* Surface owning the Buf fer of this allocation. */ | ||||
CoreSurfacePool *pool; /* Surface Pool providing the allocation. */ | CoreSurfacePool *pool; /* Surface Pool providing the allocation. */ | |||
void *data; /* Pool's private data fo r this allocation. */ | void *data; /* Pool's private data fo r this allocation. */ | |||
int size; /* Amount of data used by this allocation. */ | int size; /* Amount of data used by this allocation. */ | |||
unsigned long offset; /* Offset within address range of pool if contiguous. */ | unsigned long offset; /* Offset within address range of pool if contiguous. */ | |||
CoreSurfaceAccessFlags access; /* Possible access flags. */ | ||||
CoreSurfaceAllocationFlags flags; /* Pool can return CSALF_ ONEFORALL upon allocation of first buffer. */ | CoreSurfaceAllocationFlags flags; /* Pool can return CSALF_ ONEFORALL upon allocation of first buffer. */ | |||
CoreSurfaceAccessFlags accessed; /* Access since last sync | const CoreSurfaceAccessFlags *access; /* Possible acc | |||
hronization. */ | ess flags (pointer to pool description). */ | |||
CoreSurfaceAccessFlags accessed[_CSAID_NUM]; /* Access since | ||||
last synchronization. */ | ||||
}; | }; | |||
#define CORE_SURFACE_ALLOCATION_ASSERT(alloc) \ | #define CORE_SURFACE_ALLOCATION_ASSERT(alloc) \ | |||
do { \ | do { \ | |||
D_MAGIC_ASSERT( alloc, CoreSurfaceAllocation ); \ | D_MAGIC_ASSERT( alloc, CoreSurfaceAllocation ); \ | |||
D_ASSUME( (alloc)->size > 0 ); \ | D_ASSUME( (alloc)->size > 0 ); \ | |||
D_ASSERT( (alloc)->size >= 0 ); \ | D_ASSERT( (alloc)->size >= 0 ); \ | |||
D_ASSERT( (alloc)->offset + (alloc)->size <= ((alloc)->pool->desc .size ?:~0UL) ); \ | D_ASSERT( (alloc)->offset + (alloc)->size <= ((alloc)->pool->desc .size ?:~0UL) ); \ | |||
D_FLAGS_ASSERT( (alloc)->access, CSAF_ALL ); | D_FLAGS_ASSERT( (alloc)->access[CSAID_CPU], CSAF_ALL ); | |||
\ | \ | |||
D_FLAGS_ASSERT( (alloc)->access[CSAID_GPU], CSAF_ALL ); | ||||
\ | ||||
D_FLAGS_ASSERT( (alloc)->flags, CSALF_ALL ); \ | D_FLAGS_ASSERT( (alloc)->flags, CSALF_ALL ); \ | |||
D_FLAGS_ASSERT( (alloc)->accessed, CSAF_ALL ); | D_FLAGS_ASSERT( (alloc)->accessed[CSAID_CPU], CSAF_ALL ); | |||
\ | \ | |||
D_FLAGS_ASSERT( (alloc)->accessed[CSAID_GPU], CSAF_ALL ); | ||||
\ | ||||
} while (0) | } while (0) | |||
/* | /* | |||
* A Lock on a Surface Buffer | * A Lock on a Surface Buffer | |||
*/ | */ | |||
struct __DFB_CoreSurfaceBufferLock { | struct __DFB_CoreSurfaceBufferLock { | |||
int magic; /* Must be valid before c alling dfb_surface_pool_lock() */ | int magic; /* Must be valid before c alling dfb_surface_pool_lock() */ | |||
CoreSurfaceAccessorID accessor; /* " */ | ||||
CoreSurfaceAccessFlags access; /* " */ | CoreSurfaceAccessFlags access; /* " */ | |||
CoreSurfaceBuffer *buffer; /* Set by dfb_surface_poo l_lock() */ | CoreSurfaceBuffer *buffer; /* Set by dfb_surface_poo l_lock() */ | |||
CoreSurfaceAllocation *allocation; /* " */ | CoreSurfaceAllocation *allocation; /* " */ | |||
void *addr; /* " */ | void *addr; /* " */ | |||
unsigned long phys; /* " */ | unsigned long phys; /* " */ | |||
unsigned long offset; /* " */ | unsigned long offset; /* " */ | |||
unsigned int pitch; /* " */ | unsigned int pitch; /* " */ | |||
skipping to change at line 133 | skipping to change at line 137 | |||
lock->buffer = NULL; | lock->buffer = NULL; | |||
lock->allocation = NULL; | lock->allocation = NULL; | |||
lock->addr = NULL; | lock->addr = NULL; | |||
lock->phys = 0; | lock->phys = 0; | |||
lock->offset = ~0; | lock->offset = ~0; | |||
lock->pitch = 0; | lock->pitch = 0; | |||
lock->handle = NULL; | lock->handle = NULL; | |||
} | } | |||
static inline void | static inline void | |||
dfb_surface_buffer_lock_init( CoreSurfaceBufferLock *lock, CoreSurfaceAcces sFlags access ) | dfb_surface_buffer_lock_init( CoreSurfaceBufferLock *lock, CoreSurfaceAcces sorID accessor, CoreSurfaceAccessFlags access ) | |||
{ | { | |||
D_MAGIC_SET( lock, CoreSurfaceBufferLock ); | D_MAGIC_SET( lock, CoreSurfaceBufferLock ); | |||
lock->access = access; | lock->accessor = accessor; | |||
lock->access = access; | ||||
dfb_surface_buffer_lock_reset( lock ); | dfb_surface_buffer_lock_reset( lock ); | |||
} | } | |||
static inline void | ||||
dfb_surface_buffer_lock_deinit( CoreSurfaceBufferLock *lock ) | ||||
{ | ||||
D_MAGIC_ASSERT( lock, CoreSurfaceBufferLock ); | ||||
lock->accessor = CSAID_NONE; | ||||
lock->access = CSAF_NONE; | ||||
D_MAGIC_CLEAR( lock ); | ||||
} | ||||
#define CORE_SURFACE_BUFFER_LOCK_ASSERT(lock) \ | #define CORE_SURFACE_BUFFER_LOCK_ASSERT(lock) \ | |||
do { \ | do { \ | |||
D_MAGIC_ASSERT( lock, CoreSurfaceBufferLock ); \ | D_MAGIC_ASSERT( lock, CoreSurfaceBufferLock ); \ | |||
D_FLAGS_ASSERT( (lock)->access, CSAF_ALL ); \ | D_FLAGS_ASSERT( (lock)->access, CSAF_ALL ); \ | |||
if ((lock)->buffer) { \ | if ((lock)->buffer) { \ | |||
D_ASSERT( (lock)->allocation != NULL ); \ | D_ASSERT( (lock)->allocation != NULL ); \ | |||
D_ASSERT( (lock)->buffer == (lock)->allocation->buffer ); \ | D_ASSERT( (lock)->buffer == (lock)->allocation->buffer ); \ | |||
D_ASSUME( (lock)->addr != NULL || | D_ASSUME( (lock)->addr != NULL || (lock)->phys != 0 || (lock | |||
\ | )->offset != ~0 || (lock)->handle != NULL );\ | |||
!((lock)->access & (CSAF_CPU_READ|CSAF_CPU_WRITE)) | ||||
); \ | ||||
D_ASSUME( (lock)->phys != 0 || (lock)->offset != ~0 || (lock | ||||
)->handle != NULL || \ | ||||
!((lock)->access & (CSAF_GPU_READ|CSAF_GPU_WRITE)) | ||||
); \ | ||||
D_ASSUME( (lock)->offset == (lock)->allocation->offset || (l ock)->offset == ~0 ); \ | D_ASSUME( (lock)->offset == (lock)->allocation->offset || (l ock)->offset == ~0 ); \ | |||
D_ASSERT( (lock)->pitch > 0 || ((lock)->addr == NULL && (loc k)->phys == 0) ); \ | D_ASSERT( (lock)->pitch > 0 || ((lock)->addr == NULL && (loc k)->phys == 0) ); \ | |||
} \ | } \ | |||
else { \ | else { \ | |||
D_ASSERT( (lock)->allocation == NULL ); \ | D_ASSERT( (lock)->allocation == NULL ); \ | |||
D_ASSERT( (lock)->addr == NULL ); \ | D_ASSERT( (lock)->addr == NULL ); \ | |||
D_ASSERT( (lock)->phys == 0 ); \ | D_ASSERT( (lock)->phys == 0 ); \ | |||
D_ASSERT( (lock)->offset == ~0 ); \ | D_ASSERT( (lock)->offset == ~0 ); \ | |||
D_ASSERT( (lock)->pitch == 0 ); \ | D_ASSERT( (lock)->pitch == 0 ); \ | |||
D_ASSERT( (lock)->handle == NULL ); \ | D_ASSERT( (lock)->handle == NULL ); \ | |||
skipping to change at line 174 | skipping to change at line 187 | |||
} while (0) | } while (0) | |||
/* | /* | |||
* A Surface Buffer of a Surface | * A Surface Buffer of a Surface | |||
*/ | */ | |||
struct __DFB_CoreSurfaceBuffer { | struct __DFB_CoreSurfaceBuffer { | |||
int magic; | int magic; | |||
DirectSerial serial; /* Increased when content is w ritten. */ | DirectSerial serial; /* Increased when content is w ritten. */ | |||
CoreSurfaceAllocation *written; /* Allocation with the last wr ite access. */ | CoreSurfaceAllocation *written; /* Allocation with the last wr ite access. */ | |||
CoreSurfaceAllocation *read; /* Allocation with the last re ad access. */ | ||||
CoreSurface *surface; /* Surface owning this Surface Buffer. */ | CoreSurface *surface; /* Surface owning this Surface Buffer. */ | |||
CoreSurfacePolicy policy; | CoreSurfacePolicy policy; | |||
CoreSurfaceBufferFlags flags; /* Configuration and State fla gs. */ | CoreSurfaceBufferFlags flags; /* Configuration and State fla gs. */ | |||
DFBSurfacePixelFormat format; /* Pixel format of buffer data . */ | DFBSurfacePixelFormat format; /* Pixel format of buffer data . */ | |||
FusionVector allocs; /* Allocations within Surface Pools. */ | FusionVector allocs; /* Allocations within Surface Pools. */ | |||
#if 1 | ||||
unsigned int locked; /* Lock count. FIXME: Add fail safe cleanup! */ | unsigned int locked; /* Lock count. FIXME: Add fail safe cleanup! */ | |||
#endif | ||||
}; | }; | |||
DFBResult dfb_surface_buffer_new ( CoreSurface *surface, | DFBResult dfb_surface_buffer_new ( CoreSurface *surface, | |||
CoreSurfaceBufferFlags flags, | CoreSurfaceBufferFlags flags, | |||
CoreSurfaceBuffer **ret_buffer ) ; | CoreSurfaceBuffer **ret_buffer ) ; | |||
DFBResult dfb_surface_buffer_destroy( CoreSurfaceBuffer *buffer ); | DFBResult dfb_surface_buffer_destroy( CoreSurfaceBuffer *buffer ); | |||
DFBResult dfb_surface_buffer_lock ( CoreSurfaceBuffer *buffer, | DFBResult dfb_surface_buffer_lock ( CoreSurfaceBuffer *buffer, | |||
CoreSurfaceAccessorID accessor, | ||||
CoreSurfaceAccessFlags access, | CoreSurfaceAccessFlags access, | |||
CoreSurfaceBufferLock *ret_lock ); | CoreSurfaceBufferLock *ret_lock ); | |||
DFBResult dfb_surface_buffer_unlock ( CoreSurfaceBufferLock *lock ); | DFBResult dfb_surface_buffer_unlock ( CoreSurfaceBufferLock *lock ); | |||
DFBResult dfb_surface_buffer_read ( CoreSurfaceBuffer *buffer, | DFBResult dfb_surface_buffer_read ( CoreSurfaceBuffer *buffer, | |||
void *destination, | void *destination, | |||
int pitch, | int pitch, | |||
const DFBRectangle *rect ); | const DFBRectangle *rect ); | |||
End of changes. 14 change blocks. | ||||
17 lines changed or deleted | 34 lines changed or added | |||
surface_pool.h | surface_pool.h | |||
---|---|---|---|---|
skipping to change at line 40 | skipping to change at line 40 | |||
#define __CORE__SURFACE_POOL_H__ | #define __CORE__SURFACE_POOL_H__ | |||
#include <directfb.h> | #include <directfb.h> | |||
#include <core/coretypes.h> | #include <core/coretypes.h> | |||
#include <core/surface.h> | #include <core/surface.h> | |||
#include <core/surface_buffer.h> | #include <core/surface_buffer.h> | |||
typedef enum { | typedef enum { | |||
CSPCAPS_NONE = 0x00000000, | CSPCAPS_NONE = 0x00000000, | |||
CSPCAPS_ALL = 0x00000000 | CSPCAPS_PHYSICAL = 0x00000001, /* pool provides physical address t | |||
o buffer */ | ||||
CSPCAPS_VIRTUAL = 0x00000002, /* pool provides virtual address to | ||||
buffer */ | ||||
CSPCAPS_ALL = 0x00000003 | ||||
} CoreSurfacePoolCapabilities; | } CoreSurfacePoolCapabilities; | |||
typedef enum { | typedef enum { | |||
CSPP_DEFAULT, | CSPP_DEFAULT, | |||
CSPP_PREFERED, | CSPP_PREFERED, | |||
CSPP_ULTIMATE | CSPP_ULTIMATE | |||
} CoreSurfacePoolPriority; | } CoreSurfacePoolPriority; | |||
/* | /* | |||
* Increase this number when changes result in binary incompatibility! | * Increase this number when changes result in binary incompatibility! | |||
*/ | */ | |||
#define DFB_SURFACE_POOL_ABI_VERSION 1 | #define DFB_SURFACE_POOL_ABI_VERSION 1 | |||
#define DFB_SURFACE_POOL_DESC_NAME_LENGTH 40 | #define DFB_SURFACE_POOL_DESC_NAME_LENGTH 44 | |||
typedef struct { | typedef struct { | |||
CoreSurfacePoolCapabilities caps; | CoreSurfacePoolCapabilities caps; | |||
CoreSurfaceAccessFlags access; | CoreSurfaceAccessFlags access[_CSAID_NUM]; | |||
CoreSurfaceTypeFlags types; | CoreSurfaceTypeFlags types; | |||
CoreSurfacePoolPriority priority; | CoreSurfacePoolPriority priority; | |||
char name[DFB_SURFACE_POOL_DESC_NAME_LENGTH]; | char name[DFB_SURFACE_POOL_DESC_NAME_LENGTH]; | |||
unsigned long size; | unsigned long size; | |||
} CoreSurfacePoolDescription; | } CoreSurfacePoolDescription; | |||
typedef struct { | typedef struct { | |||
int (*PoolDataSize)( void ); | int (*PoolDataSize)(); | |||
int (*PoolLocalDataSize)( void ); | int (*PoolLocalDataSize)(); | |||
int (*AllocationDataSize)( void ); | int (*AllocationDataSize)(); | |||
/* | /* | |||
* Pool init/destroy | * Pool init/destroy | |||
*/ | */ | |||
DFBResult (*InitPool) ( CoreDFB *core, | DFBResult (*InitPool) ( CoreDFB *core, | |||
CoreSurfacePool *pool, | CoreSurfacePool *pool, | |||
void *pool_data, | void *pool_data, | |||
void *pool_local, | void *pool_local, | |||
void *system_data, | void *system_data, | |||
CoreSurfacePoolDescription *ret_desc ); | CoreSurfacePoolDescription *ret_desc ); | |||
skipping to change at line 194 | skipping to change at line 197 | |||
CoreSurfacePool *backup; | CoreSurfacePool *backup; | |||
}; | }; | |||
typedef DFBEnumerationResult (*CoreSurfacePoolCallback)( CoreSurfacePool *p ool, | typedef DFBEnumerationResult (*CoreSurfacePoolCallback)( CoreSurfacePool *p ool, | |||
void *c tx ); | void *c tx ); | |||
typedef DFBEnumerationResult (*CoreSurfaceAllocCallback)( CoreSurfaceAlloca tion *allocation, | typedef DFBEnumerationResult (*CoreSurfaceAllocCallback)( CoreSurfaceAlloca tion *allocation, | |||
void *ctx ); | void *ctx ); | |||
DFBResult dfb_surface_pools_negotiate( CoreSurfaceBuffer *buffer, | DFBResult dfb_surface_pools_negotiate( CoreSurfaceBuffer *buffer, | |||
CoreSurfaceAccessorID accessor, | ||||
CoreSurfaceAccessFlags access, | CoreSurfaceAccessFlags access, | |||
CoreSurfacePool **ret_pools, | CoreSurfacePool **ret_pools, | |||
unsigned int max_pools, | unsigned int max_pools, | |||
unsigned int *ret_num ); | unsigned int *ret_num ); | |||
DFBResult dfb_surface_pools_enumerate( CoreSurfacePoolCallback callback, | DFBResult dfb_surface_pools_enumerate( CoreSurfacePoolCallback callback, | |||
void *ctx ); | void *ctx ); | |||
DFBResult dfb_surface_pools_allocate ( CoreSurfaceBuffer *buffer, | DFBResult dfb_surface_pools_allocate ( CoreSurfaceBuffer *buffer, | |||
CoreSurfaceAccessorID accessor, | ||||
CoreSurfaceAccessFlags access, | CoreSurfaceAccessFlags access, | |||
CoreSurfaceAllocation **ret_allocat ion ); | CoreSurfaceAllocation **ret_allocat ion ); | |||
DFBResult dfb_surface_pool_initialize( CoreDFB *core, | DFBResult dfb_surface_pool_initialize( CoreDFB *core, | |||
const SurfacePoolFuncs *funcs, | const SurfacePoolFuncs *funcs, | |||
CoreSurfacePool **ret_pool ); | CoreSurfacePool **ret_pool ); | |||
DFBResult dfb_surface_pool_join ( CoreDFB *core, | DFBResult dfb_surface_pool_join ( CoreDFB *core, | |||
CoreSurfacePool *pool, | CoreSurfacePool *pool, | |||
const SurfacePoolFuncs *funcs ); | const SurfacePoolFuncs *funcs ); | |||
skipping to change at line 237 | skipping to change at line 242 | |||
CoreSurfaceAllocation **ret_allocat ion ); | CoreSurfaceAllocation **ret_allocat ion ); | |||
DFBResult dfb_surface_pool_lock ( CoreSurfacePool *pool, | DFBResult dfb_surface_pool_lock ( CoreSurfacePool *pool, | |||
CoreSurfaceAllocation *allocation, | CoreSurfaceAllocation *allocation, | |||
CoreSurfaceBufferLock *lock ); | CoreSurfaceBufferLock *lock ); | |||
DFBResult dfb_surface_pool_unlock ( CoreSurfacePool *pool, | DFBResult dfb_surface_pool_unlock ( CoreSurfacePool *pool, | |||
CoreSurfaceAllocation *allocation, | CoreSurfaceAllocation *allocation, | |||
CoreSurfaceBufferLock *lock ); | CoreSurfaceBufferLock *lock ); | |||
DFBResult dfb_surface_pool_read ( CoreSurfacePool *pool, | ||||
CoreSurfaceAllocation *allocation, | ||||
void *data, | ||||
int pitch, | ||||
const DFBRectangle *rect ); | ||||
DFBResult dfb_surface_pool_write ( CoreSurfacePool *pool, | ||||
CoreSurfaceAllocation *allocation, | ||||
const void *data, | ||||
int pitch, | ||||
const DFBRectangle *rect ); | ||||
DFBResult dfb_surface_pool_enumerate ( CoreSurfacePool *pool, | DFBResult dfb_surface_pool_enumerate ( CoreSurfacePool *pool, | |||
CoreSurfaceAllocCallback callback, | CoreSurfaceAllocCallback callback, | |||
void *ctx ); | void *ctx ); | |||
#endif | #endif | |||
End of changes. 8 change blocks. | ||||
7 lines changed or deleted | 26 lines changed or added | |||
util.h | util.h | |||
---|---|---|---|---|
skipping to change at line 37 | skipping to change at line 37 | |||
*/ | */ | |||
#ifndef __GFX__UTIL_H__ | #ifndef __GFX__UTIL_H__ | |||
#define __GFX__UTIL_H__ | #define __GFX__UTIL_H__ | |||
#include <core/surface.h> | #include <core/surface.h> | |||
void dfb_gfx_copy( CoreSurface *source, CoreSurface *destination, const DFB Rectangle *rect ); | void dfb_gfx_copy( CoreSurface *source, CoreSurface *destination, const DFB Rectangle *rect ); | |||
void dfb_gfx_copy_to( CoreSurface *source, CoreSurface *destination, const DFBRectangle *rect, int x, int y, bool from_back ); | void dfb_gfx_copy_to( CoreSurface *source, CoreSurface *destination, const DFBRectangle *rect, int x, int y, bool from_back ); | |||
void dfb_back_to_front_copy( CoreSurface *surface, const DFBRegion *region ); | void dfb_back_to_front_copy( CoreSurface *surface, const DFBRegion *region ); | |||
void dfb_back_to_front_copy_180( CoreSurface *surface, const DFBRegion *reg ion ); | void dfb_back_to_front_copy_rotation( CoreSurface *surface, const DFBRegion *region, int rotation ); | |||
void dfb_clear_depth( CoreSurface *surface, const DFBRegion *region ); | void dfb_clear_depth( CoreSurface *surface, const DFBRegion *region ); | |||
void dfb_sort_triangle( DFBTriangle *tri ); | void dfb_sort_triangle( DFBTriangle *tri ); | |||
#endif | #endif | |||
End of changes. 1 change blocks. | ||||
1 lines changed or deleted | 1 lines changed or added | |||
vt.h | vt.h | |||
---|---|---|---|---|
skipping to change at line 64 | skipping to change at line 64 | |||
DirectThread *thread; | DirectThread *thread; | |||
pthread_mutex_t lock; | pthread_mutex_t lock; | |||
pthread_cond_t wait; | pthread_cond_t wait; | |||
int vt_sig; | int vt_sig; | |||
} VirtualTerminal; | } VirtualTerminal; | |||
/* | /* | |||
* allocates and switches to a new virtual terminal | * allocates and switches to a new virtual terminal | |||
*/ | */ | |||
DFBResult dfb_vt_initialize( void ); | DFBResult dfb_vt_initialize(); | |||
DFBResult dfb_vt_join( void ); | DFBResult dfb_vt_join(); | |||
/* | /* | |||
* deallocates virtual terminal | * deallocates virtual terminal | |||
*/ | */ | |||
DFBResult dfb_vt_shutdown( bool emergency ); | DFBResult dfb_vt_shutdown( bool emergency ); | |||
DFBResult dfb_vt_leave( bool emergency ); | DFBResult dfb_vt_leave( bool emergency ); | |||
DFBResult dfb_vt_detach( bool force ); | DFBResult dfb_vt_detach( bool force ); | |||
bool dfb_vt_switch( int num ); | bool dfb_vt_switch( int num ); | |||
End of changes. 1 change blocks. | ||||
2 lines changed or deleted | 2 lines changed or added | |||
windows.h | windows.h | |||
---|---|---|---|---|
skipping to change at line 56 | skipping to change at line 56 | |||
typedef enum { | typedef enum { | |||
CWCF_NONE = 0x00000000, | CWCF_NONE = 0x00000000, | |||
CWCF_POSITION = 0x00000001, | CWCF_POSITION = 0x00000001, | |||
CWCF_SIZE = 0x00000002, | CWCF_SIZE = 0x00000002, | |||
CWCF_OPACITY = 0x00000004, | CWCF_OPACITY = 0x00000004, | |||
CWCF_STACKING = 0x00000008, | CWCF_STACKING = 0x00000008, | |||
CWCF_OPTIONS = 0x00000010, | CWCF_OPTIONS = 0x00000010, | |||
CWCF_EVENTS = 0x00000020, | CWCF_EVENTS = 0x00000020, | |||
CWCF_ASSOCIATION = 0x00000040, | ||||
CWCF_COLOR_KEY = 0x00000100, | CWCF_COLOR_KEY = 0x00000100, | |||
CWCF_OPAQUE = 0x00000200, | CWCF_OPAQUE = 0x00000200, | |||
CWCF_COLOR = 0x00000400, | ||||
CWCF_KEY_SELECTION = 0x00001000, | CWCF_KEY_SELECTION = 0x00001000, | |||
CWCF_SRC_GEOMETRY = 0x00010000, | CWCF_SRC_GEOMETRY = 0x00010000, | |||
CWCF_DST_GEOMETRY = 0x00020000, | CWCF_DST_GEOMETRY = 0x00020000, | |||
CWCF_APPLICATION_ID= 0x00080000, | CWCF_ROTATION = 0x00040000, | |||
CWCF_ALL = 0x000B177F | CWCF_ALL = 0x0007133F | |||
} CoreWindowConfigFlags; | } CoreWindowConfigFlags; | |||
struct __DFB_CoreWindowConfig { | struct __DFB_CoreWindowConfig { | |||
DFBRectangle bounds; /* position and size */ | DFBRectangle bounds; /* position and size */ | |||
int opacity; /* global alpha factor */ | int opacity; /* global alpha factor */ | |||
DFBWindowStackingClass stacking; /* level boundaries */ | DFBWindowStackingClass stacking; /* level boundaries */ | |||
DFBWindowOptions options; /* flags for appearance/behav iour */ | DFBWindowOptions options; /* flags for appearance/behav iour */ | |||
DFBWindowEventType events; /* mask of enabled events */ | DFBWindowEventType events; /* mask of enabled events */ | |||
DFBColor color; /* color for DWCAPS_COLOR */ | ||||
u32 color_key; /* transparent pixel */ | u32 color_key; /* transparent pixel */ | |||
DFBRegion opaque; /* region of the window force d to be opaque */ | DFBRegion opaque; /* region of the window force d to be opaque */ | |||
DFBWindowKeySelection key_selection; /* how to filter keys in focu s */ | DFBWindowKeySelection key_selection; /* how to filter keys in focu s */ | |||
DFBInputDeviceKeySymbol *keys; /* list of keys for DWKS_LIST */ | DFBInputDeviceKeySymbol *keys; /* list of keys for DWKS_LIST */ | |||
unsigned int num_keys; /* number of entries in key a rray */ | unsigned int num_keys; /* number of entries in key a rray */ | |||
DFBWindowGeometry src_geometry; /* advanced source geometry * / | DFBWindowGeometry src_geometry; /* advanced source geometry * / | |||
DFBWindowGeometry dst_geometry; /* advanced destination geome try */ | DFBWindowGeometry dst_geometry; /* advanced destination geome try */ | |||
DFBWindowID association; | int rotation; | |||
unsigned long application_id; /* this can be changed at run | ||||
time by the application. | ||||
* it's here so appman can ge | ||||
t a callback on change. */ | ||||
}; | }; | |||
#define TRANSLUCENT_WINDOW(w) ((w)->config.opacity < 0xff || \ | #define TRANSLUCENT_WINDOW(w) ((w)->config.opacity < 0xff || \ | |||
(w)->config.options & (DWOP_ALPHACHANNEL | D WOP_COLORKEYING)) | (w)->config.options & (DWOP_ALPHACHANNEL | D WOP_COLORKEYING)) | |||
#define VISIBLE_WINDOW(w) (!((w)->caps & DWCAPS_INPUTONLY) && \ | #define VISIBLE_WINDOW(w) (!((w)->caps & DWCAPS_INPUTONLY) && \ | |||
(w)->config.opacity > 0 && !DFB_WINDOW_DESTR OYED((w))) | (w)->config.opacity > 0 && !DFB_WINDOW_DESTR OYED((w))) | |||
/* | /* | |||
* Creates a pool of window objects. | * Creates a pool of window objects. | |||
skipping to change at line 217 | skipping to change at line 211 | |||
* stacks the window below another one | * stacks the window below another one | |||
*/ | */ | |||
DFBResult | DFBResult | |||
dfb_window_putbelow( CoreWindow *window, | dfb_window_putbelow( CoreWindow *window, | |||
CoreWindow *upper ); | CoreWindow *upper ); | |||
/* | /* | |||
* sets the source color key | * sets the source color key | |||
*/ | */ | |||
DFBResult | DFBResult | |||
dfb_window_set_color( CoreWindow *window, | ||||
DFBColor color ); | ||||
/* | ||||
* sets the source color key | ||||
*/ | ||||
DFBResult | ||||
dfb_window_set_colorkey( CoreWindow *window, | dfb_window_set_colorkey( CoreWindow *window, | |||
u32 color_key ); | u32 color_key ); | |||
/* | /* | |||
* change window configuration | * change window configuration | |||
*/ | */ | |||
DFBResult | DFBResult | |||
dfb_window_set_config( CoreWindow *window, | dfb_window_set_config( CoreWindow *window, | |||
const CoreWindowConfig *config, | const CoreWindowConfig *config, | |||
CoreWindowConfigFlags flags ); | CoreWindowConfigFlags flags ); | |||
skipping to change at line 302 | skipping to change at line 289 | |||
DFBInputDeviceModifierMask modifiers ); | DFBInputDeviceModifierMask modifiers ); | |||
void dfb_window_post_event( CoreWindow *window, DFBWindowEvent *event ); | void dfb_window_post_event( CoreWindow *window, DFBWindowEvent *event ); | |||
DFBResult dfb_window_send_configuration( CoreWindow *window ); | DFBResult dfb_window_send_configuration( CoreWindow *window ); | |||
DFBWindowID dfb_window_id( const CoreWindow *window ); | DFBWindowID dfb_window_id( const CoreWindow *window ); | |||
CoreSurface *dfb_window_surface( const CoreWindow *window ); | CoreSurface *dfb_window_surface( const CoreWindow *window ); | |||
DFBResult | ||||
dfb_window_set_rotation( CoreWindow *window, int rotation ); | ||||
#endif | #endif | |||
End of changes. 8 change blocks. | ||||
18 lines changed or deleted | 5 lines changed or added | |||
windows_internal.h | windows_internal.h | |||
---|---|---|---|---|
skipping to change at line 76 | skipping to change at line 76 | |||
int x; | int x; | |||
int y; | int y; | |||
} BoundWindow; | } BoundWindow; | |||
/* | /* | |||
* Core data of a window. | * Core data of a window. | |||
*/ | */ | |||
struct __DFB_CoreWindow { | struct __DFB_CoreWindow { | |||
FusionObject object; | FusionObject object; | |||
int magic; | ||||
DFBWindowID id; | DFBWindowID id; | |||
CoreWindowFlags flags; | CoreWindowFlags flags; | |||
DFBWindowCapabilities caps; /* window capabilities, to ena ble blending etc. */ | DFBWindowCapabilities caps; /* window capabilities, to ena ble blending etc. */ | |||
CoreWindowConfig config; | CoreWindowConfig config; | |||
CoreSurface *surface; /* backing store surface */ | CoreSurface *surface; /* backing store surface */ | |||
GlobalReaction surface_reaction; | GlobalReaction surface_reaction; | |||
skipping to change at line 99 | skipping to change at line 101 | |||
CoreLayerRegion *primary_region; /* default region of context * / | CoreLayerRegion *primary_region; /* default region of context * / | |||
CoreLayerRegion *region; /* hardware allocated window * / | CoreLayerRegion *region; /* hardware allocated window * / | |||
void *window_data; /* private data of window mana ger */ | void *window_data; /* private data of window mana ger */ | |||
CoreGraphicsSerial serial1; | CoreGraphicsSerial serial1; | |||
CoreGraphicsSerial serial2; | CoreGraphicsSerial serial2; | |||
DirectLink *bound_windows; /* list of bound windows */ | DirectLink *bound_windows; /* list of bound windows */ | |||
CoreWindow *boundto; /* window to which this window is bound (window binding) */ | ||||
CoreWindow *boundto; /* window to which this window is bound */ | DFBWindowID parent_id; /* window id of parent window (window association) */ | |||
unsigned long resource_id; | DFBWindowID toplevel_id; /* in case of a sub window top | |||
level_id != 0 */ | ||||
CoreWindow *toplevel; /* for top level windows this | ||||
will be NULL */ | ||||
FusionVector subwindows; /* list of sub windows (only v | ||||
alid for top level windows) */ | ||||
CoreWindow *subfocus; /* which of the sub windows ha | ||||
s the focus? */ | ||||
}; | }; | |||
typedef enum { | typedef enum { | |||
CWSF_NONE = 0x00000000, | CWSF_NONE = 0x00000000, | |||
CWSF_INITIALIZED = 0x00000001, | CWSF_INITIALIZED = 0x00000001, | |||
CWSF_ACTIVATED = 0x00000002, | CWSF_ACTIVATED = 0x00000002, | |||
CWSF_ALL = 0x00000003 | CWSF_ALL = 0x00000003 | |||
} CoreWindowStackFlags; | } CoreWindowStackFlags; | |||
skipping to change at line 127 | skipping to change at line 134 | |||
struct __DFB_CoreWindowStack { | struct __DFB_CoreWindowStack { | |||
DirectLink link; | DirectLink link; | |||
int magic; | int magic; | |||
CoreLayerContext *context; | CoreLayerContext *context; | |||
int width; | int width; | |||
int height; | int height; | |||
int rotation; | ||||
int rotated_width; | ||||
int rotated_height; | ||||
DFBSurfaceBlittingFlags rotated_blit; | ||||
DFBWindowID id_pool; | DFBWindowID id_pool; | |||
int num; | int num; | |||
struct { | struct { | |||
int enabled; /* is cursor enabled ? */ | int enabled; /* is cursor enabled ? */ | |||
int x, y; /* cursor position */ | int x, y; /* cursor position */ | |||
DFBDimension size; /* cursor shape size */ | DFBDimension size; /* cursor shape size */ | |||
DFBPoint hot; /* hot spot */ | DFBPoint hot; /* hot spot */ | |||
CoreSurface *surface; /* shape */ | CoreSurface *surface; /* shape */ | |||
End of changes. 5 change blocks. | ||||
2 lines changed or deleted | 19 lines changed or added | |||
windowstack.h | windowstack.h | |||
---|---|---|---|---|
skipping to change at line 42 | skipping to change at line 42 | |||
#include <core/coredefs.h> | #include <core/coredefs.h> | |||
#include <core/coretypes.h> | #include <core/coretypes.h> | |||
#include <fusion/lock.h> | #include <fusion/lock.h> | |||
/* | /* | |||
* allocates a WindowStack, initializes it, registers it for input events | * allocates a WindowStack, initializes it, registers it for input events | |||
*/ | */ | |||
CoreWindowStack *dfb_windowstack_create ( CoreLayerContext *context ); | CoreWindowStack *dfb_windowstack_create ( CoreLayerContext *context ); | |||
void dfb_windowstack_detach_devices( CoreWindowStack *stack ); | ||||
void dfb_windowstack_destroy( CoreWindowStack *stack ); | void dfb_windowstack_destroy( CoreWindowStack *stack ); | |||
void dfb_windowstack_resize ( CoreWindowStack *stack, | void dfb_windowstack_resize ( CoreWindowStack *stack, | |||
int width, | int width, | |||
int height ); | int height, | |||
int rotation ); | ||||
DirectResult dfb_windowstack_lock ( CoreWindowStack *stack ); | DirectResult dfb_windowstack_lock ( CoreWindowStack *stack ); | |||
DirectResult dfb_windowstack_unlock ( CoreWindowStack *stack ); | DirectResult dfb_windowstack_unlock ( CoreWindowStack *stack ); | |||
/* | /* | |||
* repaints all window on a window stack | * repaints all window on a window stack | |||
*/ | */ | |||
DFBResult dfb_windowstack_repaint_all( CoreWindowStack *stack ); | DFBResult dfb_windowstack_repaint_all( CoreWindowStack *stack ); | |||
End of changes. 2 change blocks. | ||||
3 lines changed or deleted | 2 lines changed or added | |||
wm_module.h | wm_module.h | |||
---|---|---|---|---|
skipping to change at line 245 | skipping to change at line 245 | |||
.RestackWindow = wm_restack_window, | .RestackWindow = wm_restack_window, | |||
.Grab = wm_grab, | .Grab = wm_grab, | |||
.Ungrab = wm_ungrab, | .Ungrab = wm_ungrab, | |||
.RequestFocus = wm_request_focus, | .RequestFocus = wm_request_focus, | |||
.UpdateStack = wm_update_stack, | .UpdateStack = wm_update_stack, | |||
.UpdateWindow = wm_update_window, | .UpdateWindow = wm_update_window, | |||
.UpdateCursor = wm_update_cursor | .UpdateCursor = wm_update_cursor | |||
}; | }; | |||
#define DFB_WINDOW_MANAGER(shortname) \ | #define DFB_WINDOW_MANAGER(shortname) \ | |||
__attribute__((constructor)) void directfbwm_##shortname( void ); \ | __attribute__((constructor)) void directfbwm_##shortname(); \ | |||
\ | \ | |||
void \ | void \ | |||
directfbwm_##shortname( void ) \ | directfbwm_##shortname() \ | |||
{ \ | { \ | |||
direct_modules_register( &dfb_core_wm_modules, \ | direct_modules_register( &dfb_core_wm_modules, \ | |||
DFB_CORE_WM_ABI_VERSION, \ | DFB_CORE_WM_ABI_VERSION, \ | |||
#shortname, &wm_funcs ); \ | #shortname, &wm_funcs ); \ | |||
} | } | |||
#endif | #endif | |||
End of changes. 1 change blocks. | ||||
9 lines changed or deleted | 9 lines changed or added | |||