Bug in loading a mesh & 64-bit woes

Last post 02-10-2008, 11:35 AM by The Spintz. 1 replies.
Sort Posts: Previous Next
  •  01-12-2008, 10:55 PM

    Bug in loading a mesh & 64-bit woes

    First question is pertaining a bug in a model viewer I have been working on. The bug seems to have appeared for a couple users from germany that is impossible for me to reproduce even using applocal to set my region to deutsch. My project is running c# + slimDX as MDX is no longer supported and xna just doesn't fit my needs.

    Here is a picture of the problem (uv bug):


    This happens when loading an obj file. The basics is that I use a stream reader to read line by line of the obj file. Works fine for north american versions of windows.

    Second problem is the inability to run on a 64-bit. I don't have a 64-bit system personally to build and test on so I am having trouble figuring this stuff out. I had the error message my friend was having, but I lost that. So if anyone runnning xp/vista 64-bit versions feels like trying to run my viewer (available here: http://craig.young.81.googlepages.com/) and pass along the error from the event logs, it would be greatly appreciated. Otherwise links/tutorials for compiling for 64-bits would be greatly appreciated.

    Thanks in advanced

  •  02-10-2008, 11:35 AM

    Re: Bug in loading a mesh & 64-bit woes

    EDIT: I'm the bomb.  I figured out how to edit this post and was able to fix the formatting.  I should get paid for firguring out how to post properly on these forums. 

    As far as DX10 / Vista go, I have had issues with 64 bit as well.  I actually run on Vista 32bit, but noticed DirectX structures are 4 byte aligned.  This causes major issues.  I specifically noticed this problem with the D3D10_BLEND_DESC structure.  I write an engine which uses a structure, which I though mapped directly to the D3D10_BLEND_DESC structure.  Here's the strucutre definition :

    typedef struct D3D10_BLEND_DESC {
        BOOL AlphaToCoverageEnable;
        BOOL BlendEnable[8];
        D3D10_BLEND SrcBlend;
        D3D10_BLEND DestBlend;
        D3D10_BLEND_OP BlendOp;
        D3D10_BLEND SrcBlendAlpha;
        D3D10_BLEND DestBlendAlpha;
        D3D10_BLEND_OP BlendOpAlpha;
        UINT8 RenderTargetWriteMask[8];
    } D3D10_BLEND_DESC;
    When using 4 byte alignment, this structure lines up fine. When uses 8 byte alignment, 4 bytes of padding are inserted between, AlphaToCoverageEnable and the BlendEnable array. Just based on my experiences with this, I don't see how DX is 64 bit compatible.
View as RSS news feed in XML
©2007 Microsoft Corporation. All rights reserved. Privacy Statement Terms of Use Code of Conduct Feedback