196 void SetValid(
bool valid) { bValid = valid; }
197 time_t GetFileTime()
const {
return file_date; }
198 time_t GetChartEditionDate()
const {
return edition_date; }
200 int GetnPlyEntries()
const {
return nPlyEntries; }
201 float *GetpPlyTable()
const {
return pPlyTable; }
203 int GetnAuxPlyEntries()
const {
return nAuxPlyEntries; }
204 float *GetpAuxPlyTableEntry(
int index)
const {
return pAuxPlyTable[index]; }
205 int GetAuxCntTableEntry(
int index)
const {
return pAuxCntTable[index]; }
207 int GetnNoCovrPlyEntries()
const {
return nNoCovrPlyEntries; }
208 float *GetpNoCovrPlyTableEntry(
int index)
const {
209 return pNoCovrPlyTable[index];
211 int GetNoCovrCntTableEntry(
int index)
const {
return pNoCovrCntTable[index]; }
213 const LLBBox &GetBBox()
const {
return m_bbox; }
215 char *GetpFullPath()
const {
return pFullPath; }
216 float GetLonMax()
const {
return LonMax; }
217 float GetLonMin()
const {
return LonMin; }
218 float GetLatMax()
const {
return LatMax; }
219 float GetLatMin()
const {
return LatMin; }
220 int GetScale()
const {
return Scale; }
221 int GetChartType()
const {
return ChartType; }
222 int GetChartFamily()
const {
return ChartFamily; }
223 int GetChartProjectionType()
const {
return ProjectionType; }
224 float GetChartSkew()
const {
return Skew; }
226 bool GetbValid() {
return bValid; }
227 void SetEntryOffset(
int n) { EntryOffset = n; }
228 const wxString *GetpFileName(
void)
const {
return m_pfilename; }
229 wxString *GetpsFullPath(
void)
const {
return m_psFullPath; }
230 wxString GetFullSystemPath()
const {
return m_fullSystemPath; }
231 const std::string &GetFullPath()
const {
return m_FullPath; }
233 const std::vector<int> &GetGroupArray(
void)
const {
return m_GroupArray; }
234 void ClearGroupArray(
void) { m_GroupArray.clear(); }
235 void AddIntToGroupArray(
int val) { m_GroupArray.push_back(val); }
236 void SetAvailable(
bool avail) { m_bavail = avail; }
238 std::vector<float> GetReducedPlyPoints();
239 std::vector<float> GetReducedAuxPlyPoints(
int iTable);
241 LLRegion quilt_candidate_region;
243 void SetScale(
int scale);
244 bool Scale_eq(
int b)
const {
return abs(Scale - b) <= rounding; }
245 bool Scale_ge(
int b)
const {
return Scale_eq(b) || Scale > b; }
246 bool Scale_gt(
int b)
const {
return Scale > b && !Scale_eq(b); }
264 float **pAuxPlyTable;
269 int nNoCovrPlyEntries;
270 int *pNoCovrCntTable;
271 float **pNoCovrPlyTable;
273 std::vector<int> m_GroupArray;
274 wxString *m_pfilename;
275 wxString *m_psFullPath;
276 wxString m_fullSystemPath;
277 std::string m_FullPath;
282 std::vector<float> m_reducedPlyPoints;
284 std::vector<std::vector<float>> m_reducedAuxPlyPointsVector;
322 bool Create(ArrayOfCDI &dir_array, wxGenericProgressDialog *pprog);
330 bool Update(ArrayOfCDI &dir_array,
bool bForce,
331 wxGenericProgressDialog *pprog);
333 bool Read(
const wxString &filePath);
334 bool Write(
const wxString &filePath);
336 bool AddSingleChart(wxString &fullpath,
bool b_force_full_search =
true);
337 bool RemoveSingleChart(wxString &ChartFullPath);
339 const wxString &GetDBFileName()
const {
return m_DBFileName; }
340 ArrayOfCDI &GetChartDirArray() {
return m_dir_array; }
341 wxArrayString &GetChartDirArrayString() {
return m_chartDirs; }
342 void SetChartDirArray(ArrayOfCDI array) { m_dir_array = array; }
343 bool CompareChartDirArray(ArrayOfCDI &test_array);
344 wxString GetMagicNumberCached(wxString dir);
346 void UpdateChartClassDescriptorArray(
void);
348 int GetChartTableEntries()
const {
return active_chartTable.size(); }
351 inline ChartTable &GetChartTable() {
return active_chartTable; }
353 bool IsValid()
const {
return bValid; }
354 int DisableChart(wxString &PathToDisable);
355 bool GetCentroidOfLargestScaleChart(
double *clat,
double *clon,
356 ChartFamilyEnum family);
357 int GetDBChartType(
int dbIndex);
358 int GetDBChartFamily(
int dbIndex);
359 float GetDBChartSkew(
int dbIndex);
360 int GetDBChartProj(
int dbIndex);
361 int GetDBChartScale(
int dbIndex);
363 bool GetDBBoundingBox(
int dbindex, LLBBox &box);
364 const LLBBox &GetDBBoundingBox(
int dbIndex);
366 int GetnAuxPlyEntries(
int dbIndex);
367 int GetDBPlyPoint(
int dbIndex,
int plyindex,
float *lat,
float *lon);
368 int GetDBAuxPlyPoint(
int dbIndex,
int plyindex,
int iAuxPly,
float *lat,
370 int GetVersion() {
return m_dbversion; }
371 wxString GetFullChartInfo(
ChartBase *pc,
int dbIndex,
int *char_width,
373 int FinddbIndex(wxString PathToFind);
374 wxString GetDBChartFileName(
int dbIndex);
375 void ApplyGroupArray(ChartGroupArray *pGroupArray);
376 bool IsChartAvailable(
int dbIndex);
377 ChartTable active_chartTable;
378 std::map<wxString, int> active_chartTable_pathindex;
380 std::vector<float> GetReducedPlyPoints(
int dbIndex);
381 std::vector<float> GetReducedAuxPlyPoints(
int dbIndex,
int iTable);
383 bool IsBusy() {
return m_b_busy; }
386 virtual ChartBase *GetChart(
const wxChar *theFilePath,
388 int AddChartDirectory(
const wxString &theDir,
bool bshow_prog);
389 void SetValid(
bool valid) { bValid = valid; }
394 std::vector<ChartClassDescriptor> m_ChartClassDescriptorArray;
395 ArrayOfCDI m_dir_array;
399 bool IsChartDirUsed(
const wxString &theDir);
401 int SearchDirAndAddCharts(wxString &dir_name_base,
403 wxGenericProgressDialog *pprog);
406 wxGenericProgressDialog *pprog,
407 wxString &dir_magic,
bool bForce);
408 bool DetectDirChange(
const wxString &dir_path,
const wxString &prog_label,
409 const wxString &magic, wxString &new_magic,
410 wxGenericProgressDialog *pprog);
413 wxGenericProgressDialog *pprog,
int isearch,
414 bool bthis_dir_in_dB);
416 bool Check_CM93_Structure(wxString dir_name);
419 wxArrayString m_chartDirs;
423 m_ChartTableEntryDummy;
424 wxString m_DBFileName;
Represents an entry in the chart table, containing information about a single chart.