.NET
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

Using DirectX in C# ObjectARX add-in

2 REPLIES 2
Reply
Message 1 of 3
gyachuk
324 Views, 2 Replies

Using DirectX in C# ObjectARX add-in

Sorry for the cryptic title. I don't know if .NET or ObjectARX group is more appropriate, but I'm trying here first.

Is there some way to have my ObjectARX dll use DirectX even though DirectX seems to have managed code in its DllMain? The managed code in DirectX causes the (MDA) error: LoaderLock was detected.

Is there some way of getting around this, other than rewriting the app to not use the DirectX classes? I've already moved the drawing over to ObjectARX. Do I have to replace all the DX classes too?

Thanks,

Greg
2 REPLIES 2
Message 2 of 3
ahmed.felix
in reply to: gyachuk

Just turn the debugging assistant off. In Visual Studio go to Debug | Exceptions | Managed Debugging Assistants and uncheck the LoaderLock. That should do it.
Message 3 of 3
gyachuk
in reply to: gyachuk

Thanks for the suggestion, but unfortunately that isn't the problem. It was already unchecked in Visual Studio.

That just controls whether Visual Studio catches the exception or lets it go through. It doesn't control whether the exception is generated.

I need some way of having the DLL loaded without generating the exception. Obviously it can be done because the DirectX DLL can be loaded by C# applications.

Thanks, Greg

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk DevCon in Munich May 28-29th


Autodesk Design & Make Report

”Boost