FSXA Sound effects

#21
Hi George:

As we are still researching 'out into the wild' beyond what was "documented" by ACES for the FSX Special Effects SDK, I'd like to better understand the scenario you described, to see if there are additional insights to be gained about successfully implementing FS Effect *.Fx file parameters.


I'd also like to determine whether Fx parameters may require individualized adjustment to accommodate one's effective FS computer system data throughput / FSX run time rendering speed ...to allow more predictable results.


My wav file plays for a much longer time than the chickens so I hear a couple of seconds then a gap before the repeat.

How can I have a continuous loop?

Edit. I changed all of the lifetimes to 24 and it seems ok.

IIUC, "my WAV file" refers to the "ES-Bells.wav" file shown in your 2nd post in this thread:

http://www.fsdeveloper.com/forum/showpost.php?p=622791&postcount=3


IIUC, playing time duration of "ES-Bells.wav" is longer than the 3-second playing time duration of "Barn_Fx.Wav" file as used in my posted 'worked examples' above.

http://www.fsdeveloper.com/forum/showpost.php?p=622791&postcount=3



And IIUC, that "ES-Bells.wav" file is being played by a FSX Effect file structure involving both a Controller Fx file and a 'Main' or 'Basic' type Fx file.



Additionally, IIUC, you found upon further testing, that if you used a parameter setting of:

* [controller.0] Lifetime=24.00, 24.00 in the Controller Fx file

...and:

* [Emitter.0] Lifetime=24.00, 24.00 in the 'Main' or 'Basic' Fx file

...the "ES-Bells.wav" sound was then able to be played in proper synchonization (without a gap before the "Looping=TRUE" parameter caused that file to be re-played) ? :confused:



Just to clarify further, you did not also set:

* [Library Effect] Lifetime=24.00, 24.00 in the Controller Fx file (...rather than Lifetime=5)

...and:

* [Library Effect] Lifetime=24.00, 24.00 in the 'Main' or 'Basic' Fx file (...rather than Lifetime=5)

...did you ? :scratchch


If by any chance you did also set the latter [Library Effect] Lifetime=24.00, 24.00 in both *.Fx files, do I understand correctly that your 2-part *.FX file FS Effect sound placement is successfully and normally playing "ES-Bells.wav" at the placement location (in the manner intended by your default and custom Effect code parameter settings within each file) ?


Thanks in advance for your further explanation of the reported scenario and parameter adjustments which resolved it. :)

GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#22
Hello,

I'm currently working on a problem. It's about the parameters of an effect. I want the peal of a church bell to start at 11:55 am and stop at 12:00 pm, so the bell works for 5 minutes. That works so well. The bell starts ringing at 11:55, but it does not end. But it should stop at 12:00 clock. Here the entire code from the 3-D software, interesting is the section HOD & MOH:

FSXML = <?xml version="1.0" encoding="ISO-8859-1" ?> <FSMakeMdlData version="9.0"> <Attachpoint name="attachpt_bottenhorn_dorfkirche_0"> <AttachedObject> <Effect effectName="fx_bottenhorn_dorfkirche_contoller" effectParams="HOD=11,11;MOH=55,59"/> </AttachedObject> </Attachpoint> </FSMakeMdlData>

I use a fx effect file, wich contain the wav file and the corrospondending controller file, wich contains the fx file. What am I doing wrong?
 
#23
https://www.fsdeveloper.com/forum/threads/sound-effects.424400/post-799825

Hello,

I'm currently working on a problem. It's about the parameters of an effect.

I want the peal of a church bell to start at 11:55 am and stop at 12:00 pm, so the bell works for 5 minutes.

That works so well. The bell starts ringing at 11:55, but it does not end. But it should stop at 12:00 clock.

