Jump to content


Photo

(Solved) Shuffle phrase ??

Scripting shuffle value ..How

  • Please log in to reply
9 replies to this topic

#1 Circe

Circe

    Advanced Member

  • Normal Members
  • PipPipPip
  • 90 posts
  • Gender:Male
  • Location:Spain
  • Interests:Visual Basic 6.0 Music Programing
    Piano Chords

Posted 10 February 2018 - 00:19

I want to change the shuffle value of a phrase from 0 to 100% via scripting, I have read the manual and appears this code, I,ve tried to write the correct sintax, but no exit. Any help to make a function like this one:



function shuffle()
renoise.song().instruments[].phrase.shuffle_amount [1]
end



Is this correct ??

Edited by Circe, 10 February 2018 - 15:50.


#2 Raul (ulneiz)

Raul (ulneiz)

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1442 posts
  • Gender:Male
  • Location:Spain

Posted 10 February 2018 - 00:27

-- Shuffle groove amount for a phrase. 
-- 0.0 = no shuffle (off), 1.0 = full shuffle 
renoise.song().instruments[].phrase.shuffle_amount
  -> [number, 0-1]
 
 
0.0 to 1.0

:excl: Development of my tools: KangarooX120SamRenderPhraseTouch  |  GT16-Colors (old)

 

:excl: My API wishlist R3.1 (updated 24 July 2017):

Spoiler

 

:excl: My Renoise 3.1 wishlist (updated 26 September 2017):

Spoiler

#3 Raul (ulneiz)

Raul (ulneiz)

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1442 posts
  • Gender:Male
  • Location:Spain

Posted 10 February 2018 - 01:20

The current documentation is incorrect (Renoise 3.1.1):

 

renoise.song().instruments[].phrase.shuffle_amount

 

error 1: "phrase", define :phrase(index)

error 2: "shuffle_amount" not exist

 

Use:

  1. print(renoise.song().instruments[1].phrases[1].shuffle)
  2. print(renoise.song():instrument(1):phrase(1).shuffle)
  3. print(renoise.song().selected_instrument:phrase(1).shuffle)
  4. print(renoise.song().selected_phrase.shuffle)

Remember that the phrase must exist...

 

Danoise report?


Edited by Raul (ulneiz), 10 February 2018 - 14:00.

:excl: Development of my tools: KangarooX120SamRenderPhraseTouch  |  GT16-Colors (old)

 

:excl: My API wishlist R3.1 (updated 24 July 2017):

Spoiler

 

:excl: My Renoise 3.1 wishlist (updated 26 September 2017):

Spoiler

#4 esaruoho

esaruoho

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2678 posts
  • Gender:Male
  • Location:Kontula, Helsinki, Finland
  • Interests://Varying Interests//

Posted 10 February 2018 - 06:51

The current documentation is incorrect (Renoise 3.1.1):

 

renoise.song().instruments[].phrase.shuffle_amount

 

error 1: "phrase", define :phrase(index)

error 2: "shuffle_amount" not exist

 

Use:

  1. print(renoise.song().instruments[1].phrases[1].shuffle)
  2. print(renoise.song().selected_instrument:phrase(1).shuffle)
  3. print(renoise.song().selected_phrase.shuffle)

Remember that the phrase must exist...

 

Danoise report?

 

cool, i'll snipe that into the github (shuffle_amount -> shuffle correction for documentation)

- there it is: https://github.com/r...e/xrnx/pull/132

 

so anyway, i created an instrument, and a phrase, and was able to set this

renoise.song().selected_phrase.shuffle=1

and am seeing

Screen Shot 2018-02-10 at 7.50.41.png

 

so it does works.


http://lackluster.org | on Bandcamp | on YouTube | on Facebook | on Spotify | on iTunes | on TiDAL | on Soundcloud | 

http://twitter.com/esaruoho | http://esaruoho.tumblr.com | GitHubesaruoho@gmail.com | 

| macOS 10.13 High Sierra | MacBook Pro 2.8 GHz Intel Core i7 / 16 Gb 1600 MHz DDR 3 |

| http://renoise.com/tools/paketti | BTC: 1BoZ9rvb8wT7dFNyVPwSX7DLj3stNo7844 | http://paypal.me/esaruoho |

| Latent Impulse Tracker/Scream Tracker 3/Schism Tracker <-> Renoise fanatic |

More API functions, please! ;) http://forum.renoise.com/index.php/topic/26329-the-api-wishlist-thread/page-3#entry240266

#5 Circe

Circe

    Advanced Member

  • Normal Members
  • PipPipPip
  • 90 posts
  • Gender:Male
  • Location:Spain
  • Interests:Visual Basic 6.0 Music Programing
    Piano Chords

Posted 10 February 2018 - 11:32

Thanks a lot Raúl and ESARUOHO.😎

#6 Raul (ulneiz)

Raul (ulneiz)

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1442 posts
  • Gender:Male
  • Location:Spain

Posted 11 February 2018 - 16:14

cool, i'll snipe that into the github (shuffle_amount -> shuffle correction for documentation)

- there it is: https://github.com/r...e/xrnx/pull/132

 

so anyway, i created an instrument, and a phrase, and was able to set this

renoise.song().selected_phrase.shuffle=1

and am seeing

attachicon.gifScreen Shot 2018-02-10 at 7.50.41.png

 

so it does works.

 

@esaruoho. I have seen that you (or Danoise) have corrected the documentation, but it is still wrong...

 

+renoise.song().instruments[].phrase.shuffle

 

The concrete line should be like this:

renoise.song().instruments[].phrases[].shuffle

There are also a couple of lines that would be well included in the documentation. If I tell you, could they be added? I see that you are a contributor to the documentation...


:excl: Development of my tools: KangarooX120SamRenderPhraseTouch  |  GT16-Colors (old)

 

:excl: My API wishlist R3.1 (updated 24 July 2017):

Spoiler

 

:excl: My Renoise 3.1 wishlist (updated 26 September 2017):

Spoiler

#7 esaruoho

esaruoho

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2678 posts
  • Gender:Male
  • Location:Kontula, Helsinki, Finland
  • Interests://Varying Interests//

Posted 12 February 2018 - 08:16

There are also a couple of lines that would be well included in the documentation. If I tell you, could they be added? I see that you are a contributor to the documentation...

 

 

Hi Raul, I have contributed some fixes with typos and corrections, but that is it. anyone whose changes + contributions are merged into the main document, is considered a contributor. I'm not affiliated with Renoise at all. Just some guy finding typos and then correcting them, or in this case, tweaking some of them a bit.


+renoise.song().instruments[].phrase.shuffle

The concrete line should be like this:

renoise.song().instruments[].phrases[].shuffle

 

created another PR, check https://github.com/r.../pull/134/files


http://lackluster.org | on Bandcamp | on YouTube | on Facebook | on Spotify | on iTunes | on TiDAL | on Soundcloud | 

http://twitter.com/esaruoho | http://esaruoho.tumblr.com | GitHubesaruoho@gmail.com | 

| macOS 10.13 High Sierra | MacBook Pro 2.8 GHz Intel Core i7 / 16 Gb 1600 MHz DDR 3 |

| http://renoise.com/tools/paketti | BTC: 1BoZ9rvb8wT7dFNyVPwSX7DLj3stNo7844 | http://paypal.me/esaruoho |

| Latent Impulse Tracker/Scream Tracker 3/Schism Tracker <-> Renoise fanatic |

More API functions, please! ;) http://forum.renoise.com/index.php/topic/26329-the-api-wishlist-thread/page-3#entry240266

#8 danoise

danoise

    Probably More God or Borg Than Human Member

  • Renoise Team
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 6880 posts
  • Gender:Male
  • Location:Berlin
  • Interests:wildlife + urban trekking

Posted 12 February 2018 - 20:38

created another PR

 

Thanks, merged 

 

Great initiative btw. - the scripting documentation is invaluable, also for us "veterans" wink.png


  • esaruoho likes this

Tracking with Stuff. API wishlist | Soundcloud


#9 esaruoho

esaruoho

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2678 posts
  • Gender:Male
  • Location:Kontula, Helsinki, Finland
  • Interests://Varying Interests//

Posted 13 February 2018 - 09:41

Thanks, merged 

Great initiative btw. - the scripting documentation is invaluable, also for us "veterans" wink.png

 

Well, up until a week or a few weeks ago i had no idea that the documentation could just be updated with PRs :) 

I'm a bit more familiar with github this year as opposed to in 2011 or so, so a bit easier to just put in some typo changes etc.


http://lackluster.org | on Bandcamp | on YouTube | on Facebook | on Spotify | on iTunes | on TiDAL | on Soundcloud | 

http://twitter.com/esaruoho | http://esaruoho.tumblr.com | GitHubesaruoho@gmail.com | 

| macOS 10.13 High Sierra | MacBook Pro 2.8 GHz Intel Core i7 / 16 Gb 1600 MHz DDR 3 |

| http://renoise.com/tools/paketti | BTC: 1BoZ9rvb8wT7dFNyVPwSX7DLj3stNo7844 | http://paypal.me/esaruoho |

| Latent Impulse Tracker/Scream Tracker 3/Schism Tracker <-> Renoise fanatic |

More API functions, please! ;) http://forum.renoise.com/index.php/topic/26329-the-api-wishlist-thread/page-3#entry240266

#10 Raul (ulneiz)

Raul (ulneiz)

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 1442 posts
  • Gender:Male
  • Location:Spain

Posted 13 February 2018 - 16:06

@esaruoho and @danoise. Thanks!  ^_^


:excl: Development of my tools: KangarooX120SamRenderPhraseTouch  |  GT16-Colors (old)

 

:excl: My API wishlist R3.1 (updated 24 July 2017):

Spoiler

 

:excl: My Renoise 3.1 wishlist (updated 26 September 2017):

Spoiler