bug: 1.3.0 and 3d sound (incl. fix)

Announcements and discussion regarding any projects related to Cyan Worlds' Plasma Engine including (but not limited to) CyanWorlds.com Engine, Drizzle, OfflineKI, PyPRP, and libHSPlasma.

bug: 1.3.0 and 3d sound (incl. fix)

Postby D'Lanor » Sun Mar 02, 2008 3:33 pm

I cannot get the 3d sound to work anymore.

My 1.2.1 alcscript flags looked like this:

Code: Select all
    flags: 3d|local


For 1.3.0 I changed it according to the new tutorial:

Code: Select all
    flags:
      - is3dsound
      - localonly


The sound however is not 3d. I was unable to test the local sound obviously, but it didn't show up in the logfile either.
Last edited by D'Lanor on Tue Mar 04, 2008 6:57 am, edited 1 time in total.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: 1.3.0 and 3d sound

Postby D'Lanor » Mon Mar 03, 2008 3:29 pm

My 3d sound suddenly started working again after I deleted the pyc files in the scripts folder.

Edit: and now it is non 3d again at the next export. This is driving me nuts.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: Bug: 1.3.0 and 3d sound (incl. fix)

Postby D'Lanor » Tue Mar 04, 2008 6:55 am

I think I fixed the flags problem in the alc_SndClasses.py source file. Can the developers evaluate this?

I noticed that in 1.2.1 the flags were set in self.fProperties:

Code: Select all
        flags = FindInDict(objscript,"sound.flags", "")
        flags = flags.replace(" ","")
        f = flags.split('|')
        for prop in f:
            if(prop == "3d"):
                self.fProperties |= plSound.Properties["kPropIs3DSound"]
            if(prop == "loop"):
                self.fProperties |= plSound.Properties["kPropLooping"]
            if(prop == "start"):
                self.fProperties |= plSound.Properties["kPropAutoStart"]
            if(prop == "local"):
                self.fProperties |= plSound.Properties["kPropLocalOnly"]


1.3.0 sets them in self.fFlags like this:

Code: Select all
        flags = FindInDict(objscript,"sound.flags",[])
        if type(flags) == list:
            self.fFlags = 0 # reset
            for flag in flags:
                if flag.lower() in plWin32Sound.scriptProps:
                    idx =  plWin32Sound.scriptProps[flag.lower()]
                    self.fFlags |= idx


self.fProperties is no longer set anywhere after being initialized with a default value.

So I changed self.fFlags back to self.fProperties and everything is ok now. :)

Code: Select all
        flags = FindInDict(objscript,"sound.flags",[])
        if type(flags) == list:
            self.fProperties = 0 # reset
            for flag in flags:
                if flag.lower() in plWin32Sound.scriptProps:
                    idx =  plWin32Sound.scriptProps[flag.lower()]
                    self.fProperties |= idx


Not sure why I thought it was working briefly once before (see previous post). Perhaps I mixed up my plugin versions and accidently loaded 1.2.1. Anyway, it works for me now at every export.
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby Paradox » Tue Mar 04, 2008 8:56 am

o.o

Why did any of my sounds work? I should have noticed a coding error like that long before a release :x
"And one day I woke to find the future held no place for me. I was unwanted in a world, that with my hands I'd helped to build. Where once was honesty and pride, I now stand broken and alone."
Paradox
 
Posts: 1261
Joined: Fri Sep 28, 2007 6:48 pm
Location: Canada

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby D'Lanor » Tue Mar 04, 2008 9:08 am

The sounds worked ok. They just weren't 3d (which can be checked by rotating your avatar). There were no export errors and nothing even shows up differently in the age logfile.

Edit: I uploaded my proposed fix to the contrib section of the SVN. I expected a password protection, but write access seems to be public. :o
"It is in self-limitation that a master first shows himself." - Goethe
User avatar
D'Lanor
 
Posts: 1980
Joined: Sat Sep 29, 2007 4:24 am

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby Robert The Rebuilder » Tue Mar 04, 2008 10:03 am

D'Lanor wrote:I uploaded my proposed fix to the contrib section of the SVN. I expected a password protection, but write access seems to be public. :o


Correct me if I'm wrong, Trylon, but I believe that's the point of the contrib folder: anyone can contribute to the plugin. The contents are reviewed, then eventually incorporated into the trunk.
Can we rebuild it? Yes, we can - here's how.

MOULagain KI# 1299

Myst Movie coming soon - spread the word!
User avatar
Robert The Rebuilder
 
Posts: 1383
Joined: Sat Sep 29, 2007 7:24 am
Location: Virginia, US

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby Nadnerb » Tue Mar 04, 2008 12:46 pm

Robert The Rebuilder wrote:
D'Lanor wrote:I uploaded my proposed fix to the contrib section of the SVN. I expected a password protection, but write access seems to be public. :o


Correct me if I'm wrong, Trylon, but I believe that's the point of the contrib folder: anyone can contribute to the plugin. The contents are reviewed, then eventually incorporated into the trunk.

This is correct. Also, D'lanor, your fix has been reviewed and merged with the trunk. Thanks. 8-)
Live KI: 34914 MOULa KI: 23247 Gehn KI: 11588 Available Ages: TunnelDemo3, BoxAge, Odema
Nadnerb
 
Posts: 1057
Joined: Fri Sep 28, 2007 8:01 pm
Location: US (Eastern Time)

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby boblishman » Sun Mar 09, 2008 11:39 am

So... has this fix been added to the 1.3.0 download and "latest.zip" too (HERE ... or are those still "broken" ... ?
when it comes to Age creation ... "DOH" seems to be my middle name...
User avatar
boblishman
 
Posts: 837
Joined: Fri Oct 05, 2007 4:47 pm
Location: Spain

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby andylegate » Sun Mar 09, 2008 12:49 pm

I think (and I do stress that word, think) that it is in the latest. The post by Nadnerb seems to indicate that the fix was reviewed and added to the plugin you would download. I think.
"I'm still trying to find the plKey for Crud!"
Image
Blender Age Creation Tutorials
3DS Max Age Creation Tutorials
User avatar
andylegate
 
Posts: 2348
Joined: Mon Oct 01, 2007 7:47 am

Re: bug: 1.3.0 and 3d sound (incl. fix)

Postby boblishman » Sun Mar 09, 2008 12:54 pm

andylegate wrote:I think (and I do stress that word, think) that it is in the latest. The post by Nadnerb seems to indicate that the fix was reviewed and added to the plugin you would download. I think.


well... it says it was added to the svn ... not the zip file ... sure, I can go and get it from the trunk, I was just hoping that for less experienced writers that it would have been added to the zips
when it comes to Age creation ... "DOH" seems to be my middle name...
User avatar
boblishman
 
Posts: 837
Joined: Fri Oct 05, 2007 4:47 pm
Location: Spain

Next

Return to Plasma Development

Who is online

Users browsing this forum: No registered users and 2 guests

cron