using System; using System.Collections.Generic; using System.Linq; using System.Runtime.InteropServices; using System.Text; using System.Threading.Tasks; namespace ConsoleApp1 { class SurfaceGridProxy { const string SURFACEGRIDLIB = "sg.dll"; /** * * \param sourcePointFile 离散点源数据文件(xyz 格式) * \param faultFile 断层(fault,不存在z数据)区域数据文件,支持 bln文件、dfd文件 * * \param outputFile 迭代输出结果文件 * \return */ [DllImport(SURFACEGRIDLIB, EntryPoint = "BuildMinCurvatureInterpolationGrid", CharSet = CharSet.Unicode, ExactSpelling = false, CallingConvention = CallingConvention.Cdecl)] public static extern bool BuildMinCurvatureInterpolationGrid(string sourcePointFile, string faultFile, string outputFile); /** * * \param sourcePointFile 离散点源数据文件(xyz 格式) * \param faultFile 断层(fault,不存在z数据)区域数据文件,支持 bln文件、dfd文件 * * \param xNodeCount 插值网格x坐标上网格节点数,默认101个(100个网格) * \param yNodeCount 插值网格y坐标上网格节点数,默认101个(100个网格) * * \param faultEdgeLevel 添加断层数据标记位到输出文件中,添加标记位有不同的等级(0~4), 默认为不添加 * \param outputFile 迭代输出结果文件 * \return */ [DllImport(SURFACEGRIDLIB, EntryPoint = "BuildMinCurvatureInterpolationGrid2", CharSet = CharSet.Unicode, ExactSpelling = false, CallingConvention = CallingConvention.Cdecl)] public static extern bool BuildMinCurvatureInterpolationGrid2(string sourcePointFile, string faultFile, ulong xNodeCount, ulong yNodeCount, int faultEdgeLevel, string outputFile); /** * \param sourcePointFile 离散点源数据文件(xyz 格式) * \param faultFile 断层(fault,不存在z数据)区域数据文件,支持 bln文件、dfd文件 * * \param xNodeCount 插值网格x坐标上网格节点数,默认101个(100个网格) * \param yNodeCount 插值网格y坐标上网格节点数,默认101个(100个网格) * \param maxIteration 最大迭代次数,默认20000次 * \param residual 迭代容忍度指标, 默认为 0.01% * \param fillValue 迭代填充值,对于迭代过程中没有数据的点使用填充值填充,默认为 0.0 * * \param faultEdgeLevel 添加断层数据标记位到输出文件中,添加标记位有不同的等级(0~4), 默认为不添加 * \param outputFile 迭代输出结果文件 * \return */ [DllImport(SURFACEGRIDLIB, EntryPoint = "BuildMinCurvatureInterpolationGrid3", CharSet = CharSet.Unicode, ExactSpelling = false, CallingConvention = CallingConvention.Cdecl)] public static extern bool BuildMinCurvatureInterpolationGrid3(string sourcePointFile, string breakLineFile, string faultFile, ulong xNodeCount, ulong yNodeCount, int maxIteration, double residual, double fillValue, int faultEdgeLevel, string outputFile); } }