Files
FileFlowsPlugins/ImageNodes/Images/ImageIsLandscape.cs
John Andrews 9761376ee1 FF-152 - saving pattern match match to "PatternMatch" variable
added help links to image and audio nodes
2022-08-08 14:51:14 +12:00

21 lines
587 B
C#

namespace FileFlows.ImageNodes.Images;
public class ImageIsLandscape: ImageBaseNode
{
public override int Inputs => 1;
public override int Outputs => 2;
public override FlowElementType Type => FlowElementType.Logic;
public override string Icon => "fas fa-image";
public override string HelpUrl => "https://docs.fileflows.com/plugins/image-nodes/image-is-landscape";
public override int Execute(NodeParameters args)
{
var img = GetImageInfo(args);
if (img == null)
return -1;
return img.IsLandscape ? 1 : 2;
}
}