-- Module SignatureSignRecordFormatModule (X.695:05/2007)
-- See also ITU-T X.695 (05/2007)
-- See also the index of all ASN.1 assignments needed in this document

SignatureSignRecordFormatModule {iso standard 19794 signature-sign(7)
  modules(0) record-format(0) version(0)}
DEFINITIONS
PER INSTRUCTIONS
-- This specifies that PER Encoding Instructions are to be applied
AUTOMATIC TAGS ::=
BEGIN

SignatureSignBlock ::= SEQUENCE {header  Header,
                                 body    Body
}

Header ::= SEQUENCE {
  formatId [NULL]
      -- This specifies that the IA5String is to
      -- be followed by a zero(NULL) octet in
      -- the encoding. 
                         IA5String("SDI"),
  standardVersion      [NULL] -- As above.
                         IA5String(SIZE (3))-- " 10" (space-one-zero) for this version --,
  channelInclusions    ChannelInclusions,
  channelDescriptions  ChannelDescriptions
}

ChannelInclusions ::= SEQUENCE {
  x-included   BOOLEAN,
  y-included   BOOLEAN,
  z-included   BOOLEAN,
  vX-included  BOOLEAN,
  vY-included  BOOLEAN,
  aX-included  BOOLEAN,
  aY-included  BOOLEAN,
  t-included   BOOLEAN,
  dt-included  BOOLEAN,
  f-included   BOOLEAN,
  s-included   BOOLEAN,
  tX-included  BOOLEAN,
  tY-included  BOOLEAN,
  az-included  BOOLEAN,
  el-included  BOOLEAN,
  r-included   BOOLEAN
}(WITH COMPONENTS {
    x-included  (TRUE),
    y-included  (TRUE)
  })

ChannelDescriptions ::= [OPTIONALITY-IN Header.channel-inclusions] 
  
  -- This specifies that the optionality bit-map is
  -- taken from the channel inclusions.  The
  -- channel-inclusions structure is needed because
  -- the same bit-map controls the optionality
  -- in each SamplePoint SEQUENCE in the
  -- SamplePoints SEQUENCE OF.  It is also
  -- desirable to make the bit-map
  -- application-visible
  SEQUENCE {
  x   SignedChannelDescr OPTIONAL,
  y   SignedChannelDescr OPTIONAL,
  z   UnsignedChannelDescr OPTIONAL,
  vX  SignedChannelDescr OPTIONAL,
  vY  SignedChannelDescr OPTIONAL,
  aX  SignedChannelDescr OPTIONAL,
  aY  SignedChannelDescr OPTIONAL,
  t   UnsignedChannelDescr OPTIONAL,
  dt  UnsignedChannelDescr OPTIONAL,
  f   UnsignedChannelDescr OPTIONAL,
  s   UnsignedChannelDescr OPTIONAL,
  tX  SignedChannelDescr OPTIONAL,
  tY  SignedChannelDescr OPTIONAL,
  az  UnsignedChannelDescr OPTIONAL,
  el  UnsignedChannelDescr OPTIONAL,
  r   UnsignedChannelDescr OPTIONAL
}
(CONSTRAINED BY {
   ChannelInclusions-- Each element can be present if and only if permitted by
   -- the ChannelInclusions --})

SignedChannelDescr ::= SEQUENCE {
  reserved      INTEGER(0..8),
  scalingValue  ScalingValue OPTIONAL,
  min           SignedInt16 OPTIONAL,
  max           SignedInt16 OPTIONAL,
  mean          SignedInt16 OPTIONAL,
  std           UnsignedInt16 OPTIONAL
}

UnsignedChannelDescr ::= SEQUENCE {
  reserved      INTEGER(0..8),
  scalingValue  ScalingValue OPTIONAL,
  min           UnsignedInt16 OPTIONAL,
  max           UnsignedInt16 OPTIONAL,
  mean          UnsignedInt16 OPTIONAL,
  std           UnsignedInt16 OPTIONAL
}

ScalingValue ::= SEQUENCE {
  exponent  [ENCODE-DIRECTLY] INTEGER(-16..15),
  -- This ensures a two's complement
  -- encoding, not an encoding from
  -- the base of -16.
  fraction  INTEGER(0..2047)
}

Body ::= [SIZE 8] SEQUENCE {
  -- 8 bit optionality bit-map, with only one bit used.  Other
  -- bits will be set to zero by encoders, ignored by decoders.
  samplePoints [LENGTH 3] [COUNT-OCTETS] SEQUENCE 
      -- Prevents optimisation for short
      -- iterations, forcing 3 octets in
      -- all cases 
      SIZE (0..16777215) OF SamplePoint,
  extendedData [TERMINATED-BY-CARRIER] -- The end of this octet string can only
      -- be determined by running out of the
      -- input buffer provided by the carrier
      -- protocol.  It is a feature of this BDB
      -- format that it relies on the CBEFF
      -- carrier to delimit it
      OCTET STRING OPTIONAL
}

SamplePoint ::= [OPTIONALITY-IN Header.channelInclusions]
   -- As above
   SEQUENCE {
  x   SignedInt16 OPTIONAL,
  y   SignedInt16 OPTIONAL,
  z   UnsignedInt16 OPTIONAL,
  vX  SignedInt16 OPTIONAL,
  vY  SignedInt16 OPTIONAL,
  aX  SignedInt16 OPTIONAL,
  aY  SignedInt16 OPTIONAL,
  t   UnsignedInt16 OPTIONAL,
  dt  UnsignedInt16 OPTIONAL,
  f   UnsignedInt16 OPTIONAL,
  s   UnsignedInt8 OPTIONAL,
  tX  SignedInt16 OPTIONAL,
  tY  SignedInt16 OPTIONAL,
  az  UnsignedInt16 OPTIONAL,
  el  UnsignedInt16 OPTIONAL,
  r   UnsignedInt16 OPTIONAL
}
(CONSTRAINED BY {
   ChannelInclusions-- Each element can be present if and only if
   -- permitted by the channel inclusions --})

UnsignedInt16 ::= INTEGER(0..65535)

SignedInt16 ::= [ENCODE-DIRECTLY] INTEGER(-32768..32767)

-- As above 
UnsignedInt8 ::= INTEGER(0..255)

END
-- Generated by Asnp, the ASN.1 pretty-printer of France Telecom R&D