MediaPortal Forums HTPC/MediaCenter

Go Back   MediaPortal Forum » MediaPortal 1 » Help on Development » General Development (no feature request here!)


General Development (no feature request here!) You were able to fix an issue, or improved a feature? Post it here.

Reply
 
LinkBack (2) Thread Tools Display Modes
Old 2007-01-29, 22:21   #11 (permalink)
Portal Developer
 
frodo's Avatar
 
Join Date: Apr 2004
Location: The Netherlands
Age: 36
Posts: 1,513
Thanks: 3
Thanked 119 Times in 44 Posts

Country:

My System

Thumbs up

hrmmm Fabrice???

could it be....
The famous Fabrice from the FFMPEG project ??

ifso.. respect!! and what can we do so you join the mediaportal team???

Frodo
frodo is offline   Reply With Quote
Old 2007-01-30, 06:40   #12 (permalink)
Portal Member
 
Join Date: Jan 2007
Location: Nice
Age: 30
Posts: 123
Thanks: 4
Thanked 12 Times in 3 Posts

Country:

My System

Default

Hello Noelix,

Thanks a lot for your test !

I read the log file, and the process is correctly launched but after it crashs :-(

Can you test the ffmpeg encoder with theses parameters in the config.txt

encoder.1pass.args=-b 150k -bt 150k -ab 96 -vcodec mpeg4 -g 300 -bf 2 -acodec mp3 -ar 22050 -f avi

the quality of the video is not good but it is just to verify if the encoding finish correctly.

and for mencoder (if you prefer) the line following

encoder.1pass.args=-ovc lavc -oac lavc -ffourcc DX50


PS for Frodo: I am affraid but i am not the Fabrice of FFMPEG project.

Bye
Fab
fabriceD06 is offline   Reply With Quote
Old 2007-01-30, 06:45   #13 (permalink)
Portal Member
 
Join Date: Jan 2007
Location: Nice
Age: 30
Posts: 123
Thanks: 4
Thanked 12 Times in 3 Posts

Country:

My System

Default

Quote:
Originally Posted by diehard2 View Post
Hello fabrice,

This was on my to do list. So, thanks! Are you the fabrice who holds the copywrite on ffmpeg? If you post the code changes and a working ffmpeg version, I can add it to the svn. Does the included ffmpeg version use libxvidcore or the internal xvid?
Hello diehard2,

I don't who holds the copy write of ffpmeg.

For the code i will wait some people says me it works before to give you ;-) to be sure to have a stable version.

Currently i use the binarie and not the DLL, because when i used the dll if the encoding crash the process MP crash also. so i prefered the solution to create an external process for not disturb the MP process.

bye Fab
fabriceD06 is offline   Reply With Quote
Old 2007-01-30, 07:02   #14 (permalink)
Portal Developer
 
frodo's Avatar
 
Join Date: Apr 2004
Location: The Netherlands
Age: 36
Posts: 1,513
Thanks: 3
Thanked 119 Times in 44 Posts

Country:

My System

Default

Fabrice

Can we also have real-time transcoding ?
Say i have an mpeg-2 transport stream and i want to transcode it in realtime
to a lower bitrate and/or lower resolution.
Output must be mpeg-2 transport stream as well

If this can be made, we could add it to the tvserver and then we can use clients over the internet
At the moment this is not possible since streaming a full mpeg-ts channel requires too much bandwidth

Frodo
frodo is offline   Reply With Quote
Old 2007-01-30, 17:34   #15 (permalink)
Portal Member
 
Noelix's Avatar
 
Join Date: Feb 2006
Location: Phoenix, AZ
Age: 26
Posts: 388
Thanks: 10
Thanked 1 Time in 1 Post

Country:

My System

Send a message via MSN to Noelix
Default

Quote:
Originally Posted by fabriceD06 View Post
Can you test the ffmpeg encoder with theses parameters in the config.txt

encoder.1pass.args=-b 150k -bt 150k -ab 96 -vcodec mpeg4 -g 300 -bf 2 -acodec mp3 -ar 22050 -f avi
Same result - a blank command prompt window. Here's the log below:
http://pastebin.team-mediaportal.com/11935
__________________
Noelix is offline   Reply With Quote
Old 2007-01-31, 06:35   #16 (permalink)
Portal Member
 
