mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 22:29:39 -06:00
Use std::istringstream or std::ostringstream instead of std::stringstream where possible.
This removes std::iostream from the inheritance chain, which reduces overhead slightly.
This commit is contained in:
@ -434,7 +434,7 @@ void PostProcessing::BlitFromTexture(const MathUtil::Rectangle<int>& dst,
|
||||
|
||||
std::string PostProcessing::GetUniformBufferHeader() const
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
u32 unused_counter = 1;
|
||||
if (g_ActiveConfig.backend_info.api_type == APIType::D3D)
|
||||
ss << "cbuffer PSBlock : register(b0) {\n";
|
||||
@ -493,7 +493,7 @@ std::string PostProcessing::GetUniformBufferHeader() const
|
||||
|
||||
std::string PostProcessing::GetHeader() const
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
ss << GetUniformBufferHeader();
|
||||
if (g_ActiveConfig.backend_info.api_type == APIType::D3D)
|
||||
{
|
||||
@ -602,7 +602,7 @@ void main(in float3 v_tex0_ : TEXCOORD0, out float4 ocol0_ : SV_Target)
|
||||
|
||||
bool PostProcessing::CompileVertexShader()
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
ss << GetUniformBufferHeader();
|
||||
|
||||
if (g_ActiveConfig.backend_info.api_type == APIType::D3D)
|
||||
|
@ -1392,7 +1392,7 @@ std::string GenerateDecodingShader(TextureFormat format, TLUTFormat palette_form
|
||||
if (!info)
|
||||
return "";
|
||||
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
switch (palette_format)
|
||||
{
|
||||
case TLUTFormat::IA8:
|
||||
@ -1414,7 +1414,7 @@ std::string GenerateDecodingShader(TextureFormat format, TLUTFormat palette_form
|
||||
|
||||
std::string GeneratePaletteConversionShader(TLUTFormat palette_format, APIType api_type)
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
|
||||
ss << R"(
|
||||
int Convert3To8(int v)
|
||||
|
@ -768,12 +768,12 @@ void VertexManagerBase::OnEndFrame()
|
||||
|
||||
#if 0
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
std::for_each(m_cpu_accesses_this_frame.begin(), m_cpu_accesses_this_frame.end(), [&ss](u32 idx) { ss << idx << ","; });
|
||||
WARN_LOG(VIDEO, "CPU EFB accesses in last frame: %s", ss.str().c_str());
|
||||
}
|
||||
{
|
||||
std::stringstream ss;
|
||||
std::ostringstream ss;
|
||||
std::for_each(m_scheduled_command_buffer_kicks.begin(), m_scheduled_command_buffer_kicks.end(), [&ss](u32 idx) { ss << idx << ","; });
|
||||
WARN_LOG(VIDEO, "Scheduled command buffer kicks: %s", ss.str().c_str());
|
||||
}
|
||||
|
Reference in New Issue
Block a user