void drawSelectionChanged(SelectionState state, IntRect selection) { g_DrawUserInput.State = state; g_DrawUserInput.Rect = selection; if (state == SELECTION_DONE) { // Crop depth if (getDepthStream().isValid() && isDepthOn() && g_DrawConfig.Streams.Depth.Coloring != DEPTH_OFF) { drawCropStream(getDepthStream(), g_DrawConfig.DepthLocation, selection, 2); } // Crop image if (getColorStream().isValid() && isColorOn() && g_DrawConfig.Streams.Color.Coloring != COLOR_OFF) { drawCropStream(getColorStream(), g_DrawConfig.ColorLocation, selection, 4); } // Crop IR if (getIRStream().isValid() && isIROn() && g_DrawConfig.Streams.Color.Coloring != COLOR_OFF) { drawCropStream(getIRStream(), g_DrawConfig.ColorLocation, selection, 4); } } }
void drawSelectionChanged(SelectionState state, IntRect selection) { g_DrawUserInput.State = state; g_DrawUserInput.Rect = selection; if (state == SELECTION_DONE) { // Crop depth if (getDepthGenerator() != NULL && g_DrawConfig.Streams.Depth.Coloring != DEPTH_OFF) { drawCropStream(getDepthGenerator(), g_DrawConfig.DepthLocation, selection, 2); } // Crop image if (getImageGenerator() != NULL && g_DrawConfig.Streams.Image.Coloring != IMAGE_OFF) { drawCropStream(getImageGenerator(), g_DrawConfig.ImageLocation, selection, 4); } // Crop IR if (getIRGenerator() != NULL && g_DrawConfig.Streams.Image.Coloring != IMAGE_OFF) { drawCropStream(getIRGenerator(), g_DrawConfig.ImageLocation, selection, 4); } } }