{"action":"created","issue":{"url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/103","labels_url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/103/labels{/name}","comments_url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/103/comments","events_url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/103/events","html_url":"https://github.com/Mindwerks/wildmidi/issues/103","id":42979888,"number":103,"title":"too quiet, need louder volume levels.","user":{"login":"chrisisonwildcode","id":6725242,"avatar_url":"https://avatars.githubusercontent.com/u/6725242?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisisonwildcode","html_url":"https://github.com/chrisisonwildcode","followers_url":"https://api.github.com/users/chrisisonwildcode/followers","following_url":"https://api.github.com/users/chrisisonwildcode/following{/other_user}","gists_url":"https://api.github.com/users/chrisisonwildcode/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisisonwildcode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisisonwildcode/subscriptions","organizations_url":"https://api.github.com/users/chrisisonwildcode/orgs","repos_url":"https://api.github.com/users/chrisisonwildcode/repos","events_url":"https://api.github.com/users/chrisisonwildcode/events{/privacy}","received_events_url":"https://api.github.com/users/chrisisonwildcode/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/Mindwerks/wildmidi/labels/enhancement","name":"enhancement","color":"84b6eb"},{"url":"https://api.github.com/repos/Mindwerks/wildmidi/labels/question","name":"question","color":"cc317c"}],"state":"open","locked":false,"assignee":{"login":"chrisisonwildcode","id":6725242,"avatar_url":"https://avatars.githubusercontent.com/u/6725242?v=3","gravatar_id":"","url":"https://api.github.com/users/chrisisonwildcode","html_url":"https://github.com/chrisisonwildcode","followers_url":"https://api.github.com/users/chrisisonwildcode/followers","following_url":"https://api.github.com/users/chrisisonwildcode/following{/other_user}","gists_url":"https://api.github.com/users/chrisisonwildcode/gists{/gist_id}","starred_url":"https://api.github.com/users/chrisisonwildcode/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chrisisonwildcode/subscriptions","organizations_url":"https://api.github.com/users/chrisisonwildcode/orgs","repos_url":"https://api.github.com/users/chrisisonwildcode/repos","events_url":"https://api.github.com/users/chrisisonwildcode/events{/privacy}","received_events_url":"https://api.github.com/users/chrisisonwildcode/received_events","type":"User","site_admin":false},"milestone":{"url":"https://api.github.com/repos/Mindwerks/wildmidi/milestones/2","labels_url":"https://api.github.com/repos/Mindwerks/wildmidi/milestones/2/labels","id":532400,"number":2,"title":"0.4 - Now with more support!","description":"The goal here is to expand WildMIDI's capabilities in terms of file support.","creator":{"login":"psi29a","id":1122069,"avatar_url":"https://avatars.githubusercontent.com/u/1122069?v=3","gravatar_id":"","url":"https://api.github.com/users/psi29a","html_url":"https://github.com/psi29a","followers_url":"https://api.github.com/users/psi29a/followers","following_url":"https://api.github.com/users/psi29a/following{/other_user}","gists_url":"https://api.github.com/users/psi29a/gists{/gist_id}","starred_url":"https://api.github.com/users/psi29a/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/psi29a/subscriptions","organizations_url":"https://api.github.com/users/psi29a/orgs","repos_url":"https://api.github.com/users/psi29a/repos","events_url":"https://api.github.com/users/psi29a/events{/privacy}","received_events_url":"https://api.github.com/users/psi29a/received_events","type":"User","site_admin":false},"open_issues":7,"closed_issues":36,"state":"open","created_at":"2014-01-10T11:54:07Z","updated_at":"2015-01-04T13:39:14Z","due_on":null,"closed_at":null},"comments":17,"created_at":"2014-09-17T08:36:00Z","updated_at":"2015-01-04T18:03:04Z","closed_at":null,"body":"I write this to help think out loud so that others may know my thinking.\r\n\r\n\r\nI propose a different approach that will dynamically adjust the volume within a very short amount of time (hardly noticeable to our ears) that will result in no need for clamping. The proper term is call \"Look ahead brick wall limiter\". In WildMIDI the implementation would not be exact due to dealing with small chunks of audio data at a time but this is how I propose it works.\r\n\r\nmix everything as per normal in the core of the lib. But instead of at the end going through and clamping the values, call a function that will then do the following:\r\n\r\n1) check to see if next peak/trough is outside limits. If so set a variable that says the goal of how much we need to adjust the volume level of that peak/trough, otherwise unset the volume adjust level.\r\n\r\n2a) if volume adjust level is set, and is not equal to the goal, adjust the level towards the goal so we reach our goal volume adjust level within 0.002 seconds of being first detected.\r\n\r\n2b) if however we don't need to adjust the volume but we are still recovering from a previous volume adjust, alter the volume enough so overall it returns to normal within 0.004 seconds.\r\n\r\n3) adjust volume of level (if needed)\r\n\r\n4) at the end of processing the sample chunk store in the MDI struct the volume adjust level and goal.\r\n\r\nIn a nut shell what we will be trying to do is to compress (not clamp) audio signals that go outside of the storage limits. This would result in better quality output.\r\n\r\nDownsides:\r\n- either end of the audio chunks being processed might create clicks under certain conditions. Will have to look at a way to limit that possibility.\r\n- slightly longer processing times (especially when some of the task may require conversion to doubles)\r\n- louder than any of our previous releases\r\n- some distortion may occur do to reshaping of the signal, but until I am ready to test I am unsure. This is especially so on the ends of the audio chunk being processed.\r\n\r\nI will put together a function to demonstrate this better and throw it into wildmidi-updates.\r\n"},"comment":{"url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/comments/68642140","html_url":"https://github.com/Mindwerks/wildmidi/issues/103#issuecomment-68642140","issue_url":"https://api.github.com/repos/Mindwerks/wildmidi/issues/103","id":68642140,"user":{"login":"psi29a","id":1122069,"avatar_url":"https://avatars.githubusercontent.com/u/1122069?v=3","gravatar_id":"","url":"https://api.github.com/users/psi29a","html_url":"https://github.com/psi29a","followers_url":"https://api.github.com/users/psi29a/followers","following_url":"https://api.github.com/users/psi29a/following{/other_user}","gists_url":"https://api.github.com/users/psi29a/gists{/gist_id}","starred_url":"https://api.github.com/users/psi29a/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/psi29a/subscriptions","organizations_url":"https://api.github.com/users/psi29a/orgs","repos_url":"https://api.github.com/users/psi29a/repos","events_url":"https://api.github.com/users/psi29a/events{/privacy}","received_events_url":"https://api.github.com/users/psi29a/received_events","type":"User","site_admin":false},"created_at":"2015-01-04T18:03:04Z","updated_at":"2015-01-04T18:03:04Z","body":"I do notice the volume, but I'm no audiophile... shitty laptop speakers. ;) I think it is good here."}}