i have a problem in tutorial 0

kamkam

03-07-2008 07:03:29

hi
i'm getting started with mogreSDK_1.4.8
for this i have downloaded mogreSDK_1.4.8 from the URL in the tutorial 0
and then i installed that in c:/OgreSDK
and the i downloaded vcredist_x86.exe and i executed that
after that i downloaded the mogreframework and i copied the .DLL file in the Bin/Debug and Bin/Release in the c:/OgreSDK and then i added the ";C:\OgreSDK\bin\release;C:\OgreSDK\bin\debug" to my PATH variable
after all,i started the c# 2005 and created a windows Application and i deleted the default Form and then i added Mogre.dll and MogreFramework.dll to the project's references and then on solution explorer i clicked on "show all files" and in Bin\debug file i copied all the .cfg files from C:\OgreSDK\bin\release and then i created a new file in Bin file of my project and then i called that "Release" and i copied all the .cfg files from C:\OgreSDK\bin\release to this file ,too
and in the resources.cfg i replaced C:/OgreSDK/ with ../../
after all, i replaced the below text to my "Program.cs":
using System;
using System.Collections.Generic;
using System.Windows.Forms;
using MogreFramework;
using Mogre;

namespace Test
{
static class Program
{
[STAThread]
static void Main()
{
OgreWindow win = new OgreWindow();
win.Go();
}
}
}
and at last i pressed F5 and i saw this message for the line "win.Go();":

Could not load file or assembly 'Mogre, Version=1.4.8.0, Culture=neutral, PublicKeyToken=null' or one of its dependencies. This application has failed to start because the application configuration is incorrect. Reinstalling the application may fix this problem. (Exception from HRESULT: 0x800736B1)

raygeee

03-07-2008 17:27:20

... and then on solution explorer i clicked on "show all files" and in Bin\debug file i copied all the .cfg files from C:\OgreSDK\bin\release and then i created a new file in Bin file of my project and then i called that "Release" and i copied all the .cfg files from C:\OgreSDK\bin\release to this file ,too
and in the resources.cfg i replaced C:/OgreSDK/ with ../../


Why did you copy release files into the debug folder?

Take a look here.

kamkam

03-07-2008 19:50:02

i saw this in tutorial0:

Adding Configuration Files
...In windows, navigate to the C:\OgreSDK\bin\release directory and copy all files with the ".cfg" extention into your project's bin\debug, and bin\release folders (you may have to create the folders)...

so i copied all the .cfg files from C:\OgreSDK\bin\release to bin\debug and bin\release
i have done a big wrong? :?

qi-an

04-07-2008 11:35:15

note : It's say copy from OgreSDK into YOUR PROJECT'S bin\debug folder ! OgreSDK's bin to yours bin ,OgreSDK's release to yours release !Do you understand? :lol:

kamkam

04-07-2008 12:02:03

I'm sorry! :( but I don't know how should i do it!! please tell me :oops:

qi-an

04-07-2008 12:31:04

Create your project with editer,then in your project floder you also can see bin\debug folder! copy ...from OgreSDK into your porject's...!understand?:lol:

kamkam

04-07-2008 14:19:18

I'm very sorry again!
you are very intelligent and I'm a little mad!
please tell me explicitly:
what have i done wrong ? and what should I do to make this correct?
please with COMPELETE explain (for dummies!)
thanks!!!!
:!:

qi-an

05-07-2008 08:24:07

I'am so sorry !
I use MogreSDK 1.4.6 anything work fine!

kamkam

05-07-2008 14:37:23

no one can help me!!! :cry:
i should do it
please help me

raygeee

05-07-2008 15:04:40

It seems you mixed up the debug and release files. They are not the same!

Delete all Ogre files in the folders ../yourproject/bin/debug and ../yourproject/bin/release.
Then copy all Ogre files from ../OgreSDK/bin/debug to ../yourproject/bin/debug and all files from ../OgreSDK/bin/release to ../yourproject/bin/release

The file plugins.cfg in the debug folder should have a _d suffix. The one in the release folder should not. But that's only the easy part. The part more important is to seperate the debug dlls from the release dlls.

kamkam

06-07-2008 17:12:08

It seems you mixed up the debug and release files. They are not the same!

Delete all Ogre files in the folders ../yourproject/bin/debug and ../yourproject/bin/release.
Then copy all Ogre files from ../OgreSDK/bin/debug to ../yourproject/bin/debug and all files from ../OgreSDK/bin/release to ../yourproject/bin/release

The file plugins.cfg in the debug folder should have a _d suffix. The one in the release folder should not. But that's only the easy part. The part more important is to seperate the debug dlls from the release dlls.


