Skip to content

MULTILEADER text background colour: R2000 DWG holds ACI 9, the DXF export holds true colour 0xC2C8C8C8 (3 records) #381

Open

Description

@DrunkOnJava

Spec: §2.11 CmColor (before R2004 a colour is the bare BS index), §20.4.86 MLeaderAnnotContext (CMC 91, the text background colour), §20.4.48 MULTILEADER.

The DXF value oracle (examples/dxf_oracle, #99) scores MULTILEADER's text background colour (text.background_color, group 91 inside CONTEXT_DATA) against AutoCAD's export. On R2004 to R2018 all 15 records per release equal. On R2000 three records differ:

file handle decoded (DWG) export (DXF group 91)
sample_AC1015.dwg 0xB22 index 9, as the word 0xC3000009 (-1023410167) -1027028792 = 0xC2C8C8C8 (true colour 200,200,200)
sample_AC1015.dwg 0xB23 same same
sample_AC1015.dwg 0xB24 same same

The R2004 to R2018 saves hold the CMC in full and decode to 0xC2C8C8C8 for the same three multileaders. The R2000 record closes exactly on its data-stream boundary with the CMC read as a bare BS, so the RGB is not in the R2000 file: the save wrote the nearest colour index (9) and AutoCAD's DXF export of the drawing, as in the other releases' exports, writes the true colour. The decoder is right; the two files hold different amounts of information. LAYER has the same kind of gap (#245: 420 with the RGB, 62 the export's nearest index).

The oracle leaves the three values scored different rather than mapping the index onto the word.

Decision

  • Either keep them different as the record of the R2000 colour model, or score a pre-R2004 colour against the nearest ACI of the exported RGB (needs the ACI table in the oracle), or list the export's true colour as not decoded on R2000 as for LAYER.

Reproduce

cargo run --release --features dxf-reader --example dxf_oracle -- <corpus-dir> --details

and read the MULTILEADER ... text.background_color lines under "Disagreements".

Metadata

Metadata

Assignees

No one assigned

    Labels

    area:entitiesEntity prescriptions in spec §20.4area:oracleComparing decoded values with AutoCAD's own DXF exportpriority:P3Follow-uprelease:R2000Affects R2000 filestype:specImplements or verifies a numbered section of ODA spec v5.4.1

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions