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.

139 lines
4.1KB

  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. #define JUCE_CORE_INCLUDE_OBJC_HELPERS 1
  26. #define JUCE_CORE_INCLUDE_COM_SMART_PTR 1
  27. #define JUCE_CORE_INCLUDE_NATIVE_HEADERS 1
  28. #include "../juce_gui_extra/juce_gui_extra.h"
  29. #include "juce_video.h"
  30. #if JUCE_MAC
  31. #if JUCE_QUICKTIME
  32. #import <QTKit/QTKit.h>
  33. #endif
  34. //==============================================================================
  35. #elif JUCE_WINDOWS
  36. #if JUCE_QUICKTIME
  37. /* If you've got an include error here, you probably need to install the QuickTime SDK and
  38. add its header directory to your include path.
  39. Alternatively, if you don't need any QuickTime services, just set the JUCE_QUICKTIME flag to 0.
  40. */
  41. #include <Movies.h>
  42. #include <QTML.h>
  43. #include <QuickTimeComponents.h>
  44. #include <MediaHandlers.h>
  45. #include <ImageCodec.h>
  46. /* If you've got QuickTime 7 installed, then these COM objects should be found in
  47. the "\Program Files\Quicktime" directory. You'll need to add this directory to
  48. your include search path to make these import statements work.
  49. */
  50. #import <QTOLibrary.dll>
  51. #import <QTOControl.dll>
  52. #if JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  53. #pragma comment (lib, "QTMLClient.lib")
  54. #endif
  55. #endif
  56. #if JUCE_USE_CAMERA || JUCE_DIRECTSHOW
  57. /* If you're using the camera classes, you'll need access to a few DirectShow headers.
  58. These files are provided in the normal Windows SDK. */
  59. #include <dshow.h>
  60. #include <dshowasf.h>
  61. #endif
  62. #if JUCE_DIRECTSHOW && JUCE_MEDIAFOUNDATION
  63. #include <evr.h>
  64. #endif
  65. #if JUCE_USE_CAMERA && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  66. #pragma comment (lib, "Strmiids.lib")
  67. #pragma comment (lib, "wmvcore.lib")
  68. #endif
  69. #if JUCE_MEDIAFOUNDATION && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  70. #pragma comment (lib, "mfuuid.lib")
  71. #endif
  72. #if JUCE_DIRECTSHOW && JUCE_MSVC && ! JUCE_DONT_AUTOLINK_TO_WIN32_LIBRARIES
  73. #pragma comment (lib, "strmiids.lib")
  74. #endif
  75. #endif
  76. //==============================================================================
  77. using namespace juce;
  78. namespace juce
  79. {
  80. #if JUCE_MAC || JUCE_IOS
  81. #if JUCE_USE_CAMERA
  82. #include "native/juce_mac_CameraDevice.mm"
  83. #endif
  84. #if JUCE_QUICKTIME
  85. #include "native/juce_mac_QuickTimeMovieComponent.mm"
  86. #endif
  87. #elif JUCE_WINDOWS
  88. #if JUCE_USE_CAMERA
  89. #include "native/juce_win32_CameraDevice.cpp"
  90. #endif
  91. #if JUCE_DIRECTSHOW
  92. #include "native/juce_win32_DirectShowComponent.cpp"
  93. #endif
  94. #if JUCE_QUICKTIME
  95. #include "native/juce_win32_QuickTimeMovieComponent.cpp"
  96. #endif
  97. #elif JUCE_LINUX
  98. #elif JUCE_ANDROID
  99. #if JUCE_USE_CAMERA
  100. #include "native/juce_android_CameraDevice.cpp"
  101. #endif
  102. #endif
  103. #if JUCE_USE_CAMERA
  104. #include "capture/juce_CameraDevice.cpp"
  105. #endif
  106. }