All times are UTC+02:00




Post new topic  Reply to topic  [ 4 posts ] 
Author Message
PostPosted: Fri Jun 28, 2024 10:27 am 

Joined: Tue May 21, 2024 4:14 pm
Posts: 5
im using DLL and .so for cross compiled project, is there a way to get specific callbacks when settings change? like a subscribtion or something? for example i have the ability to bypass the processor from within my application however if a user logs into the web-interface and re-enables i want to be able to receive an event rather then poll.

is this possible? i do see this

// stereoTool_SetCallback
// Sets up a callback for specific situations.
// Customer specific. Ask if you need us to add a callback for some situation.


Top
   
PostPosted: Sat Jun 29, 2024 11:41 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11257
Hm. Not yet.... You could periodically poll the values that you're interested in, but there's no callback (yet).

What are you planning to do with it? Convince us that this is useful and we'll add it :)


Top
   
PostPosted: Sun Jun 30, 2024 8:08 am 

Joined: Tue May 21, 2024 4:14 pm
Posts: 5
thanks hans

given i'm only looking for two parameters (bypass and valid licence) I've opted for a poll.

Next question, I need a way to inform the user to save the preset so when if my application restarts i can load the correct preset.

the current workflow is
1. user adds encoder instance to our application
2. user can add stereo tool processing, it initially starts without licence.
3. user applies licence through our web interface and the object is recreated with the licence
4. user can access stereotool webinterface from within an iframe or direct via new a tab.

its at this point where i need to way to detect that the user has changed the processing parameters and save the preset.

any thoughts on how i might achieve this? i was thinking i can just save the preset on a periodic timer, but would don't really want to.

is there a parameter i can read which says that the processing parameters have changed? or that the webinterface is currently being accessed? i could atleast assume that if the web interface is being accessed then i should save the preset every X seconds.

thanks


Top
   
PostPosted: Mon Jul 01, 2024 4:21 pm 
Site Admin
User avatar

Joined: Mon Mar 17, 2008 1:40 am
Posts: 11257
We actually do something like that internally: If settings are changed, a flag is set, and after 30 seconds the preset is saved (to avoid saving all the time). The save is done to the .ini file; the .ini file name is the name of the DLL with .dll replaced by .ini (or .so or .dylib replaced by .rc, on Linux or Mac). If you make sure that each instance loads a differently named .dll, then each instance will have its own .ini file.

There's currently no indicator that settings have been changed. A workaround for now (if you want to save the settings yourself as well) would be to check if the .ini file date/time changes. But that's of course pretty hacky....


Top
   
Display posts from previous:  Sort by  
Post new topic  Reply to topic  [ 4 posts ] 

All times are UTC+02:00


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
Powered by phpBB® Forum Software © phpBB Limited