The JUCE cross-platform C++ framework, with DISTRHO/KXStudio specific changes
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

143 lines
4.2KB

  1. /*
  2. ==============================================================================
  3. This file is part of the JUCE library.
  4. Copyright (c) 2015 - ROLI Ltd.
  5. Permission is granted to use this software under the terms of either:
  6. a) the GPL v2 (or any later version)
  7. b) the Affero GPL v3
  8. Details of these licenses can be found at: www.gnu.org/licenses
  9. JUCE is distributed in the hope that it will be useful, but WITHOUT ANY
  10. WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR
  11. A PARTICULAR PURPOSE. See the GNU General Public License for more details.
  12. ------------------------------------------------------------------------------
  13. To release a closed-source product which uses JUCE, commercial licenses are
  14. available: visit www.juce.com for more information.
  15. ==============================================================================
  16. */
  17. #ifdef JUCE_VIDEO_H_INCLUDED
  18. /* When you add this cpp file to your project, you mustn't include it in a file where you've
  19. already included any other headers - just put it inside a file on its own, possibly with your config
  20. flags preceding it, but don't include anything else. That also includes avoiding any automatic prefix
  21. header files that the compiler may be using.
  22. */
  23. #error "Incorrect use of JUCE cpp file"
  24. #endif
  25. #include "../juce_core/native/juce_BasicNativeHeaders.h"
  26. #include "../juce_gui_extra/juce_gui_extra.h"
  27. #include "juce_video.h"
  28. #if JUCE_MAC
  29. #if JUCE_QUICKTIME
  30. #define Point CarbonDummyPointName
  31. #define Component CarbonDummyCompName
  32. #import <QTKit/QTKit.h>
  33. #undef Point
  34. #undef Component
  35. #endif
  36. //==============================================================================
  37. #elif JUCE_WINDOWS
  38. #if JUCE_QUICKTIME
  39. /* If you've got an include error here, you probably need to install the QuickTime SDK and
  40. add its header directory to your include path.
  41. Alternatively, if you don't need any QuickTime services, just set the JUCE_QUICKTIME flag to 0.
  42. */
  43. #include <Movies.h>
  44. #include <QTML.h>
  45. #include <QuickTimeComponents.h>
  46. #include <MediaHandlers.h>
  47. #include <ImageCodec.h>
  48. /* If you've got QuickTime 7 installed, then these COM objects should be found in
  49. the "\Program Files\Quicktime" directory. You'll need to add this directory to
  50. your include search path to make these import statements work.
  51. */
  52. #import <QTOLibrary.dll>
  53. #import <QTOControl.dll>
  54. #if JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  55. #pragma comment (lib, "QTMLClient.lib")
  56. #endif
  57. #endif
  58. #if JUCE_USE_CAMERA || JUCE_DIRECTSHOW
  59. /* If you're using the camera classes, you'll need access to a few DirectShow headers.
  60. These files are provided in the normal Windows SDK. */
  61. #include <dshow.h>
  62. #include <dshowasf.h>
  63. #endif
  64. #if JUCE_DIRECTSHOW && JUCE_MEDIAFOUNDATION
  65. #include <evr.h>
  66. #endif
  67. #if JUCE_USE_CAMERA && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  68. #pragma comment (lib, "Strmiids.lib")
  69. #pragma comment (lib, "wmvcore.lib")
  70. #endif
  71. #if JUCE_MEDIAFOUNDATION && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  72. #pragma comment (lib, "mfuuid.lib")
  73. #endif
  74. #if JUCE_DIRECTSHOW && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  75. #pragma comment (lib, "strmiids.lib")
  76. #endif
  77. #endif
  78. //==============================================================================
  79. using namespace juce;
  80. namespace juce
  81. {
  82. #if JUCE_MAC || JUCE_IOS
  83. #include "../juce_core/native/juce_osx_ObjCHelpers.h"
  84. #if JUCE_USE_CAMERA
  85. #include "native/juce_mac_CameraDevice.mm"
  86. #endif
  87. #if JUCE_QUICKTIME
  88. #include "native/juce_mac_QuickTimeMovieComponent.mm"
  89. #endif
  90. #elif JUCE_WINDOWS
  91. #include "../juce_core/native/juce_win32_ComSmartPtr.h"
  92. #if JUCE_USE_CAMERA
  93. #include "native/juce_win32_CameraDevice.cpp"
  94. #endif
  95. #if JUCE_DIRECTSHOW
  96. #include "native/juce_win32_DirectShowComponent.cpp"
  97. #endif
  98. #if JUCE_QUICKTIME
  99. #include "native/juce_win32_QuickTimeMovieComponent.cpp"
  100. #endif
  101. #elif JUCE_LINUX
  102. #elif JUCE_ANDROID
  103. #if JUCE_USE_CAMERA
  104. #include "native/juce_android_CameraDevice.cpp"
  105. #endif
  106. #endif
  107. #if JUCE_USE_CAMERA
  108. #include "capture/juce_CameraDevice.cpp"
  109. #endif
  110. }