Merge branch 'linux' of git://github.com/dougvj/xenia into linux
# Conflicts: # .travis.yml
This commit is contained in:
@@ -184,4 +184,4 @@ GL4Shader* GL4ShaderCache::FindCachedShader(ShaderType shader_type,
|
||||
|
||||
} // namespace gl4
|
||||
} // namespace gpu
|
||||
} // namespace xe
|
||||
} // namespace xe
|
||||
|
||||
@@ -11,8 +11,10 @@
|
||||
#define XENIA_GPU_GL4_SHADER_CACHE_H_
|
||||
|
||||
#include <cstdint>
|
||||
#include <cstring>
|
||||
#include <memory>
|
||||
#include <unordered_map>
|
||||
#include <vector>
|
||||
|
||||
#include "xenia/gpu/xenos.h"
|
||||
|
||||
@@ -57,4 +59,4 @@ class GL4ShaderCache {
|
||||
} // namespace gpu
|
||||
} // namespace xe
|
||||
|
||||
#endif // XENIA_GPU_GL4_SHADER_CACHE_H_
|
||||
#endif // XENIA_GPU_GL4_SHADER_CACHE_H_
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
******************************************************************************
|
||||
* Xenia : Xbox 360 Emulator Research Project *
|
||||
******************************************************************************
|
||||
* Copyright 2016 Ben Vanik. All rights reserved. *
|
||||
* Copyright 2017 Ben Vanik. All rights reserved. *
|
||||
* Released under the BSD license - see LICENSE in the root for more details. *
|
||||
******************************************************************************
|
||||
*/
|
||||
@@ -13,6 +13,7 @@
|
||||
|
||||
#include <cfloat>
|
||||
#include <cstring>
|
||||
#include <vector>
|
||||
|
||||
#include "xenia/base/logging.h"
|
||||
#include "xenia/gpu/spirv/passes/control_flow_analysis_pass.h"
|
||||
@@ -337,8 +338,7 @@ void SpirvShaderTranslator::StartTranslation() {
|
||||
registers_ptr_,
|
||||
std::vector<Id>({b.makeUintConstant(0)}));
|
||||
auto r0 = b.createLoad(r0_ptr);
|
||||
r0 = b.createCompositeInsert(vertex_idx, r0, vec4_float_type_,
|
||||
std::vector<uint32_t>({0}));
|
||||
r0 = b.createCompositeInsert(vertex_idx, r0, vec4_float_type_, 0);
|
||||
b.createStore(r0, r0_ptr);
|
||||
} else {
|
||||
// Pixel inputs from vertex shader.
|
||||
|
||||
@@ -763,6 +763,9 @@ bool RenderCache::ParseConfiguration(RenderConfiguration* config) {
|
||||
case ColorRenderTargetFormat::k_2_10_10_10_FLOAT_unknown:
|
||||
config->color[i].format = ColorRenderTargetFormat::k_2_10_10_10_FLOAT;
|
||||
break;
|
||||
default:
|
||||
// The rest are good
|
||||
break;
|
||||
}
|
||||
}
|
||||
} else {
|
||||
@@ -843,7 +846,7 @@ bool RenderCache::ConfigureRenderPass(VkCommandBuffer command_buffer,
|
||||
color_key.edram_format = static_cast<uint16_t>(config->color[i].format);
|
||||
target_color_attachments[i] =
|
||||
FindOrCreateTileView(command_buffer, color_key);
|
||||
if (!target_color_attachments) {
|
||||
if (!target_color_attachments[i]) {
|
||||
XELOGE("Failed to get tile view for color attachment");
|
||||
return false;
|
||||
}
|
||||
@@ -906,6 +909,9 @@ CachedTileView* RenderCache::FindTileView(uint32_t base, uint32_t pitch,
|
||||
case ColorRenderTargetFormat::k_2_10_10_10_FLOAT_unknown:
|
||||
format = uint32_t(ColorRenderTargetFormat::k_2_10_10_10_FLOAT);
|
||||
break;
|
||||
default:
|
||||
// Other types as-is.
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1145,6 +1151,9 @@ void RenderCache::BlitToImage(VkCommandBuffer command_buffer,
|
||||
case ColorRenderTargetFormat::k_2_10_10_10_FLOAT_unknown:
|
||||
format = uint32_t(ColorRenderTargetFormat::k_2_10_10_10_FLOAT);
|
||||
break;
|
||||
default:
|
||||
// Rest are OK
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1258,6 +1267,9 @@ void RenderCache::ClearEDRAMColor(VkCommandBuffer command_buffer,
|
||||
case ColorRenderTargetFormat::k_2_10_10_10_FLOAT_unknown:
|
||||
format = ColorRenderTargetFormat::k_2_10_10_10_FLOAT;
|
||||
break;
|
||||
default:
|
||||
// Rest are OK
|
||||
break;
|
||||
}
|
||||
|
||||
uint32_t tile_width = num_samples == MsaaSamples::k4X ? 40 : 80;
|
||||
|
||||
@@ -84,7 +84,7 @@ class CachedTileView {
|
||||
}
|
||||
|
||||
VkExtent2D GetSize() const {
|
||||
return {key.tile_width * 80ul, key.tile_height * 16ul};
|
||||
return {key.tile_width * 80u, key.tile_height * 16u};
|
||||
}
|
||||
|
||||
private:
|
||||
|
||||
Reference in New Issue
Block a user