PDA

View Full Version : [C# | DXGI] Passare oggetti nativi a oggetti gestiti


zarko
21-07-2010, 22:03
Ciao a tutti,
ho creato in una dll c++ una funzione che restituisce lo struct DXGI_ADAPTER_DESC1 di DXGI 1.1, come faccio a riscrivere questo struct in c# per poter chiamare questa funzione da un exe .net (usanto DllImport)?

Definizione c++

typedef struct DXGI_ADAPTER_DESC1
{
WCHAR Description[ 128 ];
UINT VendorId;
UINT DeviceId;
UINT SubSysId;
UINT Revision;
SIZE_T DedicatedVideoMemory;
SIZE_T DedicatedSystemMemory;
SIZE_T SharedSystemMemory;
LUID AdapterLuid;
UINT Flags;
} DXGI_ADAPTER_DESC1;


Grazie anticipate,
Zarko.