Click or drag to resize
XDL

XColorTable Class

XColorTable 클래스는 시스템 칼라 테이블을 로딩하거나 커스텀 칼라 테이블을 만든다.
Inheritance Hierarchy
SystemObject
  Pixoneer.NXDLXColorTable

Namespace:  Pixoneer.NXDL
Assembly:  NXDL (in NXDL.dll) Version: 2.0.3.30
Syntax
C#
public class XColorTable : IDisposable

The XColorTable type exposes the following members.

Constructors
  NameDescription
Public methodXColorTable
XColorTable클래스에 대한 기본 생성자이고 멤버 변수들을 초기화한다.
Top
Methods
  NameDescription
Public methodGetCLT
특정 인덱스에 해당하는 칼라 값을 얻는다.
Public methodStatic memberGetPaletteNameList
칼라 테이블의 ID에 해당하는 이름 리스트를 얻는다. 인덱스 ID와 String Array상의 순서가 일치한다.
Public methodLoad
바이너리 데이터로 저장된 칼라 테이블 정보를 로딩한다.
Public methodLoadColorTable
eColorTable에 정의된 ColorTable ID를 이용하여 Color Table을 설정한다.
Public methodSave
칼라 테이블 정보를 바이너리 데이터로 저장한다.
Public methodSetCLT(Int32, Color)
특정 인덱스값에 특정 칼라 값을 설정한다.
Public methodSetCLT(Int32, Byte, Byte, Byte)
특정 인덱스값에 특정 칼라 값을 설정한다.
Top
Examples
// IO initialize to load image file
XRasterIO RasterIO = new XRasterIO();
String strError = "";
if (RasterIO.Initialize(out strError) == false)
{
    return;
}

// Image load
String strFilePathLoad = "D:\\Sample\\Changedetected.xdm";
XRSLoadFile xrsFileInput = RasterIO.LoadFile(strFilePathLoad, out strError, false, eIOCreateXLDMode.All_NoMsg);
XDMBand band = xrsFileInput.GetBandAt(0);
if (band.BandType == eBandType.GIS)
{
    XColorTable clrTable = new XColorTable();
    int i;
    for (i = 0; i < 256; i++)
    {
        clrTable.SetCLT(i, 0, 0, 0);
    }

    int iNumGIS = band.GetNumOfGIS();
    for (i = 0; i < iNumGIS; i++)
    {
        XRSGIS pGIS = band.GetGISAt(i);
        clrTable.SetCLT(pGIS.nID, pGIS.crRed, pGIS.crGreen, pGIS.crBlue);
    }

    // Set Color table to composite(SetCLT function) and draw...
}
See Also