ATLヘッダの利用方法

フォーラム(掲示板)ルール
フォーラム(掲示板)ルールはこちら  ※コードを貼り付ける場合は [code][/code] で囲って下さい。詳しくはこちら
tabrad2

ATLヘッダの利用方法

#1

投稿記事 by tabrad2 » 13年前

C++2010 Express editionを使用しています.
最近,bitmapファイルを読み込むためにCImage クラスを利用できることを知り,atlimage.h,atl.libを読み込んでコンパイルしました.すると下記のようなエラーと警告が出現しました.対処策の助言をお願いします.

1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(33): warning C4114: same type qualifier used more than once
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(33): error C2632: 'char' followed by 'char' is illegal
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(33): warning C4091: 'typedef ' : ignored on left of 'unsigned char' when no variable is declared
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(34): error C2632: 'short' followed by 'short' is illegal
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(34): error C2632: 'short' followed by 'int' is illegal
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(34): warning C4091: 'typedef ' : ignored on left of 'short' when no variable is declared
1>C:\Program Files\Microsoft SDKs\Windows\v7.1\include\intsafe.h(172): warning C4005: 'USHORT_MAX' : macro redefinition

ISLe
記事: 2650
登録日時: 15年前
連絡を取る:

Re: ATLヘッダの利用方法

#2

投稿記事 by ISLe » 13年前

ATLはCOMコンポーネントを作るためのライブラリで一般的なウィンドウアプリのコードといっしょには使えません。
MFC版CImageというのもありますが、EXpressはMFCをサポートしないので使えません。

Gdiplusをお勧めします。

BITMAP形式の画像ファイルならWin32 APIのLoadImage関数で読み込めますが。

閉鎖

“C言語何でも質問掲示板” へ戻る