我有一個函數,它在一個Handle
到圖像:獲取圖像的手柄在存儲器中的C#
DoSomethingWithImage(int imageHandle)
{
}
以我主,我有一個Image myImage
,它駐留在存儲器中。 如何獲得Handle
至myImage
,以便我可以將Handle
傳遞給DoSomethingWithImage()
?
main()
{
//memorySTream is a byte[]
Image myImage = Image.FromStream(memoryStream, true);
DoSomethingWithImage(???);
}
爲什麼如果你傳遞一個圖像,你會收集一個Int? – 2010-09-20 03:08:24
DoSomethingWithImage(int imageHandle)是SDK中的一個函數。我不知道爲什麼他們也接受一個整數。 SDK說int是一個Image的句柄。 – Robogal 2010-09-20 03:14:31