vitasdk
Documentation of the vitasdk
pvf.h File Reference
#include <vitasdk/build_utils.h>
#include <psp2/types.h>

Go to the source code of this file.

Data Structures

struct  ScePvfIrect
 
struct  ScePvfRect
 
struct  ScePvfCacheSystemInterface
 
struct  ScePvfInitRec
 
struct  ScePvfFontStyleInfo
 
struct  ScePvfUserImageBufferRec
 
struct  ScePvfIGlyphMetricsInfo
 
struct  ScePvfCharInfo
 
struct  ScePvfFGlyphMetricsInfo
 
struct  ScePvfFontInfo
 
struct  ScePvfIKerningInfo
 
struct  ScePvfFKerningInfo
 
struct  ScePvfKerningInfo
 
struct  ScePvfCacheKey
 

Macros

#define SCE_PVF_MAX_OPEN   18
 
#define SCE_PVF_FONTNAME_LENGTH   64
 
#define SCE_PVF_STYLENAME_LENGTH   64
 
#define SCE_PVF_FONTFILENAME_LENGTH   64
 
#define SCE_PVF_MIN_EMBOLDEN_RATE   -20.0f
 
#define SCE_PVF_MAX_EMBOLDEN_RATE   40.0f
 
#define SCE_PVF_MIN_SKEW_VALUE   -30.0f
 
#define SCE_PVF_MAX_SKEW_VALUE   30.0f
 
#define scePvfGetCharGlyphImageClip   scePvfGetCharGlyphImage_Clip
 

Typedefs

typedef unsigned int ScePvfU32
 
typedef signed int ScePvfS32
 
typedef unsigned short ScePvfU16
 
typedef unsigned char ScePvfU8
 
typedef float ScePvfFloat32
 
typedef ScePvfU32 ScePvfBool
 
typedef void * ScePvfLibId
 
typedef void * ScePvfFontId
 
typedef void * ScePvfPointer
 
typedef void * ScePvfHandle
 
typedef ScePvfS32 ScePvfError
 
typedef ScePvfS32 ScePvfInt
 
typedef ScePvfU16 ScePvfCharCode
 
typedef ScePvfS32 ScePvfFontIndex
 
typedef ScePvfS32(* ScePvfFontCacheLockFunc) (ScePvfPointer cacheInstance)
 
typedef ScePvfS32(* ScePvfFontChcheUnlockFunc) (ScePvfPointer cacheInstance)
 
typedef ScePvfPointer(* ScePvfFontChcheFindFunc) (ScePvfPointer chcheInstance, ScePvfU32 hashValue, ScePvfPointer key, ScePvfBool *result)
 
typedef ScePvfS32(* ScePvfFontChcheWriteKeyValueToCacheFunc) (ScePvfPointer cacheInstance, ScePvfPointer chcheSlot, ScePvfPointer key)
 
typedef ScePvfS32(* ScePvfFontChcheWriteToCacheFunc) (ScePvfPointer cacheInstance, ScePvfPointer cacheSlot, ScePvfPointer data0, ScePvfInt size)
 
typedef ScePvfS32(* ScePvfFontChcheReadFromCacheFunc) (ScePvfPointer cacheInstance, ScePvfPointer cacheSlot, ScePvfPointer data0)
 
typedef ScePvfPointer(* ScePvfAllocFunc) (ScePvfPointer userData, ScePvfU32 size)
 
typedef ScePvfPointer(* ScePvfReallocFunc) (ScePvfPointer userData, ScePvfPointer old_ptr, ScePvfU32 size)
 
typedef void(* ScePvfFreeFunc) (ScePvfPointer userData, ScePvfPointer ptr)
 

Enumerations

enum  ScePvfErrorCode {
  SCE_PVF_ERROR_NOMEMORY = 0x80460001 , SCE_PVF_ERROR_LIBID = 0x80460002 , SCE_PVF_ERROR_ARG = 0x80460003 , SCE_PVF_ERROR_NOFILE = 0x80460004 ,
  SCE_PVF_ERROR_FILEOPEN = 0x80460005 , SCE_PVF_ERROR_FILECLOSE = 0x80460006 , SCE_PVF_ERROR_FILEREAD = 0x80460007 , SCE_PVF_ERROR_FILESEEK = 0x80460008 ,
  SCE_PVF_ERROR_TOOMANYOPENED = 0x80460009 , SCE_PVF_ERROR_ILLEGALVERSION = 0x8046000A , SCE_PVF_ERROR_DATAINCONSISTENT = 0x8046000B , SCE_PVF_ERROR_EXPIRED = 0x8046000C ,
  SCE_PVF_ERROR_NOSUPPORT = 0x8046000E , SCE_PVF_ERROR_NOGLYPH = 0x8046000F , SCE_PVF_ERROR_UNKNOWN = 0x8046FFFF
}
 
