suggestions for OGC services

Hello,
I just update GeoserverTerrainProvider plugin in order to implement getTileDataAvailable function that will be required for Cesium 1.4. During this update I refactor my plugin to separate the specifics code of terrain provider from a generic code to parse WMS, TMS and WMTS capabilities xml. see between line 2 and line 778 (https://github.com/kaktus40/Cesium-GeoserverTerrainProvider/blob/master/GeoserverTerrainProvider.js#L778). We could call these generic code the OGCHelper.
My suggestion for Cesium dev is to rewrite imageryProvider using WMS and TMS protocol in order to use OGCHelper.
As I use geoserver, I can't use TileMapServiceImageryProvider because the server must provide a tilemapresource.xml (see the line https://github.com/AnalyticalGraphicsInc/cesium/blob/master/Source/Scene/TileMapServiceImageryProvider.js#L260). The TMS protocol doesn't specify it.

With OGCHelper, and some adaptation of TileMapServiceImageryProvider, I could use TMS from geoserver and also WMTS. OGCHelper could also be used to make a terrain provider (like my plugin) not limited to geoserver but to any geographic Information System compliant to OGC proctols.

I also think that it would be easier to maintain.
I'm waiting your opinion and comment.

This is not an area I am very familiar with, but this sounds reasonable to me. Perhaps Kevin will have more ideas here. We started something like this a long while back:

Comparing main...wms · CesiumGS/cesium · GitHub

Patrick

Ok I'm waiting Kevin's ideas.