protected long getContentSize() { long contentSize = 4; if (getVersion() == 1) { contentSize += 28; } else { contentSize += 16; } contentSize += 80; return contentSize; }
protected long getContentSize() { long contentSize = 4; if (getVersion() == 1) { contentSize += 28; } else { contentSize += 16; } contentSize += 80; return contentSize; }
protected long getContentSize() { long contentSize = 4; if (getVersion() == 1) { contentSize += 28; } else { contentSize += 16; } contentSize += 80; return contentSize; }
@Override public void _parseDetails(ByteBuffer content) { parseVersionAndFlags(content); if (getVersion() == 1) { creationTime = DateHelper.convert(IsoTypeReader.readUInt64(content)); modificationTime = DateHelper.convert(IsoTypeReader.readUInt64(content));
@Override protected void getContent(ByteBuffer byteBuffer) { writeVersionAndFlags(byteBuffer); if (getVersion() == 1) { IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); byteBuffer.putLong(duration); } else { IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); byteBuffer.putInt((int) duration); } IsoTypeWriter.writeFixedPoint1616(byteBuffer, rate); IsoTypeWriter.writeFixedPoint88(byteBuffer, volume); IsoTypeWriter.writeUInt16(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); matrix.getContent(byteBuffer); byteBuffer.putInt(previewTime); byteBuffer.putInt(previewDuration); byteBuffer.putInt(posterTime); byteBuffer.putInt(selectionTime); byteBuffer.putInt(selectionDuration); byteBuffer.putInt(currentTime); IsoTypeWriter.writeUInt32(byteBuffer, nextTrackId); }
@Override public void _parseDetails(ByteBuffer content) { parseVersionAndFlags(content); if (getVersion() == 1) { creationTime = DateHelper.convert(IsoTypeReader.readUInt64(content)); modificationTime = DateHelper.convert(IsoTypeReader.readUInt64(content)); timescale = IsoTypeReader.readUInt32(content); duration = IsoTypeReader.readUInt64(content); } else { creationTime = DateHelper.convert(IsoTypeReader.readUInt32(content)); modificationTime = DateHelper.convert(IsoTypeReader.readUInt32(content)); timescale = IsoTypeReader.readUInt32(content); duration = IsoTypeReader.readUInt32(content); } rate = IsoTypeReader.readFixedPoint1616(content); volume = IsoTypeReader.readFixedPoint88(content); IsoTypeReader.readUInt16(content); IsoTypeReader.readUInt32(content); IsoTypeReader.readUInt32(content); matrix = Matrix.fromByteBuffer(content); previewTime = content.getInt(); previewDuration = content.getInt(); posterTime = content.getInt(); selectionTime = content.getInt(); selectionDuration = content.getInt(); currentTime = content.getInt(); nextTrackId = IsoTypeReader.readUInt32(content); }
@Override protected void getContent(ByteBuffer byteBuffer) { writeVersionAndFlags(byteBuffer); if (getVersion() == 1) { IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); IsoTypeWriter.writeUInt64(byteBuffer, duration); } else { IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); IsoTypeWriter.writeUInt32(byteBuffer, duration); } IsoTypeWriter.writeFixedPoint1616(byteBuffer, rate); IsoTypeWriter.writeFixedPont88(byteBuffer, volume); IsoTypeWriter.writeUInt16(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); matrix.getContent(byteBuffer); byteBuffer.putInt(previewTime); byteBuffer.putInt(previewDuration); byteBuffer.putInt(posterTime); byteBuffer.putInt(selectionTime); byteBuffer.putInt(selectionDuration); byteBuffer.putInt(currentTime); IsoTypeWriter.writeUInt32(byteBuffer, nextTrackId); }
@Override public void _parseDetails(ByteBuffer content) { parseVersionAndFlags(content); if (getVersion() == 1) { creationTime = DateHelper.convert(IsoTypeReader.readUInt64(content)); modificationTime = DateHelper.convert(IsoTypeReader.readUInt64(content)); timescale = IsoTypeReader.readUInt32(content); duration = IsoTypeReader.readUInt64(content); } else { creationTime = DateHelper.convert(IsoTypeReader.readUInt32(content)); modificationTime = DateHelper.convert(IsoTypeReader.readUInt32(content)); timescale = IsoTypeReader.readUInt32(content); duration = IsoTypeReader.readUInt32(content); } rate = IsoTypeReader.readFixedPoint1616(content); volume = IsoTypeReader.readFixedPoint88(content); IsoTypeReader.readUInt16(content); IsoTypeReader.readUInt32(content); IsoTypeReader.readUInt32(content); matrix = Matrix.fromByteBuffer(content); previewTime = content.getInt(); previewDuration = content.getInt(); posterTime = content.getInt(); selectionTime = content.getInt(); selectionDuration = content.getInt(); currentTime = content.getInt(); nextTrackId = IsoTypeReader.readUInt32(content); }
@Override protected void getContent(ByteBuffer byteBuffer) { writeVersionAndFlags(byteBuffer); if (getVersion() == 1) { IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt64(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); IsoTypeWriter.writeUInt64(byteBuffer, duration); } else { IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(creationTime)); IsoTypeWriter.writeUInt32(byteBuffer, DateHelper.convert(modificationTime)); IsoTypeWriter.writeUInt32(byteBuffer, timescale); IsoTypeWriter.writeUInt32(byteBuffer, duration); } IsoTypeWriter.writeFixedPoint1616(byteBuffer, rate); IsoTypeWriter.writeFixedPont88(byteBuffer, volume); IsoTypeWriter.writeUInt16(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); IsoTypeWriter.writeUInt32(byteBuffer, 0); matrix.getContent(byteBuffer); byteBuffer.putInt(previewTime); byteBuffer.putInt(previewDuration); byteBuffer.putInt(posterTime); byteBuffer.putInt(selectionTime); byteBuffer.putInt(selectionDuration); byteBuffer.putInt(currentTime); IsoTypeWriter.writeUInt32(byteBuffer, nextTrackId); }