Page 1 of 1

Crop video

PostPosted: Thu Jun 04, 2020 4:23 pm
by residend
Hello!

Can serviio crop a video (black stripes above and below)?

I know how to do this using the command line in ffmpeg, but where to enter it in the profile?


offtop: how to play all videos in a row from dlna share ?

fnx.

Re: Crop video

PostPosted: Thu Jun 04, 2020 5:19 pm
by atc98092
No Serviio cannot alter the aspect ratio of the video. On occasion some displays/players might not process the aspect ratio correctly, and something can be applied via the profile. But that's only if the video needs transcoding in the first place. If you player doesn't require the video to be transcoded, then there's nothing that can be done from the Serviio end.

Continuous playback is a function of the player, not Serviio. Not all players can do so.

Re: Crop video

PostPosted: Tue Jun 09, 2020 1:19 pm
by residend
Can I use in transcoding profile ffmpeg command? Or maby I can this in other config file?

Re: Crop video

PostPosted: Tue Jun 09, 2020 1:37 pm
by atc98092
residend wrote:Can I use in transcoding profile ffmpeg command? Or maby I can this in other config file?

The profiles cannot by themselves alter the FFMPEG command beyond what Serviio has programmed in. This support page shows everything that can be included in a transcoding portion of a profile. If it's not listed here, then you can't add anything additional. https://www.serviio.org/index.php?optio ... icle&id=24

Re: Crop video

PostPosted: Sun Jun 21, 2020 8:10 am
by DenyAll
I think the OP is discussing letterboxing (black bars above and below the video) and yes, Serviio can support it.

If you add DAR="16:9" to any standard transcoding block, Serviio will add black bars to the top and bottom for any source video which has a aspect ratio that is higher than 16:9. For example:

  Code:
<Video targetContainer="mpegts" targetVCodec="mpeg2video" targetACodec="ac3" aBitrate="384" DAR="16:9" maxWidth="1920" maxHeight="1080">
   <Matches container="*" widthGreaterThan="1920" />
   <Matches container="mp4" vCodec="h264" profile="high" levelGreaterThan="3.2" />
   <Matches container="matroska" />
   <Matches container="*" vCodec="h265" />
</Video>
will transcode any video matched any the "Matches" statements and add black bars top and bottom if needed to maintain the original aspect ratio.

ps. Your TV may undo this if it is set to stretch or pan modes.