mirror of
				https://github.com/ciphervance/supercell-wx.git
				synced 2025-10-31 20:30:05 +00:00 
			
		
		
		
	Update VCP display
This commit is contained in:
		
							parent
							
								
									8d55413d03
								
							
						
					
					
						commit
						cae04fad37
					
				
					 11 changed files with 113 additions and 5 deletions
				
			
		
							
								
								
									
										13
									
								
								wxdata/include/scwx/common/vcp.hpp
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										13
									
								
								wxdata/include/scwx/common/vcp.hpp
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,13 @@ | |||
| #pragma once | ||||
| 
 | ||||
| #include <string> | ||||
| 
 | ||||
| namespace scwx | ||||
| { | ||||
| namespace common | ||||
| { | ||||
| 
 | ||||
| std::string GetVcpDescription(uint16_t vcp); | ||||
| 
 | ||||
| } // namespace common
 | ||||
| } // namespace scwx
 | ||||
|  | @ -155,8 +155,9 @@ public: | |||
|    VolumeDataBlock(VolumeDataBlock&&) noexcept; | ||||
|    VolumeDataBlock& operator=(VolumeDataBlock&&) noexcept; | ||||
| 
 | ||||
|    float latitude() const; | ||||
|    float longitude() const; | ||||
|    float    latitude() const; | ||||
|    float    longitude() const; | ||||
|    uint16_t volume_coverage_pattern_number() const; | ||||
| 
 | ||||
|    static std::shared_ptr<VolumeDataBlock> | ||||
|    Create(const std::string& dataBlockType, | ||||
|  |  | |||
							
								
								
									
										32
									
								
								wxdata/source/scwx/common/vcp.cpp
									
										
									
									
									
										Normal file
									
								
							
							
						
						
									
										32
									
								
								wxdata/source/scwx/common/vcp.cpp
									
										
									
									
									
										Normal file
									
								
							|  | @ -0,0 +1,32 @@ | |||
| #include <scwx/common/vcp.hpp> | ||||
| 
 | ||||
| #include <unordered_map> | ||||
| 
 | ||||
| namespace scwx | ||||
| { | ||||
| namespace common | ||||
| { | ||||
| 
 | ||||
| static const std::string CLEAR_AIR_MODE     = "Clear Air Mode"; | ||||
| static const std::string PRECIPITATION_MODE = "Precipitation Mode"; | ||||
| 
 | ||||
| std::string GetVcpDescription(uint16_t vcp) | ||||
| { | ||||
|    switch (vcp) | ||||
|    { | ||||
|    case 31: | ||||
|    case 32: | ||||
|    case 35: return CLEAR_AIR_MODE; | ||||
| 
 | ||||
|    case 12: | ||||
|    case 112: | ||||
|    case 121: | ||||
|    case 212: | ||||
|    case 215: return PRECIPITATION_MODE; | ||||
| 
 | ||||
|    default: return "?"; | ||||
|    } | ||||
| } | ||||
| 
 | ||||
| } // namespace common
 | ||||
| } // namespace scwx
 | ||||
|  | @ -285,6 +285,11 @@ float VolumeDataBlock::longitude() const | |||
|    return p->longitude_; | ||||
| } | ||||
| 
 | ||||
| uint16_t VolumeDataBlock::volume_coverage_pattern_number() const | ||||
| { | ||||
|    return p->volumeCoveragePatternNumber_; | ||||
| } | ||||
| 
 | ||||
| std::shared_ptr<VolumeDataBlock> | ||||
| VolumeDataBlock::Create(const std::string& dataBlockType, | ||||
|                         const std::string& dataName, | ||||
|  |  | |||
|  | @ -6,9 +6,11 @@ set(HDR_COMMON include/scwx/common/characters.hpp | |||
|                include/scwx/common/color_table.hpp | ||||
|                include/scwx/common/constants.hpp | ||||
|                include/scwx/common/products.hpp | ||||
|                include/scwx/common/types.hpp) | ||||
|                include/scwx/common/types.hpp | ||||
|                include/scwx/common/vcp.hpp) | ||||
| set(SRC_COMMON source/scwx/common/color_table.cpp | ||||
|                source/scwx/common/products.cpp) | ||||
|                source/scwx/common/products.cpp | ||||
|                source/scwx/common/vcp.cpp) | ||||
| set(HDR_UTIL include/scwx/util/iterator.hpp | ||||
|              include/scwx/util/rangebuf.hpp | ||||
|              include/scwx/util/streams.hpp | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue
	
	 Dan Paulat
						Dan Paulat