mirror of
https://gitea.nishi.boats/pyrite-dev/milsko
synced 2025-12-31 06:30:52 +00:00
xshm
git-svn-id: http://svn2.nishi.boats/svn/milsko/trunk@69 b9cfdab3-6d41-4d17-bbe4-086880011989
This commit is contained in:
@@ -3,10 +3,6 @@
|
||||
#define __MW_GDI_H__
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
|
||||
typedef struct _MwLL * MwLL, MwLLRec;
|
||||
typedef struct _MwLLColor *MwLLColor, MwLLColorRec;
|
||||
|
||||
#include <Mw/TypeDefs.h>
|
||||
#include <Mw/LowLevel.h>
|
||||
|
||||
@@ -28,4 +24,11 @@ struct _MwLLColor {
|
||||
int blue;
|
||||
};
|
||||
|
||||
struct _MwLLPixmap {
|
||||
int width;
|
||||
int height;
|
||||
|
||||
HBITMAP hBitmap;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
@@ -6,11 +6,13 @@
|
||||
|
||||
typedef struct _MwLLHandler *MwLLHandler, MwLLHandlerRec;
|
||||
#ifdef _MILSKO
|
||||
typedef struct _MwLL * MwLL, MwLLRec;
|
||||
typedef struct _MwLLColor *MwLLColor, MwLLColorRec;
|
||||
typedef struct _MwLL * MwLL, MwLLRec;
|
||||
typedef struct _MwLLColor * MwLLColor, MwLLColorRec;
|
||||
typedef struct _MwLLPixmap *MwLLPixmap, MwLLPixmapRec;
|
||||
#else
|
||||
typedef void* MwLL;
|
||||
typedef void* MwLLColor;
|
||||
typedef void* MwLLPixmap;
|
||||
#endif
|
||||
|
||||
#ifdef _MILSKO
|
||||
@@ -61,6 +63,10 @@ MWDECL int MwLLPending(MwLL handle);
|
||||
MWDECL void MwLLNextEvent(MwLL handle);
|
||||
MWDECL void MwLLSleep(int ms);
|
||||
|
||||
MWDECL MwLLPixmap MwLLCreatePixmap(MwLL handle, unsigned char* data, int width, int height);
|
||||
MWDECL void MwLLDestroyPixmap(MwLLPixmap pixmap);
|
||||
MWDECL void MwLLDrawPixmap(MwLL handle, MwRect* rect, MwLLPixmap pixmap);
|
||||
|
||||
#ifdef __cplusplus
|
||||
}
|
||||
#endif
|
||||
|
||||
@@ -10,6 +10,8 @@
|
||||
#include <windows.h>
|
||||
#else
|
||||
#include <unistd.h>
|
||||
#include <sys/ipc.h>
|
||||
#include <sys/shm.h>
|
||||
#endif
|
||||
|
||||
#if defined(_MILSKO) && defined(_WIN32)
|
||||
|
||||
@@ -3,15 +3,13 @@
|
||||
#define __MW_X11_H__
|
||||
|
||||
#include <Mw/MachDep.h>
|
||||
|
||||
typedef struct _MwLL * MwLL, MwLLRec;
|
||||
typedef struct _MwLLColor *MwLLColor, MwLLColorRec;
|
||||
|
||||
#include <Mw/TypeDefs.h>
|
||||
#include <Mw/LowLevel.h>
|
||||
|
||||
#include <X11/X.h>
|
||||
#include <X11/Xutil.h>
|
||||
#include <X11/extensions/XShm.h>
|
||||
#include <X11/extensions/Xrender.h>
|
||||
|
||||
struct _MwLL {
|
||||
Display* display;
|
||||
@@ -31,4 +29,14 @@ struct _MwLLColor {
|
||||
int blue;
|
||||
};
|
||||
|
||||
struct _MwLLPixmap {
|
||||
int width;
|
||||
int height;
|
||||
|
||||
int use_shm;
|
||||
XShmSegmentInfo shm;
|
||||
Display* display;
|
||||
XImage* image;
|
||||
};
|
||||
|
||||
#endif
|
||||
|
||||
Reference in New Issue
Block a user