+++ /dev/null
-/*M///////////////////////////////////////////////////////////////////////////////////////\r
-//\r
-// IMPORTANT: READ BEFORE DOWNLOADING, COPYING, INSTALLING OR USING.\r
-//\r
-// By downloading, copying, installing or using the software you agree to this license.\r
-// If you do not agree to this license, do not download, install,\r
-// copy or use the software.\r
-//\r
-//\r
-// Intel License Agreement\r
-// For Open Source Computer Vision Library\r
-//\r
-// Copyright (C) 2000, Intel Corporation, all rights reserved.\r
-// Third party copyrights are property of their respective owners.\r
-//\r
-// Redistribution and use in source and binary forms, with or without modification,\r
-// are permitted provided that the following conditions are met:\r
-//\r
-// * Redistribution's of source code must retain the above copyright notice,\r
-// this list of conditions and the following disclaimer.\r
-//\r
-// * Redistribution's in binary form must reproduce the above copyright notice,\r
-// this list of conditions and the following disclaimer in the documentation\r
-// and/or other materials provided with the distribution.\r
-//\r
-// * The name of Intel Corporation may not be used to endorse or promote products\r
-// derived from this software without specific prior written permission.\r
-//\r
-// This software is provided by the copyright holders and contributors "as is" and\r
-// any express or implied warranties, including, but not limited to, the implied\r
-// warranties of merchantability and fitness for a particular purpose are disclaimed.\r
-// In no event shall the Intel Corporation or contributors be liable for any direct,\r
-// indirect, incidental, special, exemplary, or consequential damages\r
-// (including, but not limited to, procurement of substitute goods or services;\r
-// loss of use, data, or profits; or business interruption) however caused\r
-// and on any theory of liability, whether in contract, strict liability,\r
-// or tort (including negligence or otherwise) arising in any way out of\r
-// the use of this software, even if advised of the possibility of such damage.\r
-//\r
-//M*/// StereoGRView.h : interface of the CStereoGRView class\r
-//\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-#if !defined(AFX_STEREOGRVIEW_H__0603BB32_3287_4D21_ADCE_7B314B91C460__INCLUDED_)\r
-#define AFX_STEREOGRVIEW_H__0603BB32_3287_4D21_ADCE_7B314B91C460__INCLUDED_\r
-\r
-#if _MSC_VER > 1000\r
-#pragma once\r
-#endif // _MSC_VER > 1000\r
-\r
-#include "PTGrey.h"\r
-#include "OpenGLView.h"\r
-#include "cv.h"\r
-\r
-#include <vector>\r
-using namespace std;\r
-\r
-class CStereoGRView : public COpenGLView\r
-{\r
-protected: // create from serialization only\r
- CStereoGRView();\r
- DECLARE_DYNCREATE(CStereoGRView)\r
-\r
-// Attributes\r
-public:\r
- CStereoGRDoc* GetDocument();\r
-\r
-\r
-// Operations\r
-public:\r
-\r
- void Update();\r
-// Overrides\r
- // ClassWizard generated virtual function overrides\r
- //{{AFX_VIRTUAL(CStereoGRView)\r
- public:\r
- virtual void OnDraw(CDC* pDC); // overridden to draw this view\r
- virtual BOOL PreCreateWindow(CREATESTRUCT& cs);\r
- virtual void OnInitialUpdate();\r
- protected:\r
- virtual BOOL OnPreparePrinting(CPrintInfo* pInfo);\r
- virtual void OnBeginPrinting(CDC* pDC, CPrintInfo* pInfo);\r
- virtual void OnEndPrinting(CDC* pDC, CPrintInfo* pInfo);\r
- //}}AFX_VIRTUAL\r
-\r
-// Implementation\r
-public:\r
- void InitModel();\r
- void Translate(float val);\r
- void RotateIncl(float val);\r
- void RotateAzim(float val);\r
- void RetrievePointCloud();\r
- void DrawScene(CDC* pDC = 0);\r
- void InitMagicCube();\r
- void OnDrawMagicCube();\r
- void UpdatePosition();\r
- void DefaultView();\r
- void DefaultData();\r
- BOOL RetrieveUserImage();\r
- BOOL IsNewData();\r
- IplImage* GetRecipient();\r
-// void SetImage(IplImage* image, BOOL copy = FALSE);\r
- IplImage* GetImage();\r
- void UpdateView();\r
- void UpdateData();\r
- BOOL RetrieveImage();\r
- void UpdateParams();\r
- virtual ~CStereoGRView();\r
-#ifdef _DEBUG\r
- virtual void AssertValid() const;\r
- virtual void Dump(CDumpContext& dc) const;\r
-#endif\r
-\r
-protected:\r
-\r
-// Generated message map functions\r
-protected:\r
- void OnDrawPointCloud();\r
- void OnDrawImage(CDC* pDC);\r
- //{{AFX_MSG(CStereoGRView)\r
- afx_msg void OnSize(UINT nType, int cx, int cy);\r
- afx_msg BOOL OnEraseBkgnd(CDC* pDC);\r
- afx_msg void OnMouseMove(UINT nFlags, CPoint point);\r
- afx_msg void OnRButtonDblClk(UINT nFlags, CPoint point);\r
- afx_msg void OnChar(UINT nChar, UINT nRepCnt, UINT nFlags);\r
- afx_msg void OnKeyDown(UINT nChar, UINT nRepCnt, UINT nFlags);\r
- //}}AFX_MSG\r
- DECLARE_MESSAGE_MAP()\r
-private:\r
- vector<float> m_points;\r
- BOOL m_wasInitialized;\r
- void ScaleTextures(int width, int height, const void** bits, int count);\r
- void InitTexture(int width, int height);\r
- void ProcessImage();\r
- void InitGL();\r
- HBITMAP m_bitmap;\r
- int m_pixelSize;\r
- IplImage* m_recipient;\r
- IplImage* m_auxImage;\r
- IplImage* m_image;\r
-\r
- void* m_texture[3];\r
- int m_tex_width;\r
- int m_tex_height;\r
- IplImage* m_planes[3];\r
- float m_dist;\r
- float m_incl;\r
- float m_azim;\r
- float m_distInc;\r
- float m_inclInc;\r
- float m_azimInc;\r
-};\r
-\r
-#ifndef _DEBUG // debug version in StereoGRView.cpp\r
-inline CStereoGRDoc* CStereoGRView::GetDocument()\r
- { return (CStereoGRDoc*)m_pDocument; }\r
-#endif\r
-\r
-/////////////////////////////////////////////////////////////////////////////\r
-\r
-//{{AFX_INSERT_LOCATION}}\r
-// Microsoft Visual C++ will insert additional declarations immediately before the previous line.\r
-\r
-#endif // !defined(AFX_STEREOGRVIEW_H__0603BB32_3287_4D21_ADCE_7B314B91C460__INCLUDED_)\r