[mythtv-users] User Jobs - transcoding?

James Abernathy jfabernathy at gmail.com
Wed Oct 26 19:55:40 UTC 2022


On Wed, Oct 26, 2022 at 3:00 PM Roland Ernst <rcrernst at gmail.com> wrote:

>
>
> On Wed, Oct 26, 2022 at 8:16 PM James Abernathy <jfabernathy at gmail.com>
> wrote:
>
>>
>>
>> On Wed, Oct 26, 2022 at 11:23 AM Roland Ernst <rcrernst at gmail.com> wrote:
>>
>>>
>>>
>>> On Wed, Oct 26, 2022 at 4:48 PM Jay Harbeston <jharbestonus at gmail.com>
>>> wrote:
>>>
>>>>
>>>>
>>>> On Oct 26, 2022, at 10:37 AM, Jay Harbeston <jharbestonus at gmail.com>
>>>> wrote:
>>>>
>>>>
>>>>
>>>> On Oct 26, 2022, at 9:37 AM, James Abernathy <jfabernathy at gmail.com>
>>>> wrote:
>>>>
>>>> I'm running the latest v32 on Ubuntu 22.04 and experimenting with
>>>> commercial flagging, editing, and  transcoding.
>>>>
>>>> My problem is with the User Job Transcode.  Using mythfrontend I
>>>> navigate to the recording and instead of playing it I navigate to User Jobs
>>>> and select Transcode video and then select default profile.  The job will
>>>> queue but fail immediately.
>>>>
>>>> Not sure if I have to set up something first, but it's not working by
>>>> default. Here's the transcode log.
>>>>
>>>> Oct 26 09:22:04 kubuntu-closet mythtranscode: mythtranscode[217202]: E
>>>> CoreContext transcode.cpp:729 (TranscodeFile) No video information found!
>>>> Oct 26 09:22:04 kubuntu-closet mythtranscode: mythtranscode[217202]: E
>>>> CoreContext transcode.cpp:730 (TranscodeFile) Please ensure that recording
>>>> profiles for the transcoder are set
>>>> Oct 26 09:22:04 kubuntu-closet mythtranscode: mythtranscode[217202]: E
>>>> CoreContext main.cpp:746 (main) Transcoding
>>>> /data/mythtv/recordings/16218_20221004020000.ts failed
>>>>
>>>>
>>>> Looks like this is the problem. You need some recording profiles. I did
>>>> do this long ago, but don’t remember whether they are defined in the
>>>> frontend or backend.
>>>>
>>>>
>>>>
>>>> Additional note: they are defined in mythtv-setup under "3. Recording
>>>> Profiles”. They settings have changed since I messed with them long ago!
>>>>
>>>>
>>> And if you want to transcode lossless using the cutlist, there is no
>>> setup in the GUI to force this. You need to add an additional flag in the
>>> database:
>>> See https://github.com/MythTV/mythtv/issues/581#issuecomment-116649216
>>> and
>>> https://lists.archive.carbon60.com/mythtv/users/624822
>>> for further information
>>> This only works for files of type  MPEG2VIDEO !
>>>
>>
>> I can't say I understand much of the threads you pointed me to.  From
>> what I can see the built in transcode options don't work at all and you
>> have to build a UserJob to do any transcoding.  I was just hoping that I
>> could find a built-in option that would take an existing recording with a
>> cutlist and just copy it, removing what the cutlist had tagged and put the
>> file back in place of the original.
>>
>> I have a User Job that takes a recording with commercials tagged and
>> manually edited to create the cutlist and then transcode it to .m4v and
>> move it to a directory on my NAS.  My job is based on the one in this Forum
>> topic (
>> https://forum.mythtv.org/viewtopic.php?f=2&t=1261&p=7857&hilit=sendTVtoNAS#p7857
>> )
>>
>> This script uses mythutil, mythtranscode, and handbrake to accomplish
>> this. I guess I could create another script to just do the transcode
>> honoring the cutlist, but I figured that would be one of the default
>> scripts.
>>
>> Jim A
>>
>>
>
> The entries on a recording 'M -> Job Options -> Begin Transcoding'
> only work for files which have a video stream of type 'MPEG2VIDEO'
> and produce either an mpeg2 program stream or a mjpeg video (nuppelvideo).
> See the error log above, you can't transcode an mpeg4 (h264/avc) recording
> with these commands.
> That was discussed multiple times on the mailing lists and the forum.
> If you want to transcode a mpegts ('MPEG2VIDEO') recording losslessly and
> in-place you need to setup the profile according to above links.
> The link I posted previously should read
> https://github.com/MythTV/mythtv/issues/581#issuecomment-1166492166
> instead of
> https://github.com/MythTV/mythtv/issues/581#issuecomment-116649216
>

