#pragma once
#include "BKOscScr_Shared.h"

#ifdef BKOSCDLL_EXPORTS
#define BKOSCDLL_API __declspec(dllexport)
#else
#define BKOSCDLL_API __declspec(dllimport)
#endif


#include <gl/gl.h>
#include <gl/glu.h>

BKEXTERN_C class BKOSCDLL_API CBKOscScrOGL: public CBKOScScr_Shared
{
		static GLdouble colors3[];
		static GLdouble vertices2[];
		static GLint indices1[];

		int            m_cx, m_cy;

		GLdouble       *m_pVerticesL;
		GLdouble       *m_pVerticesR;
		GLint         *m_pIndices2;


		CClientDC      *m_pDC;
		HDC             m_HDC;
		HGLRC           hGLRC;

		int SetWindowPixelFormat(HDC);
		BOOL create_context();

	public:
		virtual void BKOSC_OnDisplay(HWND hwndScreen, SAMPLE_TYPE *inBuf, int inLen);
		virtual HRESULT BKOSC_Screen_Init(HWND hwndScreen);
		virtual void BKOSC_Screen_Done();
		virtual void BKOSC_OnSize(int cx, int cy);
		virtual HRESULT BKOSC_OnSetBuffer(int nLen);

		CBKOscScrOGL();
		virtual ~CBKOscScrOGL();
};
