is it possible, to DISABLE TSelect - options ?
I added a optional FREEIMAGE - export of a Image.
Testing export, I noticed some format-problems.
Displaying these formats works,
but export to PCX, IFF, PSD and ICON of the defined format, doesn't work.
Using NCONVERT there is no export- and resize-problem.
Because of the FREEIMAGE-problems, maybe deleting this new added option again ?
I can protect a TSelex-option like :
oSelex1:bOnSelect := {|| IIF( cFileExt( cLImage1 ) = "BMP" .and. oSelex1:nOption = 9 ;
.and. oSelex2:nOption = 2, ; // FREEIMAGE selected
MsgAlert( "Not possible, to EXPORT : " + CRLF + ;
"BMP to ICO !", "FREEIMAGE Export-Error" ), NIL ) }
Export to FREEIMAGE :
still NEEDED => How to save a RESIZED image ?
- Code: Select all Expand view
IF LOWER(cIExpExten) = "jpeg" // OK
nExpformat := 2
ENDIF
IF LOWER(cIExpExten) = "bmp" // OK
nExpformat := 0
ENDIF
IF LOWER(cIExpExten) = "png" // OK
nExpformat := 13
ENDIF
IF LOWER(cIExpExten) = "tiff" // OK
nExpformat := 18
ENDIF
IF LOWER(cIExpExten) = "pcx" // ???
nExpformat := 10
ENDIF
IF LOWER(cIExpExten) = "iff" // ???
nExpformat := 5
ENDIF
IF LOWER(cIExpExten) = "ppm" // OK
nExpformat := 14
ENDIF
IF LOWER(cIExpExten) = "psd" // ???
nExpformat := 20
ENDIF
IF LOWER(cIExpExten) = "ico" // ???
nExpformat := 1
ENDIF
DEFINE IMAGE oLImg2 FILENAME c_path2 + cLImage1 // original
// RESIZED needed !!!!
oLImg2:SaveImage( c_path2 + cLImage2, nExpformat ) // export
oLImg2:End()
FREEIMAGE format-values :
# define FIF_BMP 0
# define FIF_ICO 1
# define FIF_JPEG 2
# define FIF_JNG 3
# define FIF_KOALA 4
# define FIF_LBM 5
# define FIF_IFF 5
# define FIF_MNG 6
# define FIF_PBM 7
# define FIF_PBMRAW 8
# define FIF_PCD 9
# define FIF_PCX 10
# define FIF_PGM 11
# define FIF_PGMRAW 12
# define FIF_PNG 13
# define FIF_PPM 14
# define FIF_PPMRAW 15
# define FIF_RAS 16
# define FIF_TARGA 17
# define FIF_TIFF 18
# define FIF_WBMP 19
# define FIF_PSD 20
# define FIF_CUT 21
# define FIF_XBM 22
# define FIF_XPM 23
# define FIF_DDS 24
Best regards
Uwe