⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 dibdoc.h

📁 segmentation sample good luck
💻 H
字号:
#if !defined(AFX_DIBDOC_H__49989ED6_536B_11D1_91FE_843B0AC10000__INCLUDED_)
#define AFX_DIBDOC_H__49989ED6_536B_11D1_91FE_843B0AC10000__INCLUDED_

#if _MSC_VER >= 1000
#pragma once
#endif // _MSC_VER >= 1000
// DIBDoc.h : header file
//

#include "imagedoc.h"

class CMonochromeBitmap;
class CDIBMonochromeBitmap;

/////////////////////////////////////////////////////////////////////////////
// CDIBDoc document

class CDIBDoc : public CImageDoc
{
protected:
	CDIBDoc();           // protected constructor used by dynamic creation
	DECLARE_DYNCREATE(CDIBDoc)

// Attributes
public:

// Operations
	virtual CMonochromeBitmap &GetMonochromeBitmap();
	virtual void StretchBlt(CDC &dc,CRect &crDest,CRect &crSrc,DWORD dwROP);
public:

// Overrides
	// ClassWizard generated virtual function overrides
	//{{AFX_VIRTUAL(CDIBDoc)
	public:
	virtual BOOL OnOpenDocument(LPCTSTR lpszPathName);
	protected:
	virtual BOOL OnNewDocument();
	//}}AFX_VIRTUAL

// Implementation
public:
	virtual BOOL IsEmpty();
	virtual int Height();
	virtual int Width();
	const BYTE * GetRaster(int nLine);
	const CByteArray & GetThresholdTable();
	int GetRasterWidthInBytes();
	LPVOID GetBitmapBits();
	BITMAPINFO * GetBitmapInfo();
	virtual ~CDIBDoc();

#ifdef _DEBUG
	virtual void AssertValid() const;
	virtual void Dump(CDumpContext& dc) const;
#endif

	// Generated message map functions
protected:
	void BuildThresholdTable();
	int m_nThreshold;
	CByteArray m_bThresholdTable;
	enum { eWhiteBackground,eBlackBackground } m_eThresholdMethod;
	CDIBMonochromeBitmap * m_pMonochromeBitmap;
	int m_nRasterWidthInBytes;
	LPVOID m_pFile;
	LPVOID m_pBits;
	BITMAPINFO *m_pBMI;
	BITMAPFILEHEADER * m_pBMFH;
	void CloseFile();
	HANDLE m_hFileMapping;
	CFile m_file;
	//{{AFX_MSG(CDIBDoc)
	afx_msg void OnImageHistogram();
	afx_msg void OnUpdateImageHistogram(CCmdUI* pCmdUI);
	//}}AFX_MSG
	DECLARE_MESSAGE_MAP()
};

//{{AFX_INSERT_LOCATION}}
// Microsoft Developer Studio will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_DIBDOC_H__49989ED6_536B_11D1_91FE_843B0AC10000__INCLUDED_)

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -