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

📄 dpreglist.h

📁 unix,linux下编译。用于蛋白质
💻 H
字号:
#ifndef dpreglist_h
#define dpreglist_h

#include "diaglist.h"

enum DPREGIONTYPE
	{
	DPREGIONTYPE_Unknown,
	DPREGIONTYPE_Diag,
	DPREGIONTYPE_Rect
	};

struct DPRegion
	{
	DPREGIONTYPE m_Type;
	union
		{
		Diag m_Diag;
		Rect m_Rect;
		};
	};

const unsigned MAX_DPREGIONS = 1024;

class DPRegionList
	{
public:
	DPRegionList()
		{
		m_uCount = 0;
		}
	~DPRegionList()
		{
		Free();
		}

public:
// Creation
	void Clear()
		{
		Free();
		}
	void Add(const DPRegion &r);

// Accessors
	unsigned GetCount() const
		{
		return m_uCount;
		}

	const DPRegion &Get(unsigned uIndex) const
		{
		assert(uIndex < m_uCount);
		return m_DPRegions[uIndex];
		}

	unsigned GetDPArea() const;

// Diagnostics
	void LogMe() const;

private:
	void Free()
		{
		m_uCount = 0;
		}

private:
	unsigned m_uCount;
	DPRegion m_DPRegions[MAX_DPREGIONS];
	};

void DiagListToDPRegionList(const DiagList &DL, DPRegionList &RL,
  unsigned uLengthA, unsigned uLengthB);

#endif	// dpreglist_h

⌨️ 快捷键说明

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