📄 subject_26234.htm
字号:
<p>
序号:26234 发表者:apple_caro 发表日期:2002-12-30 11:56:23
<br>主题:[求]可以把bmp文件变成jpg 文件的example.
<br>内容:谢谢。
<br><a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p>
<hr size=1>
<blockquote><p>
回复者:bird 回复日期:2002-12-30 12:58:36
<br>内容:http://vbaccelerator.com/codelib/gfx/vbjpeg.htm
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:bird 回复日期:2002-12-30 12:58:48
<br>内容:http://www.colosseumbuilders.com/graphicslinks.htm
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
<font color=red>答案被接受</font><br>回复者:不说 回复日期:2002-12-30 22:47:07
<br>内容:#include <windows.h><BR>#include <gdiplus.h><BR>#include <stdio.h><BR>using namespace Gdiplus;<BR><BR>INT GetEncoderClsid(const WCHAR* format, CLSID* pClsid); // helper function<BR><BR>INT main()<BR>{<BR> // Initialize GDI+.<BR> GdiplusStartupInput gdiplusStartupInput;<BR> ULONG_PTR gdiplusToken;<BR> GdiplusStartup(&gdiplusToken, &gdiplusStartupInput, NULL);<BR><BR> CLSID encoderClsid;<BR> Status stat;<BR> Image* image = new Image(L"Bird.bmp");<BR><BR> // Get the CLSID of the PNG encoder.<BR> GetEncoderClsid(L"image/jpg", &encoderClsid);<BR><BR> stat = image->Save(L"Bird.jpg", &encoderClsid, NULL);<BR><BR> if(stat == Ok)<BR> printf("Bird.png was saved successfully\n");<BR> else<BR> printf("Failure: stat = %d\n", stat); <BR><BR> delete image;<BR> GdiplusShutdown(gdiplusToken);<BR> return 0;<BR>}<BR><BR>搞定!
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
<hr size=1>
<blockquote><p>
回复者:不说 回复日期:2002-12-31 14:27:16
<br>内容:啊?这样就接受啦?我还以为至少得问问关于GDI+的东西呢……这段代码编译都通不过啊……
<br>
<a href="javascript:history.go(-1)">返回上页</a><br><a href=http://www.copathway.com/cndevforum/>访问论坛</a></p></blockquote>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -