Line data Source code
1 : /* 2 : * keadriver.cpp 3 : * 4 : * Created by Pete Bunting on 01/08/2012. 5 : * Copyright 2012 LibKEA. All rights reserved. 6 : * 7 : * This file is part of LibKEA. 8 : * 9 : * SPDX-License-Identifier: MIT 10 : * 11 : */ 12 : 13 : #include "gdal_frmts.h" 14 : #include "keadataset.h" 15 : #include "keadrivercore.h" 16 : 17 : // method to register this driver 18 9 : void GDALRegister_KEA() 19 : { 20 9 : if (!GDAL_CHECK_VERSION("KEA")) 21 0 : return; 22 : 23 9 : if (GDALGetDriverByName(DRIVER_NAME) != nullptr) 24 0 : return; 25 : 26 9 : GDALDriver *poDriver = new GDALDriver(); 27 9 : KEADriverSetCommonMetadata(poDriver); 28 : 29 9 : poDriver->pfnOpen = KEADataset::Open; 30 9 : poDriver->pfnCreate = KEADataset::Create; 31 9 : poDriver->pfnCreateCopy = KEADataset::CreateCopy; 32 9 : poDriver->pfnUnloadDriver = KEADatasetDriverUnload; 33 : 34 9 : GetGDALDriverManager()->RegisterDriver(poDriver); 35 : }