Class 'Image' not found in vc++.
Posted: 2015-11-25T23:44:51-07:00
Hi.
When I use 'Image m_image' in local function like example, it works good.
But, I've got an error when 'Image m_image' move to header .h for using class member.
Class 'Image' not found. I can't understand it.
Does anyone know how to solve this problem?
the code is as following.
When I compile above code then I've got some error as following.
When I use 'Image m_image' in local function like example, it works good.
But, I've got an error when 'Image m_image' move to header .h for using class member.
Class 'Image' not found. I can't understand it.
Does anyone know how to solve this problem?
the code is as following.
Code: Select all
#pragma once
#include <Magick++.h>
// CTestview view
class CTestview : public CScrollView
{
DECLARE_DYNCREATE(CTestview)
protected:
CTestview(); // protected constructor used by dynamic creation
virtual ~CTestview();
public:
#ifdef _DEBUG
virtual void AssertValid() const;
#ifndef _WIN32_WCE
virtual void Dump(CDumpContext& dc) const;
#endif
#endif
protected:
virtual void OnDraw(CDC* pDC); // overridden to draw this view
virtual void OnInitialUpdate(); // first time after construct
DECLARE_MESSAGE_MAP()
public:
void DoDisplayImage(void);
Image m_image
};
- ------ Build started: Project: mfc_test5, Configuration: Release Win32 ------
Build started
PrepareForBuild:
Creating directory "C:\work\mfc_test5\mfc_test5\Release\".
InitializeBuildStatus:
Creating "Release\mfc_test5.unsuccessfulbuild" because "AlwaysCreate" was specified.
ClCompile:
stdafx.cpp
mfc_test5.cpp
c:\program files\imagemagick-6.8.6-q8\include\magick/pixel-accessor.h(160): warning C4244: '=' : conversion from 'double' to 'MagickCore::MagickRealType', possible loss of data
c:\work\mfc_test5\mfc_test5\mfc_test5\Testview.h(33): error C2143: syntax error : missing ';' before '}'
mfc_test5Dlg.cpp
c:\program files\imagemagick-6.8.6-q8\include\magick/pixel-accessor.h(160): warning C4244: '=' : conversion from 'double' to 'MagickCore::MagickRealType', possible loss of data
c:\work\mfc_test5\mfc_test5\mfc_test5\Testview.h(33): error C2143: syntax error : missing ';' before '}'
C:\Program Files\Intel\plsuite\include\ipl.h(778): warning C4819: The file contains a character that cannot be represented in the current code page (949). Save the file in Unicode format to prevent data loss
C:\Program Files\Intel\plsuite\examples\Tutorial.IPL\IPLROOMS\COOKROOM\macros.inc(21): warning C4005: '_ASSERTE' : macro redefinition
C:\Program Files\Microsoft Visual Studio 10.0\VC\include\crtdbg.h(213) : see previous definition of '_ASSERTE'
Build FAILED.
Time Elapsed 00:00:37.30
========== Build: 0 succeeded, 1 failed, 0 up-to-date, 0 skipped ==========