enum  ScePvfFamilyCode { SCE_PVF_DEFAULT_FAMILY_CODE = 0 , SCE_PVF_FAMILY_SANSERIF = 1 , SCE_PVF_FAMILY_SERIF = 2 , SCE_PVF_FAMILY_ROUNDED = 3 }
 
enum  ScePvfStyleCode {
  SCE_PVF_DEFAULT_STYLE_CODE = 0 , SCE_PVF_STYLE_REGULAR = 1 , SCE_PVF_STYLE_OBLIQUE = 2 , SCE_PVF_STYLE_NARROW = 3 ,
  SCE_PVF_STYLE_NARROW_OBLIQUE = 4 , SCE_PVF_STYLE_BOLD = 5 , SCE_PVF_STYLE_BOLD_OBLIQUE = 6 , SCE_PVF_STYLE_BLACK = 7 ,
  SCE_PVF_STYLE_BLACK_OBLIQUE = 8 , SCE_PVF_STYLE_L = 101 , SCE_PVF_STYLE_M = 102 , SCE_PVF_STYLE_DB = 103 ,
  SCE_PVF_STYLE_B = 104 , SCE_PVF_STYLE_EB = 105 , SCE_PVF_STYLE_UB = 106
}
 
enum  ScePvfImageByfferPixelFormatType { SCE_PVF_USERIMAGE_DIRECT4_L = 0 , SCE_PVF_USERIMAGE_DIRECT8 = 2 }
 
enum  ScePvfLanguageCode {
  SCE_PVF_DEFAULT_LANGUAGE_CODE = 0 , SCE_PVF_LANGUAGE_J = 1 , SCE_PVF_LANGUAGE_LATIN = 2 , SCE_PVF_LANGUAGE_K = 3 ,
  SCE_PVF_LANGUAGE_C = 4 , SCE_PVF_LANGUAGE_CJK = 5
}
 
enum  ScePvfRegionCode {
  SCE_PVF_GENERIC_REGION_CODE = 0 , SCE_PVF_REGION_001 = 1 , SCE_PVF_REGION_002 = 2 , SCE_PVF_REGION_003 = 3 ,
  SCE_PVF_REGION_004 = 4 , SCE_PVF_REGION_005 = 5 , SCE_PVF_REGION_006 = 6 , SCE_PVF_REGION_007 = 7
}
 
enum  ScePvfFontVendorCountryCode { SCE_PVF_GENERIC_COUNTRY_CODE = 0 , SCE_PVF_COUNTRY_JAPAN = 1 , SCE_PVF_COUNTRY_USA = 2 , SCE_PVF_COUNTRY_KOREA = 3 }
 
enum  ScePvfBoolValue { SCE_PVF_FALSE = 0 , SCE_PVF_TRUE = 1 }
 
enum  ScePvfSubstyle { SCE_PVF_SUBSTYLE_VERTICALLAYOUT = 0x0001 , SCE_PVF_SUBSTYLE_PSEUDO_BOLD = 0x0002 , SCE_PVF_SUBSTYLE_PSEUDO_SLANT = 0x0004 }
 
enum  ScePvfDataAccessMode { SCE_PVF_FILEBASEDSTREAM = 0 , SCE_PVF_MEMORYBASEDSTREAM = 1 }
 

Functions

 VITASDK_BUILD_ASSERT_EQ (4, ScePvfU32)
 
 VITASDK_BUILD_ASSERT_EQ (4, ScePvfS32)
 
 VITASDK_BUILD_ASSERT_EQ (2, ScePvfU16)
 
 VITASDK_BUILD_ASSERT_EQ (1, ScePvfU8)
 
 VITASDK_BUILD_ASSERT_EQ (4, ScePvfFloat32)
 
 VITASDK_BUILD_ASSERT_EQ (4, ScePvfLibId)
 
 VITASDK_BUILD_ASSERT_EQ (4, ScePvfIrect)
 
 VITASDK_BUILD_ASSERT_EQ (8, ScePvfRect)
 
 VITASDK_BUILD_ASSERT_EQ (0x24, ScePvfCacheSystemInterface)
 
 VITASDK_BUILD_ASSERT_EQ (0x1C, ScePvfInitRec)
 
 VITASDK_BUILD_ASSERT_EQ (0xD8, ScePvfFontStyleInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x18, ScePvfUserImageBufferRec)
 
 VITASDK_BUILD_ASSERT_EQ (0x28, ScePvfIGlyphMetricsInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x40, ScePvfCharInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x28, ScePvfFGlyphMetricsInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x130, ScePvfFontInfo)
 
 VITASDK_BUILD_ASSERT_EQ (8, ScePvfIKerningInfo)
 
 VITASDK_BUILD_ASSERT_EQ (8, ScePvfFKerningInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x10, ScePvfKerningInfo)
 
 VITASDK_BUILD_ASSERT_EQ (0x24, ScePvfCacheKey)
 