Here (is the entire code from the 3-D software; (especially) interesting is the section HOD & MOH:

FSXML =

<?xml version="1.0" encoding="ISO-8859-1" ?>
<FSMakeMdlData version="9.0">
<Attachpoint name="attachpt_bottenhorn_dorfkirche_0">
<AttachedObject>
<Effect effectName="fx_bottenhorn_dorfkirche_contoller" effectParams="HOD=11,11;MOH=55,59"/>
</AttachedObject>
</Attachpoint>
</FSMakeMdlData>

I use a fx effect file, which contains the *.wav file and the corresponding controller file, which contains the fx file.

What am I doing wrong?

Hi Christian:

If you open in Windows NotePad, the:

fx_bottenhorn_dorfkirche_controller.fx file

...and the *.Fx file 'called' by the above *.Fx 'controller' file:

fx_bottenhorn_dorfkirche.fx (...or whatever the actual 'main' *.Fx file name is)

...then post all the text into this thread, we would be better able to help troubleshoot this scenario. :)


Alternatively, you can use ADE, gadgets' / Don Grovestine's FenceBuilder Pro, or SBuilderX to place an Effect *.Fx controller file via BGLComp, then copy EffectParams structures from the BGLComp XML code ...if you prefer a *.Fx to be placed / launched via a 3D MDL AttachPoint. ;)

GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#24
Hello Garry.

Here first the contents of the FX file and the Contoller file:


fx_bottenhorn_dorfkirche.fx
Code:
[Library Effect]
Lifetime=5
Version=2.00
Display Name=Bottenhorn Dorfkirche
Radius=5000
Priority=0
[Sound]
FileName=bottenhorn_dorfkirche.wav
MinAttenuationDistance=110.00
Looping=FALSE

[Properties]

[Emitter.0]
Lifetime=170.00, 170.00
Delay=0.00, 0.00
Bounce=0.00
Rate=1.00, 1.00
X Emitter Velocity=0.00, 0.00
Y Emitter Velocity=0.00, 0.00
Z Emitter Velocity=0.00, 0.00
Drag=0.00, 0.00
X Particle Velocity=0.00, 0.00
Y Particle Velocity=0.00, 0.00
Z Particle Velocity=0.00, 0.00
X Rotation=0.00, 0.00
Y Rotation=0.00, 0.00
Z Rotation=0.00, 0.00
X Offset=0.00, 0.00
Y Offset=0.00, 0.00
Z Offset=0.00, 0.00
Pitch=0.00, 0.00
Bank=0.00, 0.00
Heading=0.00, 0.00

[Particle.0]
Lifetime=170.00, 170.00
Type=19
X Scale=1.00, 1.00
Y Scale=1.00, 1.00
Z Scale=0.00, 0.00
X Scale Rate=0.00, 0.00
Y Scale Rate=0.00, 0.00
Z Scale Rate=0.00, 0.00
Drag=0.00, 0.00
Color Rate=0.00, 0.00
X Offset=0.00, 0.00
Y Offset=0.00, 0.00
Z Offset=0.00, 0.00
Fade In=0.00, 0.00
Fade Out=0.00, 0.00
Rotation=0.00, 0.00
Face=0, 0, 0

[ParticleAttributes.0]
Blend Mode=0
Bounce=0.00
Color Start=0, 0, 0, 0
Color End=0, 0, 0, 0
Jitter Distance=0.00
Jitter Time=0.00
uv1=0.00, 0.00
uv2=0.00, 0.00
X Scale Goal=0.00
Y Scale Goal=0.00
Z Scale Goal=0.00
Extrude Length=0.00
Extrude Pitch Max=0.00
Extrude Heading Max=0.00
fx_bottenhorn_dorfkirche_contoller.fx
Code:
[Library Effect]
Lifetime=5
Version=2.00
Radius=5000
Priority=0

[controller.0]
lifetime=0.0, 0.0
type=3
distance=5000.00, 5000.00
delay=150.00, 150.00
x offset=0.00, 0.00 
y offset=0.00, 0.00 
z offset=0.00, 0.00
effect.0=fx_bottenhorn_dorfkirche.fx, 0.00, 0.00, 0.00, 0.00, 0.00, 0.00, 2.00, 3.00

