WriteConfigurationToPreferences() doesn't save

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

afriza

  • Posts: 3
  • Joined: Fri May 15, 2020 4:10 am
  • Real Name: Afriza N. Arief

WriteConfigurationToPreferences() doesn't save

PostFri May 15, 2020 4:45 am

Hi,

I tried to write a program that prints the current bmdDeckLinkConfigVideoInputConversionMode and change it and then exit directly.

Code: Select all
result = deckLinkConfiguration->SetInt(bmdDeckLinkConfigVideoInputConversionMode, videoInputConversion);


after it returns S_OK, I tried to call

Code: Select all
result = deckLinkConfiguration->WriteConfigurationToPreferences();


followed directly by

Code: Select all
deckLinkConfiguration->Release();


however around once every two times the program is run, it doesn't actually change the preferences even though SetInt() and WriteConfigurationToPreferences() returns S_OK..

Is there any special handling that needs to be done?

The code is available at https://github.com/afriza/decklink-adapter
Offline

Cameron Nichols

Blackmagic Design

  • Posts: 443
  • Joined: Mon Sep 04, 2017 4:05 am

Re: WriteConfigurationToPreferences() doesn't save

PostFri May 22, 2020 2:53 am

Hi Afriza,

Thanks for providing your code sample, we will resolve issue in a future release. As an interim workaround, you could add delay between IDeckLinkConfiguration::WriteConfigurationToPreferences() and IDeckLinkConfiguration::Release(). I added call to std::this_thread::sleep_for() with success.

Regards
Cameron

Return to Software Developers

Who is online

Users browsing this forum: No registered users and 11 guests