Four demonstrations showing a glimpse of Scilab's potential with music. Simply run the attached scripts, they will dipslay GUIs. Requires Scilab 6.0.0 or above.
Upload date : 2017-06-22 11:39:28 MD5 : 4e61d8b2a4b92f9d4daa1f6dc41865c7 SHA1 : 217b33b619560dd0008f883eafafb374a6026175 Downloads : 203
Hello Paul, I had a try with the slider, but it bugs and blocks. This is due to a misuse of get() in slider_update() and in play(): get() is built to get the value of a given property from a given (or current) object. It does not aim to get the handle of an object according the value of one of its properties. This is the findobj() role. When in both functions findobj() is properly used instead of get(), all becomes OK: function y = slider_update(x) //sl = get("slider"); // NOK sl = findobj("tag","slider"); value = get(sl, "value"); // OK ... function play(y, rate) updateStatusBar(" Playing the sound..."); //sl = get("slider"); // NOK sl = findobj("tag", "slider"); I guess the same fix shall be applied to other scripts. Regards Samuel
> I had a try with the slider, but it bugs and blocks. Hi Samuel, "exec demo_slider.exe;" works well for me, I can't find bugs or blockings, can you please provide the version of Scilab & your OS? Regards, Paul
Hello Paul, > > I had a try with the slider, but it bugs and blocks. > > Hi Samuel, > "exec demo_slider.exe;" works well for me, I can't find bugs or blockings, > can you please provide the version of Scilab & your OS? I tried with 6.0.0 and 6.0.x NB 64 bits on Win7, since you specify "Requires Scilab 6.0.0 or above". It works for a short series of updates, and then blocks, and even sometimes crashes (mainly when dragging the slider instead of clicking on a side). Then, just after closing the slider widget, the following error message is displayed, apparently as many times as there were uneffective updates (clicks) before closing: get : Type erroné de l'argument n°1 : Un réel attendu. à la ligne 3 de la fonction slider_update ( C:\Users\Samuel\Desktop\Musical_demos6\demo_slider.sce ligne 62 ) A very strange message, since no syntax with argin#1 as a real is documented for get(). Moreover, the syntax h = get("handlePath") is not documented. But after some additional tests to go on the discussion http://mailinglists.scilab.org/Users-fr-findobj-tt4036787.html, it actually works. I have reported the lack of doc: http://bugzilla.scilab.org/15226. Regards Samuel
> get : Type erroné de l'argument n°1 : Un réel attendu. > à la ligne 3 de la fonction slider_update ( > C:\Users\Samuel\Desktop\Musical_demos6\demo_slider.sce ligne 62 ) > > A very strange message, since no syntax with argin#1 as a real is documented for get(). The only accepted number is 0, to target the console.
This comment has been deleted.
https://www.thinkcentral.online/