本文整理汇总了C#中Transceiver.GetAntConfig方法的典型用法代码示例。如果您正苦于以下问题:C# Transceiver.GetAntConfig方法的具体用法?C# Transceiver.GetAntConfig怎么用?C# Transceiver.GetAntConfig使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Transceiver
的用法示例。
在下文中一共展示了Transceiver.GetAntConfig方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: GetOnePointBackhaulPathLoss
/// <summary>
/// 获取backhaul单点路损
/// </summary>
/// <param name="trans"></param>
/// <param name="cellID"></param>
/// <param name="sectorID"></param>
/// <param name="x"></param>
/// <param name="y"></param>
/// <param name="resolution"></param>
/// <param name="isGetAntGain"></param>
/// <returns></returns>
private float[][] GetOnePointBackhaulPathLoss(Transceiver trans, short cellID, int sectorID, double x, double y, float resolution, bool isGetAntGain)
{
float[][] pathLossMatrix = new float[][] { new float[2] };
if (this.m_PathLossCellData.TransBackhaulPathLossMatrixList.Count != 0)
{
TransceiverPathLossMatrix transceiverPathLossMatrix = FindBackhaulMatrix(sectorID, cellID);
if ((transceiverPathLossMatrix == null) || this.RangeXY(x, y, transceiverPathLossMatrix))
{
pathLossMatrix[0][0] = float.MinValue;
pathLossMatrix[0][1] = float.MinValue;
return pathLossMatrix;
}
double distance = this.GetDistance(trans, sectorID, x, y);
int xIndex = (int)((x - transceiverPathLossMatrix.LeftTopX) / ((double)transceiverPathLossMatrix.Resolution));
int yIndex = (int)((transceiverPathLossMatrix.LeftTopY - y) / ((double)transceiverPathLossMatrix.Resolution));
int delayIndex = this.GetDelayIndex(xIndex, yIndex, transceiverPathLossMatrix);
if (this.IsMatixInvalid(transceiverPathLossMatrix, delayIndex))
{
pathLossMatrix[0][1] = float.MinValue;
pathLossMatrix[0][0] = float.MinValue;
}
else if (this.IsUsingMatrixs(x, y, resolution, transceiverPathLossMatrix))
{
float deltaLoss = GetBackhaulDeltaLoss(trans, x, y, distance);
GetExistsPLMatrix(isGetAntGain, pathLossMatrix, transceiverPathLossMatrix, delayIndex, deltaLoss);
}
else
{
StructAntennaParam calAntennaParam = new StructAntennaParam();
calAntennaParam.CellX = trans.Parent.X + trans.GetAntConfig(sectorID).DX;
calAntennaParam.CellY = trans.Parent.Y + trans.GetAntConfig(sectorID).DY;
calAntennaParam.IsSimple = false;
calAntennaParam.AntHeight = this.m_IGeoInfo.GetValueByGeoXYPoint(calAntennaParam.CellX, calAntennaParam.CellY, DemDataType.Height);
//用户的坐标
calAntennaParam.MsX = x;
calAntennaParam.MsY = y;
calAntennaParam.MsHeight = this.m_IGeoInfo.GetValueByGeoXYPoint(x, y, DemDataType.Height);
float num6 = transceiverPathLossMatrix.LeftTopX + (xIndex * transceiverPathLossMatrix.Resolution);
float dX = (float)((x - num6) / ((double)transceiverPathLossMatrix.Resolution));
float num8 = transceiverPathLossMatrix.LeftTopY - (yIndex * transceiverPathLossMatrix.Resolution);
float dY = (float)((num8 - y) / ((double)transceiverPathLossMatrix.Resolution));
pathLossMatrix[0][1] = this.getPathLossByWeight(xIndex, yIndex, dX, dY, transceiverPathLossMatrix);
float antGain = 0f;
if (isGetAntGain)
{
calAntennaParam.AntConfigSetUp = trans.GetAntConfig(sectorID);
antGain = this.m_AntennaGainCalculator.Calculate3DGain(calAntennaParam);
}
this.SetBackhaulMatrix(pathLossMatrix, x, y, trans, antGain, distance);
}
}
return pathLossMatrix;
}
示例2: GetDistance
private double GetDistance(Transceiver trans, int sectorID, double x, double y)
{
GeoXYPoint point = new GeoXYPoint(trans.Parent.X + trans.GetAntConfig(sectorID).DX, trans.Parent.Y + trans.GetAntConfig(sectorID).DY);
GeoXYPoint point2 = new GeoXYPoint(x, y);
return point.Distance(point2);
}