📄 fmwndvr.h
字号:
#if !defined(AFX_FMWNDVR_H__944F7A33_221B_4F76_922D_DCC8319269B7__INCLUDED_)#define AFX_FMWNDVR_H__944F7A33_221B_4F76_922D_DCC8319269B7__INCLUDED_#if _MSC_VER > 1000#pragma once#endif // _MSC_VER > 1000// FMWndVR.h : header file///////////////////////////////////////////////////////////////////////////////// RxFMWndVR window#include <afxtempl.h>#include "FMWnd3DOutline.h"#include "Matrix4D.h"#include "Vect4D.h"// yeni 2004.03.19.#include "RxySegment.h"class RxVolumeData;class RxVRRayCastingAgent;class RxRayCastingFusionAgent;class RxRayCastingCommonInfo;class RxRigidReg3DAgent;class RxRigidReg3DInfo;class RxTransform3DInfo;class RxDlgMixing;class RxFMWndVR : public RxFMWnd3DOutline{// Constructionpublic: RxFMWndVR(UINT nSeries);// Attributespublic: CPoint m_ptOld; CPoint m_ptDown; CSize m_szWindow; BYTE *m_pbyFinalImage; BOOL m_bOutputTransform; int m_SampleMode, // sample mode: 0-uniform 1-random 2-sobel 3-sobellevoy m_SampleNum, // number of sample points m_maxIter, // maximum iteration m_MIAnalysis, // MI analysis mode: 0-original MI 1-fast MI 2-surface m_MIInterpolation; // MI interpolation mode: 0-partial volume 1-trilinear 2-nearest neighbor unsigned short m_Threshold; // thresholding for sampling double m_Tolerance, // tolerance for sampling m_varFloat, // variance of float m_covarRefer, // covariance of reference m_covarFloat, // covariance of float m_etaTrans, // learning rate: translation m_etaRot, // learning rate: rotation m_TransLimit, // converge limitation of translation m_RotLimit; // converge limitation of rotating static RxVRRayCastingAgent *m_pVRRefAgent; static RxVRRayCastingAgent *m_pVRFltAgent; static RxRayCastingFusionAgent *m_pVRFusAgent; static RxRayCastingCommonInfo *m_pVRRefInfo; static RxRayCastingCommonInfo *m_pVRFltInfo; static RxMatrix4D m_mxView; static RxMatrix4D m_mxRefView; static RxMatrix4D m_mxRotation; static RxMatrix4D m_mxRegistration; static CPoint m_ptPan; static HANDLE m_hVRThread; static CWinThread *m_pVRThread; static RxRigidReg3DAgent *m_pRigidReg3DAgent; static RxRigidReg3DInfo *m_pRigidReg3DInfo; static RxTransform3DInfo *m_pTransform; static RxTransform3DInfo *m_pTransformRight; static RxTransform3DInfo *m_pTransformLeft; CList<void *, void *> m_lMeasure; // Boundary cube狼 焊咯瘤绰 搁 BOOL m_abPlaneVisible[6]; // Boundary cube狼 8俺狼 怖瘤痢 // 6------7 // 2-|----3 | // | 5----|-4 // 1------0 RxVect4D m_aptApex[8]; RxVect4D m_aptApexCrop[8]; // volume projection饶狼 image space(u,v,w)惑狼 谅钎 int m_iWMin, m_iWMax, m_iVMin, m_iVMax, m_iUMin, m_iUMax ; int m_iMPRHitTest; void UpdateMPRWindow(); // Draw Functions BOOL m_bNeedToRender; void RedrawWnd(BOOL bNeedToRender); void DrawVolume(CDC *pDC); void DrawAnnotation(CDC *pDC); void DrawOnePlane(CDC *pDC, RxVect4D vtPt1, RxVect4D vtPt2, RxVect4D vtPt3, RxVect4D vtPt4); void DrawBoundingBoxWhole(CDC *pDC); void DrawBoundingBoxCrop(CDC *pDC); void DrawMPRLine(CDC *pDC); void DrawOrientationCube(CDC *pDC); void DrawScaleBar(CDC *pDC); void DrawPatientInfo(CDC *pDC); void DrawTransOutput(CDC *pDC); void DrawLungNodule(CDC *pDC); void CalcuBoundingBox(); void CalcRgnOfVisiblePlanes(); RxDlgMixing *m_pDlgMixing; // yeni 2004.03.19. RxySegment m_SegmentAgent; BOOL m_bRegistrationDone;public: void Reset_UI_LocalSlider(); void FittingVR(); void ResetVR(); void ShowDlgMixing(BOOL bShow); void SetBtnMixing(BOOL bCheck); BOOL GetBtnMixing(); void SetCropRange(int iMin, int iMax, int iAxis); void SetChangedOTF(void *pTable);// Operationsprotected: BOOL AssignRenderInfos(RxVolumeData* pVolumeData, RxRayCastingCommonInfo *pVRInfo); BOOL AssignRegistrationInfos(); RxMatrix4D MakeViewingMatrix(RxVolumeData* pVolumeData); BOOL PerformRotateByOffset(CPoint offset); BOOL KillRenderThread(); BOOL SetDistanceFrom(CPoint point); BOOL SetAreaCenter(CPoint point); BOOL AnnotateMeasureVolume(CPoint point); BOOL AnnotateMeasureArea(CPoint point); BOOL AnnotateMeasureDistance(CPoint point); BOOL ClearAnnotationList();public: BOOL VR_Initialize(); BOOL m_bNeedRecalVolume; void SetNeedRecalVolume(); BOOL ReCalMeasureVolume(BOOL bNeedRecal); static UINT __cdecl VRThreadFunc(LPVOID pParam); BOOL RenderVolume(); BOOL DrawRenderedImage(); BOOL InitRigidRegistration(); BOOL Subtraction(); BOOL RigidRegSubtraction(); BOOL NonRigidRegistration();// Overrides // ClassWizard generated virtual function overrides //{{AFX_VIRTUAL(RxFMWndVR) //}}AFX_VIRTUAL// Implementationpublic: virtual ~RxFMWndVR(); virtual void OnActivateWnd(BOOL bActivate, CWnd *pCurWnd, CWnd *pOldWnd); // Generated message map functionsprotected: //{{AFX_MSG(RxFMWndVR) afx_msg void OnPaint(); afx_msg void OnSize(UINT nType, int cx, int cy); afx_msg void OnRButtonDown(UINT nFlags, CPoint point); afx_msg void OnRButtonUp(UINT nFlags, CPoint point); afx_msg void OnMouseMove(UINT nFlags, CPoint point); afx_msg int OnCreate(LPCREATESTRUCT lpCreateStruct); afx_msg void OnDestroy(); afx_msg void OnLButtonDown(UINT nFlags, CPoint point); afx_msg void OnLButtonUp(UINT nFlags, CPoint point); afx_msg BOOL OnSetCursor(CWnd* pWnd, UINT nHitTest, UINT message); afx_msg BOOL OnMouseWheel(UINT nFlags, short zDelta, CPoint pt); afx_msg void OnDistance(); afx_msg void OnUpdateDistance(CCmdUI* pCmdUI); afx_msg void OnArea(); afx_msg void OnUpdateArea(CCmdUI* pCmdUI); afx_msg void OnVolume(); afx_msg void OnUpdateVolume(CCmdUI* pCmdUI); afx_msg void OnRegistMode(); afx_msg void OnUpdateRegistReport(CCmdUI* pCmdUI); //}}AFX_MSG afx_msg void OnChangedZoomFactor(NMHDR* pNMHDR, LRESULT* pResult); afx_msg void OnBtnMixing(); afx_msg void OnBtnMin(); afx_msg void OnBtnMax(); afx_msg void OnOrientBtn(UINT nID); afx_msg void OnDlgApplyMixing(NMHDR* pNMHDR, LRESULT* pResult); afx_msg void OnDlgCancelMixing(NMHDR* pNMHDR, LRESULT* pResult); DECLARE_MESSAGE_MAP()};///////////////////////////////////////////////////////////////////////////////{{AFX_INSERT_LOCATION}}// Microsoft Visual C++ will insert additional declarations immediately before the previous line.#endif // !defined(AFX_FMWNDVR_H__944F7A33_221B_4F76_922D_DCC8319269B7__INCLUDED_)
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -