Jump to content


Photo

Merge Songs


  • Please log in to reply
185 replies to this topic

#51 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 23 June 2007 - 22:52

I was able to generate a Warning: DOMDocument::schemaValidate(): Element 'LinkedInstrument': '1E' is not a valid value of the atomic type 'xs:int'. in /Users/dac514/Desktop/xrns_merge/xrns_merge.php on line 407 so I guess it's not HEX.

For real... the final version?

EDIT: Scroll down...

Edited by Conner_Bw, 24 June 2007 - 16:23.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#52 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 24 June 2007 - 16:25

After an email discussion with Taktik, I believe we're done.

I've set up a web page here:

http://www.trotch.com/xrns_merge/

If Renoise.Com wants to host this page, then by all means contact me and i'll send you the files. If anyone cares to test the script and provide feedback. That's cool too.

Thanks!

:badteethslayer:

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#53 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 24 June 2007 - 17:06

1. If you merge songs with different doctypes, you'll get errors (Invalid NodeType to import in merge.php on line 38). You'll get a merged song nonetheless, which causes Renoise to choke, then crash.

2. On Windows, the temp dirs cannot be removed. But at least the temp files inside have been deleted.

PHP Warning: rmdir(C:\Temp\xrns_merge_460ef25e52c708e473f30929a26a12d8_Track02/
SampleData): Permission denied in merge.php on line 122

3. Typo: "unziping"

#54 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 24 June 2007 - 17:19

1. If you merge songs with different doctypes, you'll get errors (Invalid NodeType to import in merge.php on line 38). You'll get a merged song nonetheless, which causes Renoise to choke, then crash.


Can you send me these songs? Also change the $schema variable to something that exists on line 21. This will cause Renoise to validate your xml and abort if it fails. If $schema points somewhere non-exstant, it skips the validation step.

2. On Windows, the temp dirs cannot be removed. But at least the temp files inside have been deleted.

PHP Warning: rmdir(C:\Temp\xrns_merge_460ef25e52c708e473f30929a26a12d8_Track02/
SampleData): Permission denied in merge.php on line 122


Permissions? I don't know why it decides it can't remove Track02 but it *can* remove Track01. I had this happen to me at work on XP a few times. I changed the obliterate_directory() function to avoid this, but it started happening again last week. I believe permissions are the issue, and at work I don't control my own permissions, the IT department does. At home on my OS X machines it works fine. If anyone can figure this out it would be greatly appreciated.

3. Typo: "unziping"


Fixed.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#55 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 24 June 2007 - 17:44

Songs send. After validation, no merged song is produced - naturally, one of the songs doesn't match against the schema.

#56 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 24 June 2007 - 18:07

Songs send. After validation, no merged song is produced - naturally, one of the songs doesn't match against the schema.


I've made a few changes:

http://www.trotch.com/xrns_merge/

* Will warn insetad of die if there is a problem deleting temporary files.
* Will warn if path to RenoiseSong4.xsd is not found.

SearMeIII is failing XML validation, the doctype is <RenoiseSong doc_version="3"> which I've never seen before and it doesn't validate as correct XML. Where did that come from? A beta?

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#57 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 24 June 2007 - 19:26

Where did that come from? A beta?


Probably, yeah.

#58 mr_mark_dollin

mr_mark_dollin

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2823 posts
  • Gender:Male
  • Location:In the Pattern Matrix.
  • Interests:Quiet Revolutions.

Posted 28 June 2007 - 05:28

Hi there I'm a retarded PC user and these two files don't work for me. The zip seems broken and the exe gives an error. I'm probably doing something wrong.

btw, Conner thanks a million for taking on this idea! Can't wait to have it up and running!
Posted Image

#59 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 28 June 2007 - 12:36

The exe is self-extracting and the zip can be opened with Winzip 9.0 for example. But I agree that the app currently needs too much user intervention, which is why I am really eager to see a standalone GUi version.

#60 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 28 June 2007 - 17:31

The GUI version is not here, and I won't be the one to write it. Yeah, it sucks you have to actually learn how to use a computer to work this script, but that's the best I can do I don't know how to create GUI apps quickly enough to justify the endeavor. I too am looking forward to a GUI version, but for now...

