Jump to content

  • Log In with Google      Sign In   
  • Create Account

We're offering banner ads on our site from just $5!

1. Details HERE. 2. GDNet+ Subscriptions HERE. 3. Ad upload HERE.


Don't forget to read Tuesday's email newsletter for your chance to win a free copy of Construct 2!


Call unmanaged code out of managed / c++/cli


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
1 reply to this topic

#1 ~Helgon   Members   -  Reputation: 357

Like
0Likes
Like

Posted 27 December 2012 - 10:43 PM

Hey,

I have a little problem. The situation is that I have a Windows Form on which i render a DirectX frame.

So. The problem I have is that if I want to initialize a XMFLOAT4X4 (<xnamath.h>) I get an error.
I've realized that XMFLOAT4X4, XMVECTORF32, XMVECTOR ... evoke the error. On the other hand XMFLOAT3X3, XMFLOAT3,2 etc. work without any error or warning. Strange

It says:
"__clrcall cannot be used on functions compiled to native code" or
"This function cannot be compiled as managed"

All the problems occur because of this c++/cli - that's for sure because on native C++ all the xnamath stuff work. But I'm sure there must be a solution :/

Any idea how I can handle this problem? I can't imagine that it should not be possible to use the Microsoft's own xnamath lib.

Regards

Edited by ~Helgon, 27 December 2012 - 11:40 PM.

from time to time i find time


Sponsor:

#2 JiiPee   Members   -  Reputation: 135

Like
0Likes
Like

Posted 28 December 2012 - 04:11 AM

Can you clarify the problem a little bit? Are you refering to some dll on managed side, which is c++/Cli library, and then you get the compile error when you try to build your application? Or are you just refering to xna library and it gives the error message?


See my game dev blog: http://gamedev4hobby.blogspot.fi/




Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS