コード例 #1
0
        public void RegisterInterface(IAltSecUpdate iAltSec)
        {
            CreateOffscreenBitmap = new CreateOffscreenBitmapDelegate(iAltSec.CreateOffscreenBitmap);
            SwitchSurface         = new SwitchSurfaceDelegate(iAltSec.SwitchSurface);
            CreateNineGridBitmap  = new CreateNineGridBitmapDelegate(iAltSec.CreateNineGridBitmap);
            FrameMarker           = new FrameMarkerDelegate(iAltSec.FrameMarker);
            StreamBitmapFirst     = new StreamBitmapFirstDelegate(iAltSec.StreamBitmapFirst);
            StreamBitmapNext      = new StreamBitmapNextDelegate(iAltSec.StreamBitmapNext);
            DrawGdiPlusFirst      = new DrawGdiPlusFirstDelegate(iAltSec.DrawGdiPlusFirst);
            DrawGdiPlusNext       = new DrawGdiPlusNextDelegate(iAltSec.DrawGdiPlusNext);
            DrawGdiPlusEnd        = new DrawGdiPlusEndDelegate(iAltSec.DrawGdiPlusEnd);
            DrawGdiPlusCacheFirst = new DrawGdiPlusCacheFirstDelegate(iAltSec.DrawGdiPlusCacheFirst);
            DrawGdiPlusCacheNext  = new DrawGdiPlusCacheNextDelegate(iAltSec.DrawGdiPlusCacheNext);
            DrawGdiPlusCacheEnd   = new DrawGdiPlusCacheEndDelegate(iAltSec.DrawGdiPlusCacheEnd);

            altsec->CreateOffscreenBitmap = Marshal.GetFunctionPointerForDelegate(CreateOffscreenBitmap);
            altsec->SwitchSurface         = Marshal.GetFunctionPointerForDelegate(SwitchSurface);
            altsec->CreateNineGridBitmap  = Marshal.GetFunctionPointerForDelegate(CreateNineGridBitmap);
            altsec->FrameMarker           = Marshal.GetFunctionPointerForDelegate(FrameMarker);
            altsec->StreamBitmapFirst     = Marshal.GetFunctionPointerForDelegate(StreamBitmapFirst);
            altsec->StreamBitmapNext      = Marshal.GetFunctionPointerForDelegate(StreamBitmapNext);
            altsec->DrawGdiPlusFirst      = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusFirst);
            altsec->DrawGdiPlusNext       = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusNext);
            altsec->DrawGdiPlusEnd        = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusEnd);
            altsec->DrawGdiPlusCacheFirst = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheFirst);
            altsec->DrawGdiPlusCacheNext  = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheNext);
            altsec->DrawGdiPlusCacheEnd   = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheEnd);
        }
コード例 #2
0
		public void RegisterInterface(IAltSecUpdate iAltSec)
		{
			CreateOffscreenBitmap = new CreateOffscreenBitmapDelegate(iAltSec.CreateOffscreenBitmap);
			SwitchSurface = new SwitchSurfaceDelegate(iAltSec.SwitchSurface);
			CreateNineGridBitmap = new CreateNineGridBitmapDelegate(iAltSec.CreateNineGridBitmap);
			FrameMarker = new FrameMarkerDelegate(iAltSec.FrameMarker);
			StreamBitmapFirst = new StreamBitmapFirstDelegate(iAltSec.StreamBitmapFirst);
			StreamBitmapNext = new StreamBitmapNextDelegate(iAltSec.StreamBitmapNext);
			DrawGdiPlusFirst = new DrawGdiPlusFirstDelegate(iAltSec.DrawGdiPlusFirst);
			DrawGdiPlusNext = new DrawGdiPlusNextDelegate(iAltSec.DrawGdiPlusNext);
			DrawGdiPlusEnd = new DrawGdiPlusEndDelegate(iAltSec.DrawGdiPlusEnd);
			DrawGdiPlusCacheFirst = new DrawGdiPlusCacheFirstDelegate(iAltSec.DrawGdiPlusCacheFirst);
			DrawGdiPlusCacheNext = new DrawGdiPlusCacheNextDelegate(iAltSec.DrawGdiPlusCacheNext);
			DrawGdiPlusCacheEnd = new DrawGdiPlusCacheEndDelegate(iAltSec.DrawGdiPlusCacheEnd);
			
			altsec->CreateOffscreenBitmap = Marshal.GetFunctionPointerForDelegate(CreateOffscreenBitmap);
			altsec->SwitchSurface = Marshal.GetFunctionPointerForDelegate(SwitchSurface);
			altsec->CreateNineGridBitmap = Marshal.GetFunctionPointerForDelegate(CreateNineGridBitmap);
			altsec->FrameMarker = Marshal.GetFunctionPointerForDelegate(FrameMarker);
			altsec->StreamBitmapFirst = Marshal.GetFunctionPointerForDelegate(StreamBitmapFirst);
			altsec->StreamBitmapNext = Marshal.GetFunctionPointerForDelegate(StreamBitmapNext);
			altsec->DrawGdiPlusFirst = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusFirst);
			altsec->DrawGdiPlusNext = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusNext);
			altsec->DrawGdiPlusEnd = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusEnd);
			altsec->DrawGdiPlusCacheFirst = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheFirst);
			altsec->DrawGdiPlusCacheNext = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheNext);
			altsec->DrawGdiPlusCacheEnd = Marshal.GetFunctionPointerForDelegate(DrawGdiPlusCacheEnd);
		}