Re: Phylosophical Surface usage question.
From: Phil Taylor (phil_at_private-citizen.com)
Date: Sat, 18 Dec 2004 13:05:07 -0800
crossing process boundaries is bound to cause headaches, as its not
supported by the API.
while you may get this to work, if a driver update or anything breaks it you
are just about out of luck.
why go thru such trouble?
"Etienne Fortin" <EtienneFortin@discussions.microsoft.com> wrote in message
> Let's think about the following scenario, that violate synchronization
> guidelines but just for the fun of thinking about it.
> Ok, let's say we have an unmanaged application and a Managed DirectX
> application. The unmanaged application instanciate the Managed one as a
> object. It then pass a pointer to pixels data to the managed app. The
> app then creates a Bitmap with the supplied pointer, create a Direct3D
> Surface using that Bitmap and display that Surface to screen in a loop, at
> each vertical refresh.
> Question: If the unmanatged application modify the pixel buffer, will the
> change takes effect in what the managed app display? Or is the Managed app
> allowed to move the pixels data in memory even if an unmanaged pointer to
> pixel data was used in the creation of the Bitmap? Is the memory of the
> Bitmap pixels data locked when it is used by DirectX in the transfer to
> display memory? Will it cause access violation when the unmanaged app try
> write to the buffer?
> Etienne Fortin