Deprecated: mysql_connect(): The mysql extension is deprecated and will be removed in the future: use mysqli or PDO instead in /storage/content/49/145849/famitracker.com/public_html/forum/classes/dbHandler.php on line 29 FamiTracker
Login:
Menu:
Post: Author:
FamiTracker > General > FamiTracker Talk > Unity and NSF/FTM/something similar? Owner: CheeseGuy99 New post
Page 1 of 2 Sort: Goto Page: [1] [2] Next >>
Unity and NSF/FTM/something similar? Posted: 2014-03-23 03:22 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55550
I was wondering if there is, say, a plugin that can take NFS files or FTM files and run them (with their looping) in Unity3D? If not, is there a easy way to loop a WAV file in the same manner?

LITTLE bit off topic, I know, but I don't think it's that far off.

_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
RE: Unity and NSF/FTM/something similar? Posted: 2014-03-24 00:18 Reply | Quote
poodlecock

Avatar

Member for: 3398 days
Location: !wow
Status: Offline

#55575
[quote=CheeseGuy99]I was wondering if there is, say, a plugin that can take NSF files or FTM files and run them (with their looping) in Unity3D? If not, is there a easy way to loop a WAV file in the same manner?

LITTLE bit off topic, I know, but I don't think it's that far off.[/quote]
I don't use Unity, but I think that having one WAV file before the loop and another for the looped part may work...

_______________________
"im going to continue making this crazy stuff then after a while my style will be so sick that you will be like damn suuun that shit is so sick i dont even get it. i will be like bro its ok.. you dont have to." -omgdonut
Posted: 2014-03-24 02:12 Reply | Quote
insomniacovrlrd

Avatar

Member for: 3259 days
Location: US : Florida
Status: Offline

#55576
Hum. Someone else looking into exporting the music for use in projects. Yeah, exporting three repeats and chopping the one in the middle out is the best way to do it that I'm aware of, unfortunately.

Posted: 2014-03-24 05:55 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55579
Well, I was reading a thread about a blank space before the actual audio (I believe it was you, actually) but the problem for me arises when you need to play a intro, then loop whats after that. I may have to just record the intro, then the loop three times, cut the middle out, and play the audio files accordingly in the code. I thought of that, but I'm still quite unsure how I'm gonna do that very precisely...

Oh well, thanks for the input. If anyone has, like, a plugin or something for Unity that plays NSFs, FTMs, MML or something that I can use with famitracker, I'd be much obliged.

_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
Posted: 2014-03-24 07:02 Reply | Quote
jrlepage
Moderator

Avatar

Member for: 4983 days
Location: Canada
Status: Offline

#55581
Short of incorporating what would essentially be an NES emulator inside whatever project you're working on, yeah I guess splicing the middle loop out of a 3-loop WAV is the best solution. Make sure whatever audio editor you use doesn't introduce silence before your WAV though.

