[CLSCompliantAttribute(false)]
public ushort B { get; set; }
@property (nonatomic, assign) unsigned short b;
public short getB();
public void setB(
short shortValue
);
B # get and set (RasterColor16)
The blue component of this RasterColor16 structure.
using Leadtools;
public void RasterColor16ComponentsExample()
{
// This C# example shows how to create a normal grayscale LUT.
RasterColor16[] lut = new RasterColor16[1024];
RasterColor16 color = new RasterColor16(0, 0, 0);
for (ushort i = 0; i < 1024; i++)
{
int gray = i * 65535 / 1023;
color.R = (ushort)gray;
color.G = (ushort)gray;
color.B = (ushort)gray;
lut[i] = color;
}
}
import java.io.File;
import java.io.IOException;
import java.util.Random;
import org.junit.*;
import org.junit.Test;
import org.junit.runner.JUnitCore;
import org.junit.runner.Result;
import org.junit.runner.notification.Failure;
import static org.junit.Assert.*;
import leadtools.*;
public void rasterColor16ComponentsExample() {
// This C# example shows how to create a normal grayscale LUT.
RasterColor16[] lut = new RasterColor16[1024];
RasterColor16 color = new RasterColor16(0, 0, 0);
for (short i = 0; i < 1024; i++) {
int gray = i * 65535 / 1023;
color.setR((short) gray);
assertTrue(color.getR() == (short) gray);
color.setG((short) gray);
assertTrue(color.getG() == (short) gray);
color.setB((short) gray);
assertTrue(color.getB() == (short) gray);
lut[i] = color;
}
}
Help Collections
Raster .NET | C API | C++ Class Library | HTML5 JavaScript
Document .NET | C API | C++ Class Library | HTML5 JavaScript
Medical .NET | C API | C++ Class Library | HTML5 JavaScript
Medical Web Viewer .NET
Multimedia
Direct Show .NET | C API | Filters
Media Foundation .NET | C API | Transforms
Supported Platforms
.NET, Java, Android, and iOS/macOS Assemblies
Imaging, Medical, and Document
C API/C++ Class Libraries
Imaging, Medical, and Document
HTML5 JavaScript Libraries
Imaging, Medical, and Document