Add wind direction drawing

This commit is contained in:
Guntis Smaukstelis
2025-02-04 22:47:01 +02:00
parent e03ae14cfa
commit 9c8902e746
4 changed files with 22 additions and 6 deletions
+1
View File
@@ -15,6 +15,7 @@ case class GribGrid(
template: Short,
cols: Int,
rows: Int,
lambert: List[Int],
)
case class MeteoParam(
+4 -1
View File
@@ -98,7 +98,10 @@ object GribParser {
template = ByteBuffer.wrap(bytes.slice(12, 14)).getShort
cols = ByteBuffer.wrap(bytes.slice(30, 34)).getInt
rows = ByteBuffer.wrap(bytes.slice(34, 38)).getInt
} yield (GribGrid(template, cols, rows), length)
lambert1 = ByteBuffer.wrap(bytes.slice(34, 38)).getInt
lambert2 = ByteBuffer.wrap(bytes.slice(38, 42)).getInt
lambert = List(lambert1, lambert2)
} yield (GribGrid(template, cols, rows, lambert), length)
}
private def parse4(path: Path, ptr: Long, discipline: Int, referenceTime: ZonedDateTime): IO[(MeteoParam, GribTime, Int)] = {