OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
ossimKmlSuperOverlayPluginInit.cpp
Go to the documentation of this file.
1 //----------------------------------------------------------------------------
2 //
3 // License: See top level LICENSE.txt file
4 //
5 // Author: Mingjie Su
6 //
7 // Description: OSSIM KmlSuperOverlay plugin initialization
8 // code.
9 //
10 //----------------------------------------------------------------------------
11 // $Id: ossimKmlSuperOverlayPluginInit.cpp 2470 2011-04-26 15:32:19Z david.burken $
12 
15 // #include <ossim/imaging/ossimImageHandlerRegistry.h>
18 
19 // #include "ossimKmlSuperOverlayReaderFactory.h"
21 
22 static void setKmlDescription(ossimString& description)
23 {
24  description = "KmlSuperOverlay writer plugin\n\n";
25  // description = "KmlSuperOverlay reader plugin\n\n";
26 }
27 
28 extern "C"
29 {
32  std::vector<ossimString> theKmlObjList;
33 
34  const char* getKmlDescription()
35  {
36  return theKmlDescription.c_str();
37  }
38 
40  {
41  return (int)theKmlObjList.size();
42  }
43 
44  const char* getKmlClassName(int idx)
45  {
46  if(idx < (int)theKmlObjList.size())
47  {
48  return theKmlObjList[idx].c_str();
49  }
50  return (const char*)0;
51  }
52 
53  /* Note symbols need to be exported on windoze... */
55  ossimSharedObjectInfo** info)
56  {
60 
61  *info = &myKmlInfo;
62 
63  /* Register the readers... */
64  // ossimImageHandlerRegistry::instance()->
65  // registerFactory(ossimKmlSuperOverlayReaderFactory::instance());
66 
67  /* Register the writers... */
70 
71  setKmlDescription(theKmlDescription);
72  //ossimKmlSuperOverlayReaderFactory::instance()->getTypeNameList(theKmlObjList);
74 
75  }
76 
77  /* Note symbols need to be exported on windoze... */
79  {
80  // ossimImageHandlerRegistry::instance()->
81  // unregisterFactory(ossimKmlSuperOverlayReaderFactory::instance());
82 
85  }
86 }
OSSIM_PLUGINS_DLL void ossimSharedLibraryInitialize(ossimSharedObjectInfo **info)
static ossimImageWriterFactoryRegistry * instance()
ossimSharedLibraryGetNumberOfClassNamesPtr getNumberOfClassNames
ossimSharedObjectInfo myKmlInfo
const char * getKmlClassName(int idx)
int getKmlNumberOfClassNames()
static ossimKmlSuperOverlayWriterFactory * instance()
static method to return instance (the only one) of this class.
std::vector< ossimString > theKmlObjList
virtual void getTypeNameList(std::vector< ossimString > &typeList) const
Adds "ossimKakaduWriter" to list.
ossimSharedLibraryGetDescriptionPtr getDescription
#define OSSIM_PLUGINS_DLL
ossimSharedLibraryGetClassNamesPtr getClassName
OSSIM_PLUGINS_DLL void ossimSharedLibraryFinalize()
ossimString theKmlDescription
const char * c_str() const
Returns a pointer to a null-terminated array of characters representing the string&#39;s contents...
Definition: ossimString.h:396
const char * getKmlDescription()