Bay 12 Games Forum

Please login or register.

Login with username, password and session length
Advanced search  
Pages: 1 ... 59 60 [61] 62 63 ... 105

Author Topic: SoundSense: a sound engine for dwarf fortress.  (Read 578628 times)

Cobbler89

  • Bay Watcher
  • Cobbler cancels celebrate Caesar: mending soles
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #900 on: December 27, 2012, 08:09:31 pm »

Alright, so, I have one last set of tweaks to this enhancement. I am double-posting because editting my posts too much is starting to feel worse than double-posting.

So, I decided that rather than requiring packs be all split up by directory, at times it may be smoother just to let the user <includeListing filePathAndName="pathto/sounds.xml"/>

I also added the ability to shut off the freaking absolute path warning, for guys like me who want to have listings of our own music that isn't in the DF folder and may as well not be relative. You can keep it on if you like, or turn it off. It's "noWarnAbsolutePath" on the soundpacks element ("true" disables the warning, "false" enables it -- could if you prefer consider swapping that to "warnAbsolutePath" and make "true" keep the warning and "false" disable it, but in any case... it's there -- let me know ASAP if you want it swapped and I can upload yet another change, otherwise I'm hoping this is the end of my stream of little adjustments).

I think that covers everything; I am going to count this as "version 2.0" of my enhancements. Sorry to keep throwing extra tidbits on and on.

As always please let me know if you need any help or have any questions or just plain don't like anything in particular!



I think another thing that should be worked on, but is an entirely separate addition in any case, is support for an attribution log, where the sounds would have their attribution (copyright holder, source url and maybe basic type of license, plus maybe actual name of song if that can't be pulled from in the sound file itself) listed in the sound tag and if the configuration is set to "log attributions" then save the timestamp, name, copyright holder, source and maybe basic type of license to a text file as each sound is played so you can more easily pull up the attributions if you use Soundsense while recording a video for YouTube. I have basic ideas but will have to work through getting that set if I want to put it together myself, and I don't have as much freetime as I did just before/on Christmas.
Logged
Quote from: Mr S
You've struck embedded links. Praise the data miners!
Quote from: Strong Bad
The magma is seeping under the door.

Quote from: offspring
Quote from: Cobbler89
I have an idea. Let's play a game where you win by being as quiet as possible.
I get it, it's one of those games where losing is fun!
I spend most of your dimension's time outside of your dimension. I can't guarantee followup or followthrough on any comments, ideas, or plans.

zwei

  • Bay Watcher
  • [ECHO][MENDING]
    • View Profile
    • Fate of Heroes
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #901 on: December 28, 2012, 01:30:46 pm »

First, I have added ¨poject to google code: https://code.google.com/p/df-soundsense/ and will suibmit code changes there

Seccond, i have looked over code and changes are good, i just have some notes:
 * I found pack selection dialog annoying and removed it - it also was in xml reading class which should not do anything gui related. Better solution for pack selection other than typing directory name should be made.

And thats it :-)

Attribution as part of configuration files sounds interesting - i guess soundFile tag could be enriched by:
 * source url
 * license
 * date of retrieval
 * author
And this could be outputtable to log file

Also, missiong attribution could be annonying parse errors :-)

Cobbler89

  • Bay Watcher
  • Cobbler cancels celebrate Caesar: mending soles
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #902 on: December 30, 2012, 01:30:00 am »

That's cool -- I admit the choose pack dialog was a hack, inasmuch as it was just the fastest thing I could throw in there to allow picking the pack without manually editting the config file (although you still had to go into the config file to disable this and use whatever you specified as the "default" directory, so that probably wasn't so convenient), and isn't really the right solution for the reasons you point out, plus it's your project to decide what's more annoying than helpful.

