本文整理汇总了C++中iSetInputFile函数的典型用法代码示例。如果您正苦于以下问题:C++ iSetInputFile函数的具体用法?C++ iSetInputFile怎么用?C++ iSetInputFile使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。
在下文中一共展示了iSetInputFile函数的8个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。
示例1: ilLoadJp2F
//! Reads an already-opened Jpeg2000 file.
ILboolean ilLoadJp2F(ILHANDLE File)
{
ILuint FirstPos;
ILboolean bRet;
jas_stream_t *Stream;
iSetInputFile(File);
FirstPos = itell();
if (jas_init())
{
ilSetError(IL_LIB_JP2_ERROR);
return IL_FALSE;
}
Stream = iJp2ReadStream();
if (!Stream)
{
ilSetError(IL_COULD_NOT_OPEN_FILE);
return IL_FALSE;
}
bRet = iLoadJp2Internal(Stream, NULL);
// Close the input stream.
jas_stream_close(Stream);
iseek(FirstPos, IL_SEEK_SET);
return bRet;
}
示例2: ilIsValidBmpF
//! Checks if the ILHANDLE contains a valid .bmp file at the current position.
ILboolean ilIsValidBmpF(ILHANDLE File) {
ILuint FirstPos;
ILboolean bRet;
iSetInputFile(File);
FirstPos = itell();
bRet = iIsValidBmp();
iseek(FirstPos, IL_SEEK_SET);
return bRet;
}
示例3: ilLoadPixF
//! Reads an already-opened Pix file
ILboolean ilLoadPixF(ILHANDLE File)
{
ILuint FirstPos;
ILboolean bRet;
iSetInputFile(File);
FirstPos = itell();
bRet = iLoadPixInternal();
iseek(FirstPos, IL_SEEK_SET);
return bRet;
}
示例4: ilLoadDataF
//! Reads an already-opened raw data file
ILboolean ILAPIENTRY ilLoadDataF(ILHANDLE File, ILuint Width, ILuint Height, ILuint Depth, ILubyte Bpp)
{
ILuint FirstPos;
ILboolean bRet;
iSetInputFile(File);
FirstPos = iCurImage->io.tell(iCurImage->io.handle);
bRet = iLoadDataInternal(Width, Height, Depth, Bpp);
iCurImage->io.seek(iCurImage->io.handle, FirstPos, IL_SEEK_SET);
return bRet;
}
示例5: ilIsValidF_TIFF
//! Checks if the ILHANDLE contains a valid tiff file at the current position.
ILboolean ilIsValidF_TIFF(ILHANDLE File)
{
ILuint FirstPos;
ILboolean bRet;
iSetInputFile(File);
FirstPos = itell();
bRet = ilisValidTiffFunc();
iseek(FirstPos, IL_SEEK_SET);
return bRet;
}
示例6: ilLoadIffF
//! Reads an already-opened IFF file
ILboolean ilLoadIffF(ILHANDLE File)
{
ILuint FirstPos;
ILboolean bRet;
iSetInputFile(File);
FirstPos = itell();
bRet = iLoadIffInternal();
iseek(FirstPos, IL_SEEK_SET);
// Lbm files can have the .iff extension as well, so if Iff-loading failed,
// try to load it as a Lbm.
if (bRet == IL_FALSE)
return ilLoadIlbmF(File);
return bRet;
}
示例7: ilLoadXpm
// Reads an .xpm file
ILboolean ilLoadXpm(ILconst_string FileName)
{
ILHANDLE XpmFile;
ILboolean bXpm = IL_FALSE;
XpmFile = iopenr(FileName);
if (XpmFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bXpm;
}
iSetInputFile(XpmFile);
bXpm = ilLoadXpmF(XpmFile);
icloser(XpmFile);
return bXpm;
}
示例8: ilLoad_SUN
// Reads a Sun file
ILboolean ilLoad_SUN(ILconst_string FileName)
{
ILHANDLE SunFile;
ILboolean bSun = IL_FALSE;
SunFile = iopenr(FileName);
if (SunFile == NULL) {
ilSetError(IL_COULD_NOT_OPEN_FILE);
return bSun;
}
iSetInputFile(SunFile);
bSun = ilLoadF_SUN(SunFile);
icloser(SunFile);
return bSun;
}