using System;
using System.Collections.Generic;
using System.Drawing;
using System.IO;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Media.Imaging;
namespace Tango.RemoteDesktop
{
/// <summary>
/// Represents an image frame.
/// </summary>
/// <seealso cref="System.IDisposable" />
public interface IFrame : IDisposable
{
/// <summary>
/// Gets the frame width.
/// </summary>
int Width { get; }
/// <summary>
/// Gets the frame height.
/// </summary>
int Height { get; }
/// <summary>
/// Returns a GDI bitmap representing the frame.
/// </summary>
/// <returns></returns>
Bitmap ToBitmap();
/// <summary>
/// Returns a WPF BitmapSource representing the frame.
/// </summary>
/// <returns></returns>
BitmapSource ToBitmapSource();
/// <summary>
/// Applies this frame onto an existing bitmap.
/// </summary>
/// <param name="bitmap">The bitmap.</param>
void Apply(Bitmap bitmap);
/// <summary>
/// Returns an instance of <see cref="IFrameEncoder"/> ready to encode this frame.
/// </summary>
/// <typeparam name="T"></typeparam>
/// <returns></returns>
T ToEncoder<T>() where T : IFrameEncoder;
}
}