Welcome to Doom9's Forum, THE in-place to be for everyone interested in DVD conversion.

Before you start posting please read the forum rules. By posting to this forum you agree to abide by the rules.

 

Go Back   Doom9's Forum > Capturing and Editing Video > New and alternative a/v containers

Reply
 
Thread Tools Search this Thread Display Modes
Old 18th October 2009, 14:32   #541  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
I see. So I should keep all those defines for my Win32 builds. Thanks for info

BTW: I wonder why we need both, NDEBUG and _DEBUG. Shouldn't the absence of _DEBUG already indicate that we are in "release mode" or vice versa

Doesn't #ifdef NDEBUG have the same meaning as #ifndef _DEBUG in practice? Or are there "historical" reasons?
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 18th October 2009 at 16:44.
LoRd_MuldeR is offline   Reply With Quote
Old 18th October 2009, 15:48   #542  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Quote:
Originally Posted by Zenitram View Post
It already does.
* "Display Aspect Ratio" is the displayed DAR.
* "Original Display Aspect Ratio" is the DAR from the stream if different.

But this file has only one DAR value (the raw video DAR).
I still reckon the expression "Original Display Aspect Ratio" is wrong and should be replaced with "Frame Aspect Ratio". For the reasons I outlined here.

Quote:
Originally Posted by Zenitram View Post
Your solution is not possible: how do you display data for multiple video stream in one container? "General" container can't have video information, because there are only 1 general item (data about the container) even if there are 30 video streams (this is possible, e.g. MPEG-TS from satellites)
If the "General" heading was renamed to "Container". Then perhaps this area could be expanded to include information about the "container level signalling" used by .MKV and .MOV

For transport multiplexes with multiple video streams. Is it not possible to list the video streams information separately, like you do now with audio and subtitle streams?
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 18th October 2009, 16:01   #543  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Oh, please don't rename things. There are people who have existing code to parse the output

Just had to adjust my code, because the "Format" of all WMA files is just "WMA" now, instead of "WMA1", "WMA2" and "WMA3"
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 18th October 2009 at 17:04.
LoRd_MuldeR is offline   Reply With Quote
Old 18th October 2009, 16:44   #544  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by SeeMoreDigital View Post
I still reckon the expression "Original Display Aspect Ratio" is wrong and should be replaced with "Frame Aspect Ratio".
I don't forget.
But as LoRd_MuldeR said, some users don't like I change too much. Legacy is important for other people.
I still plan to estimate the change when I do a bigger API update.

Quote:
Originally Posted by SeeMoreDigital View Post
If the "General" heading was renamed to "Container".
Not a bad idea.
I don't promise to modify it, I will estimate the pro and cons when I change the API ("Container" is maybe not common enough, there is sometime tags or technical info like sattelitte positions and so on... Your point of view is maybe not the point of view from other users)

Quote:
Originally Posted by SeeMoreDigital View Post
Then perhaps this area could be expanded to include information about the "container level signalling" used by .MKV and .MOV
About what expanding do you think?
If you think about video related stuff (new DAR...), I don't think this is a good idea (see below)

Quote:
Originally Posted by SeeMoreDigital View Post
For transport multiplexes with multiple video streams. Is it not possible to list the video streams information separately, like you do now with audio and subtitle streams?
1/ User are interested in the DAR of his video first, they do not care about if it is at container level or stream level. Outputed video has a DAR, whatever is the origin of this DAR. Optionaly, they care about it, and they don't imagine to look in video part for one DAR and general/container part for another DAR.
2/ For multiple video streams, this adds a complexity of the interface (another level). This complexity is too much compared to gains (gains would be for 0.01% of videos, complexity for 100% of videos)

Again, I must manage different kind of users, from beginners to expert, from basic AVI file to very complex MPEG-TS with multiple programs files, from people who parse the CLI output to people using th DLL interface, and creating an understable output for all of them is not so easy as taking your advice directly.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 21st October 2009, 21:33   #545  |  Link
smok3
brontosaurusrex
 
smok3's Avatar
 
Join Date: Oct 2001
Posts: 2,392
Quote:
Originally Posted by Zenitram View Post
I am limitated by drag n drop capacities of WxWidgets toolkit.
I am moving to Qt, which is a lot better for this kind of stuff, but it is unfortunatly not yet ready.
i was brave enough to do a little workaround, until this gets fixed (comes with this cool name: MediaInfoDroplet)

keywords: osx, mac, droplet, mediainfo

whatis:
drop some media files on the icon and it will return some mediainfo values.

download:
http://forum.doom9.org/showthread.php?p=1528488
(now part of the ffdrop collection)

install example:
click to unpack that zip, drag the app to Applications folder and from there to dock, finder window, desktop. The new version will also accept new files to be droped to the allready opened window.

(tested on Lion only)

bugs reported:
spaces in file names are not handled (can't reproduce)

--------------------------

source:
Code:
#!/bin/sh
cmd=$1/Contents/Resources/mediainfo

shift
for argument in "$@" ;do
              echo $argument
             $cmd "$argument"
echo "----------------------------------"
done


echo "droped files:"
for argument in "$@" ;do
              echo $argument

done
"compiled" with platypus 4.4.

video, usage
http://youtu.be/qu2-mygpN5A
__________________
certain other member

Last edited by smok3; 19th December 2011 at 20:05.
smok3 is offline   Reply With Quote
Old 22nd October 2009, 09:00   #546  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by smok3 View Post
i was brave enough to do a little workaround
Thanks for this feature.
Do you see any problem if I include it in my official package?
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 22nd October 2009, 10:59   #547  |  Link
Brazil2
Registered User
 
Join Date: Jul 2008
Posts: 532
Sample: http://www.megaupload.com/?d=B7YJAWF0

Code:
General
Complete name                    : F:\Test\Button.flv
Format                           : Flash Video
File size                        : 3.58 MiB
Duration                         : 18s 0ms
Overall bit rate                 : 1 670 Kbps

Video
Format                           : H.263
Duration                         : 18s 0ms
Bit rate                         : 62.5 Kbps
Width                            : 704 pixels
Height                           : 400 pixels
Display aspect ratio             : 16:9
Frame rate                       : 25.000 fps
Bits/(Pixel*Frame)               : 0.009
Stream size                      : 137 KiB (4%)

Audio
Format                           : MPEG Audio
Format version                   : Version 1
Format profile                   : Layer 3
Duration                         : 18s 0ms
Bit rate mode                    : Constant
Bit rate                         : 96.0 Kbps
Channel(s)                       : 2 channels
Sampling rate                    : 44.1 KHz
Resolution                       : 16 bits
Stream size                      : 211 KiB (6%)
The average bitrate of the video stream is about 1500 Kbps not 62.5 Kbps.

The total file size is 3.58 MB but the reported size of the streams is 137 KiB (4%) for the video and 211 KiB (6%) for the audio so there is something wrong.


Suggestion: for MP3 audio it would be nice if MediaInfo could report if the audio stream is Stereo or Joint Stereo.
Brazil2 is offline   Reply With Quote
Old 22nd October 2009, 11:06   #548  |  Link
smok3
brontosaurusrex
 
smok3's Avatar
 
Join Date: Oct 2001
Posts: 2,392
Quote:
Originally Posted by Zenitram View Post
Thanks for this feature.
Do you see any problem if I include it in my official package?
i can't see any problems.
__________________
certain other member
smok3 is offline   Reply With Quote
Old 22nd October 2009, 14:51   #549  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by Brazil2 View Post
The average bitrate of the video stream is about 1500 Kbps not 62.5 Kbps.
FLV has no index, I rely on Meta tags.
videodatarate value is 62500 bps.

Code:
00000009 Meta - onMetaData - 12 elements (283 bytes)
00000009  Header (15 bytes)
00000009   PreviousTagSize:                         0 (0)
0000000D   Type:                                    12 (18)
0000000E   BodyLength:                              10C (268)
00000011   Timestamp_Base:                          0 (0)
00000014   Timestamp_Extended:                      0 (0)
00000015   StreamID:                                0 (0)
00000018  Type:                                     2 (2) - SCRIPTDATASTRING
00000019  Value_Size:                               A (10)
0000001B  Value:                                    onMetaData
00000025  Type:                                     8 (8) - SCRIPTDATAVARIABLE[ECMAArrayLength]
00000026  ECMAArrayLength:                          C (12)
(...)
0000005E  videodatarate - 62500 (24 bytes)
0000005E   StringLength:                            D (13)
00000060   StringData:                              videodatarate
0000006D   Type:                                    0 (0) - DOUBLE
0000006E   Value:                                   62.500
(...)
Currently, MediaInfo displays the result of a broken file (at least in the header): the file is broken, so result is broken.
I added an integrity check on bitrates (bitrates must be coherent, or metatag info is trashed), next version will have:

Code:
Video
Format                           : H.263
Duration                         : 18s 0ms
Bit rate                         : 1 499 Kbps
Width                            : 704 pixels
Height                           : 400 pixels
Display aspect ratio             : 16:9
Frame rate                       : 25.000 fps
Bits/(Pixel*Frame)               : 0.213
Stream size                      : 3.22 MiB (90%)
Quote:
Originally Posted by Brazil2 View Post
Suggestion: for MP3 audio it would be nice if MediaInfo could report if the audio stream is Stereo or Joint Stereo.
New version will have:
Code:
Audio
Format                           : MPEG Audio
Format version                   : Version 1
Format profile                   : Layer 3
Format settings, Mode            : Joint stereo / MS Stereo
Duration                         : 18s 0ms
Bit rate mode                    : Constant
Bit rate                         : 96.0 Kbps
Channel(s)                       : 2 channels
Sampling rate                    : 44.1 KHz
Resolution                       : 16 bits
Stream size                      : 211 KiB (6%)
(both mode and mode_extension settings)

Thanks for feedback.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 22nd October 2009, 18:14   #550  |  Link
Brazil2
Registered User
 
Join Date: Jul 2008
Posts: 532
Quote:
Originally Posted by Zenitram View Post
FLV has no index, I rely on Meta tags.
I didn't notice that because the file was playing fine in many different players I've tried.
Remuxing it with Mencoder fixed it for good.


Quote:
Originally Posted by Zenitram View Post
Currently, MediaInfo displays the result of a broken file (at least in the header): the file is broken, so result is broken.
I added an integrity check on bitrates (bitrates must be coherent, or metatag info is trashed), next version will have
And/or add a warning maybe ? Saying that the file is somehow broken.
Might be very usefull.


Quote:
Originally Posted by Zenitram View Post
New version will have:
Code:
Audio
Format                           : MPEG Audio
Format version                   : Version 1
Format profile                   : Layer 3
Format settings, Mode            : Joint stereo / MS Stereo
Nice, thanks
Brazil2 is offline   Reply With Quote
Old 22nd October 2009, 18:20   #551  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by Brazil2 View Post
I didn't notice that because the file was playing fine in many different players I've tried.
This is because players don't rely of this kind of information.
This is only an "hint" for players.

Quote:
Originally Posted by Brazil2 View Post
And/or add a warning maybe ? Saying that the file is somehow broken.
Might be very usefull.
Integrity information for user is possible, but this is not the current goal of MediaInfo, and I have already a lot of things to handle (and some are paid)
This is possible, implementation may be done later if I find a sponsor (--> $) for this. Currently, I implement in priority what can be called a bug or quick feature requests (as Joint Stereo request).

Quote:
Originally Posted by Brazil2 View Post
Nice, thanks
You're welcome.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 25th October 2009, 02:52   #552  |  Link
Keiyakusha
契約者
 
Keiyakusha's Avatar
 
Join Date: Jun 2008
Posts: 1,576
Hi!
Lets say I have an mkv file with h264 stream in it. This stream has coded frame size 848x480, there is no SAR information on stream level. On container level display dimensions are 853x480. Mediainfo shows DAR -> 16x9; Original DAR -> 16x9. As I understand Original DAR is a stream level information so shouldn't it print something like "unspecified" instead? Otherwise this can be a bit of misleading...

EDIT: Ah, one more thing. Why mediainfo always shows "Resolution: 24 bits" for h264 streams produced by x264? I believe x264 can do only YV12, which is no way 24 bit...

EDIT2: Also how about printing Container level and Stream level FPS info about h264 video in MKV (and maybe other containers) in cases when FPS is constant? (not sure how things works with non-constant fps, I'm not doing such files)

Last edited by Keiyakusha; 25th October 2009 at 04:04.
Keiyakusha is offline   Reply With Quote
Old 25th October 2009, 16:33   #553  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by Keiyakusha View Post
Lets say I have an mkv file with h264 stream in it. This stream has coded frame size 848x480, there is no SAR information on stream level. On container level display dimensions are 853x480. Mediainfo shows DAR -> 16x9; Original DAR -> 16x9. As I understand Original DAR is a stream level information so shouldn't it print something like "unspecified" instead? Otherwise this can be a bit of misleading...
There is always a default value for SAR (1.000). Try to demux your file, the raw stream is displayed even if there is no SAR explicitly defined... So an Original DAR of 16x9 is normal (848 divided by 480 and SAR=1.000).

Quote:
Originally Posted by Keiyakusha View Post
EDIT: Ah, one more thing. Why mediainfo always shows "Resolution: 24 bits" for h264 streams produced by x264? I believe x264 can do only YV12, which is no way 24 bit...
24 bit is the resolution of the output video when decompressed and displayed by the monitor. But exact, this is not a resolution of the encoded stream, and I should display only details from the encoded stream.
There is already a discussion about colorspace here:
http://sourceforge.net/projects/medi.../topic/3413408
I will add a "Color space" field in all cases (currently, it is displayed only if this is not YUV 4:2:0 for AVC), like this:
- Color space = YUV 4:2:0
- Color space = YUV 4:4:4
- Color space = RGB
- Color space = RGBA
- ...

For "resolution" field, I hesitate: I currently put "24 bits" for RGB for example, this seems right, this is 8 bit per color component (R, G, B...)
But this is not right for YUV stuff.
Which value should I put in this field from your point of view? 'bit depth'? I have no precise idea about this, because 'bit depth' should be maybe by YUV component (8 or 10 bit), but in this case I should maybe change the RGB handling and put "8 bit" too.

So... how would you handle the "Resolution" field with for example normal AVC, "High 10" AVC profile, RGB codecs, RGBA codecs?

Quote:
Originally Posted by Keiyakusha View Post
EDIT2: Also how about printing Container level and Stream level FPS info about h264 video in MKV (and maybe other containers) in cases when FPS is constant? (not sure how things works with non-constant fps, I'm not doing such files)
This is already the case:
Code:
General
Format                           : Matroska
(...)
Video
Format                           : AVC
Codec ID                         : V_MPEG4/ISO/AVC
Frame rate                       : 25.000 fps
Original frame rate              : 12.500 fps
(...)
If you have a sample not displaying original FPS, please provide it.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 25th October 2009, 17:38   #554  |  Link
Keiyakusha
契約者
 
Keiyakusha's Avatar
 
Join Date: Jun 2008
Posts: 1,576
Quote:
Originally Posted by Zenitram View Post
There is always a default value for SAR (1.000). Try to demux your file, the raw stream is displayed even if there is no SAR explicitly defined... So an Original DAR of 16x9 is normal (848 divided by 480 and SAR=1.000).
Here I'm rely on Info, reported by great indexers from Donald Graft. If I don't set SAR during encoding, I see "unspecified" in information dialog. But If i will set SAR 1:1, I will see exactly 1:1 SAR reported.

Anyway it will be good to have SAR value separated from frame size, because 848x480 SAR 1:1 and 848x480 SAR 160:159 is two different things. I think only in second case Original DAR 16:9 should be reported by mediainfo.

Quote:
Originally Posted by Zenitram View Post
If you have a sample not displaying original FPS, please provide it.
Sorry, It looks like some tools (or some versions of these tools) for muxing just overrides stream level info. Or something like that. I need to check this again...
If the file muxed with latest mkvtoolnix I difinitely can see Frame rate and original frame rate.

Quote:
Originally Posted by Zenitram View Post
So... how would you handle the "Resolution" field with for example normal AVC, "High 10" AVC profile, RGB codecs, RGBA codecs?
Thanks for explanation but I'm afraid I can't answer to this question.

Last edited by Keiyakusha; 25th October 2009 at 17:45.
Keiyakusha is offline   Reply With Quote
Old 25th October 2009, 17:59   #555  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by Keiyakusha View Post
Here I'm rely on Info, reported by great indexers from Donald Graft. If I don't set SAR during encoding, I see "unspecified" in information dialog. But If i will set SAR 1:1, I will see exactly 1:1 SAR reported.
Its behaviour is wanted, mine is wanted too.
My goal with this field is to display how a decoder would handle a "non-value". And all decoders I know handle non-value as 1.000 SAR, so I don't see any reason to display "unspecified" for my goal. This is a conscious decision.

Quote:
Originally Posted by Keiyakusha View Post
Anyway it will be good to have SAR value separated from frame size, because 848x480 SAR 1:1 and 848x480 SAR 160:159 is two different things. I think only in second case Original DAR 16:9 should be reported by mediainfo.
SAR is saved, but not displayed by default. Toggle Debug --> Advanced mode and you will see precise SAR and DAR values.
But for the "normal" view, I display "16:9" for DAR between 1.700 and 1.850 (so a DAR of 848/480=1.767 is displayed as 16:9. If you want the precise value, you need to create your own custom view(if you create your own custom view you can display 1.767 instead of a rounded to known value)

Quote:
Originally Posted by Keiyakusha View Post
Sorry, It looks like some tools (or some versions of these tools) for muxing just overrides stream level info. Or something like that. I need to check this again...
I already saw some tools removing SAR/DAR from raw stream during the muxing.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 25th October 2009, 18:47   #556  |  Link
SeeMoreDigital
Life's clearer in 4K UHD
 
SeeMoreDigital's Avatar
 
Join Date: Jun 2003
Location: Notts, UK
Posts: 12,219
Thankfully the issue about where aspect ratio signalling should be placed, ie: within the stream (stream level signalling) or within the container (container level signalling), has been made a lot easier now that Mosu's MKVmergeGUI no longer removes the aspect ratio signalling from the stream by default
__________________
| I've been testing hardware media playback devices and software A/V encoders and decoders since 2001 | My Network Layout & A/V Gear |
SeeMoreDigital is offline   Reply With Quote
Old 25th October 2009, 20:56   #557  |  Link
qyot27
...?
 
qyot27's Avatar
 
Join Date: Nov 2005
Location: Florida
Posts: 1,419
Quote:
Originally Posted by Keiyakusha View Post
EDIT2: Also how about printing Container level and Stream level FPS info about h264 video in MKV (and maybe other containers) in cases when FPS is constant? (not sure how things works with non-constant fps, I'm not doing such files)
This reminds me, on MP4 files the %FrameRate_Mode/String% option works and displays either Constant or Variable. MKV and FLV files, on the other hand, don't display this field - MKV certainly can be VFR, and I thought FLV could too. Are there plans to add support for those, or is it something that can only be easily done with MP4?
qyot27 is offline   Reply With Quote
Old 25th October 2009, 21:47   #558  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by qyot27 View Post
This reminds me, on MP4 files the %FrameRate_Mode/String% option works and displays either Constant or Variable. MKV and FLV files, on the other hand, don't display this field - MKV certainly can be VFR, and I thought FLV could too. Are there plans to add support for those, or is it something that can only be easily done with MP4?
MP4 has an index, with duration of each frame in this index, I can quickly (whithout parsing the wohole file) know if this is VBR or CBR.

MKV has no index, and has a FrameRate field defined as "Number of frames per second. Informational only" --> I am not sure this field would not be filled with average FPS if the film is VFR. I don't have such a kind of file, I can not see what is the implementation of muxers. I need to parse the whole file to be sure (this would be an option later, not currently implemented). So I prefer not to indicate CFR/VFR value.

FLV has no index, and has an optional only framerate metatag, not precise too (what is the content of this value if this is a VFR file? I have no official info about it). So I prefer not to indicate CFR/VFR value (for FLV, I have a better detection implementation, I parse the 30 first frames, if theses frames are VFR, I display "VFR" because I am sure this is VFR, but having the first 30 frames in CFR does not mean all file is CFR, so I don't display it)
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Old 26th October 2009, 03:29   #559  |  Link
DrNein
Registered User
 
Join Date: Sep 2002
Posts: 145
For XP, I have six instances of MediaInfo.dll to support the following and wonder if it is okay just to have one instance in System32 (so far it seems fine)?

MediaInfo
MediaCoder\tools
megui
Movie Catalog
MPC
Yamb
DrNein is offline   Reply With Quote
Old 26th October 2009, 08:33   #560  |  Link
Zenitram
Registered User
 
Join Date: Aug 2002
Location: France, Paris
Posts: 672
Quote:
Originally Posted by DrNein View Post
For XP, I have six instances of MediaInfo.dll to support the following and wonder if it is okay just to have one instance in System32 (so far it seems fine)?
Currently the API has not changed for a while, so no problem from my point of view. But each software has its own rules, I have no power on other software.
__________________
Want to know all about your media files? http://mediaarea.net/MediaInfo
Zenitram is offline   Reply With Quote
Reply

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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

Forum Jump


All times are GMT +1. The time now is 23:04.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.