Giter Site home page Giter Site logo

zekrom-vale / bright-youtube Goto Github PK

View Code? Open in Web Editor NEW
0.0 1.0 0.0 64.14 MB

Automatically adjusts ANY HTML5 video's brightness

Home Page: https://www.youtube.com

JavaScript 53.43% CSS 5.70% HTML 40.87%
auto brightness-level brightness js chrome youtube extention chrome-extension canvas dynamic

bright-youtube's People

Contributors

zekrom-vale avatar

Watchers

 avatar

bright-youtube's Issues

Custom functions

I will need to limit it to only code and basic functions.

// for future custom function support
function tick(ic){
	var V= oldRgb*(1-ic) + rgb*ic;
	var Sandbox= new Components.utils.Sandbox('sandbox.js');
	Sandbox.V= V;
	var dat= Components.utils.evalInSandbox(text, Sandbox, latest, 'sandbox.js');
	setFilter(dat.bright, dat.invert, dat.con, dat.sat);
}

function formula(V){
	return {'bright': bright, 'invert': invert, 'con': con, 'sat': sat};
}

more at https://developer.mozilla.org/en-US/docs/Mozilla/Tech/XPCOM/Language_Bindings/Components.utils.evalInSandbox

Better youtube button

tried this

	const box= document.createElement('span'),
	lbl= document.createElement('label'),
	opt= document.createElement('input'),
	slider= document.createElement('div'),
	name= document.createElement('span');
box.class= 'box';
lbl.class= 'switch';
opt.type= "checkbox";
opt.id= 'Brt-opt';
slider.class= 'slider round';
name.class= 'name';
	box.appendChild(lbl);
	box.appendChild(name);
	lbl.appendChild(opt);
	lbl.appendChild(slider);

/* const opt= document.createElement('input');
opt.type= 'checkbox' */
opt.checked= items.Active;
opt.id= 'Brt-opt';
document.getElementById('menu-container').appendChild(box);

More site options

  • beam
  • Mixer
  • dailymotion
  • hulu
  • vimeo
  • liveleak
  • break
  • netflix
  • vine
  • yahoo
  • viewster
  • .tv
  • vevo
  • veoh
    *Assuming that they use html5 video tag.

Add twitch support

This might involve rearranging the functions and adding new js files as I might need to have a diferent script run.

Pixelated Youtube

I have narrowed it down to function getAvColor(img) and context.drawImage(img, 0, 0);

I even tried disabling hardware acceleration. Any info would help!

Not 100% active

Sometimes the extension does not activate, possibly because the delay is too low.

Enhancer For Youtube, not reading size!

body.enhancer-for-youtube-pinned-player._400x225 #movie_player:not(.ytp-fullscreen), 
body.enhancer-for-youtube-pinned-player._400x225 #movie_player:not(.ytp-fullscreen) video.html5-main-video, 
body.enhancer-for-youtube-wide-player.enhancer-for-youtube-pinned-player._400x225 #movie_player:not(.ytp-fullscreen) video.html5-main-video, 
body.enhancer-for-youtube-pinned-player._400x225 #movie_player:not(.ytp-fullscreen) .ytp-iv-video-content, 
body.enhancer-for-youtube-wide-player.enhancer-for-youtube-pinned-player._400x225 #movie_player:not(.ytp-fullscreen) .ytp-iv-video-content {
    height: 225px !important;
    width: 400px !important;
}

clearInterval sometimes fails

function onPause(){
	clearInterval(clock);//Sometimes fails
	toggle(false);
}

clock is global
I have redundant clearInterval, and I have no idea why it fails!

Canvas alternative

Is there a way to get the average color without canvas? Because canvas is slow and resorse intensive.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.