Jump to content

  • Log In with Google      Sign In   
  • Create Account


Messed up compiles, different sub-field offsets


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 Krohm   Crossbones+   -  Reputation: 2961

Like
0Likes
Like

Posted 03 January 2013 - 09:22 AM

I don't really know where to look to fix this. Perhaps I should set a higher verbosity level?

So I checked project settings... they seem compatible. But maybe I've missed something. I guess so.

Or maybe I'm compiling against the wrong runtime in different packages? It seems not...

 

Ok, first thing first. While in the process of a bug hunt I have (I admit it has been a terrible idea) integrated AssImp in VC2012 build toolchain. Now I cannot get a correct executable. It compiles and it runs up to a certain point but then runs utterly amok.

Sometimes it seems to work with a full rebuild, but more often than not, it doesn't.

 

Problem is as follows. In the AssImp package,

AssImp_ok.png

So my understanding is the following. Structure dstMesh begins at SOME_ADDRESS. The pointer mFaces is stored at SOME_ADDRESS+124.

AssImp works as intended. The shaded lines of code were added by me.

The size of an aiMesh structure is 1176 bytes.

Seems legit.

 

Now let's get to my code. So there could be anything going on as it's a different project.

Filter_wrong.png

So sure I have messed up packing settings somehow.

I'm not even sure I've looked at them correctly. Perhaps I should look for pragmas.

Pointer size appears coherent.

I'm thinking about dumping offsets for all sub-fields and check the first difference in the hope to gain some insight on what's going on. I thought it might be a pointer-size difference but it's both 4 bytes.

 

Sure it's a project setting to double check. Or a defined macro? Where would you look?



Sponsor:

#2 Krohm   Crossbones+   -  Reputation: 2961

Like
2Likes
Like

Posted 05 January 2013 - 04:43 AM

Ok, for future reference in case anyone has similar problems.

It turns out that the project being built was still using the previous library version. Besides some minimal difference, the libraries were source-compatible and apparently link-compatible as well.






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