Join Date: Jan 2007
Location: Nice
Age: 30
Posts: 123
Thanks: 4
Thanked 12 Times in 3 Posts

Country:

My System

Default

Hello Noelix,

thanks for your help.

It is normal for command prompt windows blank, it is the background process. The video transcoding are correclty started, in log file i see


2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err]FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2006 Fabrice Bellard, et al.
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] configuration: --prefix=/mingw --enable-memalign-hack --cc=gcc-4.1 --disable-debug --enable-a52 --enable-dts --enable-gpl --enable-avisynth --enable-amr_nb --enable-amr_wb --enable-xvid --enable-x264 --enable-mp3lame --enable-vorbis --enable-libogg --enable-faac --enable-pp
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] libavutil version: 49.1.0
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] libavcodec version: 51.27.0
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] libavformat version: 51.6.0
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] built on Dec 20 2006 23:36:00, gcc: 4.1.1 [Sherpya]
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err]Input #0, asf, from 'E:\recordings\Afro Samurai SH883483x101 (1_5_2007).dvr-ms':
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Duration: 00:34:57.0, start: 0.000000, bitrate: 5631 kb/s
2007-01-30 10:21:02.531250 [Info.][Thread TransErrStream]: [ExternalTranscoder][Err] duration found 2097
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.0: Audio: mp2, 48000 Hz, stereo, 384 kb/s
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.1: Video: mpeg2video, yuv420p, 720x480, 5000 kb/s, 29.97 fps(r)
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err]Output #0, avi, to 'E:\recordings\Afro Samurai SH883483x101 (1_5_2007).avi':
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.0: Video: mpeg4, yuv420p, 720x480, q=2-31, 150 kb/s, 29.97 fps(c)
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.1: Audio: mp3, 22050 Hz, stereo, 96 kb/s
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err]Stream mapping:
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.1 -> #0.0
2007-01-30 10:21:02.531250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err] Stream #0.0 -> #0.1

and three minutes , the encoding progress


2007-01-30 10:23:46.015625 [Info.][12]: ExternalTranscoder[IsFinished] is finish False
2007-01-30 10:23:46.015625 [Info.][12]: ExternalTranscoder[Percentage] return percentage 130
2007-01-30 10:23:46.031250 [Debug][Thread TransErrStream]: [ExternalTranscoder][Err]frame= 8245 q=31.0 size= 13876kB time=275.0 bitrate= 413.3kbits/s
2007-01-30 10:23:46.031250 [Info.][Thread TransErrStream]: [ExternalTranscoder][Err] value found 275.0

After i suppose you close the blank commant prompt windows and the encoding is stopped.

When you launch the encoding from the menu compression, you can see the progression in the sub-menu state , can you check this once the transcoding is launched.

I am agree currently the percentage return is wrong (because by exemple it returns 130 % then it is 13 %, it is my stupid bug of multiplication )

For your video of 34 min, the encoding with a bit rate 150kb/s take 20~30 minutes.

you can change the bitrate in the commande line

encoder.1pass.args=-b 150k -bt 150k -ab 96 -vcodec mpeg4 -g 300 -bf 2 -acodec mp3 -ar 22050 -f avi

For a DVD the bit rate is about 1000k - 2500k.

