• <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 的筆記 閱讀(1076) 評論(0)  編輯 收藏 引用

            伊人色综合九久久天天蜜桃| 久久无码高潮喷水| 2021精品国产综合久久| 久久国产精品99国产精| 狠狠久久亚洲欧美专区| 国产激情久久久久影院小草| 香蕉99久久国产综合精品宅男自 | 精品久久久无码人妻中文字幕| 老男人久久青草av高清| 99久久久国产精品免费无卡顿 | 亚洲精品国产美女久久久| 久久久久亚洲精品天堂| 国产伊人久久| 亚洲va中文字幕无码久久不卡| 99久久99久久精品国产| 超级碰碰碰碰97久久久久| 日韩精品久久久久久| 伊人久久大香线蕉综合Av | 狠狠精品干练久久久无码中文字幕| 久久久久久久久久久免费精品| 久久青青草原精品国产| 色婷婷久久久SWAG精品| 久久久精品午夜免费不卡| 亚洲性久久久影院| 久久久久夜夜夜精品国产| 亚洲伊人久久综合影院| yellow中文字幕久久网| 亚洲∧v久久久无码精品| 久久久无码精品午夜| 久久福利青草精品资源站| 亚洲国产精品一区二区久久hs| 久久精品成人| 亚洲成色999久久网站| 九九久久自然熟的香蕉图片| 久久精品国产AV一区二区三区| 久久一区二区免费播放| 久久精品国产欧美日韩| 国产综合精品久久亚洲| 久久99精品久久只有精品| 欧美丰满熟妇BBB久久久| 一本久久a久久精品vr综合|