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

📄 freetype2fontrendering.h

📁 光滑质点无网格法SPH并行计算程序
💻 H
字号:
//      ___                       ___           ___           ___       ___     //     /\__\          ___        /\__\         /\  \         /\__\     /\  \.    //    /::|  |        /\  \      /::|  |       /::\  \       /:/  /    /::\  \.   //   /:|:|  |        \:\  \    /:|:|  |      /:/\:\  \     /:/  /    /:/\:\  \.  //  /:/|:|__|__      /::\__\  /:/|:|  |__   /:/  \:\  \   /:/  /    /::\~\:\  \. // /:/ |::::\__\  __/:/\/__/ /:/ |:| /\__\ /:/__/_\:\__\ /:/__/    /:/\:\ \:\__\.// \/__/~~/:/  / /\/:/  /    \/__|:|/:/  / \:\  /\ \/__/ \:\  \    \:\~\:\ \/__///       /:/  /  \::/__/         |:/:/  /   \:\ \:\__\    \:\  \    \:\ \:\__\.  //      /:/  /    \:\__\         |::/  /     \:\/:/  /     \:\  \    \:\ \/__/  //     /:/  /      \/__/         /:/  /       \::/  /       \:\__\    \:\__\.    //     \/__/                     \/__/         \/__/         \/__/     \/__/    // // =============================================================================//                       Minimalist OpenGL Environment// =============================================================================//// This file is part of Minimalist OpenGL Environment (MinGLE)//// Version: 0.2.0// Author: Balazs Domonkos// Filename: src/fontrendering/include/FreeType2FontRendering.h// Creation Date: January 25th 2008// Revision Date: January 25th 2008////// The Minimalist OpenGL Environment is free software: you can// redistribute it and/or modify it under the terms of the GNU// General Public License as published by the Free Software// Foundation, either version 3 of the License, or (at your// option) any later version.//// The Minimalist OpenGL Environment is distributed in the hope// that it will be useful, but WITHOUT ANY WARRANTY; without// even the implied warranty of MERCHANTABILITY or FITNESS FOR// A PARTICULAR PURPOSE. See the GNU General Public License// for more details.//// You should have received a copy of the GNU General Public License// along with Minimalist OpenGL Environment.  If not, see // <http://www.gnu.org/licenses/>. See the COPYING file included // with this distribution file for license details.///// @file FreeType2FontRendering.h/// FreeType2 font rendering implementation#ifndef __MINGLE_FREETYPE2_FONT_RENDERING_H__#define __MINGLE_FREETYPE2_FONT_RENDERING_H__// Include class definitions#include <classes.h>// MinGLE headers#include <FontRendering.h>// System headers#include <ft2build.h>#include FT_FREETYPE_Hnamespace MinGLE {class FreeType2Font : public RasterFont {protected:	/// Add a gap between letters vert and horz	/// prevents nasty artifacts when letters are too close together	static const unsigned FONT_CHAR_SPACER = 5;public:	FreeType2Font(const FT_Byte *memoryBuffer, int bufferLength,			unsigned height = DEFAULT_FONT_HEIGHT,			unsigned width = DEFAULT_FONT_WIDTH, long faceIndex = 0,			unsigned firstCharacter = DEFAULT_FIRST_CHARACTER,			unsigned lastCharacter = DEFAULT_LAST_CHARACTER,			GLenum format = DEFAULT_FONT_FORMAT,			GLenum type = DEFAULT_FONT_TYPE,			ImageScaleMode imageScaleMode = DEFAULT_IMAGE_SCALE_MODE);}; // class FreeType2Font// =============================================================================class FreeType2FontRendering : public FontRendering {protected:	static FT_Library mLibraryHandle;public:	static const std::string IMPLEMENTATION_NAME;	public:	FreeType2FontRendering();	virtual ~FreeType2FontRendering();	static FT_Library getLibraryHandle();public:protected:	virtual Font *_createFont(const std::string& filename,			VirtualFileSystem *vfs, size_t height, size_t width,			long faceIndex, size_t firstCharacter, size_t lastCharacter,			GLenum format, GLenum type, RasterFont::ImageScaleMode imageScaleMode);	virtual void _saveFont(Font *font, const std::string& filename, VirtualFileSystem *vfs);}; // FreeType2FontRendering} // namespace MinGLE#endif // __MINGLE_FREETYPE2_FONT_RENDERING_H__

⌨️ 快捷键说明

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