• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            的筆記

            隨時隨地編輯

            GdiPlus筆記

            廢話

            用過不知多少開源圖像庫,其實似乎無例外的都是幾個圖像解碼庫zlib、libpng、libjpeg的封裝。夠了,基本可以解決所有圖像問題。GdiPlus這種要死不活的東西,拜微軟所賜,偶今天才有空去瞅瞅。玩一下吧,不想為了寫幾行代碼去整個開源的解碼庫。別了,zlib;別了,libpng;別了,skia;別了,freeimage;別了,cximage;別了,devil。別了,opensource。

            source

            MSDN About GDI+
            http://msdn.microsoft.com/en-us/library/ms533797(v=VS.85).aspx

            Getting Started
            http://msdn.microsoft.com/en-us/library/ms533807(v=VS.85).aspx

            Image Class
            http://msdn.microsoft.com/en-us/library/ms534462


            Use

            Note the call to GdiplusStartup in the WinMain function. The first parameter of the GdiplusStartup function is the address of a ULONG_PTR. GdiplusStartup fills that variable with a token that is later passed to the GdiplusShutdown function. The second parameter of the GdiplusStartup function is the address of a GdiplusStartupInput structure. The preceding code relies on the default GdiplusStartupInput constructor to set the structure members appropriately.

            1.引用
            #include <gdiplus.h>
            using namespace Gdiplus;
            #pragma comment (lib,"Gdiplus.lib")

            2.初始化與銷毀

            GdiplusStartupInput gdiplusStartupInput;
            ULONG_PTR           gdiplusToken;
            // Initialize GDI+.
            GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);// Shutdown
            GdiplusShutdown(gdiplusToken);

            3.畫

            VOID OnPaint(HDC hdc)
            {
               Graphics graphics(hdc);
               Pen      pen(Color(255, 0, 0, 255));
               graphics.DrawLine(&pen, 0, 0, 200, 100);
            }

            posted on 2011-07-13 16:24 的筆記 閱讀(1070) 評論(0)  編輯 收藏 引用

            香蕉久久永久视频| 久久久久亚洲精品男人的天堂| 久久无码AV中文出轨人妻| 欧美日韩精品久久久免费观看| 久久久国产精华液| 中文字幕精品无码久久久久久3D日动漫| 亚洲а∨天堂久久精品| 久久久久亚洲AV片无码下载蜜桃| 国产精品久久久久影院色| 人妻少妇精品久久| 色偷偷偷久久伊人大杳蕉| 久久久精品国产| 模特私拍国产精品久久| 99久久777色| 综合网日日天干夜夜久久| 欧美久久一级内射wwwwww.| 婷婷伊人久久大香线蕉AV| 亚洲香蕉网久久综合影视 | 四虎亚洲国产成人久久精品| 久久综合香蕉国产蜜臀AV| 色婷婷综合久久久久中文字幕| 91视频国产91久久久| 99久久99久久精品国产片果冻 | 一本大道久久东京热无码AV| 99久久99这里只有免费的精品| 欧美亚洲国产精品久久高清| 久久影院午夜理论片无码| 97久久精品人人做人人爽| 亚洲精品高清久久| 久久超乳爆乳中文字幕| 国产精品成人99久久久久91gav | 中文国产成人精品久久亚洲精品AⅤ无码精品 | 亚洲第一永久AV网站久久精品男人的天堂AV | 欧美色综合久久久久久| 99久久国产免费福利| 国产精品免费看久久久| 久久黄色视频| 精品久久久中文字幕人妻| 国产精品久久久久久久app| 亚洲国产成人久久精品99 | 国产亚洲精品久久久久秋霞|