|
|
|
|
|
by giantrobot
2268 days ago
|
|
Most video editing software (that I've ever used) supports making clips or setting in/out points in longer videos. This doesn't necessarily make new trimmed clips as files on disk because that's expensive (storage and computation) depending on the video's codecs. Editors also expect to export a wholly new output from source so they don't need to make those intermediate clips. It's like pass by reference instead of pass by value. On iOS the trimming is done losslessly, when you trim a clip it basically does the same as what `ffmpeg` is doing here. It seeks to the new start time and copies all the GOPs (group of pictures) to the new end point. The camera records video with really short GOPs so the trimming can be pretty accurate. Only if you apply filters or crop the dimensions of the video will the trimmed clip be reencoded. Any iOS software using AVKit can do the same lossless trims, I imagine most editors on iOS do. When doing rotation I know the Photos app just changes the JPEG rotation flag in the EXIF data. If you send the raw photo to something that ignores or doesn't understand EXIF rotation you'll see just the sensor's default orientation. I believe HEIF works the same way (the container has a rotation atom). When exporting an image (reencoding for sharing or after editing) it will bake in the rotation to the image data, actually performing the rotation to the image. |
|