ScePvfLibId scePvfNewLib (ScePvfInitRec *initParam, ScePvfError *errorCode)
 
ScePvfError scePvfDoneLib (ScePvfLibId libID)
 
ScePvfError scePvfSetEM (ScePvfLibId libID, ScePvfFloat32 emValue)
 
ScePvfError scePvfSetResolution (ScePvfLibId libID, ScePvfFloat32 hResolution, ScePvfFloat32 vResolution)
 
ScePvfInt scePvfGetNumFontList (ScePvfLibId libID, ScePvfError *errorCode)
 
ScePvfError scePvfGetFontList (ScePvfLibId libID, ScePvfFontStyleInfo *fontStyleInfo, ScePvfInt arraySize)
 
ScePvfFontIndex scePvfFindOptimumFont (ScePvfLibId libID, ScePvfFontStyleInfo *fontStyleInfo, ScePvfError *errorCode)
 
ScePvfFontIndex scePvfFindFont (ScePvfLibId libID, ScePvfFontStyleInfo *fontStyleInfo, ScePvfError *errorCode)
 
ScePvfError scePvfGetFontInfoByIndexNumber (ScePvfLibId libID, ScePvfFontStyleInfo *fontStyleInfo, ScePvfFontIndex fontIndex)
 
ScePvfFontId scePvfOpen (ScePvfLibId libID, ScePvfFontIndex fontIndex, ScePvfU32 mode, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenUserFile (ScePvfLibId libID, ScePvfPointer filename, ScePvfU32 mode, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenUserFileWithSubfontIndex (ScePvfLibId libID, ScePvfPointer filename, ScePvfU32 mode, ScePvfU32 subFontIndex, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenUserMemory (ScePvfLibId libID, ScePvfPointer addr, ScePvfU32 size, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenUserMemoryWithSubfontIndex (ScePvfLibId libID, ScePvfPointer addr, ScePvfU32 size, ScePvfU32 subFontIndex, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenDefaultJapaneseFontOnSharedMemory (ScePvfLibId libID, ScePvfError *errorCode)
 
ScePvfFontId scePvfOpenDefaultLatinFontOnSharedMemory (ScePvfLibId libID, ScePvfError *errorCode)
 
ScePvfError scePvfClose (ScePvfFontId fontID)
 
ScePvfError scePvfFlush (ScePvfFontId fontID)
 
ScePvfError scePvfSetCharSize (ScePvfFontId fontID, ScePvfFloat32 hSize, ScePvfFloat32 vSize)
 
ScePvfError scePvfSetEmboldenRate (ScePvfFontId fontID, ScePvfFloat32 emboldenRate)
 
ScePvfError scePvfSetSkewValue (ScePvfFontId fontID, ScePvfFloat32 angleX, ScePvfFloat32 angleY)
 
ScePvfBool scePvfIsElement (ScePvfFontId fontID, ScePvfCharCode charCode)
 
ScePvfError scePvfGetFontInfo (ScePvfFontId fontID, ScePvfFontInfo *fontInfo)
 
ScePvfError scePvfGetCharInfo (ScePvfFontId fontID, ScePvfCharCode charCode, ScePvfCharInfo *charInfo)
 
ScePvfError scePvfGetKerningInfo (ScePvfFontId fontID, ScePvfCharCode leftCharCode, ScePvfCharCode rightCharCode, ScePvfKerningInfo *pKerningInfo)
 
ScePvfError scePvfGetCharImageRect (ScePvfFontId fontID, ScePvfCharCode charCode, ScePvfIrect *rect)
 
ScePvfError scePvfGetCharGlyphImage (ScePvfFontId fontID, ScePvfCharCode charCode, ScePvfUserImageBufferRec *imageBuffer)
 
ScePvfError scePvfGetCharGlyphImage_Clip (ScePvfFontId fontID, ScePvfCharCode charCode, ScePvfUserImageBufferRec *imageBuffer, ScePvfS32 clipX, ScePvfS32 clipY, ScePvfU32 clipWidth, ScePvfU32 clipHeight)
 
ScePvfFloat32 scePvfPixelToPointH (ScePvfLibId libID, ScePvfFloat32 pixel, ScePvfError *errorCode)
 
ScePvfFloat32 scePvfPixelToPointV (ScePvfLibId libID, ScePvfFloat32 pixel, ScePvfError *errorCode)
 
ScePvfFloat32 scePvfPointToPixelH (ScePvfLibId libID, ScePvfFloat32 point, ScePvfError *errorCode)
 
ScePvfFloat32 scePvfPointToPixelV (ScePvfLibId libID, ScePvfFloat32 point, ScePvfError *errorCode)
 
ScePvfError scePvfSetAltCharacterCode (ScePvfLibId libID, ScePvfCharCode charCode)