public LinesGisLayer(Game engine, int linesPointsCount, bool isDynamic = false) : base(engine)
{
shader = Game.Content.Load<Ubershader>("globe.Line.hlsl");
factory = shader.CreateFactory( typeof(LineFlags), Primitive.LineList, VertexInputElement.FromStructure<Gis.GeoPoint>(), BlendState.AlphaBlend, RasterizerState.CullNone, DepthStencilState.None);
thinFactory = shader.CreateFactory( typeof(LineFlags), Primitive.LineList, VertexInputElement.FromStructure<Gis.GeoPoint>(), BlendState.AlphaBlend, RasterizerState.CullNone, DepthStencilState.Readonly);
TransparencyMultiplayer = 1.0f;
OverallColor = Color4.White;
linesConstantBuffer = new ConstantBuffer(engine.GraphicsDevice, typeof(LinesConstDataStruct));
//linesConstantBuffer.SetData(linesConstData);
var vbOptions = isDynamic ? VertexBufferOptions.Dynamic : VertexBufferOptions.Default;
firstBuffer = new VertexBuffer(engine.GraphicsDevice, typeof(Gis.GeoPoint), linesPointsCount, vbOptions);
currentBuffer = firstBuffer;
PointsCpu = new Gis.GeoPoint[linesPointsCount];
Flags = (int)(LineFlags.ARC_LINE);
}