_______________________
Follow me on [url=https://twitter.com/jrlepage2a03]Twitter.
I record (some) NSFs on hardware. Feel free to [url=http://www.famitracker.com/forum/posts.php?id=3633]request a hardware render.
Posted: 2014-03-24 19:08 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55591
[quote=jrlepage]Short of incorporating what would essentially be an NES emulator inside whatever project you're working on, yeah I guess splicing the middle loop out of a 3-loop WAV is the best solution. Make sure whatever audio editor you use doesn't introduce silence before your WAV though.[/quote]

Probably Audacity, and I'm fairly sure it doesn't. Also, yeah, that's the kinda plugin I was trying to find, but when I think about it, it might impact the performance a little bit too much...

_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
Posted: 2014-03-24 19:18 Reply | Quote
GEVEN

Avatar

Member for: 3045 days
Location: Kentucky
Status: Offline

#55592
perhaps the untiy forums has a place to ask about music plugins.

_______________________
https://soundcloud.com/stevie-ray-2
Posted: 2014-03-24 21:35 Reply | Quote
poodlecock

Avatar

Member for: 3398 days
Location: !wow
Status: Offline

#55593
[quote=jrlepage]Short of incorporating what would essentially be an NES emulator inside whatever project you're working on, yeah I guess splicing the middle loop out of a 3-loop WAV is the best solution. Make sure whatever audio editor you use doesn't introduce silence before your WAV though.[/quote]
Solution #1: Don't use LAME.

_______________________
"im going to continue making this crazy stuff then after a while my style will be so sick that you will be like damn suuun that shit is so sick i dont even get it. i will be like bro its ok.. you dont have to." -omgdonut
Posted: 2014-03-24 22:44 Reply | Quote
DalekSam

Avatar

Member for: 4280 days
Location: United Kingdom, Belfast
Status: Offline

#55596
Tesserex implemented an NSF player into his C Mega Man engine which we used in Mega Man Time Tangent, so using an NSF is not out of the question. It really only applies if you're being super anal about the whole thing and want channel muting or something; otherwise, wav files would do just fine!

Posted: 2014-03-25 00:40 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55599
[quote=DalekSam]Tesserex implemented an NSF player into his C Mega Man engine which we used in Mega Man Time Tangent, so using an NSF is not out of the question. It really only applies if you're being super anal about the whole thing and want channel muting or something; otherwise, wav files would do just fine![/quote]

My problem was less with authenticity, and more with ease of importing. But, I guess it really doesn't matter, as long as the game is good.


_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
Posted: 2014-03-25 03:25 Reply | Quote
rainwarrior

Avatar

Member for: 4150 days
Location: Canada
Status: Offline

#55607
I'm certain that Unity already has very capable features for playing looped audio.

I'm not sure what motivates wanting to use NSF or FTM or MML specifically. As has been pointed out, playing back NSF basically requires the implementation of most of an NES emulator. Putting an NES emulator inside your game seems a bad idea; aside from being a lot of work, or a likely code licensing issue, that's a lot of extra CPU performance to spend.

...and it's for something you could solve with existing solutions that would sound identical. Why do you want to do this?

Posted: 2014-03-25 23:50 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55620
[quote=rainwarrior]I'm certain that Unity already has very capable features for playing looped audio.

I'm not sure what motivates wanting to use NSF or FTM or MML specifically. As has been pointed out, playing back NSF basically requires the implementation of most of an NES emulator. Putting an NES emulator inside your game seems a bad idea; aside from being a lot of work, or a likely code licensing issue, that's a lot of extra CPU performance to spend.

...and it's for something you could solve with existing solutions that would sound identical. Why do you want to do this?[/quote]

Well, basically, although it seems better in every way at this point to just loop the music normally in unity, the problem was that, when you output a WAV file from famitracker, there is no way to import one little file and, based on that file, play the intro, and loop the portion that SHOULD loop infinitely. The CPU cost is a bit too much, though...

_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
Posted: 2014-03-26 00:20 Reply | Quote
GEVEN

Avatar

Member for: 3045 days
Location: Kentucky
Status: Offline

#55622
yeah, that would require two files. an intro and a loop.

_______________________
https://soundcloud.com/stevie-ray-2
Posted: 2014-03-27 05:31 Reply | Quote
insomniacovrlrd

Avatar

Member for: 3259 days
Location: US : Florida
Status: Offline

#55665
yes, and it's quite a pain to arrive at that conclusion.

To get an intro and a loop, you have to, in my experience set your document up as follows.
A) intro frames
B) Loop frames
C) duplication of loop frames.

Have famitracker export the whole pile. Then you go into audacity and um

very carefully (luck willing, always) find the exact point the intro ends and the loop begins, and chop everything to the left

(note) if you're going to do say, normalization of the file to make it as loud as it can be without clipping, do any adjustments you have to do before cutting.

Take the left chunk, save it as [songtitle]_Intro
Then take the remainder, and find the EXACT point that the loop ends, and goes back into itself. again, it's an inexact science unfortunately. But, provided you find that exact point, isolate that middle piece that represents your loop in its entirety and export that as [songtitle]_Loop, and you're pretty much good to go.

It's a stupid amount of work with a ton of steps that you can screw up. Just being a tiny bit off on your cut points will ruin the results, and you'll have either a clunky transition from intro to Loop, or you'll have a garbage loop, or both!

Needless to say, i really wish this process was a little more straightforward. Maybe i'm stupid, but i haven't been able to come up with anything better.

Suggestions definitely welcome.

Posted: 2014-03-27 20:34 Reply | Quote
CheeseGuy99

Avatar

Member for: 3752 days
Location: Amarillo, TX
Status: Offline

#55692
[quote=insomniacovrlrd]
Needless to say, i really wish this process was a little more straightforward. Maybe i'm stupid, but i haven't been able to come up with anything better.

Suggestions definitely welcome.[/quote]

Yeah, maybe, at some point (very low priority, if you ever do this), maybe jsr would add this function in. Just have it export frames xx - xx, then export the rest, without the extra silence. It'd be nice.

_______________________
**** COMMODORE 64 BASIC V2 ****

Some other places I've tried to conquer:
[url=http://chipmusic.org/ch3dd4r]Le Chipmusic
[url=http://battleofthebits.org/barracks/Profile/CH3DD4R/]Le BattleOfTheBits
Page 1 of 2 Sort: Goto Page: [1] [2] Next >>