Can you launch the transcoding (don't close the blank prompt windows) and check in the sub-menu state or status in compression menu. Normally you can check also with the task manager, you can see a process ffmpeg.exe take some cpu ;-)



bye
Fabrice
fabriceD06 is offline   Reply With Quote
Old 2007-01-31, 06:41   #17 (permalink)
Portal Member
 
Join Date: Jan 2007
Location: Nice
Age: 30
Posts: 123
Thanks: 4
Thanked 12 Times in 3 Posts

Country:

My System

Default

Quote:
Originally Posted by frodo View Post
Fabrice

Can we also have real-time transcoding ?
Say i have an mpeg-2 transport stream and i want to transcode it in realtime
to a lower bitrate and/or lower resolution.
Output must be mpeg-2 transport stream as well

If this can be made, we could add it to the tvserver and then we can use clients over the internet
At the moment this is not possible since streaming a full mpeg-ts channel requires too much bandwidth

Frodo
Hello Frodo,

Normally it possible to encode in real time (for low bit rate ) with ffmpeg . But not with my currently modification because i use the binarie instead the dll.

I have few doubt about the topics:

1. the hardware required to encode in real time, i think some test are necessary.
2. the usage of API of FFMPEG is in C++, the integration in C# is not easy . because it necessary to wrappe all types like AVOutputStream and AVInputStream to the c# media stream

But possible with time.

Fabrice
fabriceD06 is offline   Reply With Quote
Old 2007-01-31, 06:53   #18 (permalink)
Portal Developer
 
frodo's Avatar
 
Join Date: Apr 2004
Location: The Netherlands
Age: 36
Posts: 1,513
Thanks: 3
Thanked 119 Times in 44 Posts

Country:

My System

Default

2. c++ is not a problem,
The main problem i had with ffmpeg was that it was file based
What i would like is something like:
Code:
byte* transCoded=ffmpeg.transcode(byte* tspacket);
so i supply a mpeg-2 ts packet and get a transcoded mpeg-2 ts packet back

Frodo
frodo is offline   Reply With Quote
Old 2007-01-31, 20:54   #19 (permalink)
Portal Member
 
Noelix's Avatar
 
Join Date: Feb 2006
Location: Phoenix, AZ
Age: 26
Posts: 388
Thanks: 10
Thanked 1 Time in 1 Post

Country:

My System

Send a message via MSN to Noelix
Default

Quote:
Originally Posted by fabriceD06 View Post
Can you launch the transcoding (don't close the blank prompt windows) and check in the sub-menu state or status in compression menu. Normally you can check also with the task manager, you can see a process ffmpeg.exe take some cpu ;-)
Alright I gotcha now, sorry I wasn't catching on right away. It completes its task successfully! The % is off as you noticed already, and for some reason MediaPortal.log is now 578MB after transcoding two files. Judging from past log files I've posted, it looks like it has to do with the thumbnail creation for the videos. I don't even view it in thumbnail mode and it's trying to create thumbnails over and over and failing for some reason. I don't think this is a problem with your transcoding process, but there may be a way to stop it from trying to create thumbnails while the file is being encoded... Anyways I could be completely wrong.

Seems to work great, the only thing I know people would like is to be able to change the config.txt settings within MP, and to have the transcoding process window (blank command prompt window) occur in the background as opposed to minimizing MP and bringing focus to it. Thanks so much for building this!

EDIT: I noticed that if you choose "delete original file", the MP database is not updated to reflect that change. As a result, the tv show listing remains in the database (aka Recorded TV), but is still pointing to the original .dvr-ms file, and not the new .avi file. So when you try to play the recorded-tv file, it doesn't play.
__________________

Last edited by Noelix; 2007-02-01 at 04:14.
Noelix is offline   Reply With Quote
Old 2007-01-31, 22:08   #20 (permalink)
Portal Member
 
Efros's Avatar
 
Join Date: Jan 2006
Location: Maine
Posts: 458
Thanks: 1
Thanked 0 Times in 0 Posts

Country:

My System

Default

Get a mencoder crash with xvid and dx50 config files.

MP log attached
__________________
"Here's to the electron may it never be of any use to anyone!"

Allegedly a toast at the Royal Institute of Physics at the turn of the 20th Century.

Current skin: Mepo Green

Efros is offline   Reply With Quote
Reply

Bookmarks

Tags
plugin, transcoding, video

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump

LinkBacks (?)
LinkBack to this Thread: http://forum.team-mediaportal.com/general-development-no-feature-request-here-48/mp-plugin-video-transcoding-15953/
Posted By For Type Date
Evolution(s) De Mon Installation Mp - MP-FR .:: Le forum ::. This thread Refback 2008-08-04 08:11
Comment Graver Un Enregistrement Tv ? - MP-FR .:: Le forum ::. This thread Refback 2008-07-21 21:38

Similar Threads
Thread Thread Starter Forum Replies Last Post
Cutting and transcoding, - please help Dadane General Support 0 2007-01-29 06:34
Transcoding filters etc dman_lfc Tips and Tricks 11 2007-01-25 14:33
Transcoding options Khris Improvement Suggestions 3 2006-03-08 20:53
Transcoding tthomas Improvement Suggestions 3 2005-06-20 10:28
Update Core.Transcoding to handle more in / out formats sporktastic Improvement Suggestions 9 2005-03-17 22:51


All times are GMT +1. The time now is 11:38.


Powered by vBulletin® Version 3.7.2
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 Protected by Akismet Blog with WordPress