Grabbing color palette from YouTube thumbnail
问题 I'm trying to grab the color palette from YouTube thumbnails, to better blend the YouTube video with a whole website design, and I'm wondering if there is any way of doing this? I've tried using color-thief (https://github.com/lokesh/color-thief) and this code (with no luck): var img = new Image(); img.onload = function () { var colorThief = new ColorThief(); colorThief.getColor(img); }; img.crossOrigin = 'Anonymous'; img.src = 'http://img.youtube.com/vi/NuEfvIca0XU/mqdefault.jpg From this I