public void decode(BitStream inStream) { readElementInstanceTag(inStream); profile = new Profile(inStream.readBits(2)); sampleFrequency = SampleFrequency.forInt(inStream.readBits(4)); frontChannelElementsCount = inStream.readBits(4); sideChannelElementsCount = inStream.readBits(4); backChannelElementsCount = inStream.readBits(4); lfeChannelElementsCount = inStream.readBits(2); assocDataElementsCount = inStream.readBits(3); validCCElementsCount = inStream.readBits(4); if (monoMixdown = inStream.readBool()) { Logger.LogServe("mono mixdown present, but not yet supported"); monoMixdownElementNumber = inStream.readBits(4); } if (stereoMixdown = inStream.readBool()) { Logger.LogServe("stereo mixdown present, but not yet supported"); stereoMixdownElementNumber = inStream.readBits(4); } if (matrixMixdownIDXPresent = inStream.readBool()) { Logger.LogServe("matrix mixdown present, but not yet supported"); matrixMixdownIDX = inStream.readBits(2); pseudoSurround = inStream.readBool(); } readTaggedElementArray(frontElements, inStream, frontChannelElementsCount); readTaggedElementArray(sideElements, inStream, sideChannelElementsCount); readTaggedElementArray(backElements, inStream, backChannelElementsCount); for (int i = 0; i < lfeChannelElementsCount; i++) { lfeElementTags[i] = inStream.readBits(4); } for (int i = 0; i < assocDataElementsCount; i++) { assocDataElementTags[i] = inStream.readBits(4); } for (int i = 0; i < validCCElementsCount; i++) { ccElements[i] = new CCE(inStream.readBool(), inStream.readBits(4)); } inStream.byteAlign(); int commentFieldBytes = inStream.readBits(8); commentFieldData = new byte[commentFieldBytes]; for (int i = 0; i < commentFieldBytes; i++) { commentFieldData[i] = (byte)inStream.readBits(8); } }
public void process(ICStream ics, float[] spec, SampleFrequency sf, bool decode) { //TODO... }