Sorry to be so dense, but I can't see what you mean.  All my recordings are
MPEG2 ATSC 1.0 OTA recordings with a .ts file extension. I can not see how
to  add the transcodelossless flag to the codecparams of the MPEG2
recording profile. I assume you would do that in mythtv-setup for the
backend, but can't find it. Every time I run mythfrontend and use the "M"
Job Options and select begin transcoding for default I fail with an error.

Some of the log below:

mythtranscode[222562]: N CoreContext main.cpp:568 (main) Transcoding from
/data/mythtv/recordings/16205_20221023020000.ts to
/data/mythtv/recordings/16205_20221023020000.ts.tmp
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext recorders/dtvrecorder.cpp:140 (ResetForNewFile)
DTVRec(0x7f0f81040010): ResetForNewFile(void)
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: W
CoreContext mythtranscodeplayer.cpp:19 (SetTranscoding) TranscodePlayer: No
decoder yet - cannot set transcoding
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext mythplayer.cpp:429 (OpenFile) Player(0): Opening
'/data/mythtv/recordings/16205_20221023020000.ts'
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: E
CoreContext mythvideoprofile.cpp:1324 (InitStatics) VideoProfile: No
window!
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2082 (ScanStreams) AFD: codec AC3
has 6 channels
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2566 (OpenAVCodec) AFD: Opened
codec 0x5602820f7380, id(AC3) type(Audio)
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2082 (ScanStreams) AFD: codec AC3
has 2 channels
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2566 (OpenAVCodec) AFD: Opened
codec 0x5602820efd80, id(AC3) type(Audio)
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2485 (ScanStreams) AFD: Using
ffmpeg for video decoding
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext decoders/avformatdecoder.cpp:2566 (OpenAVCodec) AFD: Opened
codec 0x560282141740, id(MPEG2VIDEO) type(Video)
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: N
CoreContext audioplayer.cpp:157 (ReinitAudio) AudioPlayer: Enabling Audio
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext transcode.cpp:305 (TranscodeFile) Honoring the cutlist while
transcoding
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext transcode.cpp:338 (TranscodeFile) Cutlist        :
8418-10884,23291-30087,43871-53460,67827-76445,91393-96416,107714-215731
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext transcode.cpp:339 (TranscodeFile) Original Length: 215731
frames
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext transcode.cpp:341 (TranscodeFile) New Length     : 75222 frames
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: N
CoreContext transcode.cpp:93 (GetProfile) Transcode: Looking for autodetect
profile: Autodetect from 1080i
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: N
CoreContext transcode.cpp:118 (GetProfile) Transcode: Using autodetect
profile: MPEG2
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: N
CoreContext transcode.cpp:774 (TranscodeFile) Forcing Recorder option
'videocodec' to ''
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: E
CoreContext recorders/recorderbase.cpp:193 (SetOption) RecBase[NULL]():
SetOption(): Unknown int option: videocodec: 0
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext recorders/recorderbase.cpp:81 (SetRingBuffer) RecBase[NULL]():
SetRingBuffer(0x560282164870)
'/data/mythtv/recordings/16205_20221023020000.ts.tmp'
Oct 26 15:45:26 kubuntu-closet mythtranscode: mythtranscode[222562]: I
CoreContext transcode.cpp:1017 (TranscodeFile) Copying Audio while
transcoding Video
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20221026/694f38a6/attachment-0001.htm>


More information about the mythtv-users mailing list