Skip to content

Commit

Permalink
Fix minor inconsistency in type cast in voip example
Browse files Browse the repository at this point in the history
because m_samples is a vector of Int16 values.
  • Loading branch information
kimci86 authored and vittorioromeo committed Oct 1, 2022
1 parent 01fc55b commit d0cf86d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/voip/Server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -85,7 +85,7 @@ class NetworkAudioStream : public sf::SoundStream
// (don't forget that we run in two separate threads)
{
sf::Lock lock(m_mutex);
m_tempBuffer.assign(m_samples.begin() + static_cast<std::vector<sf::Int64>::difference_type>(m_offset), m_samples.end());
m_tempBuffer.assign(m_samples.begin() + static_cast<std::vector<sf::Int16>::difference_type>(m_offset), m_samples.end());
}

// Fill audio data to pass to the stream
Expand Down

0 comments on commit d0cf86d

Please sign in to comment.