void OnFrameProcessed(System.Object sender, FrameProcessedEventArgs args) { Seg3D s = (Seg3D)sender; if (s != null) { Image image = s.AcquireSegmentedImage(); if (image != null) { Debug.Log("Color = " + image.Info.width + "x" + image.Info.height); texPlugin.UpdateTextureNative(image, segTex2DPtr); } else { Debug.Log("Image is null."); } } }
void OnFrameProcessed(System.Object sender, FrameProcessedEventArgs args) { Seg3D s = (Seg3D)sender; if (s == null) { Debug.Log("Null"); } else { Image image = s.AcquireSegmentedImage(); if (image != null) { texPlugin.UpdateTextureNative(image, colorTex2DPtr); } else { Debug.Log("Image is null."); } } s.Dispose(); }