Giter VIP home page Giter VIP logo

regxmllib's Issues

Define FixedArray type kind in Types register

Array with non-zero type size should be have dedicated type kind of FixedArray since they are encoded without element count and size in MXF. This also maps directly to FixedArray definitions in RegXML.

Add test vectors

Add 2 sample XML files + RegXML generated from the two sample files so that output of future revisions can be tested against the previous output.

Create 'test' target.

dupIndexEntryArray1

I used smpte_registers-bbc_rd_db_exports-201412092156 and generated www-smpte-ra-org-reg-2003-2012.xml

In this I see:

<TypeDefinitionVariableArray>
<Identification>urn:smpte:ul:060e2b34.01040101.04020700.00000000</Identification>
<Symbol>dupIndexEntryArray1</Symbol>
<Name>IndexEntryArray</Name>
<ElementType>urn:smpte:ul:060e2b34.01040101.04100600.00000000</ElementType>
</TypeDefinitionVariableArray>

Why has the symbol changed from what is in Groups.xml (i.e. "IndexEntryArray")?

XSD bugs

  • tns:GroupsRegister/tns:Entries/tns:Entry/tns:Contents/tns:Record/tns:UL should be "required"
  • change tns:ElementsRegister/tns:Entries/tns:Entry/tns:TypeUL to tns:ElementsRegister/tns:Entries/tns:Entry/tns:Type

Missing Target Set UL -- Warnings

When processing smpte_registers-bbc_rd_db_exports-201412092156 I got quite a few warnings of the form:

Jan 08, 2015 3:26:44 PM com.sandflow.smpte.regxml.dict.importer.XMLRegistryImporter fromRegister
WARNING: Missing Target Set UL at Facet null for Type urn:smpte:ul:060e2b34.01040101.05010c00.00000000

What does this mean? Are these warnings genuine? Is there a problems with the Registers entries?

Make everything in Group/Record optional but UL

  • change elements name that start with “is” to start with “Is” e.g. “IsDeprecated”
  • make “IsConcrete” optional because it only applies to Leaves (as per ST 395)
  • make everything in the “Contents” optional except for “UL”

Metadictionary class defines the wrong NS

Metadictionary should use

http://www.smpte-ra.org/schemas/2001-1b/2013/metadict

for the Extension element defined in ST 2001-1 instead of

http://sandflow.com/ns/SMPTEST2001-1/baseline

Boolean "true" may be encoded as any non-zero uint8

Boolean is defined as an "enumeration" {"1 -> true", "0 -> false"} in the register. ST 377 allows any non-zero value to mean "true".

applyRule5_2 in FragmentBuilder should accept any non-zero value to mean "true" for the special type "boolean".

README: Instructions etc

It would be handy to have some "beginner's instructions" in the README to address the following:

  • It seems that you need to have git installed and in your PATH environment variable before opening NetBeans
  • I think (perhaps) you have to have JDK8 installed (specifically this version?)
  • Recommended basic workflow for building / using the tool:
    1. Use NetBeans to build a jar file (no dependencies at all, except as above) by doing ...
    2. Execute the XMLRegistersToDict tool then the GenerateDictionaryXMLSchema tool from the command line (using the jar). Registers XML files are used as the inputs to XMLRegistersToDict.
    3. Execute the RegXMLDump tool to process MXF files

ULValueAdapter.java -- warning on compilation

Is this a concern?

regxmllib\regxmllib\src\main\java\com\sandflow\smpte\klv\adapters\ULValueAdapter.java:40: warning: [unchecked] fromValue(byte[]) in ULValueAdapter overrides <W>fromValue(byte[]) in TripletValueAdapter
    public static UL fromValue(byte[] value) {
  return type requires unchecked conversion from UL to W
  where W is a type-variable:
    W extends Object declared in method <W>fromValue(byte[])
Note: Some input files use or override a deprecated API.
Note: Recompile with -Xlint:deprecation for details.
1 warning

NetBeans info:

Product Version: NetBeans IDE 8.0.2 (Build 201411181905)
Updates: Updates available to version NetBeans 8.0.2 Patch 2
Java: 1.8.0_25; Java HotSpot(TM) 64-Bit Server VM 25.25-b02
Runtime: Java(TM) SE Runtime Environment 1.8.0_25-b18
System: Windows 7 version 6.1 running on amd64; Cp1252; en_GB (nb)

ProductReleaseType model error not noticed by regxmllib MXF reader

In the Registers, ProductReleaseType is incorrectly modelled as an Enumeration of UInt8 rather than UInt16. ProductReleaseType is used by one of the Record members of ProductVersionType. ProductVersionType is used by Identification.ToolkitVersion and Identification.ApplicationVersion (among other Elements -- although most of those are (currently) erroneous uses of this Type...).

I ran regxmllib dump tool build 34efd99 on an MXF file with the final two bytes of Identification.ToolkitVersion set as 0002h. The result was:

<r2:BuildType>VersionUnknown</r2:BuildType>

If ProductReleaseType was correctly modelled then the answer would be:

<r2:BuildType>VersionDebug</r2:BuildType>

(Note: a further complication is that where the Registers currently say "BuildType" they should actually say "Release"...)

It seems that regxmllib finds 10 bytes for fields such as Identification.ToolkitVersion but the meta-dictionary tells it only 9 are needed and so the final byte is silently discarded. My suggestion would be that an error is raised as this is a serious fault (in this case with the Registers, but it could be a problem with the MXF file). In this case, the result of the data length mis-match is that incorrect data is output (i.e. VersionUnknown instead of VersionDebug).

KLV Fill between the Header Partition Pack and the Primer Pack causes an exception

I assume (from looking at various MXF files I've tried) that's the cause of this output:

No Primer Pack found
Exception in thread "main" java.lang.NullPointerException
        at com.sandflow.smpte.klv.LocalSet.fromTriplet(LocalSet.java:113)
        at com.sandflow.smpte.tools.RegXMLDump.main(RegXMLDump.java:176)

This situation is permitted by ST 377-1:2011 Section 9.1. Note that in this MXF file it is a "legacy" KLV Fill key that is used (for KLV Fill byte 8 of the Key needs to be ignored).

I think that KLV Fill bytes not being correctly counted is probably also causing the following warning on a different MXF file:

WARNING: Index Table Segment encountered before Header Byte Count bytes read.

ST 377-1:2011 Section 9.1 notes that the KLV Fill at the end of the Header Metadata is included in the value of HeaderByteCount

Adjust reg.xsd namespace

The namespace should be something like http://www.smpte-ra.org/schemas/2001-1c/2013 (we may also want a suffix on this (but "metadict" would not be appropriate)). Not sure if it should be 2013 or not...

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.