Problem in debug

dezhi

23-05-2010 18:25:20

here is the code.
using System;
using System.Collections.Generic;
using System.Windows.Forms;
using MogreFramework;
using Mogre;

namespace Test
{
static class Program
{
[STAThread]
static void Main()
{
try
{
OgreWindow win = new OgreWindow();
win.Go();
}
catch (System.Runtime.InteropServices.SEHException)
{
if (OgreException.IsThrown)
MessageBox.Show(OgreException.LastException.FullDescription,
"An Ogre exception has occurred!");
else
throw;
}

}
}
}


and the image of debug folder


and the plugin.cfg file

# Defines plugins to load

# Define plugin folder
PluginFolder=.

# Define plugins
Plugin=RenderSystem_Direct3D9_d
Plugin=RenderSystem_GL_d
Plugin=Plugin_ParticleFX_D
Plugin=Plugin_BSPSceneManager_d
Plugin=Plugin_OctreeSceneManager_d
Plugin=Plugin_CgProgramManager_d


when built in release, it is just fine.
but in debug, with mogre_d.dll and MogreFramework.dll
here is the ogre.log file

01:46:47: Creating resource group General
01:46:47: Creating resource group Internal
01:46:47: Creating resource group Autodetect
01:46:47: SceneManagerFactory for type 'DefaultSceneManager' registered.
01:46:47: Registering ResourceManager for type Material
01:46:47: Registering ResourceManager for type Mesh
01:46:47: Registering ResourceManager for type Skeleton
01:46:47: MovableObjectFactory for type 'ParticleSystem' registered.
01:46:47: OverlayElementFactory for type Panel registered.
01:46:47: OverlayElementFactory for type BorderPanel registered.
01:46:47: OverlayElementFactory for type TextArea registered.
01:46:47: Registering ResourceManager for type Font
01:46:47: ArchiveFactory for archive type FileSystem registered.
01:46:47: ArchiveFactory for archive type Zip registered.
01:46:47: DDS codec registering
01:46:47: FreeImage version: 3.13.1
01:46:47: This program uses FreeImage, a free, open source image library supporting all common bitmap formats. See http://freeimage.sourceforge.net for details
01:46:47: Supported formats: bmp,ico,jpg,jif,jpeg,jpe,jng,koa,iff,lbm,mng,pbm,pbm,pcd,pcx,pgm,pgm,png,ppm,ppm,ras,tga,targa,tif,tiff,wap,wbmp,wbm,psd,cut,xbm,xpm,gif,hdr,g3,sgi,exr,j2k,j2c,jp2,pfm,pct,pict,pic,bay,bmq,cr2,crw,cs1,dc2,dcr,dng,erf,fff,hdr,k25,kdc,mdc,mos,mrw,nef,orf,pef,pxn,raf,raw,rdc,sr2,srf,arw,3fr,cine,ia,kc2,mef,nrw,qtk,rw2,sti,drf,dsc,ptx,cap,iiq,rwz
01:46:47: PVRTC codec registering
01:46:47: Registering ResourceManager for type HighLevelGpuProgram
01:46:47: Registering ResourceManager for type Compositor
01:46:47: MovableObjectFactory for type 'Entity' registered.
01:46:47: MovableObjectFactory for type 'Light' registered.
01:46:47: MovableObjectFactory for type 'BillboardSet' registered.
01:46:47: MovableObjectFactory for type 'ManualObject' registered.
01:46:47: MovableObjectFactory for type 'BillboardChain' registered.
01:46:47: MovableObjectFactory for type 'RibbonTrail' registered.
01:46:47: Loading library .\RenderSystem_Direct3D9_d
01:46:52: *-*-* OGRE Shutdown
01:46:52: Unregistering ResourceManager for type Compositor
01:46:52: Unregistering ResourceManager for type Font
01:46:52: Unregistering ResourceManager for type Skeleton
01:46:52: Unregistering ResourceManager for type Mesh
01:46:52: Unregistering ResourceManager for type HighLevelGpuProgram


it seems that something wrong with loading RenderSystem_Direct3D9_d.dll, but the pluging.cfg is all right and the DLL file is right there.
will someone help me? it drives me crazy.

this is the debug folder

xerios

23-05-2010 19:00:49

Does it work in release mode?

If it does, then this might be the problem : viewtopic.php?f=8&t=12052

dezhi

24-05-2010 05:47:43

thanks for reply.
I find that, in debug mode, no matter i use debug version mogre_d.dll or release version mogre.dll, with the plugins.cfg for release, it will be fine, but, if i use the plugins.cfg for debug, it will be wrong. i check the log file,

13:11:15: Creating resource group General
13:11:15: Creating resource group Internal
13:11:15: Creating resource group Autodetect
13:11:15: SceneManagerFactory for type 'DefaultSceneManager' registered.
13:11:15: Registering ResourceManager for type Material
13:11:15: Registering ResourceManager for type Mesh
13:11:15: Registering ResourceManager for type Skeleton
13:11:15: MovableObjectFactory for type 'ParticleSystem' registered.
13:11:15: OverlayElementFactory for type Panel registered.
13:11:15: OverlayElementFactory for type BorderPanel registered.
13:11:15: OverlayElementFactory for type TextArea registered.
13:11:15: Registering ResourceManager for type Font
13:11:15: ArchiveFactory for archive type FileSystem registered.
13:11:15: ArchiveFactory for archive type Zip registered.
13:11:15: DDS codec registering
13:11:15: FreeImage version: 3.13.1
13:11:15: This program uses FreeImage, a free, open source image library supporting all common bitmap formats. See http://freeimage.sourceforge.net for details
13:11:15: Supported formats: bmp,ico,jpg,jif,jpeg,jpe,jng,koa,iff,lbm,mng,pbm,pbm,pcd,pcx,pgm,pgm,png,ppm,ppm,ras,tga,targa,tif,tiff,wap,wbmp,wbm,psd,cut,xbm,xpm,gif,hdr,g3,sgi,exr,j2k,j2c,jp2,pfm,pct,pict,pic,bay,bmq,cr2,crw,cs1,dc2,dcr,dng,erf,fff,hdr,k25,kdc,mdc,mos,mrw,nef,orf,pef,pxn,raf,raw,rdc,sr2,srf,arw,3fr,cine,ia,kc2,mef,nrw,qtk,rw2,sti,drf,dsc,ptx,cap,iiq,rwz
13:11:15: PVRTC codec registering
13:11:15: Registering ResourceManager for type HighLevelGpuProgram
13:11:15: Registering ResourceManager for type Compositor
13:11:15: MovableObjectFactory for type 'Entity' registered.
13:11:15: MovableObjectFactory for type 'Light' registered.
13:11:15: MovableObjectFactory for type 'BillboardSet' registered.
13:11:15: MovableObjectFactory for type 'ManualObject' registered.
13:11:15: MovableObjectFactory for type 'BillboardChain' registered.
13:11:15: MovableObjectFactory for type 'RibbonTrail' registered.
13:11:15: Loading library .\RenderSystem_Direct3D9_d
13:11:17: *-*-* OGRE Shutdown

13:11:17: Unregistering ResourceManager for type Compositor
13:11:17: Unregistering ResourceManager for type Font
13:11:17: Unregistering ResourceManager for type Skeleton
13:11:17: Unregistering ResourceManager for type Mesh
13:11:17: Unregistering ResourceManager for type HighLevelGpuProgram


it seems like something goes wrong while loading RenderSystem_Direct3D9_d.dll. it's strange. i dont konw why. will someone help me?