1
0
Fork 0
mirror of https://github.com/juce-framework/JUCE.git synced 2026-01-10 23:44:24 +00:00

Added Inter-App Audio capabilities to standalone plug-ins

This commit is contained in:
tpoole 2017-03-01 11:55:39 +00:00
parent 00f57d43c5
commit 4c59a920b4
80 changed files with 2949 additions and 163 deletions

View file

@ -223,13 +223,23 @@ bool JPEGImageFormat::usesFileExtension (const File& f) { return f.hasFileExte
bool JPEGImageFormat::canUnderstand (InputStream& in)
{
const int bytesNeeded = 10;
const int bytesNeeded = 24;
uint8 header [bytesNeeded];
return in.read (header, bytesNeeded) == bytesNeeded
if (in.read (header, bytesNeeded) == bytesNeeded
&& header[0] == 0xff
&& header[1] == 0xd8
&& header[2] == 0xff;
&& header[2] == 0xff)
return true;
#if JUCE_USING_COREIMAGE_LOADER
return header[20] == 'j'
&& header[21] == 'p'
&& header[22] == '2'
&& header[23] == ' ';
#endif
return false;
}
#if JUCE_USING_COREIMAGE_LOADER