What zip and exe are you guys talking about? You mean zip & unzip? Basically, for Windows users, the goal is to get the open source zip.exe and unzip.exe extracted from Info-Zip. (How to Unhide File Extensions for Known File Types in Windows) What version of Windows are you running? Is it 64 bit or something? In any case, try to find the correct version of the file for your OS. I'm pretty sure these will work for you but if they don't, see previous link to Info-Zip,

UNZIP: ftp://ftp.info-zip.org/pub/infozip/win32/unz552xn.exe
ZIP: ftp://ftp.info-zip.org/pub/infozip/win32/zip232xn.zip

As explained by Bantai, the first is self-extracting, the second is a regular zip file. Extract these files and pull out zip.exe and unzip.exe in your path (example C:\Windows\System32) You only need zip.exe and unzip.exe. All the other files aren't necessary. If you don't want them, don't keep them.

Next it's a matter of installing PHP5 on your system. You could download it directly from PHP.NET or you can download a webserver package like XAMPP which comes with Apache, Mysql, a bunch of other necessary stuff if you are interested in web development. This "other stuff" is not needed for the xrns_merge script. But, you might want to consider it if you want to explore making web apps in the future. Maybe also write your own scripts?

Next, get a text editor that doesn't suck. I use Jedit but should probably use something like Context as Jedit comes with another set of dependencies you'll need to work at in order to get it running. There are other choices, I just gave you two free ones, but feel free to use whatever.

Is all that shit installed now? Good.

Next, find the command prompt. On my XP box at work it's Start -> Accessories -> Command Prompt. Double click it. Type zip -v If that doesn't work you messed up. Type unzip -v If that doesn't work, see previous comment about messing up. Go back to square one.

Type php -v If that doesn't work or returns something lower than PHP 5.2.X, you need to set the path to PHP. Exit the command prompt and read this. Add the PHP dir to the path. In my case it's C:\Program Files\xampp\php. Optionally, instead of setting up the path type "C:\Program Files\xampp\php\php" instead of php every time you want to run a script.

Next, download the script (i.e. cut and paste it into your text editor and save it as xrns_merge.php somewhere).

Next, go back to the command prompt, go to the directory you saved your script. (CD - Change Directory Command)

Finally, php xrns_merge.php "C:\Some Path\To\Song1.xrns" "C:\Some Path\To\Song2.xrns" newname.xrns

If a bunch of shit appears on the screen, read it, that's an error message that will help you solve the problem. If everything worked, then newname.xrns will have been created in your current working directory.

My guess is most of the above was worthless as most probably know how to do it. I don't mean to sound condescending, but i'm just trying to include as much info as possible.

Hope it works out!

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#61 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 28 June 2007 - 17:54

Link to xrns_merge.php webpage for good measure:

http://www.trotch.com/xrns_merge/

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#62 mr_mark_dollin

mr_mark_dollin

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2823 posts
  • Gender:Male
  • Location:In the Pattern Matrix.
  • Interests:Quiet Revolutions.

Posted 29 June 2007 - 01:58

Wow thanks for the effort! There's no way I would have figured that out. Just not, well, savy enough. Flat out thinking about how to make my songs more innovative and interesting, let alone becoming a PHP lord.

Edit: ahh my problem was WinRAR with the zip232xn.zip file - works with winzip. Please ignore me.

Edit2: Script works here. I merged the bb5 tracks by alexstrain and Carmazine. Results as expected!

Edited by Foo?, 29 June 2007 - 03:05.

Posted Image

#63 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 29 June 2007 - 04:37

Script works here. I merged the bb5 tracks by alexstrain and Carmazine. Results as expected!


Hurray!

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#64 choice

choice

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2312 posts
  • Gender:Male

Posted 30 June 2007 - 01:45

this is 'an absolute must have' in my book.


Conner, do you have a paypal account to accept good will Donations?


oh my, is this line:
"OS X and Linux users should already have zip / unzip installed by default."

inferring something? ;)

#65 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 30 June 2007 - 02:30

Conner, do you have a paypal account to accept good will Donations?


Seriously, thanks! But, I don't need the support. I appreciate people checking out the script I had fun writing it. In fact, by doing so I can now pretty much shit out PHP5 scripts as seen in this thread for this who might have missed it.

Seriously, the most daunting part of the code is packing and unpacking the songs. The XML took a while to understand. But writing this script allows me to think of how to approach other problems such as randomizing. It's a shame I can't make GUI tools, but with simple XML manipulation and ideas, I can now confidently say I can do a whole lot more at the command prompt. I think other users could too if they just tried.

Cheers!

EDIT: Seriously.

Edited by Conner_Bw, 30 June 2007 - 02:40.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#66 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 30 June 2007 - 22:47

Seriously, thanks! But, I don't need the support. I appreciate people checking out the script I had fun writing it. In fact, by doing so I can now pretty much shit out PHP5 scripts as seen in this thread for this who might have missed it.

Seriously, the most daunting part of the code is packing and unpacking the songs. The XML took a while to understand. But writing this script allows me to think of how to approach other problems such as randomizing. It's a shame I can't make GUI tools, but with simple XML manipulation and ideas, I can now confidently say I can do a whole lot more at the command prompt. I think other users could too if they just tried.

Cheers!

EDIT: Seriously.


I can make Swing guis in Java, but I am yet unfamiliar with processing XML in Java. I will check out the Swing document component, or SAX if that doesn't work, when I have some time again.

BTW When I was checking out the scaffolding capabilities of CakePHP, I noticed the Bake script had some nice PHP CLi functionality, allowing for a user-interactive script. Instead of copying the same zip/unzip code for every renoise php script, one could make them pluggable with php's __autoload and the factory design pattern. The user would be presented with a menu, like: What do you want to do today? [1] merge songs [2] randomize [3] make instant hit [x] exit...

#67 vV

vV

    God's or Borg's Chief and Ruler of All Species

  • Moderator
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 16855 posts
  • Gender:Male
  • Location:Netherlands

Posted 01 July 2007 - 14:11

The GUI version is not here, and I won't be the one to write it. Yeah, it sucks you have to actually learn how to use a computer to work this script, but that's the best I can do I don't know how to create GUI apps quickly enough to justify the endeavor. I too am looking forward to a GUI version, but for now...


You might want to try do something with Glade if it regards making a GUI environment, you need GTK+ though:

Glade for Windows:
http://gladewin32.so...t/modules/news/

Linux Glade:
http://glade.gnome.org/

Glade for Mac:
http://glade.darwinports.com/


Or if you plan to download GTK anyway, try PHP gtk:
http://www.devx.com/...Article/21235/0
Vv....


cpu Intel Core i7-4820K @3.70GHz
chipset Intel X79 chipset
mem 32 Gb 2400Mhz
os Win 7 64-bit SP1, DirectX 11
audio ESI ESP1010e - > Driver rev:2.0.6.0
video nVidia Geforce GTX780 - > Driver rev:335.23


Renoise Official Manual

#68 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 01 July 2007 - 17:40

GTK would definitely be cool to try, but it might be an exercise in futility? Getting the script up and running would still require the same user effort, if not more. It's the same thing with Java on Windows. Does the GUI offer any advantage to a user who already knows how to set up PHP5 or JAVA on a system without it?

In terms of interactivity, Cake PHP looks really nice but I definitely could make the script interactive without a MVC paradigm. Even just a basic splitting up the scripts into a few files that depend on each other with includes/requires, possibly encapsulated in classes, would definitely make writing new algorithms easier (in fact, that's how I'm working on my own machine) But again, I'm trying to force myself to keep all the code in one file so it functions as an "easy to install" script that users can cut and paste into a single file without having to think of dependencies. Personally, i'd rather be using console packages from PEAR. It's another trade-off.

Anyway, I'm up for seeing mutations of the code. If anyone wants to post their own versions, I always enjoy looking.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#69 Guest_Bantai_*

Guest_Bantai_*
  • Guests

Posted 01 July 2007 - 17:48

In terms of interactivity, Cake PHP looks really nice but I definitely could make the script interactive without a MVC paradigm.


Ofcourse. CakePHP is a complete ORM framework, I was only referring to its humble bake script.

#70 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 01 July 2007 - 18:37

Scripts have moved:
http://www.trotch.com/xrns_scripts/

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#71 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 01 July 2007 - 20:43

I am really eager to see a standalone GUi version.


Top secret and no pressure, BeatSlaughter is working on a (windows) front-end self-packaged GUI for this and the randomize script which looks very promising. Perhaps even with the possibility of auto generating simple GUI dialogues for any script of this style. Time will tell.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#72 vV

vV

    God's or Borg's Chief and Ruler of All Species

  • Moderator
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 16855 posts
  • Gender:Male
  • Location:Netherlands

Posted 02 July 2007 - 15:46

GTK would definitely be cool to try, but it might be an exercise in futility? Getting the script up and running would still require the same user effort, if not more. It's the same thing with Java on Windows. Does the GUI offer any advantage to a user who already knows how to set up PHP5 or JAVA on a system without it?

In terms of interactivity, Cake PHP looks really nice but I definitely could make the script interactive without a MVC paradigm. Even just a basic splitting up the scripts into a few files that depend on each other with includes/requires, possibly encapsulated in classes, would definitely make writing new algorithms easier (in fact, that's how I'm working on my own machine) But again, I'm trying to force myself to keep all the code in one file so it functions as an "easy to install" script that users can cut and paste into a single file without having to think of dependencies. Personally, i'd rather be using console packages from PEAR. It's another trade-off.

Anyway, I'm up for seeing mutations of the code. If anyone wants to post their own versions, I always enjoy looking.


Well if you want front end code in out-of-the-box binaries i think you are doomed to multiplatform sourcecode that gets compiled in different environments.
I personally only know XBasic as the most easy programming language on multiplatform (and runs fast!) that might with a few adjustments be compilable on MacOsx, however it has been designed for Windows and Linux. But once your GUI tool works, it will compile without problems on all three platforms.
http://www.xbasic.org
Vv....


cpu Intel Core i7-4820K @3.70GHz
chipset Intel X79 chipset
mem 32 Gb 2400Mhz
os Win 7 64-bit SP1, DirectX 11
audio ESI ESP1010e - > Driver rev:2.0.6.0
video nVidia Geforce GTX780 - > Driver rev:335.23


Renoise Official Manual

#73 Conner_Bw

Conner_Bw

    Probably More God or Borg Than Human Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPipPipPip
  • 7043 posts
  • Gender:Male
  • Location:Montreal, Quebec, Canada

Posted 02 July 2007 - 16:33

I found this for OS X last night, first I've ever heard of it, and it's really good:

http://www.bluem.net...oads/pashua_en/

Again, the issue of not being multi-platform comes up, but the above is a very nice & simple solution to the problem of script GUI for Mac, any shell script language in fact. I wrote a GUI, using PHP, in 5 minutes. This still doesn't solve not having PHP5 on the system, and when I packaged the script as a self contained application everything gets sent to console.log which is confusing for a newbie. Anyway, it's something I'm working on it for fun.

cpu Lenovo X220, Intel i7-2640M @ 2.80GHz ×4 os Windows 10 / Ubuntu 16.04 LTS
My Homepage » : My Renoise Tools » : Normalize Your Sig » : One million clicks! »


#74 Beatslaughter

Beatslaughter

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2276 posts
  • Gender:Male
  • Location:Berlin, Germany
  • Interests:Music, Blu-ray, PC Games

Posted 10 July 2007 - 15:41

Top secret and no pressure, BeatSlaughter is working on a (windows) front-end self-packaged GUI for this and the randomize script which looks very promising. Perhaps even with the possibility of auto generating simple GUI dialogues for any script of this style. Time will tell.


Check your Mail, i've sent you a first alpha version.

#75 Beatslaughter

Beatslaughter

    Guruh Motha Fakka is Levitating and Knows Everything About Renoise Member

  • Normal Members
  • PipPipPipPipPipPipPipPipPipPipPipPipPip
  • 2276 posts
  • Gender:Male
  • Location:Berlin, Germany
  • Interests:Music, Blu-ray, PC Games

Posted 10 July 2007 - 19:10

Ok, here is the first public version of the frontend for windows users. The download contains everything you need in an easy to use package for running the scripts connor_bw wrote. The frontend is currently in alpha stage and will get some updates over the next time. In case you find any flaws, report them here.

Download

Below are some screenshots, how it looks like.

Posted Image

Posted Image