I have to describe my request a bit easier. The bell will play once a day for 5 minutes - from 11:54 to 12:00 clock. In the meantime I had modified the WAV file. The WAV file is now 2:30 minutes long, the parameter "Loop" has been set to False. Initial tests show a satisfactory result. But it would be better if the sound is only 3 seconds long and repeated for 5 minutes and silences after 5 minutes.

It all seems too complicated to me. But how to set the effect, that of course I know. It was installed as an AttachPoint via Attach Point Tool directly in the 3-D model of the church and was then provided with this parameter:

Code:
FSXML = <?xml version="1.0" encoding="ISO-8859-1" ?> <FSMakeMdlData version="9.0"> <Attachpoint name="attachpt_bottenhorn_dorfkirche_0"> <AttachedObject> <Effect effectName="fx_bottenhorn_dorfkirche_contoller" effectParams="HOD=11,11;MOH=55,58"/> </AttachedObject> </Attachpoint> </FSMakeMdlData>

AttachPoint with Parameter and Code

So the question is, how do I bring the parameters HOD and MOH into the singleton, so that the bell sound repeats, but then dies after 5 minutes. Probably I think too complicated here :-(
 
#25
Hi Christian:

Do you now have a 3-second long version to test ...of the original 2-1/2 minute long "Bell" *.WAV sound file ? :scratchch

PS: Here is a "COMPACT" minimum required code version to test of your original:

fx_bottenhorn_dorfkirche.fx

[Library Effect]
Lifetime=5
Version=2.00
Display Name=Bottenhorn Dorfkirche COMPACT
Radius=5000
Priority=0

[Sound]
FileName=bottenhorn_dorfkirche.wav
MinAttenuationDistance=110.00
Looping=FALSE

[Properties]
Cockpit=1
VirtualCockpit=1
Spot=1
Tower=1
Map=1

[Emitter.0]
Lifetime=170.00, 170.00
Rate=1.00, 1.00
GaryGB
 
Last edited:
#27
Hi Christian:

I have made some *.Fx files of the above Effect code, and will see if I can refresh my memory on how your goal might be achieved. :scratchch

FYI: I have a "loop" of your Bell sound playing now at the church coordinates in FSX, to use as a test via a saved *.FLT file. :cool:


PS: Here is the BGLComp XML code that places your do_reinoldikirche.wav sound Effect via a stand-alone BGL (not via a placed MDL):

<?xml version="1.0" encoding="ISO-8859-1"?>
<FSData
version="9.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:noNamespaceSchemaLocation="bglcomp.xsd">
<!-- bottenhorn_dorfkirche_Fx_Obj_Plc.bgl -->

<SceneryObject
lat="50.794852"
lon="8.479078"
alt="0.0M"
altitudeIsAgl="TRUE"
pitch="0"
bank="0"
heading="0"
imageComplexity="VERY_SPARSE">
<Effect
effectName="fx_bottenhorn_dorfkirche_contoller.fx"
effectParams=""/>
</SceneryObject>
</FSData>
Hopefully I might find a way for this to be "scheduled" via the "EffectParams" XML singleton cited above ...by some time on Friday, :coffee:;)

GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#28
Many thanks for your help. It will probably be enough to copy the WAV file and extend it from 6 seconds to 2-3 minutes. Had in the meantime played through further situation and found that the 3 Sec variant (with loop = true) does not lead to the goal. But there is still a viable solution, even if it is not 100% satisfactory :)
 
#29
Hi Christian:

I have achieved a "rough" proof- of-concept that plays the above linked 6-Second *.WAV for only 5 minutes from 11:55 A.M. until Noon. :idea:

This is done with "Looping=FALSE" by including a "[Particle.0] Lifetime=" parameter value

If you are interested, let me know, and I will attach a ZIP of the 'work-in-progress' file set. :)



PS: Gawd, the Special Effects SDK is so profoundly under-documented; give me 60 seconds ("SOM=0,59") in a locked room with ACES ! :mad:

< No wonder there are so few examples of how to play Effect *.Fx files on a 'scheduled' basis other than via "Periods" of the day ! :banghead: >

GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#30
Moin Gary.

