CreateOpenGLScreenPreviewHelper in Mac

Ask software engineering and SDK questions for developers working on Mac OS X, Windows or Linux.
  • Author
  • Message
Offline

Gabriel Solsona

  • Posts: 11
  • Joined: Tue Dec 04, 2012 10:16 pm

CreateOpenGLScreenPreviewHelper in Mac

PostMon May 02, 2016 9:49 am

Hi Software Developers Admins,

I would like to ask if CreateOpenGLScreenPreviewHelper can be used in Mac environment. I have not seen any example in the SDK. Also, I have tries to compile an app working on Windows (with COM) but it does not compile in XCode. Here, it is the excerpt of such error:

Code: Select all
Undefined symbols for architecture x86_64:
  "_CreateOpenGLScreenPreviewHelper", referenced from:
      juce::OpenGL_Generator::CreateContext() in JUCE_DeckLink_OpenGL_Component.o
ld: symbol(s) not found for architecture x86_64


I will appreciate any help about that.
Thank you in advance,
Gabriel Solsona
Offline

Nicholas Gill

Blackmagic Design

  • Posts: 169
  • Joined: Mon May 04, 2015 10:28 pm

Re: CreateOpenGLScreenPreviewHelper in Mac

PostWed May 04, 2016 2:48 am

Hi Gabriel,

I can confirm that it is possible to use the IDeckLinkGLScreenPreviewHelper[1] interface on Mac as on Windows and Linux.

Regarding the error message mentioned, the linker has identified a declaration with a missing definition, _CreateOpenGLScreenPreviewHelper. This is not a DeckLinkAPI symbol (note the leading underscore), perhaps it is a typo, or an application specific function used to wrap CoCreateInstance on Windows.

The DeckLinkAPI function used to create an IDeckLinkGLScreenPreviewHelper instance on platforms not natively supporting COM (i.e. Mac and Linux) is CreateOpenGLScreenPreviewHelper.

Cheers,

-nick

[1] 2.5.23 IDeckLinkGLScreenPreviewHelper Interface
Offline

Gabriel Solsona

  • Posts: 11
  • Joined: Tue Dec 04, 2012 10:16 pm

Re: CreateOpenGLScreenPreviewHelper in Mac

PostWed May 04, 2016 5:18 pm

Hi Nicholas,

Thank you for your quick answer.

Yes, I know that CreateOpenGLScreenPreviewHelper() is used only for Mac and Linux platforms. In fact, this is the code excerpt that uses this function:

Code: Select all
    // Create the DeckLink screen preview helper
#ifdef JUCE_WINDOWS
    if (CoCreateInstance(CLSID_CDeckLinkGLScreenPreviewHelper, NULL, CLSCTX_ALL, IID_IDeckLinkGLScreenPreviewHelper, (void**)&m_deckLinkScreenPreviewHelper) != S_OK)
#elif JUCE_LINUX || JUCE_MAC
    m_deckLinkScreenPreviewHelper=CreateOpenGLScreenPreviewHelper();
    if (nullptr==m_deckLinkScreenPreviewHelper)
#endif

Nevertheless, for me is clarifying that BMD SDK has implemented such function in OSX. You know, when something fails again and again, one gets doubts about everything around.

I'll go further in this issue on my side,

Gabriel Solsona
Offline

Nicholas Gill

Blackmagic Design

  • Posts: 169
  • Joined: Mon May 04, 2015 10:28 pm

Re: CreateOpenGLScreenPreviewHelper in Mac

PostWed May 04, 2016 9:59 pm

Hi Gabriel,

If _CreateOpenGLScreenPreviewHelper is a typo and refers to CreateOpenGLScreenPreviewHelper this symbol is defined in DeckLinkAPIDispatch.cpp, perhaps check to ensure that this file is included in the build for your project.

Hope that helps,

-nick

Return to Software Developers

Who is online

Users browsing this forum: No registered users and 9 guests