English Amiga Board


Go Back   English Amiga Board > Coders > Coders. Language > Coders. Blitz Basic

 
 
Thread Tools
Old 24 February 2021, 21:04   #41
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
Quote:
Originally Posted by Bren McGuire View Post
Is there any free code out there to be able to load a protracker file in Blitz?
I'm not looking for player code necessarily, but something that can take a protracker file as input, load its samples in memory and access its sequence, but not necessarilty play it.
I guess as such it should not have any assembler in it to do this unless it is impossible to do without assembler.

I'm trying to make some analytics.
The whole point of high-level languages is to abstract you from the nitty gritty!

But what you're trying to do is nitty gritty.

Any language should support reading a stream of bytes from a file. This you can do, and then interpret it according the Protracker file format. Some MODs and MEDS might not follow it exactly, and you must account for this or throw an error.
Photon is offline  
Old 17 March 2021, 16:10   #42
Bren McGuire
Registered User
 
Bren McGuire's Avatar
 
Join Date: Nov 2019
Location: Croydon
Posts: 580
I don't see any problem in trying to do "nitty gritty" with any language, it's not like this is a child's programming language.


I still haven't been able to do what I wanted to do, someone sent me a PM because they refuse to post here (!?) and the code they shared was unreadable to me. People seem to forget I said I am a newbie coder and I don't fully understand coding yet. You can't just send me a bunch of uncommented code with undecipherable variables. It all looks like taken out of the magic hat.



Quote:
Originally Posted by Photon View Post
The whole point of high-level languages is to abstract you from the nitty gritty!

But what you're trying to do is nitty gritty.

Any language should support reading a stream of bytes from a file. This you can do, and then interpret it according the Protracker file format. Some MODs and MEDS might not follow it exactly, and you must account for this or throw an error.
Bren McGuire is offline  
Old 17 March 2021, 16:43   #43
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,644
Quote:
Originally Posted by Bren McGuire View Post
Would Bank allow me to do what I want?
Dude, from my experience so far with this, I'd say Bank is the only way you have to do whatever you want with the modfile. Save yourself a headache and skip the LoadModule function altogether.
Amiga1992 is offline  
Old 17 March 2021, 23:27   #44
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
Quote:
Originally Posted by Bren McGuire View Post
I don't see any problem in trying to do "nitty gritty" with any language, it's not like this is a child's programming language.
As I wrote it should support loading binary files...
Quote:
Originally Posted by Bren McGuire View Post
I still haven't been able to do what I wanted to do
... but it's also required that it does, to do what you want. Otherwise you simply can't.

Once you are able to read binary files, unless someone did the nitty gritty of interpreting the file you will have to do that nitty gritty. In whatever language you use, actually.

No language has a built-in function "LoadAndIndexSamplesFromProtrackerModule(filename)". Such a function would be too specialized.

In 2021, no language has a function "LoadXMLorJSONstandardfileAndIndexFormattedStuffInIt(filename)" either. Such a function would be too specialized.

I hope I've understood what you want and I hope you understand what I mean by this.

If you want the samples, several coders have written rippers. You could run that, get a bunch of files, and then index them.
Photon is offline  
Old 18 March 2021, 14:48   #45
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,644
Quote:
Originally Posted by Photon View Post
I hope I've understood what you want and I hope you understand what I mean by this.
I don't think you have, this fella here was asking for help exactly on how to parse a MOD file with Blitz. There's no such thing, so he has to do his own, but he's just starting with coding, so cut him some slack.

Not everyone has to learn just doing tutorials or repeating code they see, personally, I like to learn with a very specific goal or project in mind. Results might take longer to come, but it feels a lot better than just doing random code that means nothing to me.

This guy here seems to me like he had a plan...
Amiga1992 is offline  
Old 02 April 2021, 22:22   #46
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
Maybe my clear explanation is intimidating?

Cutting some slack is also informing someone when something is hard to achieve, and suggesting an alternate solution.

Akira do you recommend Blitz Basic as the right tool to use to write a sample ripper?
Photon is offline  
Old 17 April 2021, 15:40   #47
Amiga1992
Registered User
 
Join Date: May 2001
Location: ?
Posts: 19,644
Quote:
Originally Posted by Photon View Post
Akira do you recommend Blitz Basic as the right tool to use to write a sample ripper?
Why not?

I already have my own Protracker module parser built in blitz based on a lot of the topics discussed in this thread. Saving the samples would be trivial. If you mean a sample ripper as in "poke in memory and find samples", I have not tried that, but again, I don't see why not. But that's not what this dude wanted to do.

Again experimentation and learning should be encouraged, not discouraged in any way.
Amiga1992 is offline  
Old 21 April 2021, 20:26   #48
Photon
Moderator
 
Photon's Avatar
 
Join Date: Nov 2004
Location: Eksjö / Sweden
Posts: 5,602
I've expressed myself clearly. I've asked but not yet received answer if Blitz Basic parses files well. If it doesn't, why use the wrong tool?

And you've done something like it but won't share this trivial sample saving? I don't get that.
Photon is offline  
 


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools

Similar Threads
Thread Thread Starter Forum Replies Last Post
Protracker file format, number of samples phx Coders. General 21 02 August 2019 22:45
Blitz Basic 2 and Protracker mods Radertified Coders. Blitz Basic 3 13 September 2018 22:55
Can't Create File error using Protracker 2.3d ViLXDRYAD support.Apps 5 09 December 2016 15:44
Protracker 3.xx Load Sample womagrid support.Apps 3 27 May 2016 06:28
Load Cubase made sample in protracker Brick Nash support.Other 4 26 May 2016 18:28

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT +2. The time now is 14:28.

Top

Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
Page generated in 0.11816 seconds with 16 queries