I am trying to capture tab by function
chrome.tabs.captureVisibleTab(..)
on my chrome extension on Mac OS X version 10.6.8 and Chrome version 19.0.1084.53 it works fine for google and other sites but does not capture tab for Youtube.com or from any tab which contains flash player embedded.
Captured tab from youtube.com appears black and no content is visible.
Below is my code –
background.html contains
..
chrome.browserAction.onClicked.addListener(function (tab) {
images = [];
chrome.windows.getCurrent(function (win) {
chrome.tabs.captureVisibleTab(win.id, { "format": "png" }, function (imgUrl) {
chrome.tabs.create({ url: imgUrl });
});
});
});
..
manifest.json contains
{
"name": "Moon",
"version": "1.0",
"manifest_version": 1,
"background_page": "background.html",
"description": "Moon",
"browser_action": {
"default_icon": "icon.png"
},
"permissions": [
"tabs"
,"<all_urls>"
]
}
This is a Chrome bug with no known workaround.