Philipp,
It looks like audio/wav should work in the latest version of any browser except Internet Explorer just by registering the existing audio previewer for that mime type. That’s a change since we first created them, so I’ll go ahead and add it to the default set in the README file on github. You should just be able to change the mimetype in the existing example and run that locally (rather than wait for me).
In general (since we’re on the community list), the question of ‘can you preview format X’ involves a few things:
· Whether a way to view that type in a browser exists somewhere (or can be built),
· Whether someone has made the small wrapper required to launch it as a previewer from Dataverse (or can do so),
· Whether you have registered the tool for that mimetype in your instance
In Tromso, I was showing how easy the second step is. The first step is the potentially difficult one. Many of the existing previewers leverage the basic support built into HTML5 (image, video, audio formats). PDF support leverages an externally developed previewer. The others involve some custom code that calls existing libraries (i.e. the text/html previewers filter scripts and potentially malicious tags via a library, the table previewer configures an underlying tabular display library).
The last step is basically a policy question at your installation which seems straight forward (to preview or not) but can be complicated due to the limitations of the underlying previewer. In the case of audio, support for all the formats varies by browser (see https://en.wikipedia.org/wiki/HTML5_audio for example) and by the browser version and in some cases on whether they have a given extension/plug-in. Further, some previewers have limitations/bugs – I think I’ve seen rewind not work on some video types, there are probably text/html/tabular files that display but may not look like the original (e.g. the html previewer won’t allow javascript to run and that may be part of the display). If your installation has many files in these categories, or you have more users on browsers that don’t support some mimetypes well, you may not want to register those previewers for the involved mimetypes. (Or you may want to send an issue or pull request to the previewers repository that identifies and/or fixes the issue! (or that adds messaging – e.g. “This format not supported in IE – try another browser to preview this file”))
My basic advice is that, if you’ve seen a file viewable in some website, it shouldn’t be hard to get a preview in Dataverse (unless there’s a licensing issue) – possible something that could be done in limited time at a hack-a-thon. If the preview involves multiple files or the file isn’t really in a website but the entire website is a custom tool, it’s still possible but more work (Dataverse now supports tools at the Dataset level which would help if multiple files are involved). And if there’s no example to start from, you can probably still build one if you/someone knows the details of the file format.
Cheers,
-- Jim
--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to
dataverse-commu...@googlegroups.com.
To view this discussion on the web visit
https://groups.google.com/d/msgid/dataverse-community/18d464de-1ccb-4706-a9f0-353bb7d36841%40googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dataverse-community/BL0PR07MB3921DF9BAB135B51961F4D06BFE50%40BL0PR07MB3921.namprd07.prod.outlook.com.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dataverse-community/18d464de-1ccb-4706-a9f0-353bb7d36841%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Dataverse Users Community" group.
To unsubscribe from this group and stop receiving emails from it, send an email to dataverse-community+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/dataverse-community/BL0PR07MB3921DF9BAB135B51961F4D06BFE50%40BL0PR07MB3921.namprd07.prod.outlook.com.