|
29 | 29 | use AsyncAws\MediaConvert\Enum\H264Telecine; |
30 | 30 | use AsyncAws\MediaConvert\Enum\H264TemporalAdaptiveQuantization; |
31 | 31 | use AsyncAws\MediaConvert\Enum\H264UnregisteredSeiTimecode; |
| 32 | +use AsyncAws\MediaConvert\Enum\H264WriteMp4PackagingType; |
32 | 33 |
|
33 | 34 | /** |
34 | 35 | * Required when you set Codec to the value H_264. |
@@ -494,6 +495,17 @@ final class H264Settings |
494 | 495 | */ |
495 | 496 | private $unregisteredSeiTimecode; |
496 | 497 |
|
| 498 | + /** |
| 499 | + * Specify how SPS and PPS NAL units are written in your output MP4 container, according to ISO/IEC 14496-15. If the |
| 500 | + * location of these parameters doesn't matter in your workflow: Keep the default value, AVC1. MediaConvert writes SPS |
| 501 | + * and PPS NAL units in the sample description ('stsd') box (but not into samples directly). To write SPS and PPS NAL |
| 502 | + * units directly into samples (but not in the 'stsd' box): Choose AVC3. When you do, note that your output might not |
| 503 | + * play properly with some downstream systems or players. |
| 504 | + * |
| 505 | + * @var H264WriteMp4PackagingType::*|null |
| 506 | + */ |
| 507 | + private $writeMp4PackagingType; |
| 508 | + |
497 | 509 | /** |
498 | 510 | * @param array{ |
499 | 511 | * AdaptiveQuantization?: null|H264AdaptiveQuantization::*, |
@@ -540,6 +552,7 @@ final class H264Settings |
540 | 552 | * Telecine?: null|H264Telecine::*, |
541 | 553 | * TemporalAdaptiveQuantization?: null|H264TemporalAdaptiveQuantization::*, |
542 | 554 | * UnregisteredSeiTimecode?: null|H264UnregisteredSeiTimecode::*, |
| 555 | + * WriteMp4PackagingType?: null|H264WriteMp4PackagingType::*, |
543 | 556 | * } $input |
544 | 557 | */ |
545 | 558 | public function __construct(array $input) |
@@ -588,6 +601,7 @@ public function __construct(array $input) |
588 | 601 | $this->telecine = $input['Telecine'] ?? null; |
589 | 602 | $this->temporalAdaptiveQuantization = $input['TemporalAdaptiveQuantization'] ?? null; |
590 | 603 | $this->unregisteredSeiTimecode = $input['UnregisteredSeiTimecode'] ?? null; |
| 604 | + $this->writeMp4PackagingType = $input['WriteMp4PackagingType'] ?? null; |
591 | 605 | } |
592 | 606 |
|
593 | 607 | /** |
@@ -636,6 +650,7 @@ public function __construct(array $input) |
636 | 650 | * Telecine?: null|H264Telecine::*, |
637 | 651 | * TemporalAdaptiveQuantization?: null|H264TemporalAdaptiveQuantization::*, |
638 | 652 | * UnregisteredSeiTimecode?: null|H264UnregisteredSeiTimecode::*, |
| 653 | + * WriteMp4PackagingType?: null|H264WriteMp4PackagingType::*, |
639 | 654 | * }|H264Settings $input |
640 | 655 | */ |
641 | 656 | public static function create($input): self |
@@ -941,6 +956,14 @@ public function getUnregisteredSeiTimecode(): ?string |
941 | 956 | return $this->unregisteredSeiTimecode; |
942 | 957 | } |
943 | 958 |
|
| 959 | + /** |
| 960 | + * @return H264WriteMp4PackagingType::*|null |
| 961 | + */ |
| 962 | + public function getWriteMp4PackagingType(): ?string |
| 963 | + { |
| 964 | + return $this->writeMp4PackagingType; |
| 965 | + } |
| 966 | + |
944 | 967 | /** |
945 | 968 | * @internal |
946 | 969 | */ |
@@ -1157,6 +1180,12 @@ public function requestBody(): array |
1157 | 1180 | } |
1158 | 1181 | $payload['unregisteredSeiTimecode'] = $v; |
1159 | 1182 | } |
| 1183 | + if (null !== $v = $this->writeMp4PackagingType) { |
| 1184 | + if (!H264WriteMp4PackagingType::exists($v)) { |
| 1185 | + throw new InvalidArgument(\sprintf('Invalid parameter "writeMp4PackagingType" for "%s". The value "%s" is not a valid "H264WriteMp4PackagingType".', __CLASS__, $v)); |
| 1186 | + } |
| 1187 | + $payload['writeMp4PackagingType'] = $v; |
| 1188 | + } |
1160 | 1189 |
|
1161 | 1190 | return $payload; |
1162 | 1191 | } |
|
0 commit comments