public Mp4StcoBox(Mp4BoxHeader header,ByteBuffer originalDataBuffer,int adjustment){
  this.header=header;
  this.dataBuffer=originalDataBuffer.slice();
  dataBuffer.position(dataBuffer.position() + VERSION_FLAG_LENGTH + OTHER_FLAG_LENGTH);
  this.noOfOffSets=Utils.getIntBE(dataBuffer,dataBuffer.position(),(dataBuffer.position() + NO_OF_OFFSETS_LENGTH - 1));
  dataBuffer.position(dataBuffer.position() + NO_OF_OFFSETS_LENGTH);
  for (int i=0; i < noOfOffSets; i++) {
    int offset=Utils.getIntBE(dataBuffer,dataBuffer.position(),(dataBuffer.position() + NO_OF_OFFSETS_LENGTH - 1));
    offset=offset + adjustment;
    dataBuffer.put(Utils.getSizeBEInt32(offset));
  }
}

public Mp4StcoBox ( Mp4BoxHeader header , ByteBuffer originalDataBuffer , int adjustment ) { this . header = header ; this . dataBuffer = originalDataBuffer . slice ( ) ; dataBuffer . position ( dataBuffer . position ( ) + VERSION_FLAG_LENGTH + OTHER_FLAG_LENGTH ) ; this . noOfOffSets = Utils . getIntBE ( dataBuffer , dataBuffer . position ( ) , ( dataBuffer . position ( ) + NO_OF_OFFSETS_LENGTH - 1 ) ) ; dataBuffer . position ( dataBuffer . position ( ) + NO_OF_OFFSETS_LENGTH ) ; for ( int i = 0 ; i < noOfOffSets ; i ++ ) { int offset = Utils . getIntBE ( dataBuffer , dataBuffer . position ( ) , ( dataBuffer . position ( ) + NO_OF_OFFSETS_LENGTH - 1 ) ) ; offset = offset + adjustment ; dataBuffer . put ( Utils . getSizeBEInt32 ( offset ) ) ; } }
construct box from data and adjust offets accordingly
