com.coremedia.iso.boxes.FileTypeBox Java Examples

The following examples show how to use com.coremedia.iso.boxes.FileTypeBox. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: MP4Builder.java    From TelePlus-Android with GNU General Public License v2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie, boolean split) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;
    splitMdat = split;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #2
Source File: MP4Builder.java    From VideoCompressor with Apache License 2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #3
Source File: MP4Builder.java    From Telegram with GNU General Public License v2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie, boolean split) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    wroteSinceLastMdat += dataOffset;
    splitMdat = split;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #4
Source File: MP4Builder.java    From TelePlus-Android with GNU General Public License v2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie, boolean split) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;
    splitMdat = split;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #5
Source File: MP4Builder.java    From react-native-video-helper with MIT License 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #6
Source File: MP4Builder.java    From Telegram-FOSS with GNU General Public License v2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie, boolean split) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    wroteSinceLastMdat += dataOffset;
    splitMdat = split;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #7
Source File: MP4Builder.java    From VideoCompressor with Apache License 2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #8
Source File: MP4Builder.java    From deltachat-android with GNU General Public License v3.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #9
Source File: MP4Builder.java    From talk-android with MIT License 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #10
Source File: MP4Builder.java    From SiliCompressor with Apache License 2.0 6 votes vote down vote up
public MP4Builder createMovie(Mp4Movie mp4Movie) throws Exception {
    currentMp4Movie = mp4Movie;

    fos = new FileOutputStream(mp4Movie.getCacheFile());
    fc = fos.getChannel();

    FileTypeBox fileTypeBox = createFileTypeBox();
    fileTypeBox.getBox(fc);
    dataOffset += fileTypeBox.getSize();
    writedSinceLastMdat += dataOffset;

    mdat = new InterleaveChunkMdat();

    sizeBuffer = ByteBuffer.allocateDirect(4);

    return this;
}
 
Example #11
Source File: MP4Builder.java    From Telegram with GNU General Public License v2.0 5 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("iso2");
    minorBrands.add("avc1");
    minorBrands.add("mp41");
    return new FileTypeBox("isom", 512, minorBrands);
}
 
Example #12
Source File: MP4Builder.java    From Telegram-FOSS with GNU General Public License v2.0 5 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("iso2");
    minorBrands.add("avc1");
    minorBrands.add("mp41");
    return new FileTypeBox("isom", 512, minorBrands);
}
 
Example #13
Source File: MP4Builder.java    From TelePlus-Android with GNU General Public License v2.0 5 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("iso2");
    minorBrands.add("avc1");
    minorBrands.add("mp41");
    return new FileTypeBox("isom", 512, minorBrands);
}
 
Example #14
Source File: MP4Builder.java    From TelePlus-Android with GNU General Public License v2.0 5 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("iso2");
    minorBrands.add("avc1");
    minorBrands.add("mp41");
    return new FileTypeBox("isom", 512, minorBrands);
}
 
Example #15
Source File: MP4Builder.java    From talk-android with MIT License 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}
 
Example #16
Source File: MP4Builder.java    From SiliCompressor with Apache License 2.0 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}
 
Example #17
Source File: MP4Builder.java    From VideoCompressor with Apache License 2.0 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}
 
Example #18
Source File: MP4Builder.java    From deltachat-android with GNU General Public License v3.0 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}
 
Example #19
Source File: MP4Builder.java    From react-native-video-helper with MIT License 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}
 
Example #20
Source File: MP4Builder.java    From VideoCompressor with Apache License 2.0 4 votes vote down vote up
protected FileTypeBox createFileTypeBox() {
    LinkedList<String> minorBrands = new LinkedList<>();
    minorBrands.add("isom");
    minorBrands.add("3gp4");
    return new FileTypeBox("isom", 0, minorBrands);
}