#pragma once

#include "NZLiveDisplay.h"

// CDlgRTSPViewer 대화 상자입니다.

class CDlgRTSPViewer : public CDialog
{
	DECLARE_DYNAMIC(CDlgRTSPViewer)

public:
	CDlgRTSPViewer(CWnd* pParent = NULL);   // 표준 생성자입니다.
	virtual ~CDlgRTSPViewer();

// 대화 상자 데이터입니다.
	enum { IDD = IDD_RTSP_VIEWER };


public:
	BOOL Run( LPCTSTR addr, LPCTSTR port, LPCTSTR url, LPCTSTR id, LPCTSTR pw );
	BOOL m_running;

protected:
	CString m_addr;
	CString m_port;
	CString m_url;
	CString m_id;
	CString m_pw;
	CString m_rtsp_full_url;

	HANDLE m_display;
	ULONG_PTR m_gdiplusToken;

protected:
	virtual void DoDataExchange(CDataExchange* pDX) override;    // DDX/DDV 지원입니다.
	virtual BOOL OnInitDialog() override;
	virtual void OnCancel() override;

	static BOOL CALLBACK OnCustomDraw(int nChannel, LPBITMAP pBitmap, LPRECT pSrcRect, LONG_PTR pUserParam);

	DECLARE_MESSAGE_MAP()
	afx_msg void OnDestroy();
	afx_msg void OnLButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnLButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnLButtonDblClk(UINT nFlags, CPoint point);
	afx_msg void OnRButtonDown(UINT nFlags, CPoint point);
	afx_msg void OnRButtonUp(UINT nFlags, CPoint point);
	afx_msg void OnRButtonDblClk(UINT nFlags, CPoint point);
	afx_msg void OnBnClickedBtnRun();
	afx_msg void OnBnClickedBtnStop();
};
