2d-platformer/vendor/SFML-3.0.0/doc/html/classsf_1_1Music.html

2446 lines
150 KiB
HTML

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<title>SFML - Simple and Fast Multimedia Library</title>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8" />
<link rel="stylesheet" type="text/css" href="doxygen.css" title="default" media="screen,print" />
<script type="text/javascript" src="jquery.js"></script>
<script type="text/javascript" src="dynsections.js"></script>
<script type="text/javascript" src="clipboard.js"></script>
<script type="text/javascript" src="cookie.js"></script>
<link rel="stylesheet" type="text/css" href="search/search.css" />
<link rel="stylesheet" type="text/css" href="searchOverrides.css" />
<script type="text/javascript" src="search/searchdata.js"></script>
<script type="text/javascript" src="search/search.js"></script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(document).ready(function() { init_search(); });
/* @license-end */
</script>
</head>
<body>
<div id="banner-container">
<div id="banner">
<span id="sfml">SFML 3.0.0</span>
</div>
</div>
<div id="content">
<div>
<!-- Generated by Doxygen 1.12.0 -->
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
var searchBox = new SearchBox("searchBox", "search/",'.html');
/* @license-end */
</script>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function() { codefold.init(0); });
/* @license-end */
</script>
<div id="navrow1" class="tabs">
<ul class="tablist">
<li><a href="index.html"><span>Main&#160;Page</span></a></li>
<li><a href="topics.html"><span>Topics</span></a></li>
<li><a href="namespaces.html"><span>Namespaces</span></a></li>
<li class="current"><a href="annotated.html"><span>Classes</span></a></li>
<li><a href="files.html"><span>Files</span></a></li>
<li>
<div id="MSearchBox" class="MSearchBoxInactive">
<span class="left">
<span id="MSearchSelect" onmouseover="return searchBox.OnSearchSelectShow()" onmouseout="return searchBox.OnSearchSelectHide()">&#160;</span>
<input type="text" id="MSearchField" value="" placeholder="Search" accesskey="S"
onfocus="searchBox.OnSearchFieldFocus(true)"
onblur="searchBox.OnSearchFieldFocus(false)"
onkeyup="searchBox.OnSearchFieldChange(event)"/>
</span><span class="right">
<a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="search/close.svg" alt=""/></a>
</span>
</div>
</li>
</ul>
</div>
<div id="navrow2" class="tabs2">
<ul class="tablist">
<li><a href="annotated.html"><span>Class&#160;List</span></a></li>
<li><a href="classes.html"><span>Class&#160;Index</span></a></li>
<li><a href="hierarchy.html"><span>Class&#160;Hierarchy</span></a></li>
<li><a href="functions.html"><span>Class&#160;Members</span></a></li>
</ul>
</div>
<script type="text/javascript">
/* @license magnet:?xt=urn:btih:d3d9a9a6595521f9666a5e94cc830dab83b65699&amp;dn=expat.txt MIT */
$(function(){ initResizable(false); });
/* @license-end */
</script>
<!-- window showing the filter options -->
<div id="MSearchSelectWindow"
onmouseover="return searchBox.OnSearchSelectShow()"
onmouseout="return searchBox.OnSearchSelectHide()"
onkeydown="return searchBox.OnSearchSelectKey(event)">
</div>
<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<div id="MSearchResults">
<div class="SRPage">
<div id="SRIndex">
<div id="SRResults"></div>
<div class="SRStatus" id="Loading">Loading...</div>
<div class="SRStatus" id="Searching">Searching...</div>
<div class="SRStatus" id="NoMatches">No Matches</div>
</div>
</div>
</div>
</div>
<div id="nav-path" class="navpath">
<ul>
<li class="navelem"><a class="el" href="namespacesf.html">sf</a></li><li class="navelem"><a class="el" href="classsf_1_1Music.html">Music</a></li> </ul>
</div>
</div><!-- top -->
<div id="doc-content">
<div class="header">
<div class="summary">
<a href="#nested-classes">Classes</a> &#124;
<a href="#pub-types">Public Types</a> &#124;
<a href="#pub-methods">Public Member Functions</a> &#124;
<a href="#pro-methods">Protected Member Functions</a> &#124;
<a href="classsf_1_1Music-members.html">List of all members</a> </div>
<div class="headertitle"><div class="title">sf::Music Class Reference<div class="ingroups"><a class="el" href="group__audio.html">Audio module</a></div></div></div>
</div><!--header-->
<div class="contents">
<p>Streamed music played from an audio file.
<a href="#details">More...</a></p>
<p><code>#include &lt;<a class="el" href="Music_8hpp_source.html">SFML/Audio/Music.hpp</a>&gt;</code></p>
<div class="dynheader">
Inheritance diagram for sf::Music:</div>
<div class="dyncontent">
<div class="center">
<img src="classsf_1_1Music.png" usemap="#sf::Music_map" alt=""/>
<map id="sf::Music_map" name="sf::Music_map">
<area href="classsf_1_1SoundStream.html" title="Abstract base class for streamed audio sources." alt="sf::SoundStream" shape="rect" coords="0,112,115,136"/>
<area href="classsf_1_1SoundSource.html" title="Base class defining a sound&#39;s properties." alt="sf::SoundSource" shape="rect" coords="0,56,115,80"/>
<area href="classsf_1_1AudioResource.html" title="Base class for classes that require an audio device." alt="sf::AudioResource" shape="rect" coords="0,0,115,24"/>
</map>
</div></div>
<table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="nested-classes" name="nested-classes"></a>
Classes</h2></td></tr>
<tr class="memitem:"><td class="memItemLeft" align="right" valign="top">struct &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="structsf_1_1Music_1_1Span.html">Span</a></td></tr>
<tr class="memdesc:"><td class="mdescLeft">&#160;</td><td class="mdescRight">Structure defining a time range using the template type. <a href="structsf_1_1Music_1_1Span.html#details">More...</a><br /></td></tr>
<tr class="separator:"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-types" name="pub-types"></a>
Public Types</h2></td></tr>
<tr class="memitem:a8f92f34d1714edb7178ba2a8a5a845e8" id="r_a8f92f34d1714edb7178ba2a8a5a845e8"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">TimeSpan</a> = <a class="el" href="structsf_1_1Music_1_1Span.html">Span</a>&lt;<a class="el" href="classsf_1_1Time.html">Time</a>&gt;</td></tr>
<tr class="separator:a8f92f34d1714edb7178ba2a8a5a845e8"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac43af72c98c077500b239bc75b812f03" id="r_ac43af72c98c077500b239bc75b812f03"><td class="memItemLeft" align="right" valign="top">enum class &#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03">Status</a> { <a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03ac23e2b09ebe6bf4cb5e2a9abe85c0be2">Stopped</a>
, <a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03ae99180abf47a8b3a856e0bcb2656990a">Paused</a>
, <a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03ac9dbb2b7c84159b632d71e512eba8428">Playing</a>
}</td></tr>
<tr class="memdesc:ac43af72c98c077500b239bc75b812f03"><td class="mdescLeft">&#160;</td><td class="mdescRight">Enumeration of the sound source states. <a href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03">More...</a><br /></td></tr>
<tr class="separator:ac43af72c98c077500b239bc75b812f03"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ab13ce12bd2ef4856511824557b07cce5" id="r_ab13ce12bd2ef4856511824557b07cce5"><td class="memItemLeft" align="right" valign="top">using&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ab13ce12bd2ef4856511824557b07cce5">EffectProcessor</a></td></tr>
<tr class="memdesc:ab13ce12bd2ef4856511824557b07cce5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Callable that is provided with sound data for processing. <br /></td></tr>
<tr class="separator:ab13ce12bd2ef4856511824557b07cce5"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pub-methods" name="pub-methods"></a>
Public Member Functions</h2></td></tr>
<tr class="memitem:a0bc787d8e022b3a9b89cf2c28befd42e" id="r_a0bc787d8e022b3a9b89cf2c28befd42e"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a0bc787d8e022b3a9b89cf2c28befd42e">Music</a> ()</td></tr>
<tr class="memdesc:a0bc787d8e022b3a9b89cf2c28befd42e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Default constructor. <br /></td></tr>
<tr class="separator:a0bc787d8e022b3a9b89cf2c28befd42e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8cf69ccb581b452f442eb01b9348efda" id="r_a8cf69ccb581b452f442eb01b9348efda"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a8cf69ccb581b452f442eb01b9348efda">Music</a> (const std::filesystem::path &amp;filename)</td></tr>
<tr class="memdesc:a8cf69ccb581b452f442eb01b9348efda"><td class="mdescLeft">&#160;</td><td class="mdescRight">Construct a music from an audio file. <br /></td></tr>
<tr class="separator:a8cf69ccb581b452f442eb01b9348efda"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:acc7af0cebb8ca0ca4ab8edccd46499ab" id="r_acc7af0cebb8ca0ca4ab8edccd46499ab"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#acc7af0cebb8ca0ca4ab8edccd46499ab">Music</a> (const void *data, std::size_t sizeInBytes)</td></tr>
<tr class="memdesc:acc7af0cebb8ca0ca4ab8edccd46499ab"><td class="mdescLeft">&#160;</td><td class="mdescRight">Construct a music from an audio file in memory. <br /></td></tr>
<tr class="separator:acc7af0cebb8ca0ca4ab8edccd46499ab"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac762a80c77e26eef4ba5dcf6d4bbd4bd" id="r_ac762a80c77e26eef4ba5dcf6d4bbd4bd"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ac762a80c77e26eef4ba5dcf6d4bbd4bd">Music</a> (<a class="el" href="classsf_1_1InputStream.html">InputStream</a> &amp;stream)</td></tr>
<tr class="memdesc:ac762a80c77e26eef4ba5dcf6d4bbd4bd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Construct a music from an audio file in a custom stream. <br /></td></tr>
<tr class="separator:ac762a80c77e26eef4ba5dcf6d4bbd4bd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:afbf878e783aa23be86edaeda32f967a4" id="r_afbf878e783aa23be86edaeda32f967a4"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#afbf878e783aa23be86edaeda32f967a4">~Music</a> () override</td></tr>
<tr class="memdesc:afbf878e783aa23be86edaeda32f967a4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Destructor. <br /></td></tr>
<tr class="separator:afbf878e783aa23be86edaeda32f967a4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a5b7618e529f9a9898bd9dac217f41e78" id="r_a5b7618e529f9a9898bd9dac217f41e78"><td class="memItemLeft" align="right" valign="top">&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a5b7618e529f9a9898bd9dac217f41e78">Music</a> (<a class="el" href="classsf_1_1Music.html">Music</a> &amp;&amp;) noexcept</td></tr>
<tr class="memdesc:a5b7618e529f9a9898bd9dac217f41e78"><td class="mdescLeft">&#160;</td><td class="mdescRight">Move constructor. <br /></td></tr>
<tr class="separator:a5b7618e529f9a9898bd9dac217f41e78"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a45592644dd5d8b916ee98c0f98039020" id="r_a45592644dd5d8b916ee98c0f98039020"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Music.html">Music</a> &amp;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a45592644dd5d8b916ee98c0f98039020">operator=</a> (<a class="el" href="classsf_1_1Music.html">Music</a> &amp;&amp;) noexcept</td></tr>
<tr class="memdesc:a45592644dd5d8b916ee98c0f98039020"><td class="mdescLeft">&#160;</td><td class="mdescRight">Move assignment. <br /></td></tr>
<tr class="separator:a45592644dd5d8b916ee98c0f98039020"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9493f462e07423d891f117a8b4c613fe" id="r_a9493f462e07423d891f117a8b4c613fe"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a9493f462e07423d891f117a8b4c613fe">openFromFile</a> (const std::filesystem::path &amp;filename)</td></tr>
<tr class="memdesc:a9493f462e07423d891f117a8b4c613fe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Open a music from an audio file. <br /></td></tr>
<tr class="separator:a9493f462e07423d891f117a8b4c613fe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae93b21bcf28ff0b5fec458039111386e" id="r_ae93b21bcf28ff0b5fec458039111386e"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ae93b21bcf28ff0b5fec458039111386e">openFromMemory</a> (const void *data, std::size_t sizeInBytes)</td></tr>
<tr class="memdesc:ae93b21bcf28ff0b5fec458039111386e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Open a music from an audio file in memory. <br /></td></tr>
<tr class="separator:ae93b21bcf28ff0b5fec458039111386e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4e55d1910a26858b44778c26b237d673" id="r_a4e55d1910a26858b44778c26b237d673"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a4e55d1910a26858b44778c26b237d673">openFromStream</a> (<a class="el" href="classsf_1_1InputStream.html">InputStream</a> &amp;stream)</td></tr>
<tr class="memdesc:a4e55d1910a26858b44778c26b237d673"><td class="mdescLeft">&#160;</td><td class="mdescRight">Open a music from an audio file in a custom stream. <br /></td></tr>
<tr class="separator:a4e55d1910a26858b44778c26b237d673"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a288ef6f552a136b0e56952dcada3d672" id="r_a288ef6f552a136b0e56952dcada3d672"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Time.html">Time</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a288ef6f552a136b0e56952dcada3d672">getDuration</a> () const</td></tr>
<tr class="memdesc:a288ef6f552a136b0e56952dcada3d672"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the total duration of the music. <br /></td></tr>
<tr class="separator:a288ef6f552a136b0e56952dcada3d672"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aae3451cad5c16ee6a6e124e62ed61361" id="r_aae3451cad5c16ee6a6e124e62ed61361"><td class="memItemLeft" align="right" valign="top"><a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">TimeSpan</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#aae3451cad5c16ee6a6e124e62ed61361">getLoopPoints</a> () const</td></tr>
<tr class="memdesc:aae3451cad5c16ee6a6e124e62ed61361"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the positions of the of the sound's looping sequence. <br /></td></tr>
<tr class="separator:aae3451cad5c16ee6a6e124e62ed61361"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae7b339f0a957dfad045f3f28083a015e" id="r_ae7b339f0a957dfad045f3f28083a015e"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e">setLoopPoints</a> (<a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">TimeSpan</a> timePoints)</td></tr>
<tr class="memdesc:ae7b339f0a957dfad045f3f28083a015e"><td class="mdescLeft">&#160;</td><td class="mdescRight">Sets the beginning and duration of the sound's looping sequence using <code><a class="el" href="classsf_1_1Time.html" title="Represents a time value.">sf::Time</a></code> <br /></td></tr>
<tr class="separator:ae7b339f0a957dfad045f3f28083a015e"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af05290eb2c6a316790fb18c5912a5dd6" id="r_af05290eb2c6a316790fb18c5912a5dd6"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6">play</a> () override</td></tr>
<tr class="memdesc:af05290eb2c6a316790fb18c5912a5dd6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Start or resume playing the audio stream. <br /></td></tr>
<tr class="separator:af05290eb2c6a316790fb18c5912a5dd6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2285cedcbcb5f3c97828c664934dc0de" id="r_a2285cedcbcb5f3c97828c664934dc0de"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a2285cedcbcb5f3c97828c664934dc0de">pause</a> () override</td></tr>
<tr class="memdesc:a2285cedcbcb5f3c97828c664934dc0de"><td class="mdescLeft">&#160;</td><td class="mdescRight">Pause the audio stream. <br /></td></tr>
<tr class="separator:a2285cedcbcb5f3c97828c664934dc0de"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a781fe51135fdc5679fe22a5665110143" id="r_a781fe51135fdc5679fe22a5665110143"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a781fe51135fdc5679fe22a5665110143">stop</a> () override</td></tr>
<tr class="memdesc:a781fe51135fdc5679fe22a5665110143"><td class="mdescLeft">&#160;</td><td class="mdescRight">Stop playing the audio stream. <br /></td></tr>
<tr class="separator:a781fe51135fdc5679fe22a5665110143"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1f70933912dd9498f4dc99feefed27f3" id="r_a1f70933912dd9498f4dc99feefed27f3"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a1f70933912dd9498f4dc99feefed27f3">getChannelCount</a> () const</td></tr>
<tr class="memdesc:a1f70933912dd9498f4dc99feefed27f3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Return the number of channels of the stream. <br /></td></tr>
<tr class="separator:a1f70933912dd9498f4dc99feefed27f3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7da448dc40d81a33b8dc555fbf0d3fbf" id="r_a7da448dc40d81a33b8dc555fbf0d3fbf"><td class="memItemLeft" align="right" valign="top">unsigned int&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a7da448dc40d81a33b8dc555fbf0d3fbf">getSampleRate</a> () const</td></tr>
<tr class="memdesc:a7da448dc40d81a33b8dc555fbf0d3fbf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the stream sample rate of the stream. <br /></td></tr>
<tr class="separator:a7da448dc40d81a33b8dc555fbf0d3fbf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1ae6bfce0ec385a11e87697323227799" id="r_a1ae6bfce0ec385a11e87697323227799"><td class="memItemLeft" align="right" valign="top">std::vector&lt; <a class="el" href="group__audio.html#ga9800c7f3d5e7a9c9310f707b2c995ff3">SoundChannel</a> &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a1ae6bfce0ec385a11e87697323227799">getChannelMap</a> () const</td></tr>
<tr class="memdesc:a1ae6bfce0ec385a11e87697323227799"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the map of position in sample frame to sound channel. <br /></td></tr>
<tr class="separator:a1ae6bfce0ec385a11e87697323227799"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a607e74492ca84764be563f36d75a1384" id="r_a607e74492ca84764be563f36d75a1384"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03">Status</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a607e74492ca84764be563f36d75a1384">getStatus</a> () const override</td></tr>
<tr class="memdesc:a607e74492ca84764be563f36d75a1384"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the current status of the stream (stopped, paused, playing) <br /></td></tr>
<tr class="separator:a607e74492ca84764be563f36d75a1384"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af416a5f84c8750d2acb9821d78bc8646" id="r_af416a5f84c8750d2acb9821d78bc8646"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#af416a5f84c8750d2acb9821d78bc8646">setPlayingOffset</a> (<a class="el" href="classsf_1_1Time.html">Time</a> timeOffset)</td></tr>
<tr class="memdesc:af416a5f84c8750d2acb9821d78bc8646"><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the current playing position of the stream. <br /></td></tr>
<tr class="separator:af416a5f84c8750d2acb9821d78bc8646"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae288f3c72edbad9cc7ee938ce5b907c1" id="r_ae288f3c72edbad9cc7ee938ce5b907c1"><td class="memItemLeft" align="right" valign="top"><a class="el" href="classsf_1_1Time.html">Time</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#ae288f3c72edbad9cc7ee938ce5b907c1">getPlayingOffset</a> () const</td></tr>
<tr class="memdesc:ae288f3c72edbad9cc7ee938ce5b907c1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the current playing position of the stream. <br /></td></tr>
<tr class="separator:ae288f3c72edbad9cc7ee938ce5b907c1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0c14b35d1dc64bf10e02b7a876540966" id="r_a0c14b35d1dc64bf10e02b7a876540966"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a0c14b35d1dc64bf10e02b7a876540966">setLooping</a> (bool loop)</td></tr>
<tr class="memdesc:a0c14b35d1dc64bf10e02b7a876540966"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set whether or not the stream should loop after reaching the end. <br /></td></tr>
<tr class="separator:a0c14b35d1dc64bf10e02b7a876540966"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4f72aa9d4e185b4c02ffbb97075c7e82" id="r_a4f72aa9d4e185b4c02ffbb97075c7e82"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a4f72aa9d4e185b4c02ffbb97075c7e82">isLooping</a> () const</td></tr>
<tr class="memdesc:a4f72aa9d4e185b4c02ffbb97075c7e82"><td class="mdescLeft">&#160;</td><td class="mdescRight">Tell whether or not the stream is in loop mode. <br /></td></tr>
<tr class="separator:a4f72aa9d4e185b4c02ffbb97075c7e82"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a7593f4e30cde575c057d62ff1c47f1b3" id="r_a7593f4e30cde575c057d62ff1c47f1b3"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a7593f4e30cde575c057d62ff1c47f1b3">setEffectProcessor</a> (<a class="el" href="classsf_1_1SoundSource.html#ab13ce12bd2ef4856511824557b07cce5">EffectProcessor</a> effectProcessor) override</td></tr>
<tr class="memdesc:a7593f4e30cde575c057d62ff1c47f1b3"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the effect processor to be applied to the sound. <br /></td></tr>
<tr class="separator:a7593f4e30cde575c057d62ff1c47f1b3"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a72a13695ed48b7f7b55e7cd4431f4bb6" id="r_a72a13695ed48b7f7b55e7cd4431f4bb6"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a72a13695ed48b7f7b55e7cd4431f4bb6">setPitch</a> (float pitch)</td></tr>
<tr class="memdesc:a72a13695ed48b7f7b55e7cd4431f4bb6"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the pitch of the sound. <br /></td></tr>
<tr class="separator:a72a13695ed48b7f7b55e7cd4431f4bb6"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ad08a99b6f3492b940a2ef20c8d3cbc72" id="r_ad08a99b6f3492b940a2ef20c8d3cbc72"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ad08a99b6f3492b940a2ef20c8d3cbc72">setPan</a> (float pan)</td></tr>
<tr class="memdesc:ad08a99b6f3492b940a2ef20c8d3cbc72"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the pan of the sound. <br /></td></tr>
<tr class="separator:ad08a99b6f3492b940a2ef20c8d3cbc72"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2f192f2b49fb8e2b82f3498d3663fcc2" id="r_a2f192f2b49fb8e2b82f3498d3663fcc2"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a2f192f2b49fb8e2b82f3498d3663fcc2">setVolume</a> (float volume)</td></tr>
<tr class="memdesc:a2f192f2b49fb8e2b82f3498d3663fcc2"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the volume of the sound. <br /></td></tr>
<tr class="separator:a2f192f2b49fb8e2b82f3498d3663fcc2"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a6586a19a8d1060bdf93e3c4b6ee039a7" id="r_a6586a19a8d1060bdf93e3c4b6ee039a7"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a6586a19a8d1060bdf93e3c4b6ee039a7">setSpatializationEnabled</a> (bool enabled)</td></tr>
<tr class="memdesc:a6586a19a8d1060bdf93e3c4b6ee039a7"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set whether spatialization of the sound is enabled. <br /></td></tr>
<tr class="separator:a6586a19a8d1060bdf93e3c4b6ee039a7"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a17ba9ed01925395652181a7b2a7d3aef" id="r_a17ba9ed01925395652181a7b2a7d3aef"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a17ba9ed01925395652181a7b2a7d3aef">setPosition</a> (const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;position)</td></tr>
<tr class="memdesc:a17ba9ed01925395652181a7b2a7d3aef"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the 3D position of the sound in the audio scene. <br /></td></tr>
<tr class="separator:a17ba9ed01925395652181a7b2a7d3aef"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac46223c70c01f43bb6a443001cdd0599" id="r_ac46223c70c01f43bb6a443001cdd0599"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ac46223c70c01f43bb6a443001cdd0599">setDirection</a> (const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;direction)</td></tr>
<tr class="memdesc:ac46223c70c01f43bb6a443001cdd0599"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the 3D direction of the sound in the audio scene. <br /></td></tr>
<tr class="separator:ac46223c70c01f43bb6a443001cdd0599"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aba2cbcc0be18840880b54a112a0e69a1" id="r_aba2cbcc0be18840880b54a112a0e69a1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#aba2cbcc0be18840880b54a112a0e69a1">setCone</a> (const <a class="el" href="structsf_1_1SoundSource_1_1Cone.html">Cone</a> &amp;cone)</td></tr>
<tr class="memdesc:aba2cbcc0be18840880b54a112a0e69a1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the cone properties of the sound in the audio scene. <br /></td></tr>
<tr class="separator:aba2cbcc0be18840880b54a112a0e69a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a3ed894bdb323e26518c9e1548fc3488c" id="r_a3ed894bdb323e26518c9e1548fc3488c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a3ed894bdb323e26518c9e1548fc3488c">setVelocity</a> (const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;velocity)</td></tr>
<tr class="memdesc:a3ed894bdb323e26518c9e1548fc3488c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the 3D velocity of the sound in the audio scene. <br /></td></tr>
<tr class="separator:a3ed894bdb323e26518c9e1548fc3488c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2d229ff4e5f5d61bb12c1a6b94841f96" id="r_a2d229ff4e5f5d61bb12c1a6b94841f96"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a2d229ff4e5f5d61bb12c1a6b94841f96">setDopplerFactor</a> (float factor)</td></tr>
<tr class="memdesc:a2d229ff4e5f5d61bb12c1a6b94841f96"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the doppler factor of the sound. <br /></td></tr>
<tr class="separator:a2d229ff4e5f5d61bb12c1a6b94841f96"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aeae4c21b585e54814b6a8ca8542ddf49" id="r_aeae4c21b585e54814b6a8ca8542ddf49"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#aeae4c21b585e54814b6a8ca8542ddf49">setDirectionalAttenuationFactor</a> (float factor)</td></tr>
<tr class="memdesc:aeae4c21b585e54814b6a8ca8542ddf49"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the directional attenuation factor of the sound. <br /></td></tr>
<tr class="separator:aeae4c21b585e54814b6a8ca8542ddf49"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ac478a8b813faf7dd575635b102081d0d" id="r_ac478a8b813faf7dd575635b102081d0d"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ac478a8b813faf7dd575635b102081d0d">setRelativeToListener</a> (bool relative)</td></tr>
<tr class="memdesc:ac478a8b813faf7dd575635b102081d0d"><td class="mdescLeft">&#160;</td><td class="mdescRight">Make the sound's position relative to the listener or absolute. <br /></td></tr>
<tr class="separator:ac478a8b813faf7dd575635b102081d0d"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a75bbc2c34addc8b25a14edb908508afe" id="r_a75bbc2c34addc8b25a14edb908508afe"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a75bbc2c34addc8b25a14edb908508afe">setMinDistance</a> (float distance)</td></tr>
<tr class="memdesc:a75bbc2c34addc8b25a14edb908508afe"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the minimum distance of the sound. <br /></td></tr>
<tr class="separator:a75bbc2c34addc8b25a14edb908508afe"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a484275e6ecfa041ea9e690a8635c2212" id="r_a484275e6ecfa041ea9e690a8635c2212"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a484275e6ecfa041ea9e690a8635c2212">setMaxDistance</a> (float distance)</td></tr>
<tr class="memdesc:a484275e6ecfa041ea9e690a8635c2212"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the maximum distance of the sound. <br /></td></tr>
<tr class="separator:a484275e6ecfa041ea9e690a8635c2212"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:ae6789b20e1a7525d6a7611466e955f50" id="r_ae6789b20e1a7525d6a7611466e955f50"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#ae6789b20e1a7525d6a7611466e955f50">setMinGain</a> (float gain)</td></tr>
<tr class="memdesc:ae6789b20e1a7525d6a7611466e955f50"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the minimum gain of the sound. <br /></td></tr>
<tr class="separator:ae6789b20e1a7525d6a7611466e955f50"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aaf799cceb2a8b3d5a93320c35a955fb1" id="r_aaf799cceb2a8b3d5a93320c35a955fb1"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#aaf799cceb2a8b3d5a93320c35a955fb1">setMaxGain</a> (float gain)</td></tr>
<tr class="memdesc:aaf799cceb2a8b3d5a93320c35a955fb1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the maximum gain of the sound. <br /></td></tr>
<tr class="separator:aaf799cceb2a8b3d5a93320c35a955fb1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa2adff44cd2f8b4e3c7315d7c2a45626" id="r_aa2adff44cd2f8b4e3c7315d7c2a45626"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626">setAttenuation</a> (float attenuation)</td></tr>
<tr class="memdesc:aa2adff44cd2f8b4e3c7315d7c2a45626"><td class="mdescLeft">&#160;</td><td class="mdescRight">Set the attenuation factor of the sound. <br /></td></tr>
<tr class="separator:aa2adff44cd2f8b4e3c7315d7c2a45626"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4736acc2c802f927544c9ce52a44a9e4" id="r_a4736acc2c802f927544c9ce52a44a9e4"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a4736acc2c802f927544c9ce52a44a9e4">getPitch</a> () const</td></tr>
<tr class="memdesc:a4736acc2c802f927544c9ce52a44a9e4"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the pitch of the sound. <br /></td></tr>
<tr class="separator:a4736acc2c802f927544c9ce52a44a9e4"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a0fbe0259aa4fc8440d34d156bb8dd901" id="r_a0fbe0259aa4fc8440d34d156bb8dd901"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a0fbe0259aa4fc8440d34d156bb8dd901">getPan</a> () const</td></tr>
<tr class="memdesc:a0fbe0259aa4fc8440d34d156bb8dd901"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the pan of the sound. <br /></td></tr>
<tr class="separator:a0fbe0259aa4fc8440d34d156bb8dd901"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a04243fb5edf64561689b1d58953fc4ce" id="r_a04243fb5edf64561689b1d58953fc4ce"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a04243fb5edf64561689b1d58953fc4ce">getVolume</a> () const</td></tr>
<tr class="memdesc:a04243fb5edf64561689b1d58953fc4ce"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the volume of the sound. <br /></td></tr>
<tr class="separator:a04243fb5edf64561689b1d58953fc4ce"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a805a8bba4ce7ac1f04fdb073974fee9b" id="r_a805a8bba4ce7ac1f04fdb073974fee9b"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a805a8bba4ce7ac1f04fdb073974fee9b">isSpatializationEnabled</a> () const</td></tr>
<tr class="memdesc:a805a8bba4ce7ac1f04fdb073974fee9b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Tell whether spatialization of the sound is enabled. <br /></td></tr>
<tr class="separator:a805a8bba4ce7ac1f04fdb073974fee9b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8d199521f55550c7a3b2b0f6950dffa1" id="r_a8d199521f55550c7a3b2b0f6950dffa1"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a8d199521f55550c7a3b2b0f6950dffa1">getPosition</a> () const</td></tr>
<tr class="memdesc:a8d199521f55550c7a3b2b0f6950dffa1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the 3D position of the sound in the audio scene. <br /></td></tr>
<tr class="separator:a8d199521f55550c7a3b2b0f6950dffa1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a2d9b249242e403d0f2638977357995fd" id="r_a2d9b249242e403d0f2638977357995fd"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a2d9b249242e403d0f2638977357995fd">getDirection</a> () const</td></tr>
<tr class="memdesc:a2d9b249242e403d0f2638977357995fd"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the 3D direction of the sound in the audio scene. <br /></td></tr>
<tr class="separator:a2d9b249242e403d0f2638977357995fd"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adee94455dfe9d1a87ec45d1afe09e092" id="r_adee94455dfe9d1a87ec45d1afe09e092"><td class="memItemLeft" align="right" valign="top"><a class="el" href="structsf_1_1SoundSource_1_1Cone.html">Cone</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#adee94455dfe9d1a87ec45d1afe09e092">getCone</a> () const</td></tr>
<tr class="memdesc:adee94455dfe9d1a87ec45d1afe09e092"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the cone properties of the sound in the audio scene. <br /></td></tr>
<tr class="separator:adee94455dfe9d1a87ec45d1afe09e092"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a9ae37256230fe3bce3ddab5edf8936a1" id="r_a9ae37256230fe3bce3ddab5edf8936a1"><td class="memItemLeft" align="right" valign="top"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a>&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a9ae37256230fe3bce3ddab5edf8936a1">getVelocity</a> () const</td></tr>
<tr class="memdesc:a9ae37256230fe3bce3ddab5edf8936a1"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the 3D velocity of the sound in the audio scene. <br /></td></tr>
<tr class="separator:a9ae37256230fe3bce3ddab5edf8936a1"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:af6eb03a66214b68bc2f4edb42952e6f5" id="r_af6eb03a66214b68bc2f4edb42952e6f5"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#af6eb03a66214b68bc2f4edb42952e6f5">getDopplerFactor</a> () const</td></tr>
<tr class="memdesc:af6eb03a66214b68bc2f4edb42952e6f5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the doppler factor of the sound. <br /></td></tr>
<tr class="separator:af6eb03a66214b68bc2f4edb42952e6f5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:aa1ac48f196605eb96521344bc8eb93b5" id="r_aa1ac48f196605eb96521344bc8eb93b5"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#aa1ac48f196605eb96521344bc8eb93b5">getDirectionalAttenuationFactor</a> () const</td></tr>
<tr class="memdesc:aa1ac48f196605eb96521344bc8eb93b5"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the directional attenuation factor of the sound. <br /></td></tr>
<tr class="separator:aa1ac48f196605eb96521344bc8eb93b5"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:adcdb4ef32c2f4481d34aff0b5c31534b" id="r_adcdb4ef32c2f4481d34aff0b5c31534b"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#adcdb4ef32c2f4481d34aff0b5c31534b">isRelativeToListener</a> () const</td></tr>
<tr class="memdesc:adcdb4ef32c2f4481d34aff0b5c31534b"><td class="mdescLeft">&#160;</td><td class="mdescRight">Tell whether the sound's position is relative to the listener or is absolute. <br /></td></tr>
<tr class="separator:adcdb4ef32c2f4481d34aff0b5c31534b"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a605ca7f359ec1c36fcccdcd4696562ac" id="r_a605ca7f359ec1c36fcccdcd4696562ac"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a605ca7f359ec1c36fcccdcd4696562ac">getMinDistance</a> () const</td></tr>
<tr class="memdesc:a605ca7f359ec1c36fcccdcd4696562ac"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the minimum distance of the sound. <br /></td></tr>
<tr class="separator:a605ca7f359ec1c36fcccdcd4696562ac"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a471e2644f3599ac583bca92072ed3eec" id="r_a471e2644f3599ac583bca92072ed3eec"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a471e2644f3599ac583bca92072ed3eec">getMaxDistance</a> () const</td></tr>
<tr class="memdesc:a471e2644f3599ac583bca92072ed3eec"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the maximum distance of the sound. <br /></td></tr>
<tr class="separator:a471e2644f3599ac583bca92072ed3eec"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a08a8b71fc60a4549db55add457209829" id="r_a08a8b71fc60a4549db55add457209829"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a08a8b71fc60a4549db55add457209829">getMinGain</a> () const</td></tr>
<tr class="memdesc:a08a8b71fc60a4549db55add457209829"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the minimum gain of the sound. <br /></td></tr>
<tr class="separator:a08a8b71fc60a4549db55add457209829"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a706eddad92fa4cf16b108b8942b72f26" id="r_a706eddad92fa4cf16b108b8942b72f26"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a706eddad92fa4cf16b108b8942b72f26">getMaxGain</a> () const</td></tr>
<tr class="memdesc:a706eddad92fa4cf16b108b8942b72f26"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the maximum gain of the sound. <br /></td></tr>
<tr class="separator:a706eddad92fa4cf16b108b8942b72f26"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a8ad7dafb4f1b4afbc638cebe24f48cc9" id="r_a8ad7dafb4f1b4afbc638cebe24f48cc9"><td class="memItemLeft" align="right" valign="top">float&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9">getAttenuation</a> () const</td></tr>
<tr class="memdesc:a8ad7dafb4f1b4afbc638cebe24f48cc9"><td class="mdescLeft">&#160;</td><td class="mdescRight">Get the attenuation factor of the sound. <br /></td></tr>
<tr class="separator:a8ad7dafb4f1b4afbc638cebe24f48cc9"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table><table class="memberdecls">
<tr class="heading"><td colspan="2"><h2 class="groupheader"><a id="pro-methods" name="pro-methods"></a>
Protected Member Functions</h2></td></tr>
<tr class="memitem:a7f6dd1344f23285e13a26a46d1bb9f5c" id="r_a7f6dd1344f23285e13a26a46d1bb9f5c"><td class="memItemLeft" align="right" valign="top">bool&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a7f6dd1344f23285e13a26a46d1bb9f5c">onGetData</a> (<a class="el" href="structsf_1_1SoundStream_1_1Chunk.html">Chunk</a> &amp;data) override</td></tr>
<tr class="memdesc:a7f6dd1344f23285e13a26a46d1bb9f5c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Request a new chunk of audio samples from the stream source. <br /></td></tr>
<tr class="separator:a7f6dd1344f23285e13a26a46d1bb9f5c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1256e51d366ae951408dc287f4cf486c" id="r_a1256e51d366ae951408dc287f4cf486c"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1256e51d366ae951408dc287f4cf486c">onSeek</a> (<a class="el" href="classsf_1_1Time.html">Time</a> timeOffset) override</td></tr>
<tr class="memdesc:a1256e51d366ae951408dc287f4cf486c"><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the current playing position in the stream source. <br /></td></tr>
<tr class="separator:a1256e51d366ae951408dc287f4cf486c"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a1edba64c835fd76ba474965dee216aaf" id="r_a1edba64c835fd76ba474965dee216aaf"><td class="memItemLeft" align="right" valign="top">std::optional&lt; std::uint64_t &gt;&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="#a1edba64c835fd76ba474965dee216aaf">onLoop</a> () override</td></tr>
<tr class="memdesc:a1edba64c835fd76ba474965dee216aaf"><td class="mdescLeft">&#160;</td><td class="mdescRight">Change the current playing position in the stream source to the loop offset. <br /></td></tr>
<tr class="separator:a1edba64c835fd76ba474965dee216aaf"><td class="memSeparator" colspan="2">&#160;</td></tr>
<tr class="memitem:a4a698d4096306ac1792fa320068aa5d0" id="r_a4a698d4096306ac1792fa320068aa5d0"><td class="memItemLeft" align="right" valign="top">void&#160;</td><td class="memItemRight" valign="bottom"><a class="el" href="classsf_1_1SoundStream.html#a4a698d4096306ac1792fa320068aa5d0">initialize</a> (unsigned int channelCount, unsigned int sampleRate, const std::vector&lt; <a class="el" href="group__audio.html#ga9800c7f3d5e7a9c9310f707b2c995ff3">SoundChannel</a> &gt; &amp;channelMap)</td></tr>
<tr class="memdesc:a4a698d4096306ac1792fa320068aa5d0"><td class="mdescLeft">&#160;</td><td class="mdescRight">Define the audio stream parameters. <br /></td></tr>
<tr class="separator:a4a698d4096306ac1792fa320068aa5d0"><td class="memSeparator" colspan="2">&#160;</td></tr>
</table>
<a name="details" id="details"></a><h2 class="groupheader">Detailed Description</h2>
<div class="textblock"><p>Streamed music played from an audio file. </p>
<p>Musics are sounds that are streamed rather than completely loaded in memory.</p>
<p>This is especially useful for compressed musics that usually take hundreds of MB when they are uncompressed: by streaming it instead of loading it entirely, you avoid saturating the memory and have almost no loading delay. This implies that the underlying resource (file, stream or memory buffer) must remain valid for the lifetime of the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object.</p>
<p>Apart from that, a <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> has almost the same features as the <code><a class="el" href="classsf_1_1SoundBuffer.html" title="Storage for audio samples defining a sound.">sf::SoundBuffer</a></code> / <code><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">sf::Sound</a></code> pair: you can play/pause/stop it, request its parameters (channels, sample rate), change the way it is played (pitch, volume, 3D position, ...), etc.</p>
<p>As a sound stream, a music is played in its own thread in order not to block the rest of the program. This means that you can leave the music alone after calling <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code>, it will manage itself very well.</p>
<p>Usage example: </p><div class="fragment"><div class="line"><span class="comment">// Open a music from an audio file</span></div>
<div class="line"><a class="code hl_class" href="classsf_1_1Music.html">sf::Music</a> music(<span class="stringliteral">&quot;music.ogg&quot;</span>);</div>
<div class="line"> </div>
<div class="line"><span class="comment">// Change some parameters</span></div>
<div class="line">music.setPosition({0, 1, 10}); <span class="comment">// change its 3D position</span></div>
<div class="line">music.setPitch(2); <span class="comment">// increase the pitch</span></div>
<div class="line">music.setVolume(50); <span class="comment">// reduce the volume</span></div>
<div class="line">music.setLooping(<span class="keyword">true</span>); <span class="comment">// make it loop</span></div>
<div class="line"> </div>
<div class="line"><span class="comment">// Play it</span></div>
<div class="line">music.play();</div>
<div class="ttc" id="aclasssf_1_1Music_html"><div class="ttname"><a href="classsf_1_1Music.html">sf::Music</a></div><div class="ttdoc">Streamed music played from an audio file.</div><div class="ttdef"><b>Definition</b> <a href="Music_8hpp_source.html#l00052">Music.hpp:53</a></div></div>
</div><!-- fragment --><dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">sf::Sound</a></code>, <code><a class="el" href="classsf_1_1SoundStream.html" title="Abstract base class for streamed audio sources.">sf::SoundStream</a></code> </dd></dl>
<p class="definition">Definition at line <a class="el" href="Music_8hpp_source.html#l00052">52</a> of file <a class="el" href="Music_8hpp_source.html">Music.hpp</a>.</p>
</div><h2 class="groupheader">Member Typedef Documentation</h2>
<a id="ab13ce12bd2ef4856511824557b07cce5" name="ab13ce12bd2ef4856511824557b07cce5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ab13ce12bd2ef4856511824557b07cce5">&#9670;&#160;</a></span>EffectProcessor</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">using <a class="el" href="classsf_1_1SoundSource.html#ab13ce12bd2ef4856511824557b07cce5">sf::SoundSource::EffectProcessor</a></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<b>Initial value:</b><div class="fragment"><div class="line"> std::function&lt;</div>
<div class="line"> void(<span class="keyword">const</span> <span class="keywordtype">float</span>* inputFrames, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span>&amp; inputFrameCount, <span class="keywordtype">float</span>* outputFrames, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span>&amp; outputFrameCount, <span class="keywordtype">unsigned</span> <span class="keywordtype">int</span> frameChannelCount)&gt;</div>
</div><!-- fragment -->
<p>Callable that is provided with sound data for processing. </p>
<p>When the audio engine sources sound data from sound sources it will pass the data through an effects processor if one is set. The sound data will already be converted to the internal floating point format.</p>
<p><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">Sound</a> data that is processed this way is provided in frames. Each frame contains 1 floating point sample per channel. If e.g. the data source provides stereo data, each frame will contain 2 floats.</p>
<p>The effects processor function takes 4 parameters:</p><ul>
<li>The input data frames, channels interleaved</li>
<li>The number of input data frames available</li>
<li>The buffer to write output data frames to, channels interleaved</li>
<li>The number of output data frames that the output buffer can hold</li>
<li>The channel count</li>
</ul>
<p>The input and output frame counts are in/out parameters.</p>
<p>When this function is called, the input count will contain the number of frames available in the input buffer. The output count will contain the size of the output buffer i.e. the maximum number of frames that can be written to the output buffer.</p>
<p>Attempting to read more frames than the input frame count or write more frames than the output frame count will result in undefined behaviour.</p>
<p>It is important to note that the channel count of the audio engine currently sourcing data from this sound will always be provided in <code>frameChannelCount</code>. This can be different from the channel count of the sound source so make sure to size necessary processing buffers according to the engine channel count and not the sound source channel count.</p>
<p>When done processing the frames, the input and output frame counts must be updated to reflect the actual number of frames that were read from the input and written to the output.</p>
<p>The processing function should always try to process as much sound data as possible i.e. always try to fill the output buffer to the maximum. In certain situations for specific effects it can be possible that the input frame count and output frame count aren't equal. As long as the frame counts are updated accordingly this is perfectly valid.</p>
<p>If the audio engine determines that no audio data is available from the data source, the input data frames pointer is set to <code>nullptr</code> and the input frame count is set to 0. In this case it is up to the function to decide how to handle the situation. For specific effects e.g. Echo/Delay buffered data might still be able to be written to the output buffer even if there is no longer any input data.</p>
<p>An important thing to remember is that this function is directly called by the audio engine. Because the audio engine runs on an internal thread of its own, make sure access to shared data is synchronized appropriately.</p>
<p>Because this function is stored by the <code><a class="el" href="classsf_1_1SoundSource.html" title="Base class defining a sound&#39;s properties.">SoundSource</a></code> object it will be able to be called as long as the <code><a class="el" href="classsf_1_1SoundSource.html" title="Base class defining a sound&#39;s properties.">SoundSource</a></code> object hasn't yet been destroyed. Make sure that any data this function references outlives the <a class="el" href="classsf_1_1SoundSource.html" title="Base class defining a sound&#39;s properties.">SoundSource</a> object otherwise use-after-free errors will occur. </p>
<p class="definition">Definition at line <a class="el" href="SoundSource_8hpp_source.html#l00154">154</a> of file <a class="el" href="SoundSource_8hpp_source.html">SoundSource.hpp</a>.</p>
</div>
</div>
<a id="a8f92f34d1714edb7178ba2a8a5a845e8" name="a8f92f34d1714edb7178ba2a8a5a845e8"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8f92f34d1714edb7178ba2a8a5a845e8">&#9670;&#160;</a></span>TimeSpan</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">using <a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">sf::Music::TimeSpan</a> = <a class="el" href="structsf_1_1Music_1_1Span.html">Span</a>&lt;<a class="el" href="classsf_1_1Time.html">Time</a>&gt;</td>
</tr>
</table>
</div><div class="memdoc">
<p class="definition">Definition at line <a class="el" href="Music_8hpp_source.html#l00067">67</a> of file <a class="el" href="Music_8hpp_source.html">Music.hpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Member Enumeration Documentation</h2>
<a id="ac43af72c98c077500b239bc75b812f03" name="ac43af72c98c077500b239bc75b812f03"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac43af72c98c077500b239bc75b812f03">&#9670;&#160;</a></span>Status</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">enum class <a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03">sf::SoundSource::Status</a></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">strong</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Enumeration of the sound source states. </p>
<table class="fieldtable">
<tr><th colspan="2">Enumerator</th></tr><tr><td class="fieldname"><a id="ac43af72c98c077500b239bc75b812f03ac23e2b09ebe6bf4cb5e2a9abe85c0be2" name="ac43af72c98c077500b239bc75b812f03ac23e2b09ebe6bf4cb5e2a9abe85c0be2"></a>Stopped&#160;</td><td class="fielddoc"><p><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">Sound</a> is not playing. </p>
</td></tr>
<tr><td class="fieldname"><a id="ac43af72c98c077500b239bc75b812f03ae99180abf47a8b3a856e0bcb2656990a" name="ac43af72c98c077500b239bc75b812f03ae99180abf47a8b3a856e0bcb2656990a"></a>Paused&#160;</td><td class="fielddoc"><p><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">Sound</a> is paused. </p>
</td></tr>
<tr><td class="fieldname"><a id="ac43af72c98c077500b239bc75b812f03ac9dbb2b7c84159b632d71e512eba8428" name="ac43af72c98c077500b239bc75b812f03ac9dbb2b7c84159b632d71e512eba8428"></a>Playing&#160;</td><td class="fielddoc"><p><a class="el" href="classsf_1_1Sound.html" title="Regular sound that can be played in the audio environment.">Sound</a> is playing. </p>
</td></tr>
</table>
<p class="definition">Definition at line <a class="el" href="SoundSource_8hpp_source.html#l00054">54</a> of file <a class="el" href="SoundSource_8hpp_source.html">SoundSource.hpp</a>.</p>
</div>
</div>
<h2 class="groupheader">Constructor &amp; Destructor Documentation</h2>
<a id="a0bc787d8e022b3a9b89cf2c28befd42e" name="a0bc787d8e022b3a9b89cf2c28befd42e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0bc787d8e022b3a9b89cf2c28befd42e">&#9670;&#160;</a></span>Music() <span class="overload">[1/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">sf::Music::Music </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Default constructor. </p>
<p>Construct an empty music that does not contain any data. </p>
</div>
</div>
<a id="a8cf69ccb581b452f442eb01b9348efda" name="a8cf69ccb581b452f442eb01b9348efda"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8cf69ccb581b452f442eb01b9348efda">&#9670;&#160;</a></span>Music() <span class="overload">[2/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Music::Music </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>filename</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">explicit</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Construct a music from an audio file. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the file must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">filename</td><td>Path of the music file to open</td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classsf_1_1Exception.html" title="Library-specific exception type.">sf::Exception</a></td><td>if loading was unsuccessful</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#ae93b21bcf28ff0b5fec458039111386e" title="Open a music from an audio file in memory.">openFromMemory</a></code>, <code><a class="el" href="#a4e55d1910a26858b44778c26b237d673" title="Open a music from an audio file in a custom stream.">openFromStream</a></code> </dd></dl>
</div>
</div>
<a id="acc7af0cebb8ca0ca4ab8edccd46499ab" name="acc7af0cebb8ca0ca4ab8edccd46499ab"></a>
<h2 class="memtitle"><span class="permalink"><a href="#acc7af0cebb8ca0ca4ab8edccd46499ab">&#9670;&#160;</a></span>Music() <span class="overload">[3/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">sf::Music::Music </td>
<td>(</td>
<td class="paramtype">const void *</td> <td class="paramname"><span class="paramname"><em>data</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">std::size_t</td> <td class="paramname"><span class="paramname"><em>sizeInBytes</em></span>&#160;)</td>
</tr>
</table>
</div><div class="memdoc">
<p>Construct a music from an audio file in memory. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the <em>data</em> buffer must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed. That is, you can't deallocate the buffer right after calling this function.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">data</td><td>Pointer to the file data in memory </td></tr>
<tr><td class="paramname">sizeInBytes</td><td>Size of the data to load, in bytes</td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classsf_1_1Exception.html" title="Library-specific exception type.">sf::Exception</a></td><td>if loading was unsuccessful</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a9493f462e07423d891f117a8b4c613fe" title="Open a music from an audio file.">openFromFile</a></code>, <code><a class="el" href="#a4e55d1910a26858b44778c26b237d673" title="Open a music from an audio file in a custom stream.">openFromStream</a></code> </dd></dl>
</div>
</div>
<a id="ac762a80c77e26eef4ba5dcf6d4bbd4bd" name="ac762a80c77e26eef4ba5dcf6d4bbd4bd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac762a80c77e26eef4ba5dcf6d4bbd4bd">&#9670;&#160;</a></span>Music() <span class="overload">[4/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Music::Music </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1InputStream.html">InputStream</a> &amp;</td> <td class="paramname"><span class="paramname"><em>stream</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">explicit</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Construct a music from an audio file in a custom stream. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the <code>stream</code> must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">stream</td><td>Source stream to read from</td></tr>
</table>
</dd>
</dl>
<dl class="exception"><dt>Exceptions</dt><dd>
<table class="exception">
<tr><td class="paramname"><a class="el" href="classsf_1_1Exception.html" title="Library-specific exception type.">sf::Exception</a></td><td>if loading was unsuccessful</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a9493f462e07423d891f117a8b4c613fe" title="Open a music from an audio file.">openFromFile</a></code>, <code><a class="el" href="#ae93b21bcf28ff0b5fec458039111386e" title="Open a music from an audio file in memory.">openFromMemory</a></code> </dd></dl>
</div>
</div>
<a id="afbf878e783aa23be86edaeda32f967a4" name="afbf878e783aa23be86edaeda32f967a4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#afbf878e783aa23be86edaeda32f967a4">&#9670;&#160;</a></span>~Music()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Music::~Music </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Destructor. </p>
</div>
</div>
<a id="a5b7618e529f9a9898bd9dac217f41e78" name="a5b7618e529f9a9898bd9dac217f41e78"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a5b7618e529f9a9898bd9dac217f41e78">&#9670;&#160;</a></span>Music() <span class="overload">[5/5]</span></h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">sf::Music::Music </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1Music.html">Music</a> &amp;&amp;</td> <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Move constructor. </p>
</div>
</div>
<h2 class="groupheader">Member Function Documentation</h2>
<a id="a8ad7dafb4f1b4afbc638cebe24f48cc9" name="a8ad7dafb4f1b4afbc638cebe24f48cc9"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8ad7dafb4f1b4afbc638cebe24f48cc9">&#9670;&#160;</a></span>getAttenuation()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getAttenuation </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the attenuation factor of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Attenuation factor of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626" title="Set the attenuation factor of the sound.">setAttenuation</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a605ca7f359ec1c36fcccdcd4696562ac" title="Get the minimum distance of the sound.">getMinDistance</a></code> </dd></dl>
</div>
</div>
<a id="a1f70933912dd9498f4dc99feefed27f3" name="a1f70933912dd9498f4dc99feefed27f3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1f70933912dd9498f4dc99feefed27f3">&#9670;&#160;</a></span>getChannelCount()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">unsigned int sf::SoundStream::getChannelCount </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Return the number of channels of the stream. </p>
<p>1 channel means a mono sound, 2 means stereo, etc.</p>
<dl class="section return"><dt>Returns</dt><dd>Number of channels </dd></dl>
</div>
</div>
<a id="a1ae6bfce0ec385a11e87697323227799" name="a1ae6bfce0ec385a11e87697323227799"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1ae6bfce0ec385a11e87697323227799">&#9670;&#160;</a></span>getChannelMap()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::vector&lt; <a class="el" href="group__audio.html#ga9800c7f3d5e7a9c9310f707b2c995ff3">SoundChannel</a> &gt; sf::SoundStream::getChannelMap </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the map of position in sample frame to sound channel. </p>
<p>This is used to map a sample in the sample stream to a position during spatialization.</p>
<dl class="section return"><dt>Returns</dt><dd>Map of position in sample frame to sound channel </dd></dl>
</div>
</div>
<a id="adee94455dfe9d1a87ec45d1afe09e092" name="adee94455dfe9d1a87ec45d1afe09e092"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adee94455dfe9d1a87ec45d1afe09e092">&#9670;&#160;</a></span>getCone()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="structsf_1_1SoundSource_1_1Cone.html">Cone</a> sf::SoundSource::getCone </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the cone properties of the sound in the audio scene. </p>
<dl class="section return"><dt>Returns</dt><dd>Cone properties of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#aba2cbcc0be18840880b54a112a0e69a1" title="Set the cone properties of the sound in the audio scene.">setCone</a></code> </dd></dl>
</div>
</div>
<a id="a2d9b249242e403d0f2638977357995fd" name="a2d9b249242e403d0f2638977357995fd"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2d9b249242e403d0f2638977357995fd">&#9670;&#160;</a></span>getDirection()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> sf::SoundSource::getDirection </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the 3D direction of the sound in the audio scene. </p>
<dl class="section return"><dt>Returns</dt><dd>Direction of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#ac46223c70c01f43bb6a443001cdd0599" title="Set the 3D direction of the sound in the audio scene.">setDirection</a></code> </dd></dl>
</div>
</div>
<a id="aa1ac48f196605eb96521344bc8eb93b5" name="aa1ac48f196605eb96521344bc8eb93b5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa1ac48f196605eb96521344bc8eb93b5">&#9670;&#160;</a></span>getDirectionalAttenuationFactor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getDirectionalAttenuationFactor </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the directional attenuation factor of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Directional attenuation factor of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#aeae4c21b585e54814b6a8ca8542ddf49" title="Set the directional attenuation factor of the sound.">setDirectionalAttenuationFactor</a></code> </dd></dl>
</div>
</div>
<a id="af6eb03a66214b68bc2f4edb42952e6f5" name="af6eb03a66214b68bc2f4edb42952e6f5"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af6eb03a66214b68bc2f4edb42952e6f5">&#9670;&#160;</a></span>getDopplerFactor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getDopplerFactor </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the doppler factor of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Doppler factor of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a2d229ff4e5f5d61bb12c1a6b94841f96" title="Set the doppler factor of the sound.">setDopplerFactor</a></code> </dd></dl>
</div>
</div>
<a id="a288ef6f552a136b0e56952dcada3d672" name="a288ef6f552a136b0e56952dcada3d672"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a288ef6f552a136b0e56952dcada3d672">&#9670;&#160;</a></span>getDuration()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Time.html">Time</a> sf::Music::getDuration </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the total duration of the music. </p>
<dl class="section return"><dt>Returns</dt><dd><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">Music</a> duration </dd></dl>
</div>
</div>
<a id="aae3451cad5c16ee6a6e124e62ed61361" name="aae3451cad5c16ee6a6e124e62ed61361"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aae3451cad5c16ee6a6e124e62ed61361">&#9670;&#160;</a></span>getLoopPoints()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">TimeSpan</a> sf::Music::getLoopPoints </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the positions of the of the sound's looping sequence. </p>
<dl class="section return"><dt>Returns</dt><dd>Loop <a class="el" href="classsf_1_1Time.html" title="Represents a time value.">Time</a> position class.</dd></dl>
<dl class="section warning"><dt>Warning</dt><dd>Since <code><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e" title="Sets the beginning and duration of the sound&#39;s looping sequence using sf::Time">setLoopPoints()</a></code> performs some adjustments on the provided values and rounds them to internal samples, a call to <code><a class="el" href="#aae3451cad5c16ee6a6e124e62ed61361" title="Get the positions of the of the sound&#39;s looping sequence.">getLoopPoints()</a></code> is not guaranteed to return the same times passed into a previous call to <code><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e" title="Sets the beginning and duration of the sound&#39;s looping sequence using sf::Time">setLoopPoints()</a></code>. However, it is guaranteed to return times that will map to the valid internal samples of this <a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">Music</a> if they are later passed to <code><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e" title="Sets the beginning and duration of the sound&#39;s looping sequence using sf::Time">setLoopPoints()</a></code>.</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e" title="Sets the beginning and duration of the sound&#39;s looping sequence using sf::Time">setLoopPoints</a></code> </dd></dl>
</div>
</div>
<a id="a471e2644f3599ac583bca92072ed3eec" name="a471e2644f3599ac583bca92072ed3eec"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a471e2644f3599ac583bca92072ed3eec">&#9670;&#160;</a></span>getMaxDistance()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getMaxDistance </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the maximum distance of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Maximum distance of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a484275e6ecfa041ea9e690a8635c2212" title="Set the maximum distance of the sound.">setMaxDistance</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9" title="Get the attenuation factor of the sound.">getAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="a706eddad92fa4cf16b108b8942b72f26" name="a706eddad92fa4cf16b108b8942b72f26"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a706eddad92fa4cf16b108b8942b72f26">&#9670;&#160;</a></span>getMaxGain()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getMaxGain </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the maximum gain of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Maximum gain of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#aaf799cceb2a8b3d5a93320c35a955fb1" title="Set the maximum gain of the sound.">setMaxGain</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9" title="Get the attenuation factor of the sound.">getAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="a605ca7f359ec1c36fcccdcd4696562ac" name="a605ca7f359ec1c36fcccdcd4696562ac"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a605ca7f359ec1c36fcccdcd4696562ac">&#9670;&#160;</a></span>getMinDistance()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getMinDistance </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the minimum distance of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Minimum distance of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a75bbc2c34addc8b25a14edb908508afe" title="Set the minimum distance of the sound.">setMinDistance</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9" title="Get the attenuation factor of the sound.">getAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="a08a8b71fc60a4549db55add457209829" name="a08a8b71fc60a4549db55add457209829"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a08a8b71fc60a4549db55add457209829">&#9670;&#160;</a></span>getMinGain()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getMinGain </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the minimum gain of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Minimum gain of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#ae6789b20e1a7525d6a7611466e955f50" title="Set the minimum gain of the sound.">setMinGain</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9" title="Get the attenuation factor of the sound.">getAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="a0fbe0259aa4fc8440d34d156bb8dd901" name="a0fbe0259aa4fc8440d34d156bb8dd901"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0fbe0259aa4fc8440d34d156bb8dd901">&#9670;&#160;</a></span>getPan()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getPan </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the pan of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Pan of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#ad08a99b6f3492b940a2ef20c8d3cbc72" title="Set the pan of the sound.">setPan</a></code> </dd></dl>
</div>
</div>
<a id="a4736acc2c802f927544c9ce52a44a9e4" name="a4736acc2c802f927544c9ce52a44a9e4"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4736acc2c802f927544c9ce52a44a9e4">&#9670;&#160;</a></span>getPitch()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getPitch </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the pitch of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Pitch of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a72a13695ed48b7f7b55e7cd4431f4bb6" title="Set the pitch of the sound.">setPitch</a></code> </dd></dl>
</div>
</div>
<a id="ae288f3c72edbad9cc7ee938ce5b907c1" name="ae288f3c72edbad9cc7ee938ce5b907c1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae288f3c72edbad9cc7ee938ce5b907c1">&#9670;&#160;</a></span>getPlayingOffset()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Time.html">Time</a> sf::SoundStream::getPlayingOffset </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the current playing position of the stream. </p>
<dl class="section return"><dt>Returns</dt><dd>Current playing position, from the beginning of the stream</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#af416a5f84c8750d2acb9821d78bc8646" title="Change the current playing position of the stream.">setPlayingOffset</a></code> </dd></dl>
</div>
</div>
<a id="a8d199521f55550c7a3b2b0f6950dffa1" name="a8d199521f55550c7a3b2b0f6950dffa1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a8d199521f55550c7a3b2b0f6950dffa1">&#9670;&#160;</a></span>getPosition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> sf::SoundSource::getPosition </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the 3D position of the sound in the audio scene. </p>
<dl class="section return"><dt>Returns</dt><dd>Position of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a17ba9ed01925395652181a7b2a7d3aef" title="Set the 3D position of the sound in the audio scene.">setPosition</a></code> </dd></dl>
</div>
</div>
<a id="a7da448dc40d81a33b8dc555fbf0d3fbf" name="a7da448dc40d81a33b8dc555fbf0d3fbf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7da448dc40d81a33b8dc555fbf0d3fbf">&#9670;&#160;</a></span>getSampleRate()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">unsigned int sf::SoundStream::getSampleRate </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the stream sample rate of the stream. </p>
<p>The sample rate is the number of audio samples played per second. The higher, the better the quality.</p>
<dl class="section return"><dt>Returns</dt><dd>Sample rate, in number of samples per second </dd></dl>
</div>
</div>
<a id="a607e74492ca84764be563f36d75a1384" name="a607e74492ca84764be563f36d75a1384"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a607e74492ca84764be563f36d75a1384">&#9670;&#160;</a></span>getStatus()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1SoundSource.html#ac43af72c98c077500b239bc75b812f03">Status</a> sf::SoundStream::getStatus </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">override</span><span class="mlabel">virtual</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the current status of the stream (stopped, paused, playing) </p>
<dl class="section return"><dt>Returns</dt><dd>Current status </dd></dl>
<p>Implements <a class="el" href="classsf_1_1SoundSource.html#ab4d68d465eb18709d38e164a5c0ee2c4">sf::SoundSource</a>.</p>
</div>
</div>
<a id="a9ae37256230fe3bce3ddab5edf8936a1" name="a9ae37256230fe3bce3ddab5edf8936a1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9ae37256230fe3bce3ddab5edf8936a1">&#9670;&#160;</a></span>getVelocity()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> sf::SoundSource::getVelocity </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the 3D velocity of the sound in the audio scene. </p>
<dl class="section return"><dt>Returns</dt><dd>Velocity of the sound</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a3ed894bdb323e26518c9e1548fc3488c" title="Set the 3D velocity of the sound in the audio scene.">setVelocity</a></code> </dd></dl>
</div>
</div>
<a id="a04243fb5edf64561689b1d58953fc4ce" name="a04243fb5edf64561689b1d58953fc4ce"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a04243fb5edf64561689b1d58953fc4ce">&#9670;&#160;</a></span>getVolume()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">float sf::SoundSource::getVolume </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Get the volume of the sound. </p>
<dl class="section return"><dt>Returns</dt><dd>Volume of the sound, in the range [0, 100]</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a2f192f2b49fb8e2b82f3498d3663fcc2" title="Set the volume of the sound.">setVolume</a></code> </dd></dl>
</div>
</div>
<a id="a4a698d4096306ac1792fa320068aa5d0" name="a4a698d4096306ac1792fa320068aa5d0"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4a698d4096306ac1792fa320068aa5d0">&#9670;&#160;</a></span>initialize()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::initialize </td>
<td>(</td>
<td class="paramtype">unsigned int</td> <td class="paramname"><span class="paramname"><em>channelCount</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">unsigned int</td> <td class="paramname"><span class="paramname"><em>sampleRate</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">const std::vector&lt; <a class="el" href="group__audio.html#ga9800c7f3d5e7a9c9310f707b2c995ff3">SoundChannel</a> &gt; &amp;</td> <td class="paramname"><span class="paramname"><em>channelMap</em></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">protected</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Define the audio stream parameters. </p>
<p>This function must be called by derived classes as soon as they know the audio settings of the stream to play. Any attempt to manipulate the stream (<code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code>, ...) before calling this function will fail. It can be called multiple times if the settings of the audio stream change, but only when the stream is stopped.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">channelCount</td><td>Number of channels of the stream </td></tr>
<tr><td class="paramname">sampleRate</td><td>Sample rate, in samples per second </td></tr>
<tr><td class="paramname">channelMap</td><td>Map of position in sample frame to sound channel </td></tr>
</table>
</dd>
</dl>
</div>
</div>
<a id="a4f72aa9d4e185b4c02ffbb97075c7e82" name="a4f72aa9d4e185b4c02ffbb97075c7e82"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4f72aa9d4e185b4c02ffbb97075c7e82">&#9670;&#160;</a></span>isLooping()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::SoundStream::isLooping </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Tell whether or not the stream is in loop mode. </p>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if the stream is looping, <code>false</code> otherwise</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#a0c14b35d1dc64bf10e02b7a876540966" title="Set whether or not the stream should loop after reaching the end.">setLooping</a></code> </dd></dl>
</div>
</div>
<a id="adcdb4ef32c2f4481d34aff0b5c31534b" name="adcdb4ef32c2f4481d34aff0b5c31534b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#adcdb4ef32c2f4481d34aff0b5c31534b">&#9670;&#160;</a></span>isRelativeToListener()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::SoundSource::isRelativeToListener </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Tell whether the sound's position is relative to the listener or is absolute. </p>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if the position is relative, <code>false</code> if it's absolute</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#ac478a8b813faf7dd575635b102081d0d" title="Make the sound&#39;s position relative to the listener or absolute.">setRelativeToListener</a></code> </dd></dl>
</div>
</div>
<a id="a805a8bba4ce7ac1f04fdb073974fee9b" name="a805a8bba4ce7ac1f04fdb073974fee9b"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a805a8bba4ce7ac1f04fdb073974fee9b">&#9670;&#160;</a></span>isSpatializationEnabled()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::SoundSource::isSpatializationEnabled </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td> const</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Tell whether spatialization of the sound is enabled. </p>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if spatialization is enabled, <code>false</code> if it's disabled</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a6586a19a8d1060bdf93e3c4b6ee039a7" title="Set whether spatialization of the sound is enabled.">setSpatializationEnabled</a></code> </dd></dl>
</div>
</div>
<a id="a7f6dd1344f23285e13a26a46d1bb9f5c" name="a7f6dd1344f23285e13a26a46d1bb9f5c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7f6dd1344f23285e13a26a46d1bb9f5c">&#9670;&#160;</a></span>onGetData()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::Music::onGetData </td>
<td>(</td>
<td class="paramtype"><a class="el" href="structsf_1_1SoundStream_1_1Chunk.html">Chunk</a> &amp;</td> <td class="paramname"><span class="paramname"><em>data</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span><span class="mlabel">override</span><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Request a new chunk of audio samples from the stream source. </p>
<p>This function fills the chunk from the next samples to read from the audio file.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">data</td><td>Chunk of data to fill</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> to continue playback, <code>false</code> to stop </dd></dl>
<p>Implements <a class="el" href="classsf_1_1SoundStream.html#a968ec024a6e45490962c8a1121cb7c5f">sf::SoundStream</a>.</p>
</div>
</div>
<a id="a1edba64c835fd76ba474965dee216aaf" name="a1edba64c835fd76ba474965dee216aaf"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1edba64c835fd76ba474965dee216aaf">&#9670;&#160;</a></span>onLoop()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">std::optional&lt; std::uint64_t &gt; sf::Music::onLoop </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Change the current playing position in the stream source to the loop offset. </p>
<p>This is called by the underlying <code><a class="el" href="classsf_1_1SoundStream.html" title="Abstract base class for streamed audio sources.">SoundStream</a></code> whenever it needs us to reset the seek position for a loop. We then determine whether we are looping on a loop point or the end-of-file, perform the seek, and return the new position.</p>
<dl class="section return"><dt>Returns</dt><dd>The seek position after looping (or <code>std::nullopt</code> if there's no loop) </dd></dl>
<p>Reimplemented from <a class="el" href="classsf_1_1SoundStream.html#ac7c8b90227522b48f357ac856d6e0853">sf::SoundStream</a>.</p>
</div>
</div>
<a id="a1256e51d366ae951408dc287f4cf486c" name="a1256e51d366ae951408dc287f4cf486c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a1256e51d366ae951408dc287f4cf486c">&#9670;&#160;</a></span>onSeek()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::Music::onSeek </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1Time.html">Time</a></td> <td class="paramname"><span class="paramname"><em>timeOffset</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">protected</span><span class="mlabel">virtual</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Change the current playing position in the stream source. </p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">timeOffset</td><td>New playing position, from the beginning of the music </td></tr>
</table>
</dd>
</dl>
<p>Implements <a class="el" href="classsf_1_1SoundStream.html#a907036dd2ca7d3af5ead316e54b75997">sf::SoundStream</a>.</p>
</div>
</div>
<a id="a9493f462e07423d891f117a8b4c613fe" name="a9493f462e07423d891f117a8b4c613fe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a9493f462e07423d891f117a8b4c613fe">&#9670;&#160;</a></span>openFromFile()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::Music::openFromFile </td>
<td>(</td>
<td class="paramtype">const std::filesystem::path &amp;</td> <td class="paramname"><span class="paramname"><em>filename</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Open a music from an audio file. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the file must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">filename</td><td>Path of the music file to open</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if loading succeeded, <code>false</code> if it failed</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#ae93b21bcf28ff0b5fec458039111386e" title="Open a music from an audio file in memory.">openFromMemory</a></code>, <code><a class="el" href="#a4e55d1910a26858b44778c26b237d673" title="Open a music from an audio file in a custom stream.">openFromStream</a></code> </dd></dl>
</div>
</div>
<a id="ae93b21bcf28ff0b5fec458039111386e" name="ae93b21bcf28ff0b5fec458039111386e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae93b21bcf28ff0b5fec458039111386e">&#9670;&#160;</a></span>openFromMemory()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::Music::openFromMemory </td>
<td>(</td>
<td class="paramtype">const void *</td> <td class="paramname"><span class="paramname"><em>data</em></span>, </td>
</tr>
<tr>
<td class="paramkey"></td>
<td></td>
<td class="paramtype">std::size_t</td> <td class="paramname"><span class="paramname"><em>sizeInBytes</em></span>&#160;)</td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Open a music from an audio file in memory. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the <code>data</code> buffer must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed. That is, you can't deallocate the buffer right after calling this function.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">data</td><td>Pointer to the file data in memory </td></tr>
<tr><td class="paramname">sizeInBytes</td><td>Size of the data to load, in bytes</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if loading succeeded, <code>false</code> if it failed</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a9493f462e07423d891f117a8b4c613fe" title="Open a music from an audio file.">openFromFile</a></code>, <code><a class="el" href="#a4e55d1910a26858b44778c26b237d673" title="Open a music from an audio file in a custom stream.">openFromStream</a></code> </dd></dl>
</div>
</div>
<a id="a4e55d1910a26858b44778c26b237d673" name="a4e55d1910a26858b44778c26b237d673"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a4e55d1910a26858b44778c26b237d673">&#9670;&#160;</a></span>openFromStream()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">bool sf::Music::openFromStream </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1InputStream.html">InputStream</a> &amp;</td> <td class="paramname"><span class="paramname"><em>stream</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">nodiscard</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Open a music from an audio file in a custom stream. </p>
<p>This function doesn't start playing the music (call <code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play()</a></code> to do so). See the documentation of <code><a class="el" href="classsf_1_1InputSoundFile.html" title="Provide read access to sound files.">sf::InputSoundFile</a></code> for the list of supported formats.</p>
<dl class="section warning"><dt>Warning</dt><dd>Since the music is not loaded at once but rather streamed continuously, the <code>stream</code> must remain accessible until the <code><a class="el" href="classsf_1_1Music.html" title="Streamed music played from an audio file.">sf::Music</a></code> object loads a new music or is destroyed.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">stream</td><td>Source stream to read from</td></tr>
</table>
</dd>
</dl>
<dl class="section return"><dt>Returns</dt><dd><code>true</code> if loading succeeded, <code>false</code> if it failed</dd></dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#a9493f462e07423d891f117a8b4c613fe" title="Open a music from an audio file.">openFromFile</a></code>, <code><a class="el" href="#ae93b21bcf28ff0b5fec458039111386e" title="Open a music from an audio file in memory.">openFromMemory</a></code> </dd></dl>
</div>
</div>
<a id="a45592644dd5d8b916ee98c0f98039020" name="a45592644dd5d8b916ee98c0f98039020"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a45592644dd5d8b916ee98c0f98039020">&#9670;&#160;</a></span>operator=()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname"><a class="el" href="classsf_1_1Music.html">Music</a> &amp; sf::Music::operator= </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1Music.html">Music</a> &amp;&amp;</td> <td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">noexcept</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Move assignment. </p>
</div>
</div>
<a id="a2285cedcbcb5f3c97828c664934dc0de" name="a2285cedcbcb5f3c97828c664934dc0de"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2285cedcbcb5f3c97828c664934dc0de">&#9670;&#160;</a></span>pause()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::pause </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Pause the audio stream. </p>
<p>This function pauses the stream if it was playing, otherwise (stream already paused or stopped) it has no effect.</p>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play</a></code>, <code><a class="el" href="classsf_1_1SoundStream.html#a781fe51135fdc5679fe22a5665110143" title="Stop playing the audio stream.">stop</a></code> </dd></dl>
<p>Implements <a class="el" href="classsf_1_1SoundSource.html#a21553d4e8fcf136231dd8c7ad4630aba">sf::SoundSource</a>.</p>
</div>
</div>
<a id="af05290eb2c6a316790fb18c5912a5dd6" name="af05290eb2c6a316790fb18c5912a5dd6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af05290eb2c6a316790fb18c5912a5dd6">&#9670;&#160;</a></span>play()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::play </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Start or resume playing the audio stream. </p>
<p>This function starts the stream if it was stopped, resumes it if it was paused, and restarts it from the beginning if it was already playing. This function uses its own thread so that it doesn't block the rest of the program while the stream is played.</p>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#a2285cedcbcb5f3c97828c664934dc0de" title="Pause the audio stream.">pause</a></code>, <code><a class="el" href="classsf_1_1SoundStream.html#a781fe51135fdc5679fe22a5665110143" title="Stop playing the audio stream.">stop</a></code> </dd></dl>
<p>Implements <a class="el" href="classsf_1_1SoundSource.html#a6e1bbb1f247ed8743faf3b1ed6f2bc21">sf::SoundSource</a>.</p>
</div>
</div>
<a id="aa2adff44cd2f8b4e3c7315d7c2a45626" name="aa2adff44cd2f8b4e3c7315d7c2a45626"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aa2adff44cd2f8b4e3c7315d7c2a45626">&#9670;&#160;</a></span>setAttenuation()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setAttenuation </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>attenuation</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the attenuation factor of the sound. </p>
<p>The attenuation is a multiplicative factor which makes the sound more or less loud according to its distance from the listener. An attenuation of 0 will produce a non-attenuated sound, i.e. its volume will always be the same whether it is heard from near or from far. On the other hand, an attenuation value such as 100 will make the sound fade out very quickly as it gets further from the listener. The default value of the attenuation is 1.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">attenuation</td><td>New attenuation factor of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a8ad7dafb4f1b4afbc638cebe24f48cc9" title="Get the attenuation factor of the sound.">getAttenuation</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#a75bbc2c34addc8b25a14edb908508afe" title="Set the minimum distance of the sound.">setMinDistance</a></code> </dd></dl>
</div>
</div>
<a id="aba2cbcc0be18840880b54a112a0e69a1" name="aba2cbcc0be18840880b54a112a0e69a1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aba2cbcc0be18840880b54a112a0e69a1">&#9670;&#160;</a></span>setCone()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setCone </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="structsf_1_1SoundSource_1_1Cone.html">Cone</a> &amp;</td> <td class="paramname"><span class="paramname"><em>cone</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the cone properties of the sound in the audio scene. </p>
<p>The cone defines how directional attenuation is applied. The default cone of a sound is (2 * PI, 2 * PI, 1).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">cone</td><td>Cone properties of the sound in the scene</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#adee94455dfe9d1a87ec45d1afe09e092" title="Get the cone properties of the sound in the audio scene.">getCone</a></code> </dd></dl>
</div>
</div>
<a id="ac46223c70c01f43bb6a443001cdd0599" name="ac46223c70c01f43bb6a443001cdd0599"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac46223c70c01f43bb6a443001cdd0599">&#9670;&#160;</a></span>setDirection()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setDirection </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;</td> <td class="paramname"><span class="paramname"><em>direction</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the 3D direction of the sound in the audio scene. </p>
<p>The direction defines where the sound source is facing in 3D space. It will affect how the sound is attenuated if facing away from the listener. The default direction of a sound is (0, 0, -1).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">direction</td><td>Direction of the sound in the scene</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a2d9b249242e403d0f2638977357995fd" title="Get the 3D direction of the sound in the audio scene.">getDirection</a></code> </dd></dl>
</div>
</div>
<a id="aeae4c21b585e54814b6a8ca8542ddf49" name="aeae4c21b585e54814b6a8ca8542ddf49"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aeae4c21b585e54814b6a8ca8542ddf49">&#9670;&#160;</a></span>setDirectionalAttenuationFactor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setDirectionalAttenuationFactor </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>factor</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the directional attenuation factor of the sound. </p>
<p>Depending on the virtual position of an output channel relative to the listener (such as in surround sound setups), sounds will be attenuated when emitting them from certain channels. This factor determines how strong the attenuation based on output channel position relative to the listener is.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">factor</td><td>New directional attenuation factor to apply to the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#aa1ac48f196605eb96521344bc8eb93b5" title="Get the directional attenuation factor of the sound.">getDirectionalAttenuationFactor</a></code> </dd></dl>
</div>
</div>
<a id="a2d229ff4e5f5d61bb12c1a6b94841f96" name="a2d229ff4e5f5d61bb12c1a6b94841f96"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2d229ff4e5f5d61bb12c1a6b94841f96">&#9670;&#160;</a></span>setDopplerFactor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setDopplerFactor </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>factor</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the doppler factor of the sound. </p>
<p>The doppler factor determines how strong the doppler shift will be.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">factor</td><td>New doppler factor to apply to the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#af6eb03a66214b68bc2f4edb42952e6f5" title="Get the doppler factor of the sound.">getDopplerFactor</a></code> </dd></dl>
</div>
</div>
<a id="a7593f4e30cde575c057d62ff1c47f1b3" name="a7593f4e30cde575c057d62ff1c47f1b3"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a7593f4e30cde575c057d62ff1c47f1b3">&#9670;&#160;</a></span>setEffectProcessor()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::setEffectProcessor </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1SoundSource.html#ab13ce12bd2ef4856511824557b07cce5">EffectProcessor</a></td> <td class="paramname"><span class="paramname"><em>effectProcessor</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the effect processor to be applied to the sound. </p>
<p>The effect processor is a callable that will be called with sound data to be processed.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">effectProcessor</td><td>The effect processor to attach to this sound, attach an empty processor to disable processing </td></tr>
</table>
</dd>
</dl>
<p>Reimplemented from <a class="el" href="classsf_1_1SoundSource.html#a93f431c479da8b7774af4f393099ada4">sf::SoundSource</a>.</p>
</div>
</div>
<a id="a0c14b35d1dc64bf10e02b7a876540966" name="a0c14b35d1dc64bf10e02b7a876540966"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a0c14b35d1dc64bf10e02b7a876540966">&#9670;&#160;</a></span>setLooping()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::setLooping </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>loop</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set whether or not the stream should loop after reaching the end. </p>
<p>If set, the stream will restart from beginning after reaching the end and so on, until it is stopped or <code>setLooping(false)</code> is called. The default looping state for streams is <code>false</code>.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">loop</td><td><code>true</code> to play in loop, <code>false</code> to play once</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#a4f72aa9d4e185b4c02ffbb97075c7e82" title="Tell whether or not the stream is in loop mode.">isLooping</a></code> </dd></dl>
</div>
</div>
<a id="ae7b339f0a957dfad045f3f28083a015e" name="ae7b339f0a957dfad045f3f28083a015e"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae7b339f0a957dfad045f3f28083a015e">&#9670;&#160;</a></span>setLoopPoints()</h2>
<div class="memitem">
<div class="memproto">
<table class="memname">
<tr>
<td class="memname">void sf::Music::setLoopPoints </td>
<td>(</td>
<td class="paramtype"><a class="el" href="#a8f92f34d1714edb7178ba2a8a5a845e8">TimeSpan</a></td> <td class="paramname"><span class="paramname"><em>timePoints</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</div><div class="memdoc">
<p>Sets the beginning and duration of the sound's looping sequence using <code><a class="el" href="classsf_1_1Time.html" title="Represents a time value.">sf::Time</a></code> </p>
<p><code><a class="el" href="#ae7b339f0a957dfad045f3f28083a015e" title="Sets the beginning and duration of the sound&#39;s looping sequence using sf::Time">setLoopPoints()</a></code> allows for specifying the beginning offset and the duration of the loop such that, when the music is enabled for looping, it will seamlessly seek to the beginning whenever it encounters the end of the duration. Valid ranges for <code>timePoints.offset</code> and <code>timePoints.length</code> are [0, Dur) and (0, Dur-offset] respectively, where Dur is the value returned by <code><a class="el" href="#a288ef6f552a136b0e56952dcada3d672" title="Get the total duration of the music.">getDuration()</a></code>. Note that the EOF "loop point" from the end to the beginning of the stream is still honored, in case the caller seeks to a point after the end of the loop range. This function can be safely called at any point after a stream is opened, and will be applied to a playing sound without affecting the current playing offset.</p>
<dl class="section warning"><dt>Warning</dt><dd>Setting the loop points while the stream's status is Paused will set its status to Stopped. The playing offset will be unaffected.</dd></dl>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">timePoints</td><td>The definition of the loop. Can be any time points within the sound's length</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="#aae3451cad5c16ee6a6e124e62ed61361" title="Get the positions of the of the sound&#39;s looping sequence.">getLoopPoints</a></code> </dd></dl>
</div>
</div>
<a id="a484275e6ecfa041ea9e690a8635c2212" name="a484275e6ecfa041ea9e690a8635c2212"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a484275e6ecfa041ea9e690a8635c2212">&#9670;&#160;</a></span>setMaxDistance()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setMaxDistance </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>distance</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the maximum distance of the sound. </p>
<p>The "maximum distance" of a sound is the minimum distance at which it is heard at its minimum volume. Closer than the maximum distance, it will start to fade in according to its attenuation factor. The default value of the maximum distance is the maximum value a float can represent.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">distance</td><td>New maximum distance of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a471e2644f3599ac583bca92072ed3eec" title="Get the maximum distance of the sound.">getMaxDistance</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626" title="Set the attenuation factor of the sound.">setAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="aaf799cceb2a8b3d5a93320c35a955fb1" name="aaf799cceb2a8b3d5a93320c35a955fb1"></a>
<h2 class="memtitle"><span class="permalink"><a href="#aaf799cceb2a8b3d5a93320c35a955fb1">&#9670;&#160;</a></span>setMaxGain()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setMaxGain </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>gain</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the maximum gain of the sound. </p>
<p>When the sound is closer from the listener than the "minimum distance" the attenuated gain is clamped so it cannot go above the maximum gain value.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">gain</td><td>New maximum gain of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a706eddad92fa4cf16b108b8942b72f26" title="Get the maximum gain of the sound.">getMaxGain</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626" title="Set the attenuation factor of the sound.">setAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="a75bbc2c34addc8b25a14edb908508afe" name="a75bbc2c34addc8b25a14edb908508afe"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a75bbc2c34addc8b25a14edb908508afe">&#9670;&#160;</a></span>setMinDistance()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setMinDistance </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>distance</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the minimum distance of the sound. </p>
<p>The "minimum distance" of a sound is the maximum distance at which it is heard at its maximum volume. Further than the minimum distance, it will start to fade out according to its attenuation factor. A value of 0 ("inside the head
of the listener") is an invalid value and is forbidden. The default value of the minimum distance is 1.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">distance</td><td>New minimum distance of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a605ca7f359ec1c36fcccdcd4696562ac" title="Get the minimum distance of the sound.">getMinDistance</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626" title="Set the attenuation factor of the sound.">setAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="ae6789b20e1a7525d6a7611466e955f50" name="ae6789b20e1a7525d6a7611466e955f50"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ae6789b20e1a7525d6a7611466e955f50">&#9670;&#160;</a></span>setMinGain()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setMinGain </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>gain</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the minimum gain of the sound. </p>
<p>When the sound is further away from the listener than the "maximum distance" the attenuated gain is clamped so it cannot go below the minimum gain value.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">gain</td><td>New minimum gain of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a08a8b71fc60a4549db55add457209829" title="Get the minimum gain of the sound.">getMinGain</a></code>, <code><a class="el" href="classsf_1_1SoundSource.html#aa2adff44cd2f8b4e3c7315d7c2a45626" title="Set the attenuation factor of the sound.">setAttenuation</a></code> </dd></dl>
</div>
</div>
<a id="ad08a99b6f3492b940a2ef20c8d3cbc72" name="ad08a99b6f3492b940a2ef20c8d3cbc72"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ad08a99b6f3492b940a2ef20c8d3cbc72">&#9670;&#160;</a></span>setPan()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setPan </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>pan</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the pan of the sound. </p>
<p>Using panning, a mono sound can be panned between stereo channels. When the pan is set to -1, the sound is played only on the left channel, when the pan is set to +1, the sound is played only on the right channel.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">pan</td><td>New pan to apply to the sound [-1, +1]</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a0fbe0259aa4fc8440d34d156bb8dd901" title="Get the pan of the sound.">getPan</a></code> </dd></dl>
</div>
</div>
<a id="a72a13695ed48b7f7b55e7cd4431f4bb6" name="a72a13695ed48b7f7b55e7cd4431f4bb6"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a72a13695ed48b7f7b55e7cd4431f4bb6">&#9670;&#160;</a></span>setPitch()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setPitch </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>pitch</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the pitch of the sound. </p>
<p>The pitch represents the perceived fundamental frequency of a sound; thus you can make a sound more acute or grave by changing its pitch. A side effect of changing the pitch is to modify the playing speed of the sound as well. The default value for the pitch is 1.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">pitch</td><td>New pitch to apply to the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a4736acc2c802f927544c9ce52a44a9e4" title="Get the pitch of the sound.">getPitch</a></code> </dd></dl>
</div>
</div>
<a id="af416a5f84c8750d2acb9821d78bc8646" name="af416a5f84c8750d2acb9821d78bc8646"></a>
<h2 class="memtitle"><span class="permalink"><a href="#af416a5f84c8750d2acb9821d78bc8646">&#9670;&#160;</a></span>setPlayingOffset()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::setPlayingOffset </td>
<td>(</td>
<td class="paramtype"><a class="el" href="classsf_1_1Time.html">Time</a></td> <td class="paramname"><span class="paramname"><em>timeOffset</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Change the current playing position of the stream. </p>
<p>The playing position can be changed when the stream is either paused or playing. Changing the playing position when the stream is stopped has no effect, since playing the stream would reset its position.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">timeOffset</td><td>New playing position, from the beginning of the stream</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#ae288f3c72edbad9cc7ee938ce5b907c1" title="Get the current playing position of the stream.">getPlayingOffset</a></code> </dd></dl>
</div>
</div>
<a id="a17ba9ed01925395652181a7b2a7d3aef" name="a17ba9ed01925395652181a7b2a7d3aef"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a17ba9ed01925395652181a7b2a7d3aef">&#9670;&#160;</a></span>setPosition()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setPosition </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;</td> <td class="paramname"><span class="paramname"><em>position</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the 3D position of the sound in the audio scene. </p>
<p>Only sounds with one channel (mono sounds) can be spatialized. The default position of a sound is (0, 0, 0).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">position</td><td>Position of the sound in the scene</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a8d199521f55550c7a3b2b0f6950dffa1" title="Get the 3D position of the sound in the audio scene.">getPosition</a></code> </dd></dl>
</div>
</div>
<a id="ac478a8b813faf7dd575635b102081d0d" name="ac478a8b813faf7dd575635b102081d0d"></a>
<h2 class="memtitle"><span class="permalink"><a href="#ac478a8b813faf7dd575635b102081d0d">&#9670;&#160;</a></span>setRelativeToListener()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setRelativeToListener </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>relative</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Make the sound's position relative to the listener or absolute. </p>
<p>Making a sound relative to the listener will ensure that it will always be played the same way regardless of the position of the listener. This can be useful for non-spatialized sounds, sounds that are produced by the listener, or sounds attached to it. The default value is <code>false</code> (position is absolute).</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">relative</td><td><code>true</code> to set the position relative, <code>false</code> to set it absolute</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#adcdb4ef32c2f4481d34aff0b5c31534b" title="Tell whether the sound&#39;s position is relative to the listener or is absolute.">isRelativeToListener</a></code> </dd></dl>
</div>
</div>
<a id="a6586a19a8d1060bdf93e3c4b6ee039a7" name="a6586a19a8d1060bdf93e3c4b6ee039a7"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a6586a19a8d1060bdf93e3c4b6ee039a7">&#9670;&#160;</a></span>setSpatializationEnabled()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setSpatializationEnabled </td>
<td>(</td>
<td class="paramtype">bool</td> <td class="paramname"><span class="paramname"><em>enabled</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set whether spatialization of the sound is enabled. </p>
<p>Spatialization is the application of various effects to simulate a sound being emitted at a virtual position in 3D space and exhibiting various physical phenomena such as directional attenuation and doppler shift.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">enabled</td><td><code>true</code> to enable spatialization, <code>false</code> to disable</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a805a8bba4ce7ac1f04fdb073974fee9b" title="Tell whether spatialization of the sound is enabled.">isSpatializationEnabled</a></code> </dd></dl>
</div>
</div>
<a id="a3ed894bdb323e26518c9e1548fc3488c" name="a3ed894bdb323e26518c9e1548fc3488c"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a3ed894bdb323e26518c9e1548fc3488c">&#9670;&#160;</a></span>setVelocity()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setVelocity </td>
<td>(</td>
<td class="paramtype">const <a class="el" href="namespacesf.html#aabc495912efba35400b484ea842664d0">Vector3f</a> &amp;</td> <td class="paramname"><span class="paramname"><em>velocity</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the 3D velocity of the sound in the audio scene. </p>
<p>The velocity is used to determine how to doppler shift the sound. Sounds moving towards the listener will be perceived to have a higher pitch and sounds moving away from the listener will be perceived to have a lower pitch.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">velocity</td><td>Velocity of the sound in the scene</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a9ae37256230fe3bce3ddab5edf8936a1" title="Get the 3D velocity of the sound in the audio scene.">getVelocity</a></code> </dd></dl>
</div>
</div>
<a id="a2f192f2b49fb8e2b82f3498d3663fcc2" name="a2f192f2b49fb8e2b82f3498d3663fcc2"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a2f192f2b49fb8e2b82f3498d3663fcc2">&#9670;&#160;</a></span>setVolume()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundSource::setVolume </td>
<td>(</td>
<td class="paramtype">float</td> <td class="paramname"><span class="paramname"><em>volume</em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Set the volume of the sound. </p>
<p>The volume is a value between 0 (mute) and 100 (full volume). The default value for the volume is 100.</p>
<dl class="params"><dt>Parameters</dt><dd>
<table class="params">
<tr><td class="paramname">volume</td><td>Volume of the sound</td></tr>
</table>
</dd>
</dl>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundSource.html#a04243fb5edf64561689b1d58953fc4ce" title="Get the volume of the sound.">getVolume</a></code> </dd></dl>
</div>
</div>
<a id="a781fe51135fdc5679fe22a5665110143" name="a781fe51135fdc5679fe22a5665110143"></a>
<h2 class="memtitle"><span class="permalink"><a href="#a781fe51135fdc5679fe22a5665110143">&#9670;&#160;</a></span>stop()</h2>
<div class="memitem">
<div class="memproto">
<table class="mlabels">
<tr>
<td class="mlabels-left">
<table class="memname">
<tr>
<td class="memname">void sf::SoundStream::stop </td>
<td>(</td>
<td class="paramname"><span class="paramname"><em></em></span></td><td>)</td>
<td></td>
</tr>
</table>
</td>
<td class="mlabels-right">
<span class="mlabels"><span class="mlabel">override</span><span class="mlabel">virtual</span><span class="mlabel">inherited</span></span> </td>
</tr>
</table>
</div><div class="memdoc">
<p>Stop playing the audio stream. </p>
<p>This function stops the stream if it was playing or paused, and does nothing if it was already stopped. It also resets the playing position (unlike <code><a class="el" href="classsf_1_1SoundStream.html#a2285cedcbcb5f3c97828c664934dc0de" title="Pause the audio stream.">pause()</a></code>).</p>
<dl class="section see"><dt>See also</dt><dd><code><a class="el" href="classsf_1_1SoundStream.html#af05290eb2c6a316790fb18c5912a5dd6" title="Start or resume playing the audio stream.">play</a></code>, <code><a class="el" href="classsf_1_1SoundStream.html#a2285cedcbcb5f3c97828c664934dc0de" title="Pause the audio stream.">pause</a></code> </dd></dl>
<p>Implements <a class="el" href="classsf_1_1SoundSource.html#a06501a25b12376befcc7ee1ed4865fda">sf::SoundSource</a>.</p>
</div>
</div>
<hr/>The documentation for this class was generated from the following file:<ul>
<li><a class="el" href="Music_8hpp_source.html">Music.hpp</a></li>
</ul>
</div><!-- contents -->
</div>
<div id="footer-container">
<div id="footer">
SFML is licensed under the terms and conditions of the <a href="https://www.sfml-dev.org/license.php">zlib/png license</a>.<br />
Copyright &copy; Laurent Gomila &nbsp;::&nbsp;
Documentation generated by <a href="http://www.doxygen.org/" title="doxygen website">doxygen</a> &nbsp;::&nbsp;
</div>
</div>
</body>
</html>