DirectX 10 failure with Lazarus lazarus / 72-DirectX ---------------------------------------------------------------------- SonnyBoyXXl · 2013-10-07 10:43 Hello together! I'm working on a DirectX 10/11 project and was hanging for a while now at the following problem: Code: [Select]Result := D3DX10CreateEffectFromFile(PChar('color.fx'), TD3D10_ShaderMacro(nil^), nil, 'fx_4_0', D3D10_SHADER_ENABLE_STRICTNESS, 0,  FD3D10Device, nil, nil, m_effect, errorMessage, nil);      m_technique := m_effect.GetTechniqueByIndex(0);     if (m_technique = nil) then     begin         Result := E_FAIL;         Exit;     end;     if not m_technique.IsValid then     begin         Result:=E_FAIL;         exit;     end;     result:=m_technique.GetDesc(techniqueDesc);     pass:=m_technique.GetPassByIndex(0);     if not pass.IsValid then     begin         Result := E_FAIL;         Exit;     end;     Result :=pass.GetDesc(passDesc); When I debug, the pass.GetDesc doesn't return valid information (which I will need to create the InputLayout). I tried this code now with Delphi XE2 and everything working fine with Delphi, so I believe now this a compiler issue. I use the JSB headers. Can anybody help? ---------------------------------------------------------------------- BlueIcaro · 2013-10-07 12:21 try to compile in delphi mode http://www.freepascal.org/docs-html/prog/progse73.html may be there some problem with de calling convetion. I'm don't know any thing about DirectX, but you can try it /BLueIcaro ---------------------------------------------------------------------- marcov · 2013-10-07 12:55 In D2010, pchar will be a pwidechar, while in FPC it is still a PAnsichar like in  versions before D2009 ---------------------------------------------------------------------- SonnyBoyXXl · 2015-06-09 12:37 Hi all, I have solved this problem now ! ORCA Interface works well. Also the Headers are now available. https://github.com/CMCHTPC/DelphiDX12