Leah Sapan
Leah Sapan

Reputation: 3791

Chrome Plugin - Generate PNG/JPG from portion of window

Is it possible to generate a screen capture from a portion of the page using a Google Chrome plugin?

Taking it one step further, is it possible to take multiple of these and generate a PDF or PPT from them?

Ideally my vision is that a user will be able to click a button on the page (and if they have the plugin), it will let them export a visual to PNG, etc.

Upvotes: 0

Views: 1125

Answers (1)

Xan
Xan

Reputation: 77541

It is possible to capture a currently open tab with Chrome extension API:

chrome.tabs.captureVisibleTab(integer windowId, object options, function callback)

Captures the visible area of the currently active tab in the specified window.

If you need to capture the whole page, there are plenty of extensions that scroll the page, taking screenshots, and then combine the images. Exapmle: Full Page Screen Capture

Generating a PDF/PPT out of that is too broad for the scope of the question.

Upvotes: 2

Related Questions