←Select platform

Space Property

Summary
Gets or sets a value that represents the space between cubes.
Syntax
C#
C++/CLI
Python
public int Space { get; set; } 
public: 
property int Space { 
   int get(); 
   void set (    int ); 
} 
Space # get and set (CubismCommand) 

Property Value

Value that represents the space between cubes, in pixels. As this value decreases the concentration of cubes increases and vice versa. The valid range is from 1 to the image or region dimension that is minimum, that is the minimum value of the height and width. This property only accepts positive values.

Example
C#
using Leadtools; 
using Leadtools.Codecs; 
using Leadtools.ImageProcessing.Effects; 
 
 
public void CubismCommandExample() 
{ 
   // Load an image 
   RasterCodecs codecs = new RasterCodecs(); 
   codecs.ThrowExceptionsOnInvalidImages = true; 
 
   RasterImage image = codecs.Load(Path.Combine(LEAD_VARS.ImagesDir, @"ImageProcessingDemo\Image2.jpg")); 
 
   // Prepare the command 
   CubismCommand command = new CubismCommand(); 
   command.Space = 5; 
   command.Length = 15; 
   command.Brightness = 200; 
   command.Angle = 4500; 
   command.FillColor = new RasterColor(255, 0, 0); 
   command.Flags = CubismCommandFlags.Color | CubismCommandFlags.Rectangle | CubismCommandFlags.Random; 
   command.Run(image); 
   codecs.Save(image, Path.Combine(LEAD_VARS.ImagesDir, "Result.jpg"), RasterImageFormat.Jpeg, 24); 
 
} 
 
static class LEAD_VARS 
{ 
   public const string ImagesDir = @"C:\LEADTOOLS22\Resources\Images"; 
} 
Requirements

Target Platforms

Help Version 22.0.2023.3.31
Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.

Leadtools.ImageProcessing.Effects Assembly

Products | Support | Contact Us | Intellectual Property Notices
© 1991-2023 LEAD Technologies, Inc. All Rights Reserved.