MBS Plugin Documentation
Statistics - FAQ - Plugin Parts (All, Dependencies) - Class hierarchie
New in Version 7.0 7.1 7.2 7.3 7.4 7.5 7.6 7.7 7.8 8.0 8.1 8.2 8.3 8.4 8.5 8.6 8.7 9.0
The list of the themes, classes, controls, modules, global methods by category, global methods by name, screenshots, licenses and examples.
Platforms to show: All Mac Windows Linux Cross-Platform
JPEGImporterMBS.AllowDamaged as boolean
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: whether you want damaged pictures to be returned.
Notes:
If AllowDamaged is false, nil will be returned if the picture is damaged.
Default value is false.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: whether you want damaged pictures to be returned.
Notes:
If AllowDamaged is false, nil will be returned if the picture is damaged.
Default value is false.
(Read and Write property)
JPEGImporterMBS.BlueTestPicture as picture
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 5.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns a 100x100 pixel big picture filles with RGB(0,0,255).
Notes: Just for testing how well the plugin picture code works.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 5.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns a 100x100 pixel big picture filles with RGB(0,0,255).
Notes: Just for testing how well the plugin picture code works.
class JPEGImporterMBS
class, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: A class for JPEG Importing.
Example:
This class is not depending on any library! It works without QuickTime even on System 7, but as it contains everything needed this method is around 100 KB big!
(REALbasic's OpenAsPicture depends on QuickTime)
class, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: A class for JPEG Importing.
Example:
dim g as FolderItem
dim ji as JPEGImporterMBS
dim je as JPEGExporterMBS
dim f as FolderItem
dim m as MemoryBlock
// this code copies a JPG: CMYK or RGB
// import it
g=DesktopFolder.Child("PICT1533.JPG")
ji=new JPEGImporterMBS
ji.File=g
ji.AllowDamaged=true
ji.CMYK=true // if it is cmyk
if ji.InitJPEG then
do
loop until ji.LoopJPEG<>0
ji.FinishJPEG
end if
// export it
f=desktopfolder.child("PICT1533 copy.JPG")
je=new JPEGExporterMBS
je.File=f
je.Quality=75
if ji.CMYK then
m=ji.PictureData
je.ExportCMYK m, ji.Width, ji.Height, ji.Width*4
else
je.Picture=ji.Picture
je.Export
end if
Notes: This class is not depending on any library! It works without QuickTime even on System 7, but as it contains everything needed this method is around 100 KB big!
(REALbasic's OpenAsPicture depends on QuickTime)
JPEGImporterMBS.CleanMarkers
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Clears the marker list.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Clears the marker list.
JPEGImporterMBS.CMYK as Boolean
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Whether the decompressor has imported the picture as a CMYK image into a memoryblock.
Example:
This property sets the Mode property to ModeCMYK.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Whether the decompressor has imported the picture as a CMYK image into a memoryblock.
Example:
dim g as FolderItem
dim ji as JPEGImporterMBS
g=getFolderItem("a_auf")
ji=new JPEGImporterMBS
ji.File=g
if ji.InitJPEG then
if ji.CMYK then
MsgBox "CMYK"
else
MsgBox "not"
end if
end if
Notes: This property sets the Mode property to ModeCMYK.
(Read and Write property)
JPEGImporterMBS.ColorComponentCount as Integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The number of color components.
Notes:
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The number of color components.
Notes:
| 1 | Grayscale |
| 3 | RGB |
| 4 | CMYK |
JPEGImporterMBS.CurrentDepth as integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The depth of the picture property.
Notes:
In the current implementation always 32bit.
0 if the loading of the picture failed.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The depth of the picture property.
Notes:
In the current implementation always 32bit.
0 if the loading of the picture failed.
(Read and Write property)
JPEGImporterMBS.data as string
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The source string.
Notes:
If file is nil, the compressed data is taken from this property.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The source string.
Notes:
If file is nil, the compressed data is taken from this property.
(Read and Write property)
JPEGImporterMBS.Error(message as string)
event, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: This events reports all error messages from the jpeg library.
event, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: This events reports all error messages from the jpeg library.
JPEGImporterMBS.ErrorMessage as string
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The last error message reported.
Notes: (Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The last error message reported.
Notes: (Read and Write property)
JPEGImporterMBS.ExifData as String
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The exif data stored in the file.
Notes:
Only used when ReadExifData is set to true before you import the image.
The string contains the binary content of a exif data on disc.
Value is "" if no data was found.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The exif data stored in the file.
Notes:
Only used when ReadExifData is set to true before you import the image.
The string contains the binary content of a exif data on disc.
Value is "" if no data was found.
(Read and Write property)
JPEGImporterMBS.file as folderitem
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The destination file.
Notes:
If file is nil, the source is taken from the data property.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The destination file.
Notes:
If file is nil, the source is taken from the data property.
(Read and Write property)
JPEGImporterMBS.FileOffset as integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The offset inside the file.
Notes: (Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The offset inside the file.
Notes: (Read and Write property)
JPEGImporterMBS.FinishJPEG
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Releases all memory buffers needed for the JPEG decompression.
Notes:
This must be called if you used InitJPEG!
Else you have a memory leak.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Releases all memory buffers needed for the JPEG decompression.
Notes:
This must be called if you used InitJPEG!
Else you have a memory leak.
JPEGImporterMBS.GreenTestPicture as picture
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 5.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns a 100x100 pixel big picture filles with RGB(0,255,0).
Notes: Just for testing how well the plugin picture code works.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 5.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns a 100x100 pixel big picture filles with RGB(0,255,0).
Notes: Just for testing how well the plugin picture code works.
JPEGImporterMBS.Height as integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The height of the picture.
Notes:
0 if the loading of the picture failed.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The height of the picture.
Notes:
0 if the loading of the picture failed.
(Read and Write property)
JPEGImporterMBS.HorizontalResolution as Integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The horizontal resolution.
Notes: (Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The horizontal resolution.
Notes: (Read and Write property)
JPEGImporterMBS.Import
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Imports the picture.
Example:
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Imports the picture.
Example:
dim f as FolderItem
dim ji as new JPEGImporterMBS
dim je as new JPEGExporterMBS
dim m as MemoryBlock
dim i,c as integer
// read jpeg
f=DesktopFolder.Child("input.jpg")
ji.Mode=ji.ModeRGB // read RGB to memoryblock
ji.File=f
ji.Import
m=ji.PictureData
// add red
c=m.Size-1
for i=0 to c step 3
m.Byte(i)=255
next
// write jpeg
f=DesktopFolder.Child("test.jpg")
je.File=f
je.ExportRGB(m,ji.Width, ji.Height, ji.Width*3)
Notes: The memoryblock data must be in the format with bytes in the order RGB.JPEGImporterMBS.ImportCMYK
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Imports a CMYK picture.
Example:
This methods should read all JPEG files you can get, but I've only tested it for 32 bit color and 8 bit grayscale.
The read CMYK values are stored in the picturedata property.
This method uses the YieldTicks property and may yield time to other threads.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Imports a CMYK picture.
Example:
dim g as FolderItem
dim ji as JPEGImporterMBS
dim je as JPEGExporterMBS
dim f as FolderItem
dim m as MemoryBlock
// import it
g=getOpenFolderItem("image/jpeg")
ji=new JPEGImporterMBS
ji.File=g
ji.AllowDamaged=true
ji.ImportCMYK
m=ji.PictureData
// export it
f=desktopfolder.child("test.jpg")
je=new JPEGExporterMBS
je.HorizontalResolution=300
je.VerticalResolution=300
je.ResolutionUnit=1
je.File=f
je.Quality=75
je.ExportCMYK m, ji.Width, ji.Height, ji.Width*4
Notes: This methods should read all JPEG files you can get, but I've only tested it for 32 bit color and 8 bit grayscale.
The read CMYK values are stored in the picturedata property.
This method uses the YieldTicks property and may yield time to other threads.
JPEGImporterMBS.Info(message as string, msglevel as integer)
event, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: This events reports all information messages from the jpeg library.
Notes:
msglevel is one of:
event, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: This events reports all information messages from the jpeg library.
Notes:
msglevel is one of:
| -1: | recoverable corrupt-data warning, may want to abort. |
| 0: | important advisory messages (always display to user). |
| 1: | first level of tracing detail. |
| 2,3,...: | successively more detailed tracing messages. |
JPEGImporterMBS.InitJPEG as boolean
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Initializes the JPEG decompressor for use with LoopJPEG.
Example:
Call FinishJPEG even if this failes.
Returns true if you can loop using LoopJPEG.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Initializes the JPEG decompressor for use with LoopJPEG.
Example:
dim g as FolderItem
dim ji as JPEGImporterMBS
dim je as JPEGExporterMBS
dim f as FolderItem
dim m as MemoryBlock
// this code copies a JPG: CMYK or RGB
// import it
g=DesktopFolder.Child("PICT1533.JPG")
ji=new JPEGImporterMBS
ji.File=g
ji.AllowDamaged=true
ji.CMYK=true // if it is cmyk
if ji.InitJPEG then
do
loop until ji.LoopJPEG<>0
ji.FinishJPEG
end if
// export it
f=desktopfolder.child("PICT1533 copy.JPG")
je=new JPEGExporterMBS
je.File=f
je.Quality=75
if ji.CMYK then
m=ji.PictureData
je.ExportCMYK m, ji.Width, ji.Height, ji.Width*4
else
je.Picture=ji.Picture
je.Export
end if
Notes: Call FinishJPEG even if this failes.
Returns true if you can loop using LoopJPEG.
JPEGImporterMBS.LoopJPEG as integer
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Decompresses one line of the picture.
Example:
Return values:
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.3, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Decompresses one line of the picture.
Example:
j=new JPEGImporterMBS
...
if j.initJPEG then
do
loop until j.LoopJPEG<>0
end if
j.FinishJPEG
backdrop=j.Picture // nil if failed
Notes: Return values:
| 0 | Decompression was okay |
| 1 | Finished decompression |
| 2 | if there was an error. |
| 3 | Not initialized |
| 4 | Header only was requested |
JPEGImporterMBS.MarkerCount as integer
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Number of markers found in the JPEG data stream.
Notes: Only available if ReadMarkers was true on reading the JPEG data.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Number of markers found in the JPEG data stream.
Notes: Only available if ReadMarkers was true on reading the JPEG data.
JPEGImporterMBS.MarkerItem(index as integer) as JPEGImporterMarkerMBS
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns the marker with the given index.
Notes: Only available if ReadMarkers was true on reading the JPEG data.
method, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 6.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Returns the marker with the given index.
Notes: Only available if ReadMarkers was true on reading the JPEG data.
JPEGImporterMBS.Mode as Integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The operation mode.
Notes:
Can be either ModePicture (Default), ModeRGB or ModeCMYK.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The operation mode.
Notes:
Can be either ModePicture (Default), ModeRGB or ModeCMYK.
(Read and Write property)
JPEGImporterMBS.ModeCMYK=2
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Notes:
Load the image into the picturedata property.
Memoryblock with 4 bytes per pixel.
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Notes:
Load the image into the picturedata property.
Memoryblock with 4 bytes per pixel.
JPEGImporterMBS.ModeGray=3
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.7, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Example:
Load the image into the picturedata property.
Memoryblock with one byte per pixel.
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.7, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Example:
dim j as new JPEGImporterMBS
j.Mode=j.ModeGray
j.File=DesktopFolder.Child("testGray.JPG")
j.Import
MsgBox str(j.Width)+" x "+str(j.Height)
Notes: Load the image into the picturedata property.
Memoryblock with one byte per pixel.
JPEGImporterMBS.ModePicture=0
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Notes: Load the image into the picture property.
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Notes: Load the image into the picture property.
JPEGImporterMBS.ModeRGB=1
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Example:
Load the image into the picturedata property.
Memoryblock with 3 bytes per pixel.
const, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Plugin version: 8.4, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: One of the mode constants.
Example:
dim j as new JPEGImporterMBS
j.Mode=j.ModeRGB
j.File=DesktopFolder.Child("testRGB.JPG")
j.Import
MsgBox str(j.Width)+" x "+str(j.Height)
Notes: Load the image into the picturedata property.
Memoryblock with 3 bytes per pixel.
JPEGImporterMBS.OriginalDepth as integer
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The original depth of the picture.
Notes:
Value maybe 8 for grayscale pictures and 24 or 32 for colored pictures.
0 if the loading of the picture failed.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The original depth of the picture.
Notes:
Value maybe 8 for grayscale pictures and 24 or 32 for colored pictures.
0 if the loading of the picture failed.
(Read and Write property)
JPEGImporterMBS.Picture as Picture
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The picture as the result.
Notes:
Set to nil on any error.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The picture as the result.
Notes:
Set to nil on any error.
(Read and Write property)
JPEGImporterMBS.PictureData as MemoryBlock
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The cmyk picture data after importing.
Example:
Basicly a memoryblock with one byte for each channel.
Ordered CMYK.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 3.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The cmyk picture data after importing.
Example:
dim g as FolderItem
dim ji as JPEGImporterMBS
dim je as JPEGExporterMBS
dim f as FolderItem
dim m as MemoryBlock
// import it
g=getFolderItem("CMYK Example.jpg")
ji=new JPEGImporterMBS
ji.File=g
ji.AllowDamaged=true
ji.ImportCMYK
m=ji.PictureData
msgBox g.name
// export it
f=desktopfolder.child("CMYK Example2.jpg")
je=new JPEGExporterMBS
je.File=f
je.Quality=75
je.ExportCMYK m, ji.Width, ji.Height, ji.Width*4
Notes: Basicly a memoryblock with one byte for each channel.
Ordered CMYK.
(Read and Write property)
JPEGImporterMBS.ProfileData as String
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The ICC profile stored in the file.
Example:
Only used when ReadProfileData is set to true before you import the image.
The string contains the binary content of a profile file on disc. So you can pass it to the CMOpenProfileFromDataMBS function or write it to a file using the binarystream class.
Value is "" if no profile was found.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 7.2, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: The ICC profile stored in the file.
Example:
dim f as FolderItem
dim j as JPEGImporterMBS
dim p as CMProfileMBS
f=DesktopFolder.Child("test2.jpg")
j=new JPEGImporterMBS
j.ReadMarkers=true // else no metadata is read at all
j.ReadProfileData=true // needed to fill ProfileData property
j.file=f
j.Import
if j.ProfileData="" then
MsgBox "no profile"
Return
end if
p=CMOpenProfileFromDataMBS(j.ProfileData)
MsgBox p.Name
Notes: Only used when ReadProfileData is set to true before you import the image.
The string contains the binary content of a profile file on disc. So you can pass it to the CMOpenProfileFromDataMBS function or write it to a file using the binarystream class.
Value is "" if no profile was found.
(Read and Write property)
JPEGImporterMBS.ReadExifData as Boolean
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Whether the plugin should read in the exif data.
Notes:
If there is exif data, it will be stored in the ExifData property.
Setting this value to true will set ReadMarkers to true, too.
The data is stored in one or more markers, so it is needed to read them before extracting the data.
(Read and Write property)
property, Pictures Import and Export, MBS JPEG Plugin (JPEGDecompression), class JPEGImporterMBS, Console safe, Plugin version: 8.5, Mac OS X: Works, Windows: Works, Linux x86: Works, Feedback.
Function: Whether the plugin should read in the exif data.
Notes:
If there is exif data, it will be stored in the ExifData property.
Setting this value to true will set ReadMarkers to true, too.
The data is stored in one or more markers, so it is needed to read them before extracting the data.
(Read and Write property)
The items on this page are in the following plugins: MBS JPEG Plugin.
Monkeybread Software Realbasic Plugins - Pfarrgemeinderat St. Arnulf Nickenich