Confirmed users, Bureaucrats and Sysops emeriti
1,680
edits
m (moved Plugins:DrawImageModel to NPAPI:DrawImage) |
No edit summary |
||
| Line 64: | Line 64: | ||
} NPImageData; | } NPImageData; | ||
= NPImageFormat | = NPImageFormat Type Negotiation = | ||
* NPNVSupportedImageFormats (NPNVariable = ?) | |||
* NPPVImageFormat (NPPVariable = ?) | |||
Negotiating the image format will work similarly to [[NPAPI:Models|drawing and event model negotiation]], but the value of NPNVsupportsImageFormat will be a bitmap of supported types. Based on the browser's supported formats, the plugin should select a format. | |||
NPImageFormat supportedFormats; | |||
NPImageFormat | browserFuncs->getvalue(instance, NPNVsupportsImageFormat, &supportedFormats); | ||
... | |||
browserFuncs->setvalue(instance, NPPVImageFormat, (void*)selectedFormat); | |||