thanks for your attention,
but i did it and it didn't make any difference in my problem

kamkam

11-07-2008 08:29:35

I guess all the problems are about my adding configurations
please study my first note CAREFULLY and HELP me!!!! :cry:

EMeythaler

16-07-2008 17:01:13

Okay, I had this same problem and I did two things to fix it. First, you need to download the source for the Mogre Framework and compile it yourself. There's a link to it at the beginning of Tutorial 0. Once that compiles, run the test app that comes with it. It should work. Now, copy the config files from the test app's release or debug folder (it doesn't matter which, they're the same) as well as MogreFramework.dll and Mogre.dll (not sure if that's actually necessary, but it's what i did) and paste them in the debug and release folders of your project. It should work now. Hope that helps.

EMeythaler

16-07-2008 17:04:10

As far as I can tell the issue is that the MogreFramework SDK references the wrong Ogre.dll (an older version, so you have to recompile so it will reference the new one). Additionally, the config files that come with Mogre reference the debug builds of the dlls, which as far as I understand it, Mogre doesn't like. It wants the release versions. Either way, copying the config files from the framework test app worked for me. If you installed Mogre in the default location, you shouldn't even have to change the config files at all. Everything should be set up perfectly already.

raygeee

16-07-2008 23:50:32

As far as I can tell the issue is that the MogreFramework SDK references the wrong Ogre.dll (an older version, so you have to recompile so it will reference the new one). Additionally, the config files that come with Mogre reference the debug builds of the dlls, <...>
I guess you mean the Mogre.dll? Might be, can't tell atm. Could someone verify that?

<...> which as far as I understand it, Mogre doesn't like. It wants the release versions. Either way, copying the config files from the framework test app worked for me. If you installed Mogre in the default location, you shouldn't even have to change the config files at all. Everything should be set up perfectly already.Maybe you got it working but Mogre does NOT have a general problem with the debug versions. You just MUST have the correct dlls and the right references to them everywhere, then it works. But, as many people here can tell you that's not an easy task at the beginning. ;-)

EMeythaler

17-07-2008 01:26:03

Maybe you got it working but Mogre does NOT have a general problem with the debug versions. You just MUST have the correct dlls and the right references to them everywhere, then it works. But, as many people here can tell you that's not an easy task at the beginning.

Exactly, I only just started with Mogre about two days ago (I've been programming Ogre for about three years though). As soon as my problem went away, I didn't pursue it any further. I'm only using Mogre for tools development (gotta love Windows Forms), so if it works, then that's good enough for me. My only goal with posting the fix that I found was to help kamkam get going. I am by no means an expert when it comes to Mogre.

Additionally, I'm using VC 2008 express for Mogre Development (my school uses 2005, so that's what's on my laptop), so there could be problems from that, but I did notice that the only project I had that worked (both debug and release) without any problems was the Mogre Framework Test project. And it only references the Release .dlls (I didn't mess with the config files that came with it).

Makaze

17-07-2008 15:42:55

I can't get things to work with the debug configs either. The second there is an _d on any of the plugins no dice no matter what dlls I'm pointing to. So while there may not be a core problem with Mogre using the debug build there certainly seems to be one with the latest release.

kamkam

17-07-2008 16:22:38

Okay, I had this same problem and I did two things to fix it. First, you need to download the source for the Mogre Framework and compile it yourself. There's a link to it at the beginning of Tutorial 0. Once that compiles, run the test app that comes with it. It should work. Now, copy the config files from the test app's release or debug folder (it doesn't matter which, they're the same) as well as MogreFramework.dll and Mogre.dll (not sure if that's actually necessary, but it's what i did) and paste them in the debug and release folders of your project. It should work now. Hope that helps.

I'm sorry dear EMeythaler , but i'm an amateur and I cannot understand what you said . please give more information and more explicitly!
i want an step by step instruction, for example please,write the link and write how can i complie that ...
:oops:
if you do,i will never forget your help,thanks

EMeythaler

17-07-2008 18:39:41

Okay, no problem. Before I can help you though, I need to know if you have Subversion (SVN). If you don't, you can download and install it from here http://tortoisesvn.tigris.org/. That link should take you to the Tortoise SVN client. Once you have that installed, let me know, and I can guide you through the rest of the steps.

kamkam

19-07-2008 15:36:57

Okay, no problem. Before I can help you though, I need to know if you have Subversion (SVN). If you don't, you can download and install it from here http://tortoisesvn.tigris.org/. That link should take you to the Tortoise SVN client. Once you have that installed, let me know, and I can guide you through the rest of the steps.

thanks,okay, i have downloaded and installed that ,what should i do now?