IMcImageSetAddImage Method
|
|
Add the frames of an image to the specified position
Namespace:
MediaCy.IQL.Sets
Assembly:
MediaCy.IQL.Sets (in MediaCy.IQL.Sets.dll) Version: 10.0.6912.0
SyntaxSub AddImage (
ImageOrFile As Object,
Organization As McImageSetExtents,
Location As McImageSetLocations
)
Parameters
- ImageOrFile
- Type: SystemObject
If a string, or vector of strings, the image file(s) to add. Otherwise this may be a
McFrame or McImage instance or an array of such instances. Only the
ActiveFrameRange of the source McImage(s) will be added to the data set if
the McImage.UseActiveFrameRange property is true. If the
McImage.UseActiveFrameRange property is false, then only the ActiveFrame of
that source image is added to the data set.
Organization: The organization of the frames within the image as a
McImageSetExtents collection of McImageSetExtent instances. The first
element in the collection identifies the type and gives the length of the
fastest moving dimension, followed by the types and lengths of any
progressively slower moving dimensions. The product of the Organization
dimension lengths must match the total number of frames supplied by the
ImageOrFile argument, taking ActiveFrameRange(s) into account.
Location: The set location at which to add the image. - Organization
- Type: MediaCy.IQL.SetsMcImageSetExtents
- Location
- Type: MediaCy.IQL.SetsMcImageSetLocations
RemarksAdds the supplied image to the specified position. The image can be
specified as a McImage that is open in the application, or as the image file
containing the frames. When the image is specified as a McImage, the image's
ActiveFrameRange will be added to the set
Since the image can contain multiple frames, the Organization parameter must be
used to indicate the organization (i.e., the order and length of dimensions) of
those frames. As illustrated in the example, the dimension that varies the most
rapidly should be the first dimension specified in the organization collection,
followed by the dimension that varies next most rapidly, etc.
ExamplesSub CreateSetFromImage()
Dim aSet As McImageSet
If ThisApplication.ActiveImage Is Nothing Then
MsgBox "Please open the PollenGreen.seq image file"
Exit Sub
End If
If ThisApplication.ActiveImage.FrameCount <> 48 Then
MsgBox "Please open the PollenGreen.seq image file"
Exit Sub
End If
Set aSet = ImageSets.Add("SampleSet")
aSet.Experimenter = "IQ user"
aSet.Description = "This is a sample set of 3 pollen grains, taken as follows:" + vbCrLf + " 16 Z positions " + vbCrLf + " repeated for each of " + vbCrLf + " 3 sites (the X/Y location of the grains) by" + vbCrLf + " 4 channels (R, G, B, and color composite)"
Dim theOrg As New McImageSetExtents
theOrg.Add mcisdZ, 16
theOrg.Add mcisdSite, 3
Dim theLoc As New McImageSetLocations
aSet.AddImage ActiveImage, theOrg, theLoc
End Sub
See Also