private void UpdateTitle() { Text = "Frame Preview"; if (_ffmpegResult != null && _ffmpegResult.IsUsingCustomHeaderSource()) { Text += " (Using Default Codec Header)"; } }
public static void DrawBitmapRect(Graphics graphics, IBitmapThumbTarget bitmapThumbTarget, FFmpegResult ffmpegResult, int x, int y) { Color color; if (bitmapThumbTarget.HasMouseFocus) { color = ColorBitmapMouseOver; } else if (bitmapThumbTarget.IsSelected) { color = ColorBitmapSelected; } else if (ffmpegResult != null && ffmpegResult.IsUsingCustomHeaderSource()) { color = ColorBitmapUsingHeaderSource; } else { color = ColorBitmapDefault; } var pen = new Pen(color); graphics.DrawRectangle(pen, x + 1, y + 1, bitmapThumbTarget.Width - 3, bitmapThumbTarget.Height - 3); graphics.DrawRectangle(pen, x, y, bitmapThumbTarget.Width - 1, bitmapThumbTarget.Height - 1); pen.Dispose(); }