home
products
contribute
download
documentation
forum
Home
Forums
New posts
Search forums
What's new
New posts
All posts
Latest activity
Members
Registered members
Current visitors
Donate
Log in
Register
What's new
Search
Search
Search titles only
By:
New posts
Search forums
Search titles only
By:
Menu
Log in
Register
Navigation
Install the app
Install
More options
Contact us
Close Menu
Forums
HTPC Projects
Hardware
Ambient Lighting System
AtmoLight - 1.18.6.0 [2016-09-21]
Contact us
RSS
JavaScript is disabled. For a better experience, please enable JavaScript in your browser before proceeding.
You are using an out of date browser. It may not display this or other websites correctly.
You should upgrade or use an
alternative browser
.
Reply to thread
Message
<blockquote data-quote="Lightning303" data-source="post: 1086412" data-attributes="member: 97876"><p>Thanks,</p><p>i looked at your code and tested it. BUt as far as i can see it does the same as MediaPortals method is doing. The difference is that your scale is linear and the one from MediaPortal is logorithmic, also your values have higher values, but the resolution stays the same.</p><p>To get a better feel for it, i made yours logorithmic aswell an plotted both in a graph.</p><p>The blue dots represent the MP method and my approach, the red dots yours.</p><p>Note that i added 80 to MP values to get it nicely in the graph, this only moves the graph on the axis but does not influence the information of the values.</p><p></p><p>[ATTACH=full]151591[/ATTACH] </p><p></p><p>Code i used:</p><p></p><p>[CODE=C#] Bitmap bassFan = new Bitmap(1000, 128);</p><p> Graphics bassFanGFX = Graphics.FromImage(bassFan);</p><p> int i = 0;</p><p></p><p>...</p><p></p><p> if (i < 1000)</p><p> {</p><p> bassFanGFX.FillRectangle(new SolidBrush(Color.Blue), i, (int)(dbLevel[0]+80), 1, 1);</p><p> bassFanGFX.FillRectangle(new SolidBrush(Color.Red), i, (int)(20 * Math.Log10(Lpeak)), 1, 1);</p><p> i++;</p><p> }</p><p> else</p><p> {</p><p> bassFan.Save("C:\\ProgramData\\Team MediaPortal\\MediaPortal\\vumetergraph.bmp");</p><p> }[/CODE]</p><p></p><p>Again, thanks for your help and time, but i dont see any real difference here.</p></blockquote><p></p>
[QUOTE="Lightning303, post: 1086412, member: 97876"] Thanks, i looked at your code and tested it. BUt as far as i can see it does the same as MediaPortals method is doing. The difference is that your scale is linear and the one from MediaPortal is logorithmic, also your values have higher values, but the resolution stays the same. To get a better feel for it, i made yours logorithmic aswell an plotted both in a graph. The blue dots represent the MP method and my approach, the red dots yours. Note that i added 80 to MP values to get it nicely in the graph, this only moves the graph on the axis but does not influence the information of the values. [ATTACH=full]151591[/ATTACH] Code i used: [CODE=C#] Bitmap bassFan = new Bitmap(1000, 128); Graphics bassFanGFX = Graphics.FromImage(bassFan); int i = 0; ... if (i < 1000) { bassFanGFX.FillRectangle(new SolidBrush(Color.Blue), i, (int)(dbLevel[0]+80), 1, 1); bassFanGFX.FillRectangle(new SolidBrush(Color.Red), i, (int)(20 * Math.Log10(Lpeak)), 1, 1); i++; } else { bassFan.Save("C:\\ProgramData\\Team MediaPortal\\MediaPortal\\vumetergraph.bmp"); }[/CODE] Again, thanks for your help and time, but i dont see any real difference here. [/QUOTE]
Insert quotes…
Verification
Post reply
Forums
HTPC Projects
Hardware
Ambient Lighting System
AtmoLight - 1.18.6.0 [2016-09-21]
Contact us
RSS
Top
Bottom