If we were to allow switching the pack without manually editting the config file, would we want something more in the line of the filesystem browsing dialog (of course, specifying that what we want is a directory) that Windows makes available to most programs? (I think it's called the "Open File Dialog", obviously enough. If only everything about Windows were that obvious, really...)

Google says (if I'm understanding correct) that in Java, using Java code rather than OS-specific stuff, there's a Swing thing for this and an Awt thing for this. (At least, I think Awt is a general Java library like Swing; I'm not familiar with Awt though.) Would we want the Swing way (assuming this is what we want at all)?

Given that the pack initially loads before the GUI, would it make sense to have SoundSense.java call whatever directory-choosing browser/method is ultimately used before loading the pack the first time? Or would it make more sense to load the GUI and let the GUI load the pack so it's all handled normally in the GUI whether loading, reloading or choosing a different directory? Or would it be best to continue initially loading the default pack specified in the config file, and make changing it require letting Soundsense load the current one before you get to the GUI where you can switch the pack directory and reload? I'm actually leaning toward the middle option, assuming there's not some other way to integrate it that I'm overlooking, and still assuming that having some way within Soundsense to change the directory without manually editting the configuration is desirable (I know I at any rate would use it, though as I said before I'm an oddity and it needs to be something that at the least can be switched off so as to be nonintrusive for anyone who wouldn't use it).



I also have an entirely unrelated issue -- yesterday I discovered that setting delay="8500" in your sound element does not wait 8.5 seconds to play music on a channel. (8.5 seconds is the length of the Bay 12 Games and Toady One logos/whatever before the DF intro.) Is that intentional? I don't see any particular reason not to allow the user to deliberately set music (channel-bound sound) to come on only after a sound effect or pause, unless how the channel works is incompatible with setting a delay. I was hoping to be able to make music play at the end of a sound effect, or over the DF intro after the Bay 12 / Toady One logo thingies at the beginning. Of course I could just make it a channelless sound effect -- but then I can't stop it early when other music is switched on. (By the way, it also appears, unless I got horribly turned around trying to figure this out, that haltOnMatch actually defaults to false if not present, which probably is intentional but I had assumed otherwise based on usage examples -- I'll have to double-check the directions on that point.)



To throw on the brainstorming pile: another wild thing that might be handy is to make SoundsXML read/write instead of just read so that another GUI/application could be built to assist in creating and editting sound/music listings. (Would that be able to write comments if it's possible at all? If not that could be a notable limitation...) That's practically a whole new project, however, albeit entirely connected to this one. Hey, I might do it if I find enough time before my interest wanders to something completely different. (If I don't, I might come back and do it in a couple years if nobody has and one day I wake up and feel like it. When it comes to spare time projects I'm not spending my employed forty hours a week on, I can sometimes be a fickle coder, but I try to work with stuff in such a way that it doesn't hurt to leave it and come back to it later.)



Going on New Year's visit to relatives tomorrow, so I may not be back for a week, but I'll make sure I look for any replies/comments by next weekend at least.
Logged
Quote from: Mr S
You've struck embedded links. Praise the data miners!
Quote from: Strong Bad
The magma is seeping under the door.

Quote from: offspring
Quote from: Cobbler89
I have an idea. Let's play a game where you win by being as quiet as possible.
I get it, it's one of those games where losing is fun!
I spend most of your dimension's time outside of your dimension. I can't guarantee followup or followthrough on any comments, ideas, or plans.

zwei

  • Bay Watcher
  • [ECHO][MENDING]
    • View Profile
    • Fate of Heroes
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #903 on: January 05, 2013, 02:04:38 pm »

...

I think that reloading is unnecessary.

Each sound "knows" name of xml file which contained it (parentFile attribute), so we can keep list of disabled xmls and ignore sounds contained in them. That allows players to toggle sound sets while running with minimal reloading needed (only when something actually changes in filesystem)

And since gui already shows tree with xml files and related sounds in second tab, that could be natural place for disabling them.

----

haltonmatch should be true by default.

Delay should indeed be ingnored on channel - but i think i should fix that.

----

Editor for soundpacks is interesting idea, but i am not really sure whether it will be worthwhile. Go for it if you want to, i guess.

Cobbler89

  • Bay Watcher
  • Cobbler cancels celebrate Caesar: mending soles
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #904 on: January 05, 2013, 06:59:18 pm »

Let me double-check that I got this right... have the selected directory load all the packs (official, my custom ones, etc.), and then disable the ones I don't want to use at any given point?

That would certainly make it a matter of the GUI, and in some ways simplify the mixing of packs in various combinations, but on the other hand with pack(s) (sets) like the default pack set that are split up into many, many xml files it could get rather tedious, and for complex combinations (e.g. "this set of music, but also the official weather sounds and the official cat headbump sound effects, plus the recording of me saying 'I'm Batman' set to play whenever the log includes '.*[Bb]atm[ae]n.*' just because I'm funny like that") would be a lot more manual than just picking a listing that loads/activates the right combination of sounds/music... And I have no idea whether the autoupdater would work as intended/desired for particular pack sets if Soundsense also loaded a whole bunch of other pack sets either, whether multiple pack sets' autoupdate configurations could be loaded into Soundsense at once, things like that, though I suppose with a little experimentation and/or code investigation I could find that out.

I guess I'll keep chewing it over for the moment; I've just had a couple other things dumped in my lap for me to take care of/participate in for a while, too, so I can't try anything in particular just yet.
Logged
Quote from: Mr S
You've struck embedded links. Praise the data miners!
Quote from: Strong Bad
The magma is seeping under the door.

Quote from: offspring
Quote from: Cobbler89
I have an idea. Let's play a game where you win by being as quiet as possible.
I get it, it's one of those games where losing is fun!
I spend most of your dimension's time outside of your dimension. I can't guarantee followup or followthrough on any comments, ideas, or plans.

Skin36

  • Bay Watcher
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #905 on: January 06, 2013, 04:29:22 am »

http://shot.qip.ru/00b0A8-3VVx8eqRz/

These two files are not played
Logged

zwei

  • Bay Watcher
  • [ECHO][MENDING]
    • View Profile
    • Fate of Heroes
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #906 on: January 06, 2013, 08:14:36 am »

http://shot.qip.ru/00b0A8-3VVx8eqRz/

These two files are not played

I just tried them and they do play on my system. Can you try with newer ss?

Let me double-check that I got this right... have the selected directory load all the packs (official, my custom ones, etc.), and then disable the ones I don't want to use at any given point?

That would certainly make it a matter of the GUI, and in some ways simplify the mixing of packs in various combinations, but on the other hand with pack(s) (sets) like the default pack set that are split up into many, many xml files it could get rather tedious, and for complex combinations (e.g. "this set of music, but also the official weather sounds and the official cat headbump sound effects, plus the recording of me saying 'I'm Batman' set to play whenever the log includes '.*[Bb]atm[ae]n.*' just because I'm funny like that") would be a lot more manual than just picking a listing that loads/activates the right combination of sounds/music... And I have no idea whether the autoupdater would work as intended/desired for particular pack sets if Soundsense also loaded a whole bunch of other pack sets either, whether multiple pack sets' autoupdate configurations could be loaded into Soundsense at once, things like that, though I suppose with a little experimentation and/or code investigation I could find that out.

I guess I'll keep chewing it over for the moment; I've just had a couple other things dumped in my lap for me to take care of/participate in for a while, too, so I can't try anything in particular just yet.

Well, I went ahead and implemented it as a feature :-) Yes, it would be annoying to set up everything as you want to, but it is something done only once i guess. I can make it saner by enabling user to toggle whole group (= xmls found in same directory)



New release r37: http://df.zweistein.cz/soundsense/soundSense_37_167.zip

* Parts of soundpacks contained in single xml file can be toogled on and off.
* Delay now works as expected with sounds played on channels.

Skin36

  • Bay Watcher
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #907 on: January 06, 2013, 08:35:58 am »




http://shot.qip.ru/00b0A8-3VVx8eqRz/

These two files are not played

I just tried them and they do play on my system. Can you try with newer ss?


in new release r37  it work ))) thanks !
Logged

OverlordTNT

  • Bay Watcher
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #908 on: January 11, 2013, 01:22:35 pm »

suggestion: dwarves should make a "derp" sound with every step they take
Logged

thburns

  • Bay Watcher
  • I came, I saw..... It sucked!
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #909 on: January 15, 2013, 07:53:24 am »

This is bothering me. I have recently tried soundsense, but when I update the files and try to restart AVG finds viruses. What the hell?
Logged
If only life and parenting were as easy as "Dwarf Fortress"

zwei

  • Bay Watcher
  • [ECHO][MENDING]
    • View Profile
    • Fate of Heroes
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #910 on: January 15, 2013, 08:35:18 am »

This is bothering me. I have recently tried soundsense, but when I update the files and try to restart AVG finds viruses. What the hell?

What exactly does it report?

I just put ss throught various online multi-av scanner services and it did not find anything interesting.

thburns

  • Bay Watcher
  • I came, I saw..... It sucked!
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #911 on: January 15, 2013, 08:45:34 am »

I don't remember exactly. First time I used it was with masterwork. I updated the sound files, then ran both SS and masterwork. AVG found a medium threat in both. Then using LNP, SS, It just found one in SS. In both cases it removed entire SS utility. As for masterwork the virus was only found after updating SS. (i.e. I played masterwork for a few days with no problem, until SS.)
Logged
If only life and parenting were as easy as "Dwarf Fortress"

Greiger

  • Bay Watcher
  • Reptilian Illuminati member. Keep it secret.
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #912 on: January 15, 2013, 12:08:27 pm »

Hm I just checked it myself, my Avast! says it's clean but I checked it against an online file scanner I know and it does indeed come up with a hit.  It's probably a false positive though, as it seems to be coming up as a generic form of a virus instead of the virus itself, which seems to indicate to me a heuristics hit.

It comes up as Trojan/JboxGeneric.mkl when scanned by Jiangmin by the site.  Everything else says it's clean though.

Here is the result page for the scan of the .exe

As I said before though it seems to be a false positive as far as I can see.  Maybe some code in StoneSense looks like some JBox code.

---
P.S. Actually my version of soundsense may be outdated.  I'll also see if theres a newer version and scan that as well.
P.P.S Same results for 37. No difference.
« Last Edit: January 15, 2013, 12:16:31 pm by Greiger »
Logged
Disclaimer: Not responsible for dwarven deaths from the use or misuse of this post.
Quote
I don't need friends!! I've got knives!!!

thburns

  • Bay Watcher
  • I came, I saw..... It sucked!
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #913 on: January 15, 2013, 12:14:55 pm »

I hope I deleted it just to be safe, until I had some more info. But I do remember AVG gave a generic name. So yeah it's probably cool.
Logged
If only life and parenting were as easy as "Dwarf Fortress"

Greiger

  • Bay Watcher
  • Reptilian Illuminati member. Keep it secret.
    • View Profile
Re: SoundSense: a sound engine for dwarf fortress.
« Reply #914 on: January 15, 2013, 01:10:36 pm »

Just want to add that I've used soundsense in some way shape or form basically since it began, I have never had any problems with it. 

False positives happen, they happen a lot.  I'm still using soundsense happily even after coming up with those results.  The primary reason I put up my findings is to that Zwei could have as much info as I can give in determining what is causing the hit, and so that others could analyze the results themselves in fairness.  I do not intend to scare anybody away from using the program. 

I love soundsense there have been very few utilities I have used alongside DF.  One is DFHack, the second is Stonesense, and the third is soundsense.
Logged
Disclaimer: Not responsible for dwarven deaths from the use or misuse of this post.
Quote
I don't need friends!! I've got knives!!!
Pages: 1 ... 59 60 [61] 62 63 ... 105