Last active
July 12, 2016 17:59
-
-
Save mousebird/29fdbae4c5244699eda256ef16e11bfe to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
func createLayer(baseView: MaplyBaseViewController) -> (MaplyQuadImageTilesLayer) { | |
let precipTileSource = MaplyMultiplexTileSource(sources: tileSources) | |
// Create a precipitation layer that animates | |
let precipLayer = MaplyQuadImageTilesLayer(tileSource: precipTileSource!) | |
precipLayer?.imageDepth = UInt32(tileSources.count) | |
precipLayer?.animationPeriod = 1.0 | |
precipLayer?.imageFormat = MaplyQuadImageFormat.ImageUByteRed | |
precipLayer?.numSimultaneousFetches = 4 | |
precipLayer?.handleEdges = false | |
precipLayer?.coverPoles = false | |
precipLayer?.shaderProgramName = WeatherShader.setupWeatherShader(baseView) | |
precipLayer?.fade = 0.5 | |
return precipLayer! | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment