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 > Programming and Hacking > Development

Reply
 
Thread Tools Search this Thread Display Modes
Old 3rd January 2015, 12:49   #1141  |  Link
jpsdr
Registered User
 
Join Date: Oct 2002
Location: France
Posts: 2,309
Quote:
Originally Posted by LoRd_MuldeR View Post
but I will certainly do it before the next "final" release.
That's finaly all that matters.
jpsdr is offline   Reply With Quote
Old 3rd January 2015, 16:14   #1142  |  Link
justonce01
Registered User
 
Join Date: Jan 2014
Posts: 5
Quote:
Originally Posted by LoRd_MuldeR View Post
Got it. Thanks.
justonce01 is offline   Reply With Quote
Old 10th January 2015, 22:38   #1143  |  Link
Octo-puss
Registered User
 
Join Date: Jan 2008
Posts: 571
Would it be possible to add the possibility to add entire folder(s) as a source? I have one huge folder containing the discography of a band I want to encode, and it's very annoying to add each album manually.
Octo-puss is offline   Reply With Quote
Old 11th January 2015, 11:43   #1144  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by Octo-puss View Post
Would it be possible to add the possibility to add entire folder(s) as a source? I have one huge folder containing the discography of a band I want to encode, and it's very annoying to add each album manually.
Try "File" → "Open Folder Recursively"
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 11th January 2015 at 11:51.
LoRd_MuldeR is offline   Reply With Quote
Old 12th January 2015, 15:08   #1145  |  Link
Octo-puss
Registered User
 
Join Date: Jan 2008
Posts: 571
Haha thanks, I didn't think there was any other functionality hidden somewhere in the menus. Could you add it as an extra button though, please?
Octo-puss is offline   Reply With Quote
Old 13th January 2015, 21:42   #1146  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by Octo-puss View Post
Haha thanks, I didn't think there was any other functionality hidden somewhere in the menus. Could you add it as an extra button though, please?
Hmm, I don't think I will add yet another button for this.
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊
LoRd_MuldeR is offline   Reply With Quote
Old 14th January 2015, 09:26   #1147  |  Link
Octo-puss
Registered User
 
Join Date: Jan 2008
Posts: 571
Why not? It makes perfect sense. Lots of programs have extra buttons for either selecting a file or an entire folder. Why would I have to go to a menu to do something that is so similar to something else that has its own button? It's not like my arm would fall off by going into a menu instead of clicking on a button, but as you could see, I didn't even think such functionality existed, because the first impression you get from LameXP is that all the functionality is right there in the windows.
Octo-puss is offline   Reply With Quote
Old 14th January 2015, 20:43   #1148  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by Octo-puss View Post
Why not? It makes perfect sense. Lots of programs have extra buttons for either selecting a file or an entire folder. Why would I have to go to a menu to do something that is so similar to something else that has its own button? It's not like my arm would fall off by going into a menu instead of clicking on a button, but as you could see, I didn't even think such functionality existed, because the first impression you get from LameXP is that all the functionality is right there in the windows.
I think the button triple of "Add", "Remove" and "Clear" is good just the way it is. So I don't want to spoil the clarity of the GUI. Adding a second (slightly different) "Add" button would be kind of redundant. Also I believe that adding a whole directory structure recursively is not something that most users need most of the time. And if they ever need it, the "File" menu is the most obvious place to look for something like this. But maybe I'll add a word or two to the manual.
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 14th January 2015 at 21:12.
LoRd_MuldeR is offline   Reply With Quote
Old 14th January 2015, 21:21   #1149  |  Link
manolito
Registered User
 
manolito's Avatar
 
Join Date: Sep 2003
Location: Berlin, Germany
Posts: 3,078
XMPlay uses another interesting alternative:
It only has single buttons for adding / removing titles, but if you right-click one of the buttons it deals with whole folders instead of single files. Another possibility would be using Shift-Click for dealing with folders...


Cheers
manolito
manolito is offline   Reply With Quote
Old 14th January 2015, 22:50   #1150  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by LoRd_MuldeR View Post
... But maybe I'll add a word or two to the manual.
Done.
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊
LoRd_MuldeR is offline   Reply With Quote
Old 16th January 2015, 14:03   #1151  |  Link
schiff1108
Registered User
 
Join Date: Nov 2014
Posts: 4
Tags

I would like to understand the approach on tags. What tags should get copied from source to output?
In particular I am missing the tags "composer" and "album artist".
When I check the source file with MediaInfo, I do find the tag values as expected. I have made some shots with using Custom Encoding Parameters, but w/o success.

Thanks.
schiff1108 is offline   Reply With Quote
Old 16th January 2015, 22:19   #1152  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by schiff1108 View Post
I would like to understand the approach on tags. What tags should get copied from source to output?
In particular I am missing the tags "composer" and "album artist".
When I check the source file with MediaInfo, I do find the tag values as expected. I have made some shots with using Custom Encoding Parameters, but w/o success.
Meta data is extracted from the original file via MediaInfo. It then will be kept in an internal data structure. And finally it will be re-embedded into the output file, according to the individual encoder's capabilities.

One important thing to understand is that there is not the one standard for meta information! Every file format uses its own eccentric way to keep meta information. Some file formats, like e.g. MP3's "ID3v1" tags, are very limited, with only a few pre-defined fields. With those you can only use the pre-defined fields and that's it. At the same time, some other formats are very flexible, because they store arbitrary key-value pairs. On the one hand, this flexibility is great. But on the other hand, it makes it hard to figure out which keys are actually used practice - and which ones are actually recognized by (most) applications. Therefore "copying" meta information from one file format to another one is not as trivial as you might imagine!

The approach that I took with LameXP is that I designed the internal "meta information" data structure roughly as a "smallest common denominator" for what most file formats offer. This data structure will be filled with the meta tags that MediaInfo brings up. However, not every information that MediaInfo might be able to extract from a specific file format necessarily has an equivalent field in the internal data structure! There are far too many different (obscure) tags that might appear in some file to reserve a field for every single one of them. Instead, our internal data structure is restricted to the most important tags. So it's quite possible that we can not retain every single bit of information that MediaInfo has tracked down!


[EDIT]

Currently, the meta information that can be kept in the internal data structure are as follows:
Code:
QString m_titel;
QString m_artist;
QString m_album;
QString m_genre;
QString m_comment;
QString m_containerType;
QString m_containerProfile;
QString m_audioType;
QString m_audioProfile;
QString m_audioVersion;
QString m_audioEncodeLib;
unsigned int m_audioSamplerate;
unsigned int m_audioChannels;
unsigned int m_audioBitdepth;
unsigned int m_audioBitrate;
unsigned int m_audioBitrateMode;
unsigned int m_duration;
unsigned int m_year;
unsigned int m_position;
ArtworkModel m_cover;
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 16th January 2015 at 22:44.
LoRd_MuldeR is offline   Reply With Quote
Old 16th January 2015, 23:45   #1153  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
Would you consider adding a QMap of unknown and custom tags, that can be re-embedded if the output supports them?
foxyshadis is offline   Reply With Quote
Old 16th January 2015, 23:58   #1154  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by foxyshadis View Post
Would you consider adding a QMap of unknown and custom tags, that can be re-embedded if the output supports them?
I don't think that would solve anything. Of course, with a Map we can maintain arbitrary key-value pairs. That is very flexible, obviously. So we could simply dump everything that MediaInfo brings up into the Map. That's straight forward. But the real challenge here is that, eventually, we need to re-embed all that information into the output file! For example, the LAME encoder accepts a "--tt" switch to specify the "title" of the track and a "--ta" switch to specify the "artist". Thus, I know that if we are using LAME, then I need to pass the value of m_titel via "--tt" switch and the value of m_artist via "--ta" switch. But what to do with the "PhaseOfMoonWhenThisAlbumWasRecorded" entry, if such key appears in the Map?
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 17th January 2015 at 00:01.
LoRd_MuldeR is offline   Reply With Quote
Old 17th January 2015, 10:28   #1155  |  Link
foxyshadis
ангел смерти
 
foxyshadis's Avatar
 
Join Date: Nov 2004
Location: Lost
Posts: 9,558
Quote:
Originally Posted by LoRd_MuldeR View Post
I don't think that would solve anything. Of course, with a Map we can maintain arbitrary key-value pairs. That is very flexible, obviously. So we could simply dump everything that MediaInfo brings up into the Map. That's straight forward. But the real challenge here is that, eventually, we need to re-embed all that information into the output file! For example, the LAME encoder accepts a "--tt" switch to specify the "title" of the track and a "--ta" switch to specify the "artist". Thus, I know that if we are using LAME, then I need to pass the value of m_titel via "--tt" switch and the value of m_artist via "--ta" switch. But what to do with the "PhaseOfMoonWhenThisAlbumWasRecorded" entry, if such key appears in the Map?
Well, if you have Ogg/FLAC or APE tags you just write them back as-is, same if you're going from one id3v2 format to another, just copy everything. (Except encoder and created date tags.) For everything else, map if tags are standardized, drop if not; no one's going to seriously expect to see a PhaseOfMoon tag to end up in mp3. You must already have a map of common entries from one format to another, in the form of the conversions to and from your variables, since id3v2 and Ogg tags are completely different, so it's mostly a matter of extending that with more common tags and allowing arbitrary ones to pass through if possible.

