Click or drag to resize
XDL

NXMilmapLayerImageProcess Class

Milmap 뷰에 영상 처리 구성 요소를 추가하고자 할 때 이 레이어를 사용한다.
Inheritance Hierarchy

Namespace:  Pixoneer.NXDL.NXMilmap
Assembly:  NXMilmap (in NXMilmap.dll) Version: 2.0.3.31
Syntax
C#
public class NXMilmapLayerImageProcess : NXRenderLayer

The NXMilmapLayerImageProcess type exposes the following members.

Constructors
  NameDescription
Public methodNXMilmapLayerImageProcess
Top
Properties
  NameDescription
Public propertyLayerVisible
레이어의 도시여부를 확인하거나 설정한다.
(Overrides NXRenderLayerLayerVisible.)
Top
Methods
  NameDescription
Public methodAddXDMComposite
이 레이어에 XDMComposite를 추가한다.
Public methodEnableShaderAlgorithm
GPU를 통한 쉐이더 알고리즘을 활성화할지 비활성화할지 설정한다.
Public methodGenShaderCodeBasso
Basso 쉐이더 코드를 생성한다.
Public methodGenShaderCodeCBS
CBS(Contrast Brightness Saturation) 쉐이더 코드를 생성한다.
Public methodGenShaderCodeEdge
모서리 탐지 쉐이더 코드를 생성한다.
Public methodGenShaderCodeHDR
HDR(High Dynamic Range) 쉐이더 코드를 생성한다.
Public methodGenShaderCodeNew
초기화와 함께 새로운 쉐이더 코드를 생성한다.
Public methodGetLayerID
레이어의 ID를 가져온다.
(Overrides NXRenderLayerGetLayerID.)
Public methodGetXDMCompManager
이 레이어의 composite 관리자를 가져온다.
Public methodInitialize
내부 초기화 함수. 최초로 사용될 때 NXMilmapEngine이 자동호출한다.
(Overrides NXRenderLayerInitialize.)
Public methodSetShaderAlgorithm
쉐이더 알고리즘 코드를 설정한다.
Top
Examples
예제 #1:
partial class FormMain
{
    private Pixoneer.NXDL.NXMilmap.NXMilmapView nxMilmapView1;
    private Pixoneer.NXDL.NXMilmap.NXMilmapLayerImageProcess nxMilmapImageProcessLayer1;
    public XScene m_Scene;
    private void InitializeComponent()
    {
        this.nxMilmapView1 = new Pixoneer.NXDL.NXMilmap.NXMilmapView();
        this.nxMilmapImageProcessLayer1 = new Pixoneer.NXDL.NXMilmap.NXMilmapLayerImageProcess();
    }
    private void FormMain_Load(object sender, EventArgs e)
    {
        NXRenderLayer layer = (NXRenderLayer)nxMilmapImageProcessLayer1;
        nxMilmapView1.AddRenderLayer(ref layer);

        // Open file
        OpenFileDialog openFileDialog = new OpenFileDialog();
        openFileDialog.Filter = "XDM file(*.xdm)|*.XDM||";
        openFileDialog.RestoreDirectory = true;

        if (openFileDialog.ShowDialog() != DialogResult.OK) return;

        string strFileName = openFileDialog.FileName;
        string strError;
        m_xrsFileInput = m_RSFileDriverManager.LoadFile(strFileName, out strError, true, eIOCreateXLDMode.All_NoMsg);

        XDMComposite newComp = new XDMComposite();
        newComp.Name = strFileName;
        if (m_xrsFileInput.NumBand >= 3)
        {
            XDMBand bandL0 = m_xrsFileInput.GetBandAt(0);
            XDMBand bandL1 = m_xrsFileInput.GetBandAt(1);
            XDMBand bandL2 = m_xrsFileInput.GetBandAt(2);

            newComp.Mode = eCompMode.RGB;
            newComp.SetBand(ref bandL0, 2);
            newComp.SetBand(ref bandL1, 1);
            newComp.SetBand(ref bandL2, 0);
            for (int i = 0; i < 3; i++)
            {
                newComp.SetCutType(eCompCutType.Ct95, i);                    //Cut Type Gaussian 95
                newComp.SetStretchCoverage(eCompStretchCoverage.Band, i);   //XDMCOMPOSITE_SC_BAND
                newComp.SetStretchType(eCompStretchType.Gaussian, i);       //XDMCOMPOSITE_ST_GAUSSIAN
                newComp.SetCutMin(0.0, i);
                newComp.SetCutMax(255.0, i);
            }
        }
        else
        {
            XDMBand bandL0 = m_xrsFileInput.GetBandAt(0);
            newComp.Mode = eCompMode.Gray;
            newComp.SetBand(ref bandL0, 0);

            newComp.SetCutType(eCompCutType.Ct95, 0);
            newComp.SetStretchCoverage(eCompStretchCoverage.Band, 0);
            newComp.SetStretchType(eCompStretchType.Gaussian, 0);
        }
        nxMilmapImageProcessLayer1.AddXDMComposite(ref newComp);

        // Set image process algorithm
        nxMilmapImageProcessLayer1.SetShaderAlgorithm(nxMilmapImageProcessLayer1.GenShaderCodeHDR());
    }
}
See Also