原贴:请教GDI+实现图形的缩放,显示程序 (construct ) 
请斑竹大人通融一下,等我的问题解决了(顶多三天)就结贴

解决方案 »

  1.   

    原贴:http://expert.csdn.net/Expert/topic/2631/2631453.xml?temp=.4543573
    assert1,我说话算数!
      

  2.   

    http://www.vckbase.com/document/viewdoc.asp?id=451
      

  3.   

    Scaling Images
    You can use the DrawImage method of the Graphics class to draw and position images. DrawImage is an overloaded method, so there are several ways you can supply it with arguments. One variation of the DrawImage method receives the address of an Image object and a reference to a Rectangle object. The rectangle specifies the destination for the drawing operation; that is, it specifies the rectangle in which the image will be drawn. If the size of the destination rectangle is different from the size of the original image, the image is scaled to fit the destination rectangle. The following example draws the same image three times: once with no scaling, once with an expansion, and once with a compression. Bitmap myBitmap(L"Spiral.png");
    Rect expansionRect(80, 10, 2 * myBitmap.GetWidth(), myBitmap.GetHeight());
    Rect compressionRect(210, 10, myBitmap.GetWidth() / 2, 
       myBitmap.GetHeight() / 2);myGraphics.DrawImage(&myBitmap, 10, 10);
    myGraphics.DrawImage(&myBitmap, expansionRect);
    myGraphics.DrawImage(&myBitmap, compressionRect);
      

  4.   

    //抱歉很忙,原来是设定更改jpeg质量的,忘记删除了//鼠标拖动图像,即pan view,就是得到鼠标移动距离,再让滚动条移动位置就行了//GDIplusImageDoc.cpp 173行 的 &encoderParameters 改为NULL//即用默认的jpeg质量.更改如下: Status last =  m_pImage->Save(ToWChar   (strFileSave.GetBuffer(strFileSave.GetLength())),    &clsid, NULL);
      

  5.   

    pan view的程序已发,明天回家了,^_^