Lines Matching refs:bitrate
66 function BitrateColor($bitrate, $BitrateMaxScale=768) { argument
70 $bitrate *= (256 / $BitrateMaxScale); // scale from 1-[768]kbps to 1-256
71 $bitrate = round(min(max($bitrate, 1), 256));
72 $bitrate--; // scale from 1-256kbps to 0-255kbps
74 $Rcomponent = max(255 - ($bitrate * 2), 0);
75 $Gcomponent = max(($bitrate * 2) - 255, 0);
76 if ($bitrate > 127) {
77 $Bcomponent = max((255 - $bitrate) * 2, 0);
79 $Bcomponent = max($bitrate * 2, 0);
84 function BitrateText($bitrate, $decimals=0) { argument
85 …return '<span style="color: #'.BitrateColor($bitrate).'">'.number_format($bitrate, $decimals).' kb…