⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 udsimnt.h

📁 嵌入式开发工具
💻 H
字号:
/* udsimnt.h - SimNT driver header file *//* Copyright 2000-2003 Wind River Systems, Inc. All Rights Reserved *//*modification history--------------------01e,24jun03,jlb  Update to Tornado 2.201d,29nov00,msr  Fixed SPR #62522 - input drivers now read from pipe.01c,16nov00,msr  Added monoBitmapStretchBlt() and transBitmapStretchBlt().01b,22may00,lcs  Remove reference to windows.h, uglInit.h & Americanize GREY                 color spelling01a,15dec99,msr  written.*/#ifndef INCLUDE_udsimnt_h#define INCLUDE_udsimnt_h#if __cplusplusextern "C" {#endif/* includes *//* Get the Device Driver Configuration Definitions */#ifndef INCLUDE_SIMULATOR_GRAPHICS#define INCLUDE_SIMULATOR_GRAPHICS#define BUILD_DRIVER#include <uglInit.h>#endif /* INCLUDE_SIMULATOR_GRAPHICS */#define UGL_GRAPHICS_NAME       "NT Simulator"#define UGL_GRAPHICS_CREATE     uglSimPcDevCreate#ifdef INCLUDE_UGL_GRAYSCALE2#define UGL_COLOR_DEPTH         2#define UGL_MODE_FLAGS          (UGL_MODE_DIRECT_COLOR | UGL_MODE_GRAY_SCALE) #endif /* INCLUDE_UGL_GRAYSCALE2 */#ifdef INCLUDE_UGL_GRAYSCALE4#define UGL_COLOR_DEPTH         4#define UGL_MODE_FLAGS          (UGL_MODE_DIRECT_COLOR | UGL_MODE_GRAY_SCALE) #endif /* INCLUDE_UGL_GRAYSCALE4 */#ifdef INCLUDE_UGL_GRAYSCALE8#define UGL_COLOR_DEPTH         8#define UGL_MODE_FLAGS          (UGL_MODE_DIRECT_COLOR | UGL_MODE_GRAY_SCALE) #endif /* INCLUDE_UGL_GRAYSCALE8 */#ifdef INCLUDE_UGL_INDEXED4#define UGL_MODE_FLAGS          UGL_MODE_INDEXED_COLOR#define UGL_COLOR_DEPTH         4#endif /* INCLUDE_UGL_INDEXED4 */#ifdef INCLUDE_UGL_INDEXED8#define UGL_MODE_FLAGS          UGL_MODE_INDEXED_COLOR#define UGL_COLOR_DEPTH         8#endif /* INCLUDE_UGL_INDEXED8 */#ifdef INCLUDE_UGL_RGB565#define UGL_COLOR_DEPTH         16#define UGL_MODE_FLAGS          UGL_MODE_DIRECT_COLOR#endif /* INCLUDE_UGL_RGB565 */#ifdef INCLUDE_UGL_ARGB8888#define UGL_COLOR_DEPTH         32#define UGL_MODE_FLAGS          UGL_MODE_DIRECT_COLOR#endif /* INCLUDE_UGL_ARGB8888 *//* Keyboard definitions */#ifdef INCLUDE_SIMULATOR_KEYBOARD#define UGL_KEYBOARD_INIT       uglSimPcKbdInit#endif /* INCLUDE_SIMULATOR_KEYBOARD */#ifdef SYS_KEYBOARD_NAME#undef SYS_KEYBOARD_NAME#endif#define SYS_KEYBOARD_NAME       "/pipe/kbd"/* Pointer definitions */#ifdef INCLUDE_SIMULATOR_POINTER#define UGL_POINTER_INIT        uglSimPcPtrInit#endif /* INCLUDE_SIMULATOR_POINTER */#ifdef SYS_POINTER_NAME#undef SYS_POINTER_NAME#endif#define SYS_POINTER_NAME        "/pipe/ptr"#include <ugl/driver/graphics/generic/udgen.h>#include <ugl/uglinput.h>#include "./ugl_winLib.h"/* device dependant bitmap */typedef struct ugl_simnt_ddb    {    UGL_BMAP_HEADER header;         /* header info */    WIN_HBITMAP hBitmap;            /* Windows bitmap */    } UGL_SIMNT_DDB;/* monochrome device dependant bitmap */typedef struct ugl_simnt_mddb    {    UGL_BMAP_HEADER header;         /* header info */    WIN_HBITMAP hBitmap;            /* Windows bitmap */    } UGL_SIMNT_MDDB;/* simulator for PC driver */typedef struct ugl_simnt_driver    {    UGL_GENERIC_DRIVER  generic;    /* inherits generic driver */    int             fdKeyboard;     /* file descriptor for keyboard pipe */    int             fdPointer;      /* file descriptor for pointer pipe */    UGL_SIMNT_DDB * pDrawDdb;       /* id of draw page bitmap */    WIN_HWND        hSimWnd;        /* handle to simulator window */    UGL_UINT32      threadId;       /* id of simulator window message thread */    WIN_HPEN        hPen;           /* active pen (for lines, etc) */    WIN_HBRUSH      hBrush;         /* active brush (for fills, etc) */    WIN_HRGN        hClipRegion;    /* clipping region */    WIN_HDC         hScreenDc;      /* device context for visible window */    WIN_HDC         hDrawDc;        /* device context for draw page */    WIN_HDC         hBltDc;         /* device context for bitblt src */    WIN_HDC         hExtraDc;       /* device context for misc. operations */    } UGL_SIMNT_DRIVER;/* general */UGL_UGI_DRIVER * uglSimPcDevCreate (UGL_ORD instance, UGL_UINT32 intLevel,                                    UGL_UINT32 intVector);UGL_STATUS uglSimPcDevDestroy (UGL_UGI_DRIVER * pDriver);UGL_STATUS uglSimPcModeAvailGet (UGL_UGI_DRIVER * pDriver,                                 UGL_UINT32 * pNumModes,                                  const UGL_MODE ** pModeArray);UGL_STATUS uglSimPcModeSet (UGL_UGI_DRIVER * pDriver, UGL_MODE * pMode);UGL_STATUS uglSimPcGcSet (UGL_UGI_DRIVER * pDriver, UGL_GC_ID gc);UGL_STATUS uglSimPcInfo (UGL_UGI_DRIVER * pDriver, UGL_INFO_REQ infoRequest,                          void *info);UGL_STATUS uglSimPcColorAlloc (UGL_DEVICE_ID devId, UGL_ARGB * pAllocColors,                               UGL_ORD * pIndex, UGL_ARGB * pActualColors,                               UGL_COLOR * pUglColors, UGL_SIZE numCOlors);/* drawing primitives */UGL_STATUS uglSimPcPixelSet (UGL_UGI_DRIVER * pDriver, UGL_POINT * pPoint,                              UGL_COLOR color);UGL_STATUS uglSimPcPixelGet (UGL_UGI_DRIVER * pDriver, UGL_POINT * pPoint,                              UGL_COLOR *pColor);UGL_STATUS uglSimPcLine (UGL_UGI_DRIVER * pDriver, UGL_POINT * p1,                          UGL_POINT * p2);UGL_STATUS uglSimPcRectangle (UGL_UGI_DRIVER * pDriver, UGL_RECT * rect);UGL_STATUS uglSimPcPolygon (UGL_UGI_DRIVER * pDriver,                             const UGL_POINT * pointArray,                            UGL_ORD numPoints);UGL_STATUS uglSimPcEllipse (UGL_UGI_DRIVER * pDriver, UGL_RECT * pBoundRect,                             UGL_POINT * pStartArc, UGL_POINT * pEndArc);/* bitmap routines */UGL_DDB_ID uglSimPcBitmapCreate (UGL_UGI_DRIVER * pDriver, UGL_DIB  * pDib,                                  UGL_DIB_CREATE_MODE createMode,                                 UGL_UINT32 initValue, UGL_MEM_POOL_ID poolId);UGL_STATUS uglSimPcBitmapDestroy (UGL_UGI_DRIVER * pDriver,                                  UGL_DDB_ID ddbId);UGL_STATUS uglSimPcBitmapBlt (UGL_UGI_DRIVER * pDriver, UGL_DDB_ID srcDdbId,                              UGL_RECT * pSourceRect, UGL_DDB_ID destDdbId,                              UGL_POINT * pDestPoint);UGL_STATUS uglSimPcBitmapRead (UGL_UGI_DRIVER * pDriver, UGL_DDB_ID ddbId,                                UGL_RECT * pSrcRect,UGL_DIB  * pDib,                                 UGL_POINT * pDstPt);UGL_STATUS uglSimPcBitmapWrite (UGL_UGI_DRIVER * pDriver, UGL_DIB  * pDib,                                UGL_RECT * pSrcRect, UGL_DDB_ID ddbId,                                UGL_POINT * pDstPt);UGL_STATUS uglSimPcBitmapStretchBlt(UGL_DEVICE_ID devId,                                     UGL_DDB_ID sourceBitmap,                                     UGL_RECT * pSourceRect,                                     UGL_DDB_ID destBitmap,                                     UGL_RECT * pDestRect);/* monochrome bitmap routines */UGL_MDDB_ID uglSimPcMonoBitmapCreate (UGL_UGI_DRIVER * pDriver,                                      UGL_MDIB * pMdib, UGL_ORD createMode,                                      UGL_UINT8 initValue,                                      UGL_MEM_POOL_ID poolId);UGL_STATUS uglSimPcMonoBitmapDestroy (UGL_UGI_DRIVER * pDriver,                                      UGL_MDDB_ID mDdbId);UGL_STATUS uglSimPcMonoBitmapBlt (UGL_UGI_DRIVER * pDriver,                                     UGL_MDDB * pSrcMddb,                                    UGL_RECT * pSourceRect,                                     UGL_DDB_ID dstDdbId,                                    UGL_POINT * pDestPoint);UGL_STATUS uglSimPcMonoBitmapStretchBlt (UGL_DEVICE_ID devId,                                          UGL_MDDB_ID pSrcMddb,                                          UGL_RECT * pSourceRect,                                          UGL_DDB_ID pDstDdb,                                          UGL_RECT * pDestRect);UGL_STATUS uglSimPcMonoBitmapRead (UGL_UGI_DRIVER * pDriver,                                   UGL_MDDB_ID mDdbId, UGL_RECT * pSrcRect,                                   UGL_MDIB * pMdib, UGL_POINT * pDstPt);UGL_STATUS uglSimPcMonoBitmapWrite (UGL_UGI_DRIVER * pDriver,                                    UGL_MDIB * pMdib, UGL_RECT * pSrcRect,                                    UGL_MDDB_ID mDdbId,UGL_POINT * pDstPt);/* transparent bitmap routines */UGL_STATUS uglSimPcTransBitmapStretchBlt (UGL_DEVICE_ID devId,                                          UGL_MDDB_ID pSrcTddb,                                          UGL_RECT * pSourceRect,                                          UGL_DDB_ID pDstDdb,                                          UGL_RECT * pDestRect);/* pageing routines */UGL_STATUS uglSimPcPageDrawSet (UGL_UGI_DRIVER * pDriver, UGL_PAGE * pPage);UGL_STATUS uglSimPcPageVisibleSet (UGL_UGI_DRIVER * pDriver, UGL_PAGE * pPage);UGL_STATUS uglSimPcColorConvert (UGL_UGI_DRIVER * pDriver, void * sourceArray,                                  UGL_COLOR_FORMAT sourceFormat,                                  void * destArray, UGL_COLOR_FORMAT destFormat,                                 UGL_SIZE arraySize);/* input routines */UGL_INPUT_DEVICE * uglSimPcPtrInit (char * pDevName,                                     UGL_EVENT_SERVICE_ID eventServiceId);UGL_INPUT_DEVICE * uglSimPcKbdInit (char * pDevName,                                     UGL_EVENT_SERVICE_ID eventServiceId);#if __cplusplus} /* extern "C" */#endif#endif

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -