本文整理汇总了C#中System.IO.StreamWriter.Export_IBUF方法的典型用法代码示例。如果您正苦于以下问题:C# StreamWriter.Export_IBUF方法的具体用法?C# StreamWriter.Export_IBUF怎么用?C# StreamWriter.Export_IBUF使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.IO.StreamWriter
的用法示例。
在下文中一共展示了StreamWriter.Export_IBUF方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: Export_IBUF_Main
void Export_IBUF_Main(StreamWriter w, IBUF ibuf, MLOD.Mesh mesh)
{
if (ibuf == null) { w.WriteLine("; ibuf is null"); w.WriteLine("ibuf 0"); return; }
w.WriteLine(string.Format("ibuf {0}", mesh.PrimitiveCount));
w.Export_IBUF(mpb, ibuf.GetIndices(mesh), IBUF.IndexCountFromPrimitiveType(mesh.PrimitiveType), mesh.PrimitiveCount);
}
示例2: Export_IBUF_Geos
void Export_IBUF_Geos(StreamWriter w, IBUF ibuf, MLOD.Mesh mesh, int geoStateIndex)
{
if (ibuf == null) { w.WriteLine("; ibuf is null for geoState"); w.WriteLine(string.Format("ibuf {0} 0 0", geoStateIndex)); return; }
int sizePerPrimitive = IBUF.IndexCountFromPrimitiveType(mesh.PrimitiveType);
MLOD.GeometryState geoState = mesh.GeometryStates[geoStateIndex];
if (geosIBUFIsContained(geoState, sizePerPrimitive, mesh)) w.WriteLine("; ibuf is contained within main mesh");
w.WriteLine(string.Format("ibuf {0} {1} {2}", geoStateIndex, geoState.StartIndex, geoState.PrimitiveCount));
if (geosIBUFIsContained(geoState, sizePerPrimitive, mesh)) return;
w.Export_IBUF(mpb, ibuf.GetIndices(mesh, geoStateIndex), sizePerPrimitive, geoState.PrimitiveCount);
}