![]() | NXMapLayerCompLink Class |
Namespace: Pixoneer.NXDL.NXMap
public class NXMapLayerCompLink : NXMapLayer
The NXMapLayerCompLink type exposes the following members.
Name | Description | |
---|---|---|
![]() | NXMapLayerCompLink |
Name | Description | |
---|---|---|
![]() | FrontAlpha | 앞쪽 composite에 대한 투명값을 가져오거나 설정한다. |
![]() | LayerVisible | 레이어의 도시여부를 확인하거나 설정한다. (Overrides NXMapLayerLayerVisible.) |
![]() | LayoutMode | Composite를 연결하는 방법(Horizontal이나 Vertical)에 대한 레이어 모드를 가져오거나 설정한다. /// |
![]() | ShowBoundary | 전체 영역에 대한 경계를 보이거나 숨길수 있는 여부를 설정하거나 얻는다. |
Name | Description | |
---|---|---|
![]() | EnableCache | 캐싱을 활성화한다. |
![]() | GetXDLCompManager1 | 첫번째 Composite manager를 가져온다. |
![]() | GetXDLCompManager2 | 두번째 Composite manager를 가져온다. |
![]() | Invalidate | 전체 화면을 갱신하도록 하며, 컨트롤의 내용을 다시 그리도록 한다. |
![]() | Lock | 쓰레드를 잠근다. |
![]() | SetComp1Front | 첫번째 composite를 앞쪽으로 이동한다. |
![]() | SetComp2Front | 두번째 composite를 앞쪽으로 이동한다. |
![]() | UnLock | 잠근 쓰레드를 푼다. |
![]() | ZoomFit | 화면에 전체 영상이 도시되도록 확대축소하는 함수이다. |
using Pixoneer.NXDL.NIO; partial class FormMain { private Pixoneer.NXDL.NXMap.NXMapView nxMapView1; private Pixoneer.NXDL.NXMap.NXMapLayerCompLink nxMapLayerCompLink1; private void InitializeComponent() { this.nxMapView1 = new Pixoneer.NXDL.NXMap.NXMapView(); this.nxMapLayerCompLink1 = new Pixoneer.NXDL.NXMap.NXMapLayerCompLink(); this.nxMapLayerCompLink1.BorderStyle = System.Windows.Forms.BorderStyle.FixedSingle; this.nxMapLayerCompLink1.FrontAlpha = 1F; this.nxMapLayerCompLink1.LayoutMode = Pixoneer.NXDL.NXMap.NXMapLayerCompLink.eLayoutMode.Horizontal; this.nxMapLayerCompLink1.Location = new System.Drawing.Point(20, 75); this.nxMapLayerCompLink1.Name = "nxMapLayerCompLink1"; this.nxMapLayerCompLink1.Size = new System.Drawing.Size(145, 30); this.nxMapLayerCompLink1.TabIndex = 1; this.nxMapLayerCompLink1.Visible = false; this.nxMapView1.Controls.Add(this.nxMapLayerCompLink1); } private void horToolStripMenuItem_Click(object sender, EventArgs e) { nxMapLayerCompLink1.LayoutMode = NXMapLayerCompLink.eLayoutMode.Horizontal; } private void vertToolStripMenuItem_Click(object sender, EventArgs e) { nxMapLayerCompLink1.LayoutMode = NXMapLayerCompLink.eLayoutMode.Vertical; } private void openPairFilesToolStripMenuItem_Click(object sender, EventArgs e) { string strFile1 = ""; string strFile2 = ""; if (openFileDialog1.ShowDialog() == DialogResult.OK) { strFile1 = openFileDialog1.FileName; } else return; if (openFileDialog1.ShowDialog() == DialogResult.OK) { strFile2 = openFileDialog1.FileName; } else return; FillCompisiteManager(strFile1, false); FillCompisiteManager(strFile2, true); nxMapLayerCompLink1.ZoomFit(); } private void FillCompisiteManager(string strFile, bool bS) { String strError; XRSLoadFile xrsFile = m_RSFileDriverManager.LoadFile(strFile, out strError, true, eIOCreateXLDMode.All_NoMsg); if (xrsFile == null) return; XDMComposite newcomp; XDMCompManager xdmManager; if(bS) xdmManager = nxMapLayerCompLink1.GetXDLCompManager2(); else xdmManager = nxMapLayerCompLink1.GetXDLCompManager1(); int numBand = xrsFile.NumBand; newcomp = new XDMComposite(); newcomp.Name = xrsFile.FileName; if (numBand >= 3) { XDMBand bandL0 = xrsFile.GetBandAt(0); XDMBand bandL1 = xrsFile.GetBandAt(1); XDMBand bandL2 = xrsFile.GetBandAt(2); newcomp.Mode = eCompMode.RGB; if (bS) { newcomp.SetBand(ref bandL0, 0); newcomp.SetBand(ref bandL1, 2); newcomp.SetBand(ref bandL2, 1); } else { 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 = xrsFile.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); } xdmManager.AddXDMComposite(ref newcomp); newcomp = null; xdmManager = null; } }