omParser.readEncapsulatedImageFrame(
            dataSet,
            dataSet.elements.x7fe00010,
            frameIndex,
            basicOffsetTable
          );
        }

        return dicomParser.readEncapsulatedPixelDataFromFragments(
          dataSet,
          dataSet.elements.x7fe00010,
          frameIndex
        );
      }

      // Helper routine to convert from the decoded jpegOutputData to an RGBA array.
      // Currently this routine only handles MONOCHROME1, MONOCHROME2 and RGB
      fun