(Album Artist is especially extremely common and part of the default file properties GUI in almost every media player, so that in particular should get special treatment. Even if the Vorbis and id3v2 specs don't mention it, the defacto standard is ALBUMARTIST for the comment tag and TPE2 for id3v2.)

I can try to whip something up if you like, I'm free tomorrow.

Last edited by foxyshadis; 17th January 2015 at 10:38.
foxyshadis is offline   Reply With Quote
Old 17th January 2015, 15:14   #1156  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
It's not as simple as that, I think. Any solution that is like "if we are going from file format A to file format B then let's do it like this, and if we are going from file format C to file format D then let's do it like that" is not really feasible in practice, because there are way to many possible combinations. Having to implement a special path for each possible combination is no good solution and is hardly extensible. Instead, what we need in practice are solutions that work from any file format to any file format. This, however, requires boiling things down to a "smallest common denominator". And then, of course, not every eccentricity of every file format can be retained. But that's an acceptable trade-off.

For example, the LAME encoder has a dedicated "--ta" switch to set the "artits" of the track. So if the original file had an "artist" tag, we certainly want to pass this via "--ta name" switch, and not via the generic "--tv key=value" switch (introduced with ID3v2.3). Now you could say that we have a few recognized tags that will be passed via dedicated switches and everything else is passed via the generic "--tv" switch. However, what if the original did not have an "artist" tag, but did have a "performer" tag instead? In this case we probably want to pass the value of the "performer" tag to the "--ta" switch, rather than the generic "--tv" switch! Thus, some "smart" mapping of the commonly used tags needs to be implemented.

But we don't want to re-implement this required mapping again and again in every single encoder class! Currently, the required mapping happens at one single point! And that's the FileAnalyzer class. After that, our internal data structure either has a value in its m_artist field, or not. That's a clean design. And the LameEncoder class does not need to care about file format eccentricities, e.g. whether the info originally had been called "artist", "performer" or whatever. LAME simply passes the value of m_artist to the "--ta" param. And that's it! Making the FileAnalyzer class "dumb", by having it dump everything into a Map, would require scattering the actual processing of metainfo among all the Encoder classes - bad code design, IMHO.
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 17th January 2015 at 15:37.
LoRd_MuldeR is offline   Reply With Quote
Old 17th January 2015, 19:10   #1157  |  Link
soneca
Registered User
 
Join Date: Feb 2008
Location: Brazil
Posts: 753
It would be very difficult to implement an access to a database to LameXP and thus choose from such information to this database?
soneca is offline   Reply With Quote
Old 17th January 2015, 22:19   #1158  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
Quote:
Originally Posted by soneca View Post
It would be very difficult to implement an access to a database to LameXP and thus choose from such information to this database?
You mean like Gracenote or FreeDB?

I haven't digged into this topic enough to give a definite answer. I would have to see what kind of API these services offer and whether we can use them 100% free of charges. Somehow they need to "analyze" the audio file in order to be able to determine the meta info. So, if their API requires access to the "raw" (uncompressed) audio data to do the required analysis, it probably wouldn't fit into LameXP. That's because LameXP doesn't actually decompress the input audio files until they are actually converted. And if they require the application to compute some kind of "fingerprint" which is then sent to the web-server for analysis, then it all would depend on how exactly that fingerprint has to be computed...
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊

Last edited by LoRd_MuldeR; 17th January 2015 at 22:23.
LoRd_MuldeR is offline   Reply With Quote
Old 18th January 2015, 01:19   #1159  |  Link
soneca
Registered User
 
Join Date: Feb 2008
Location: Brazil
Posts: 753
Quote:
Originally Posted by LoRd_MuldeR View Post
You mean like Gracenote or FreeDB?
That's it!
But not to analyze file by file, but the cd's as a whole, the commercial albums.
As the plugin (CTBD) of Cuetools for example.
soneca is offline   Reply With Quote
Old 25th January 2015, 19:14   #1160  |  Link
LoRd_MuldeR
Software Developer
 
LoRd_MuldeR's Avatar
 
Join Date: Jun 2005
Location: Last House on Slunk Street
Posts: 13,248
LameXP v4.11 Beta-14
http://sourceforge.net/projects/lame...4.exe/download

Quote:
Changes between v4.10 and v4.11 [unreleased]:
* Upgraded build environment to Microsoft Visual Studio 2013 with Update-4
* Starting with this version, LameXP is based on the MUtilities library + massive code clean-up
* Updated MediaInfo to v0.7.72 (2015-01-07), compiled with ICL 15.0 and MSVC 12.0
* Updated SoX to v14.4.2-Git (2012-10-06), compiled with ICL 15.0 and MSVC 12.0
* Updated Opus libraries to v1.1.x and Opus-Tools v0.1.9 to latest Git Master (2014-10-04)
* Updated mpg123 decoder to v1.21.0 (2014-10-11), compiled with GCC 4.9.1
* Updated Vorbis encoder to OggEnc v2.87 (2014-06-24), using libvorbis v1.3.4 and aoTuV b6.03_2014
* Updated Vorbis decoder to OggDec v1.10.1 (2014-06-25), using libVorbis v1.3.4
* Updated FLAC encoder/decoder to v1.3.1 (2014-11-26), compiled with ICL 15.0 and MSVC 12.0
* Updated GnuPG to v1.4.18 (2014-06-30), compiled with GCC 4.9.1
* Updated QAAC add-in to the latest to QAAC v2.44, including a fix for the --artwork option
* Fixed potential crash in Cue Sheet importer (occurred when all input files were missing)
* Fixed a severe performance bottleneck, especially with a large number of parallel instances
* Fixed a very rare problem that, occasionally, prevented the TEMP folder from being removed
* The limit for the maximum number of parallel instances has been increased to 32
* Experimental support for Windows 10 Technical Preview
__________________
Go to https://standforukraine.com/ to find legitimate Ukrainian Charities 🇺🇦✊
LoRd_MuldeR is offline   Reply With Quote
Reply

Tags
aac, aotuv, flac, lame, lamexp, mp3, mp4, ogg, oggenc, opus, vorbis

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 08:55.


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