Jump to content

  • Log In with Google      Sign In   
  • Create Account

SharpDX Sharing textures between 32-bit and 64-bit process


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
No replies to this topic

#1 Asik   Members   -  Reputation: 136

Like
0Likes
Like

Posted 27 August 2013 - 12:19 PM

I have a bit of a strange use case. My application uses 2 processes. One process is 32-bit and will create a texture (IDirect3DSurface9, i.e. SharpDX.Direct3D9.Surface) for sharing. It will send the shared handle to another process which is 64-bit and also uses SharpDX. From this process it will read the shared handle and attempt to open the shared texture. Ultimately the use case is that the 32-bit process writes into the texture using some unmanaged 32-bit libraries, and the 64-bit process displays the texture using AnyCPU/64-bit libraries.

 

I wonder if this can work at all considering IntPtr is 64-bit on 64-bit processes and 32-bit on 32-bit processes, and this is the type used to represent shared texture handles in SharpDX. Direct3D is a 32-bit-only API, right? Therefore the upper 32 bits of an IntPtr used to store a Direct3D handle should be unused, right?


Edited by Asik, 27 August 2013 - 12:20 PM.


Sponsor:



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