public boolean hasDataRef() { DataInfoBox dinf = getMdia().getMinf().getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; boolean result = false; for (Box box : dref.boxes) { result |= (((FullBox) box).getFlags() & 0x1) != 0x1; } return result; }
public boolean hasDataRef() { DataInfoBox dinf = getMdia().getMinf().getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; boolean result = false; for (Box box : dref.boxes) { result |= (((FullBox) box).getFlags() & 0x1) != 0x1; } return result; }
public boolean hasDataRef() { DataInfoBox dinf = getMdia().getMinf().getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; boolean result = false; for (Box box : dref.boxes) { result |= (((FullBox) box).getFlags() & 0x1) != 0x1; } return result; }
public boolean isPureRef() { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; for (Box box : dref.boxes) { if ((((FullBox) box).getFlags() & 0x1) != 0) return false; } return true; }
public boolean isPureRef() { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; for (Box box : dref.boxes) { if ((((FullBox) box).getFlags() & 0x1) != 0) return false; } return true; }
public boolean isPureRef() { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { return false; } DataRefBox dref = dinf.getDref(); if (dref == null) return false; for (Box box : dref.boxes) { if ((((FullBox) box).getFlags() & 0x1) != 0) return false; } return true; }
public void setDataRef(String url) { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { dinf = new DataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); UrlBox urlBox = new UrlBox(url); if (dref == null) { dref = new DataRefBox(); dinf.add(dref); dref.add(urlBox); } else { ListIterator<Box> lit = dref.boxes.listIterator(); while (lit.hasNext()) { FullBox box = (FullBox) lit.next(); if ((box.getFlags() & 0x1) != 0) lit.set(urlBox); } } }
public void setDataRef(String url) { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { dinf = new DataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); UrlBox urlBox = new UrlBox(url); if (dref == null) { dref = new DataRefBox(); dinf.add(dref); dref.add(urlBox); } else { ListIterator<Box> lit = dref.boxes.listIterator(); while (lit.hasNext()) { FullBox box = (FullBox) lit.next(); if ((box.getFlags() & 0x1) != 0) lit.set(urlBox); } } }
public void setDataRef(String url) { MediaInfoBox minf = getMdia().getMinf(); DataInfoBox dinf = minf.getDinf(); if (dinf == null) { dinf = DataInfoBox.createDataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); UrlBox urlBox = UrlBox.createUrlBox(url); if (dref == null) { dref = DataRefBox.createDataRefBox(); dinf.add(dref); dref.add(urlBox); } else { ListIterator<Box> lit = dref.boxes.listIterator(); while (lit.hasNext()) { FullBox box = (FullBox) lit.next(); if ((box.getFlags() & 0x1) != 0) lit.set(urlBox); } } }
private void cleanDrefs(TrakBox trak) { MediaInfoBox minf = trak.getMdia().getMinf(); DataInfoBox dinf = trak.getMdia().getMinf().getDinf(); if (dinf == null) { dinf = new DataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); if (dref == null) { dref = new DataRefBox(); dinf.add(dref); } dref.getBoxes().clear(); dref.add(AliasBox.createSelfRef()); for (SampleEntry entry : NodeBox.findAll(trak, SampleEntry.class, "mdia", "minf", "stbl", "stsd", null)) { entry.setDrefInd((short) 1); } }
private void cleanDrefs(TrakBox trak) { MediaInfoBox minf = trak.getMdia().getMinf(); DataInfoBox dinf = trak.getMdia().getMinf().getDinf(); if (dinf == null) { dinf = new DataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); if (dref == null) { dref = new DataRefBox(); dinf.add(dref); } dref.getBoxes().clear(); dref.add(AliasBox.createSelfRef()); for (SampleEntry entry : NodeBox.findAll(trak, SampleEntry.class, "mdia", "minf", "stbl", "stsd", null)) { entry.setDrefInd((short) 1); } }
private void cleanDrefs(TrakBox trak) { MediaInfoBox minf = trak.getMdia().getMinf(); DataInfoBox dinf = trak.getMdia().getMinf().getDinf(); if (dinf == null) { dinf = DataInfoBox.createDataInfoBox(); minf.add(dinf); } DataRefBox dref = dinf.getDref(); if (dref == null) { dref = DataRefBox.createDataRefBox(); dinf.add(dref); } dref.getBoxes().clear(); dref.add(AliasBox.createSelfRef()); SampleEntry[] sampleEntries = trak.getSampleEntries(); for (int i = 0; i < sampleEntries.length; i++) { SampleEntry entry = sampleEntries[i]; entry.setDrefInd((short) 1); } }