Sign in to follow this  

[.net] BadImageFormatException from creating a simple class instance

This topic is 4244 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Recommended Posts

First, take a look at this screenshot. http://silvershade-games.com/downloads/fascinating.jpg Declaration of the base class: public abstract class RenderManagerBase Declaration of the implementation of the class: public class RenderManagerDirectX9 : RenderManagerBase Two standard classes, but i get the BadImageFormatException when creating an instance of the class and i have no idea why. The system that its compiled under has a processor with 2 cores and running windows with 64bit support. However, when i compile the same thing on my machine (AMD Athlon 64 which only has one core) it compiles fine. We both have Visual Studio 2005, running XP. Any ideas? :)

Share this post


Link to post
Share on other sites
Quote:
Original post by Machaira
Which DX update are you running? According to the docs for the August 05 update, the Material class's constructor doesn't take a parameter.


I forgot to mention that the material you see there is not a DX material but a custom one used internally by the engine.

Share this post


Link to post
Share on other sites
Quote:
Original post by Machaira
Have you stepped through the code for the constructors, especially for the Material object?


Ive stepped through the code and the crash occurs before the contructor
members have a chance to get called, as highlighted in yellow on the screenshot.
Thats why im puzzled, because i have never seen a class creation crash like this.

Share this post


Link to post
Share on other sites

This topic is 4244 days old which is more than the 365 day threshold we allow for new replies. Please post a new topic.

If you intended to correct an error in the post then please contact us.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this