So is there any way to do it that way? Well, that would be a fat dog !
Then I would like to ask you something to chat from the sewing box, that would be worth a further test :scratchch
 
#31
https://www.fsdeveloper.com/forum/threads/sound-effects.424400/post-799984

Moin Gary.

So is there any way to do it that way? Well, that would be a fat dog !
Then I would like to ask you something to chat from the sewing box, that would be worth a further test :scratchch

Hi Christian:

Sorry, but I am rather unfamiliar with some German colloquial expressions, so please forgive my confusion. :oops:


(But before I assume that I am being invited to send you a Chicago-style 'Hot Dog', a bit of fun is in order !). :)



https://en.wikipedia.org/wiki/Dirty_Hungarian_Phrasebook


However, I have the impression that you intended to do more than "keep me in stitches" from laughing. :rotfl:

So, may I suggest that perhaps Google's translate feature might help ? :idea:

https://www.google.com/search?biw=1.....0...1.1.64.psy-ab..0.1.247....0.LzgEO-a-DoI

GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#32
"My Hoovercraft ist full of eels" :laughing:

Hi Gary.

In the context of problem solving, a "fat dog" is a paraphrase for a good cause. It means something like "That would be great," or "If that works, it would be very nice." It is a positive phrase. You can not eat a "fat dog"!
 
#33
Hi Christian:

I sent you a PM with an attachment of the Scheduled_Sound_Loop_WIP "'work-in-progress" files. ;)


When I can get some more time available, I will try to fine-tune the synchronization of the re-played Bell sound so that it works precisely.

After I have achieved that, I will post a copy of all the source code as a worked example for the FS community to refer to, as I have not yet been able to find a publicly-posted example of how to play Effect *.Fx files on a 'scheduled' basis other than via "Periods" of the day. :teacher:

Although you appear to still be exploring your options with the length of the *.WAV file to be played, I thought you might wish to review the source code in the PM since "A stitch in time saves nine". :)

https://en.wiktionary.org/wiki/a_stitch_in_time_saves_nine


PS: Thanks for recently posting your excellent "worked example" files to FS Developer 'Resources'; I owe you a "Chicgo-style Hot Dog" ! :D

https://en.wikipedia.org/wiki/Chicago-style_hot_dog


GaryGB
 
Last edited:

Christian Bahr

Resource contributor
#34
A hot dog in the Chicago style would suit my taste very much: D

And the philosophy "A stitch in time saves nine" corresponds exactly to my ideas of scenery design!

Have now tested your concept. It seems like the WAV file is always restarted as soon as I move in avatar mode with the avatar towards the church. If I stop, then the sound is played correctly. But as soon as I start walking again, there is a kind of stuttering effect of the sound. Just as if the sound is started over and over again. The strange thing is that this happens only when I move to the sound. If I turn with the avatar and stand with my back to the sound and walk in the opposite direction, then the sound is reproduced correctly - it does not stutter.

Now I have tried something myself and as it is now, it works very well. Nevertheless. The sound system of the FSX / P3D remains a big mystery to me. Enclosed the files. You are welcome to post and disclose it to users. It is to wish that it helps someone further :)
 
#35
Hi Christian:

Many thanks again for your generosity in sharing the above innovation and example work-flow with other FS developers. :)


FYI: I have been rather pre-occupied with time commitment on other projects over this last week, and have not yet had time to work further with your linked files; but hope to do so after I return from traveling for the next week or so. ;)

I am referring Caleb to this thread (and perhaps to your advisment as well ? :teacher:), in order for him to study the concepts in this thread in preparation for enhancing a puddle on the ground so it will display a small splash Effect and to play a splash sound when the user aircraft rolls over it. :idea:

https://www.fsdeveloper.com/forum/threads/puddles.442953/


Regards,

GaryGB
 

Christian Bahr

Resource contributor
#36
Hi Gary,

these are very interesting approaches that you are discussing in the puddle topic. Really interesting! I find these cross-connections of different techniques such as the fx files, the material settings and the platform as a water surface particularly interesting :)
 
Top