fostfox / lua-cpp-s101-integration

5 stars 0 forks source link

Table instead of orientationValue:scaledDecimal #35

Open fostfox opened 5 years ago

fostfox commented 5 years ago

OUTLOG.txt

Feature : [1333] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 00000000085FEFE0;PointInstruction:RDOCAL03;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 3,21,8
---------------------------------------
Feature : [1334] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 0000000008600070;PointInstruction:RDOCAL02;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 7,21,8
---------------------------------------
Feature : [1335] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 0000000008601100;PointInstruction:RDOCAL03;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 2,21,8
---------------------------------------
Feature : [1336] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 0000000008601E70;PointInstruction:RDOCAL03;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 4,21,8
---------------------------------------
Feature : [1337] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 0000000008603EF0;PointInstruction:RDOCAL03;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 5,21,8
---------------------------------------
Feature : [1338] RDOCAL
 ViewingGroup:25060;DrawingPriority:6;DisplayPlane:UnderRADAR;Rotation:GeographicCRS,table: 0000000008604B20;PointInstruction:RDOCAL02;LocalOffset:3.51,3.51;FontSize:10;TextInstruction:Nr 6,21,8
---------------------------------------

MayBy cause of problem

featurePortrayal:AddInstructions('Rotation:GeographicCRS,' .. tostring(feature.orientationValue) .. '')

fostfox commented 5 years ago

https://github.com/ArnMips/lua-cpp-s101-integration/blob/d8c050c1597c34602f60eacf70b9879eeda2ed8e/build/debug/lua/S100Scripting.lua#L177-L205

fostfox commented 5 years ago

Maybe fix this

https://github.com/ArnMips/lua-cpp-s101-integration/blob/d8c050c1597c34602f60eacf70b9879eeda2ed8e/build/debug/lua/RadioCallingInPoint.lua#L13

To this

featurePortrayal:AddInstructions('Rotation:GeographicCRS,' .. tostring(feature.orientationValue[1]) .. '')

And all across the file RadioCallingInPoint.lua

fostfox commented 5 years ago

In accordance with S-101FC_1.0.0_20190409.xml

<S100FC:S100_FC_FeatureType isAbstract="false">
      <S100FC:name>Radio calling-in point</S100FC:name>
      ...
      <S100FC:code>RadioCallingInPoint</S100FC:code>
      ...
      <S100FC:alias>RDOCAL</S100FC:alias>
      ...
      <S100FC:attributeBinding sequential="false">
        <S100FC:multiplicity>
          <S100Base:lower>0</S100Base:lower>
          <S100Base:upper xsi:nil="false" infinite="false">2</S100Base:upper>
        </S100FC:multiplicity>
        <S100FC:attribute ref="orientationValue"/>
      </S100FC:attributeBinding>
      ...
    </S100FC:S100_FC_FeatureType>

Attribute orientationValue has 0..2 multiplisity