本文整理汇总了C++中icloser函数的典型用法代码示例。如果您正苦于以下问题:C++ icloser函数的具体用法?C++ icloser怎么用?C++ icloser使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了icloser函数的20个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的C++代码示例。
示例1: ilLoadPltPal
//! Loads an .plt palette file.
ILboolean ilLoadPltPal(ILconst_string FileName)
{
ILHANDLE PltFile;
if (!iCheckExtension(FileName, IL_TEXT("plt"))) {
ilSetError(IL_INVALID_EXTENSION);
return IL_FALSE;
}
if (iCurImage == NULL) {
ilSetError(IL_ILLEGAL_OPERATION);
return IL_FALSE;
}
PltFile = iopenr(FileName);
if (PltFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return IL_FALSE;
}
if (iCurImage->Pal.Palette && iCurImage->Pal.PalSize > 0 && iCurImage->Pal.PalType != IL_PAL_NONE) {
ifree(iCurImage->Pal.Palette);
iCurImage->Pal.Palette = NULL;
}
iCurImage->Pal.PalSize = GetLittleUInt();
if (iCurImage->Pal.PalSize == 0) {
ilSetError(IL_INVALID_FILE_HEADER);
return IL_FALSE;
}
iCurImage->Pal.PalType = IL_PAL_RGB24;
iCurImage->Pal.Palette = (ILubyte*)ialloc(iCurImage->Pal.PalSize);
if (!iCurImage->Pal.Palette) {
icloser(PltFile);
return IL_FALSE;
}
if (iread(iCurImage->Pal.Palette, iCurImage->Pal.PalSize, 1) != 1) {
ifree(iCurImage->Pal.Palette);
iCurImage->Pal.Palette = NULL;
icloser(PltFile);
return IL_FALSE;
}
icloser(PltFile);
return IL_TRUE;
}
开发者ID:SylviaTanenbaum,项目名称:3d-simulation-and-game,代码行数:49,代码来源:il_pal.c
示例2: ilIsValid_JPEG
//! Checks if the file specified in FileName is a valid .jpg file.
ILboolean ilIsValid_JPEG(ILconst_string FileName)
{
ILHANDLE JpegFile;
ILboolean bJpeg = IL_FALSE;
if (!iCheckExtension(FileName, IL_TEXT("jpg")) &&
!iCheckExtension(FileName, IL_TEXT("jpe")) &&
!iCheckExtension(FileName, IL_TEXT("jpeg")) &&
!iCheckExtension(FileName, IL_TEXT("jif")) &&
!iCheckExtension(FileName, IL_TEXT("jfif")))
{
ilSetError(IL_INVALID_EXTENSION);
return bJpeg;
}
JpegFile = iopenr(FileName);
if (JpegFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bJpeg;
}
bJpeg = ilIsValidF_JPEG(JpegFile);
icloser(JpegFile);
return bJpeg;
}
开发者ID:xksteven,项目名称:myOpenGL,代码行数:27,代码来源:il_jpeg.c
示例3: ilLoadJpeg
ILboolean ilLoadJpeg(ILconst_string FileName)
{
ILHANDLE JpegFile;
ILboolean bJpeg = IL_FALSE;
JpegFile = iopenr(FileName);
if (JpegFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bJpeg;
}
bJpeg = ilLoadJpegF(JpegFile);
icloser(JpegFile);
return bJpeg;
}
开发者ID:ProfessorKaos64,项目名称:tdm,代码行数:31,代码来源:il_jpeg.c
示例4: ilLoadActPal
//! Loads an .act palette file.
ILboolean ilLoadActPal(ILconst_string FileName)
{
ILHANDLE ActFile;
if (!iCheckExtension(FileName, IL_TEXT("act"))) {
ilSetError(IL_INVALID_EXTENSION);
return IL_FALSE;
}
if (iCurImage == NULL) {
ilSetError(IL_ILLEGAL_OPERATION);
return IL_FALSE;
}
ActFile = iopenr(FileName);
if (ActFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return IL_FALSE;
}
if (iCurImage->Pal.Palette && iCurImage->Pal.PalSize > 0 && iCurImage->Pal.PalType != IL_PAL_NONE) {
ifree(iCurImage->Pal.Palette);
iCurImage->Pal.Palette = NULL;
}
iCurImage->Pal.PalType = IL_PAL_RGB24;
iCurImage->Pal.PalSize = 768;
iCurImage->Pal.Palette = (ILubyte*)ialloc(768);
if (!iCurImage->Pal.Palette) {
icloser(ActFile);
return IL_FALSE;
}
if (iread(iCurImage->Pal.Palette, 1, 768) != 768) {
icloser(ActFile);
return IL_FALSE;
}
icloser(ActFile);
return IL_TRUE;
}
开发者ID:SylviaTanenbaum,项目名称:3d-simulation-and-game,代码行数:43,代码来源:il_pal.c
示例5: ilLoadIff
//! Reads an IFF file
ILboolean ilLoadIff(const ILstring FileName)
{
ILHANDLE iffFile;
ILboolean ret = IL_FALSE;
iffFile = iopenr(FileName);
if (iffFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return ret;
}
ret = ilLoadIffF(iffFile);
icloser(iffFile);
return ret;
}
开发者ID:123woodman,项目名称:minko,代码行数:15,代码来源:il_iff.c
示例6: ilLoadBlp
//! Reads a BLP file
ILboolean ilLoadBlp(ILconst_string FileName)
{
ILHANDLE BlpFile;
ILboolean bBlp = IL_FALSE;
BlpFile = iopenr(FileName);
if (BlpFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bBlp;
}
bBlp = ilLoadBlpF(BlpFile);
icloser(BlpFile);
return bBlp;
}
开发者ID:damucz,项目名称:devil,代码行数:17,代码来源:il_blp.cpp
示例7: ilLoadIcns
//! Reads an icon file.
ILboolean ilLoadIcns(ILconst_string FileName)
{
ILHANDLE IcnsFile;
ILboolean bIcns = IL_FALSE;
IcnsFile = iopenr(FileName);
if (IcnsFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bIcns;
}
bIcns = ilLoadIcnsF(IcnsFile);
icloser(IcnsFile);
return bIcns;
}
开发者ID:AlfiyaZi,项目名称:DevIL,代码行数:17,代码来源:il_icns.c
示例8: ilLoadWdp
//! Reads a WDP file
ILboolean ilLoadWdp(ILconst_string FileName)
{
ILHANDLE WdpFile;
ILboolean bWdp = IL_FALSE;
WdpFile = iopenr(FileName);
if (WdpFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bWdp;
}
bWdp = ilLoadWdpF(WdpFile);
icloser(WdpFile);
return bWdp;
}
开发者ID:123woodman,项目名称:minko,代码行数:17,代码来源:il_wdp.c
示例9: ilLoad_ROT
//! Reads a ROT file
ILboolean ilLoad_ROT(ILconst_string FileName)
{
ILHANDLE RotFile;
ILboolean bRot = IL_FALSE;
RotFile = iopenr(FileName);
if (RotFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bRot;
}
bRot = ilLoadF_ROT(RotFile);
icloser(RotFile);
return bRot;
}
开发者ID:xksteven,项目名称:myOpenGL,代码行数:17,代码来源:il_rot.c
示例10: ilLoadSgi
/*! Reads a SGI file */
ILboolean ilLoadSgi(ILconst_string FileName)
{
ILHANDLE SgiFile;
ILboolean bSgi = IL_FALSE;
SgiFile = iopenr(FileName);
if (SgiFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bSgi;
}
bSgi = ilLoadSgiF(SgiFile);
icloser(SgiFile);
return bSgi;
}
开发者ID:kphillisjr,项目名称:DevIL,代码行数:17,代码来源:il_sgi.c
示例11: ilLoadPsp
//! Reads a PSP file
ILboolean ilLoadPsp(ILconst_string FileName)
{
ILHANDLE PSPFile;
ILboolean bPsp = IL_FALSE;
PSPFile = iopenr(FileName);
if (PSPFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bPsp;
}
bPsp = ilLoadPspF(PSPFile);
icloser(PSPFile);
return bPsp;
}
开发者ID:123woodman,项目名称:minko,代码行数:17,代码来源:il_psp.c
示例12: ilLoad_TIFF
//! Reads a Tiff file
ILboolean ilLoad_TIFF(ILconst_string FileName)
{
ILHANDLE TiffFile;
ILboolean bTiff = IL_FALSE;
TiffFile = iopenr(FileName);
if (TiffFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
}
else {
bTiff = ilLoadF_TIFF(TiffFile);
icloser(TiffFile);
}
return bTiff;
}
开发者ID:xksteven,项目名称:myOpenGL,代码行数:17,代码来源:il_tiff.c
示例13: ilLoadLif
//! Reads a .Lif file
ILboolean ilLoadLif(ILconst_string FileName)
{
ILHANDLE LifFile;
ILboolean bLif = IL_FALSE;
LifFile = iopenr(FileName);
if (LifFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bLif;
}
bLif = ilLoadLifF(LifFile);
icloser(LifFile);
return bLif;
}
开发者ID:mirusyang,项目名称:nebula3,代码行数:17,代码来源:il_lif.c
示例14: ilLoadKtx
//! Reads a .ktx file
ILboolean ilLoadKtx(ILconst_string FileName)
{
ILHANDLE KtxFile;
ILboolean bKtx = IL_FALSE;
KtxFile = iopenr(FileName);
if (KtxFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bKtx;
}
bKtx = ilLoadKtxF(KtxFile);
icloser(KtxFile);
return bKtx;
}
开发者ID:AlfiyaZi,项目名称:DevIL,代码行数:17,代码来源:il_ktx.c
示例15: ilLoadCut
//! Reads a .cut file
ILboolean ilLoadCut(ILconst_string FileName)
{
ILHANDLE CutFile;
ILboolean bCut = IL_FALSE;
CutFile = iopenr(FileName);
if (CutFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bCut;
}
bCut = ilLoadCutF(CutFile);
icloser(CutFile);
return bCut;
}
开发者ID:123woodman,项目名称:minko,代码行数:17,代码来源:il_cut.c
示例16: ilLoadHdr
//! Reads a .hdr file
ILboolean ilLoadHdr(ILconst_string FileName)
{
ILHANDLE HdrFile;
ILboolean bHdr = IL_FALSE;
HdrFile = iopenr(FileName);
if (HdrFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bHdr;
}
bHdr = ilLoadHdrF(HdrFile);
icloser(HdrFile);
return bHdr;
}
开发者ID:kphillisjr,项目名称:DevIL,代码行数:17,代码来源:il_hdr.c
示例17: ilLoadIlbm
// Reads a file
ILboolean ilLoadIlbm(ILconst_string FileName)
{
ILHANDLE IlbmFile;
ILboolean bIlbm = IL_FALSE;
IlbmFile = iopenr(FileName);
if (IlbmFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bIlbm;
}
bIlbm = ilLoadIlbmF(IlbmFile);
icloser(IlbmFile);
return bIlbm;
}
开发者ID:damucz,项目名称:devil,代码行数:17,代码来源:il_ilbm.cpp
示例18: ilLoadPix
//! Reads a Pix file
ILboolean ilLoadPix(ILconst_string FileName)
{
ILHANDLE PixFile;
ILboolean bPix = IL_FALSE;
PixFile = iopenr(FileName);
if (PixFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bPix;
}
bPix = ilLoadPixF(PixFile);
icloser(PixFile);
return bPix;
}
开发者ID:DentonW,项目名称:DevIL,代码行数:17,代码来源:il_pix.cpp
示例19: ilLoadGif
//! Reads a Gif file
ILboolean ilLoadGif(const ILstring FileName)
{
ILHANDLE GifFile;
ILboolean bGif = IL_FALSE;
GifFile = iopenr(FileName);
if (GifFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bGif;
}
bGif = ilLoadGifF(GifFile);
icloser(GifFile);
return bGif;
}
开发者ID:MichaelH13,项目名称:sdkpub,代码行数:17,代码来源:il_gif.c
示例20: ilLoad_PCD
//! Reads a .pcd file
ILboolean ilLoad_PCD(ILconst_string FileName)
{
ILHANDLE PcdFile;
ILboolean bPcd = IL_FALSE;
PcdFile = iopenr(FileName);
if (PcdFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bPcd;
}
bPcd = ilLoadF_PCD(PcdFile);
icloser(PcdFile);
return bPcd;
}
开发者ID:xksteven,项目名称:myOpenGL,代码行数:17,代码来源:il_pcd.c
注:本文中的icloser函数示例由纯净天空整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。 |
请发表评论