LAMPCAE/src/PluginWBFZExchangePlugin/BaseTool.h

94 lines
2.7 KiB
C
Raw Normal View History

2024-04-07 16:19:33 +00:00
#pragma once
#pragma once
#ifndef BASETOOL_H
#define BASETOOL_H
///
/// 基本类、基本函数
///
//#define EIGEN_USE_MKL_ALL
//#define EIGEN_VECTORIZE_SSE4_2
//#include <mkl.h>
//#include <mkl.h>
#include <complex>
#include <iostream>
#include <Eigen/Core>
#include <Eigen/Dense>
#include <time.h>
#include <string>
#include <omp.h>
#include "referenceHeader.h"
#include <gdal.h>
#include <gdal_priv.h>
#include <gdalwarper.h>
#include <ogrsf_frmts.h>
#include <fstream>
#include "GeoOperator.h"
#include <vector>
#include <string>
using namespace std;
using namespace Eigen;
///////////////////////////////////// 运行时间打印 //////////////////////////////////////////////////////////
QString getCurrentTimeString();
QString getCurrentShortTimeString();
2024-04-07 16:19:33 +00:00
std::vector<QString> splitString(const QString& str, char delimiter);
2024-04-07 16:19:33 +00:00
/////////////////////////////// 基本图像类 结束 //////////////////////////////////////////////////////////
string Convert(float Num);
QString JoinPath(const QString& path, const QString& filename);
2024-04-07 16:19:33 +00:00
////////////////////////////// 坐标部分基本方法 //////////////////////////////////////////
////////////////////////////// 坐标部分基本方法 //////////////////////////////////////////
////////////////////////////// 插值 ////////////////////////////////////////////
complex<double> Cubic_Convolution_interpolation(double u, double v, Eigen::MatrixX<complex<double>> img);
2024-04-07 16:19:33 +00:00
complex<double> Cubic_kernel_weight(double s);
2024-04-07 16:19:33 +00:00
double Bilinear_interpolation(Landpoint p0, Landpoint p11, Landpoint p21, Landpoint p12, Landpoint p22);
2024-04-07 16:19:33 +00:00
bool onSegment(Point_3d Pi, Point_3d Pj, Point_3d Q);
2024-04-07 16:19:33 +00:00
Point_3d invBilinear(Point_3d p, Point_3d a, Point_3d b, Point_3d c, Point_3d d);
2024-04-07 16:19:33 +00:00
//
// WGS84 到J2000 坐标系的变换
// 参考网址https://blog.csdn.net/hit5067/article/details/116894616
// 资料网址http://celestrak.org/spacedata/
// 参数文件:
// a. Earth Orientation Parameter 文件: http://celestrak.org/spacedata/EOP-Last5Years.csv
// b. Space Weather Data 文件: http://celestrak.org/spacedata/SW-Last5Years.csv
// 备注上述文件是自2017年-五年内
/**
wgs84 J2000 WGS t ,BLH
step 1: WGS 84
step 2:
step 3:
step 4:
step 5: J2000
**/
double sind(double degree);
2024-04-07 16:19:33 +00:00
double cosd(double d);
2024-04-07 16:19:33 +00:00
#endif