1
1
Fork 0
mirror of https://github.com/QB64-Phoenix-Edition/QB64pe.git synced 2024-07-01 15:00:38 +00:00
QB64-PE/internal/help/_SNDOPENRAW.txt

38 lines
913 B
Plaintext
Raw Normal View History

2016-03-18 11:36:04 +00:00
{{DISPLAYTITLE:_SNDOPENRAW}}
2017-10-10 14:55:21 +00:00
The [[_SNDOPENRAW]] function opens a new channel to fill with _SNDRAW content to manage multiple dynamically generated sounds.
2016-03-18 11:36:04 +00:00
{{PageSyntax}}
2017-10-10 14:55:21 +00:00
: {{Parameter|pipeHandle&}} = [[_SNDOPENRAW]]
2016-03-18 11:36:04 +00:00
2017-10-10 14:55:21 +00:00
{{PageDescription}}
2016-03-18 11:36:04 +00:00
* You can manage multiple dynamically generated sounds at once without having to worry about mixing.
* Use [[_SNDCLOSE]] to remove the pipe sound handles from memory.
2017-10-10 14:55:21 +00:00
{{PageExamples}}
2016-03-18 11:36:04 +00:00
''Example:'' Combining 2 sounds without worrying about mixing:
{{CodeStart}} '' ''
a = {{Cl|_SNDOPENRAW}}
b = {{Cl|_SNDOPENRAW}}
{{Cl|FOR...NEXT|FOR}} x = 1 {{Cl|TO}} 100000
{{Cl|_SNDRAW}} {{Cl|SIN}}(x / 10), , a 'fill with a tone
{{Cl|_SNDRAW}} {{Cl|RND}} * 1 - 0.5, , b 'fill with static
{{Cl|NEXT}}
{{Cl|_SNDCLOSE}} a
{{Cl|_SNDCLOSE}} b '' ''
{{CodeEnd}}{{small|Code by Galleon}}
{{PageSeeAlso}}
2017-10-10 14:55:21 +00:00
* [[_SNDRAWDONE]]
2016-03-18 11:36:04 +00:00
* [[_SNDRAW]]
* [[_SNDCLOSE]]
2019-04-15 01:15:33 +00:00
{{PageNavigation}}
<