Skip to content

Commit

Permalink
Revert "[FragmentedSampleReader] Create senc when saio/saiz/senc are …
Browse files Browse the repository at this point in the history
…missing"

This reverts commit c4d224c.
  • Loading branch information
CastagnaIT committed Oct 29, 2024
1 parent b0130e9 commit 9833d0c
Showing 1 changed file with 0 additions and 10 deletions.
10 changes: 0 additions & 10 deletions src/samplereader/FragmentedSampleReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -22,8 +22,6 @@
#include "utils/Utils.h"
#include "utils/log.h"

#include <bento4/Ap4SencAtom.h>

using namespace UTILS;

namespace
Expand Down Expand Up @@ -388,14 +386,6 @@ AP4_Result CFragmentedSampleReader::ProcessMoof(AP4_ContainerAtom* moof,
if (!m_protectedDesc || !traf)
return AP4_ERROR_INVALID_FORMAT;

// If the boxes saiz, saio, senc are missing, the stream does not conform to the specs and
// may not be decrypted, so try create an empty senc where all samples will use the same default IV
if (!traf->GetChild(AP4_ATOM_TYPE_SAIO) && !traf->GetChild(AP4_ATOM_TYPE_SAIZ) &&
!traf->GetChild(AP4_ATOM_TYPE_SENC))
{
traf->AddChild(new AP4_SencAtom());
}

bool reset_iv(false);
if (AP4_FAILED(result = AP4_CencSampleInfoTable::Create(m_protectedDesc, traf, algorithm_id,
reset_iv, *m_FragmentStream,
Expand Down

0 comments on commit 9833d0c

Please sign in to comment.