Initializes a new DiscreteFourierTransformCommand class object with explicit parameters.
public DiscreteFourierTransformCommand(
Leadtools.Imageprocessing.Core.FourierTransformInformation fourierTransformInformation,
Leadtools.LeadRect range,
Leadtools.Imageprocessing.Core.DiscreteFourierTransformCommandFlags flags
)
Public Function New( _
ByVal fourierTransformInformation As Leadtools.Imageprocessing.Core.FourierTransformInformation, _
ByVal range As Leadtools.LeadRect, _
ByVal flags As Leadtools.Imageprocessing.Core.DiscreteFourierTransformCommandFlags _
)
public DiscreteFourierTransformCommand(
Leadtools.Imageprocessing.Core.FourierTransformInformation fourierTransformInformation,
Leadtools.LeadRect range,
Leadtools.Imageprocessing.Core.DiscreteFourierTransformCommandFlags flags
)
- (instancetype)initWithInformation:(LTFourierTransformInformation *)information
range:(LeadRect)range
flags:(LTDiscreteFourierTransformCommandFlags)flags
function DiscreteFourierTransformCommand(
fourierTransformInformation ,
range ,
flags
)
public:
DiscreteFourierTransformCommand(
Leadtools.Imageprocessing.Core.FourierTransformInformation^ fourierTransformInformation,
Leadtools.LeadRect range,
Leadtools.Imageprocessing.Core.DiscreteFourierTransformCommandFlags flags
)
fourierTransformInformation
FourierTransformInformation structure. The Data property of the FourierTransformInformation object is a two-dimensional array that holds the frequency components of the image. Its size must be the same as the image. This array is filled by the command when DiscreteFourierTransformCommandFlags.DiscreteFourierTransform has been set, and it must be sent to the command to construct the image from it when DiscreteFourierTransformCommandFlags.InverseDiscreteFourierTransform has been set.
range
Specifies the frequency range to be computed when DiscreteFourierTransformCommandFlags.InverseDiscreteFourierTransform flag is set. It specifies the frequency range that will be used in the image construction when DiscreteFourierTransformCommandFlags.InverseDiscreteFourierTransform is set. The left value refers to the minimum X harmonic, the right refers to the maximum X harmonic, the top refers to the minimum Y harmonic and the bottom refers to the maximum Y harmonic. The maximum X harmonic equals (Width -1) and the maximum Y harmonic equals (Height -1). The minimum X harmonic equals 0 and the minimum Y harmonic equals 0.
flags
Flags that indicate the transformation type, operation channel, frequency data type used to reconstruct the image, the clipping type, the used or computed frequencies range, the operation on the specified X harmonics range, and the operation on the specified Y harmonics range. You can use a bitwise OR ( ¦ ) to specify one flag from each group.
Run the DiscreteFourierTransformCommand on an image.
Imports Leadtools
Imports Leadtools.Codecs
Imports Leadtools.ImageProcessing.Core
Public Sub DiscreteFourierTransformConstructorExample()
Dim codecs As New RasterCodecs()
codecs.ThrowExceptionsOnInvalidImages = True
Dim leadImage As RasterImage = codecs.Load(Path.Combine(LEAD_VARS.ImagesDir, "Master.jpg"))
' Prepare the command
Dim FTArray As FourierTransformInformation
FTArray = New FourierTransformInformation(leadImage)
Dim rcRange As LeadRect
rcRange = New LeadRect(0, 0, CType((leadImage.Width / 4), Integer), CType((leadImage.Height / 2), Integer))
Dim command As DiscreteFourierTransformCommand
command = New DiscreteFourierTransformCommand(FTArray, rcRange, DiscreteFourierTransformCommandFlags.DiscreteFourierTransform Or _
DiscreteFourierTransformCommandFlags.Gray Or DiscreteFourierTransformCommandFlags.Range Or _
DiscreteFourierTransformCommandFlags.InsideX Or DiscreteFourierTransformCommandFlags.OutsideY)
' Apply DFT.
command.Run(leadImage)
End Sub
Public NotInheritable Class LEAD_VARS
Public Const ImagesDir As String = "C:\Users\Public\Documents\LEADTOOLS Images"
End Class
using Leadtools;
using Leadtools.Codecs;
using Leadtools.ImageProcessing.Core;
public void DiscreteFourierTransformConstructorExample()
{
// Load an image
RasterCodecs codecs = new RasterCodecs();
codecs.ThrowExceptionsOnInvalidImages = true;
RasterImage image = codecs.Load(Path.Combine(LEAD_VARS.ImagesDir, "Master.jpg"));
// Prepare the command
FourierTransformInformation FTArray = new FourierTransformInformation(image);
LeadRect rcRange = new LeadRect(0, 0, image.Width / 4, image.Height / 2);
DiscreteFourierTransformCommand command = new DiscreteFourierTransformCommand(FTArray, rcRange , DiscreteFourierTransformCommandFlags.DiscreteFourierTransform | DiscreteFourierTransformCommandFlags.Gray |
DiscreteFourierTransformCommandFlags.Range | DiscreteFourierTransformCommandFlags.InsideX | DiscreteFourierTransformCommandFlags.OutsideY);
// Apply DFT.
command.Run(image);
}
static class LEAD_VARS
{
public const string ImagesDir = @"C:\Users\Public\Documents\LEADTOOLS Images";
}
using Leadtools;
using Leadtools.Codecs;
using Leadtools.ImageProcessing.Core;
public async Task DiscreteFourierTransformConstructorExample()
{
// Load an image
RasterCodecs codecs = new RasterCodecs();
codecs.ThrowExceptionsOnInvalidImages = true;
// Load the image
string srcFileName = @"Assets\Image1.cmp";
StorageFile loadFile = await Tools.AppInstallFolder.GetFileAsync(srcFileName);
RasterImage image = await codecs.LoadAsync(LeadStreamFactory.Create(loadFile));
// Prepare the command
FourierTransformInformation FTArray = new FourierTransformInformation(image);
LeadRect rcRange = LeadRectHelper.Create(0, 0, image.Width / 4, image.Height / 2);
DiscreteFourierTransformCommand command = new DiscreteFourierTransformCommand(FTArray, rcRange , DiscreteFourierTransformCommandFlags.DiscreteFourierTransform | DiscreteFourierTransformCommandFlags.Gray |
DiscreteFourierTransformCommandFlags.Range | DiscreteFourierTransformCommandFlags.InsideX | DiscreteFourierTransformCommandFlags.OutsideY);
// Apply DFT.
command.Run(image);
}
Raster .NET | C API | C++ Class Library | JavaScript HTML5
Document .NET | C API | C++ Class Library | JavaScript HTML5
Medical .NET | C API | C++ Class Library | JavaScript HTML5
Medical Web Viewer .NET
Your email has been sent to support! Someone should be in touch! If your matter is urgent please come back into chat.
Chat Hours:
Monday - Friday, 8:30am to 6pm ET
Thank you for your feedback!
Please fill out the form again to start a new chat.
All agents are currently offline.
Chat Hours:
Monday - Friday
8:30AM - 6PM EST
To contact us please fill out this form and we will contact you via email.