diff options
| author | 2022-03-19 21:51:16 -0700 | |
|---|---|---|
| committer | 2022-03-24 18:13:33 -0700 | |
| commit | ca12a77670d1463c2257bcdd829bb9bc56f1461b (patch) | |
| tree | 8c6f7781383232909584d65e982376cb2e7ecd46 /src/video_core | |
| parent | hle: nvflinger: BufferQueueProducer: Handle SetPreallocatedBuffer with empty ... (diff) | |
| download | yuzu-ca12a77670d1463c2257bcdd829bb9bc56f1461b.tar.gz yuzu-ca12a77670d1463c2257bcdd829bb9bc56f1461b.tar.xz yuzu-ca12a77670d1463c2257bcdd829bb9bc56f1461b.zip | |
hle: nvflinger: Migrate android namespace -> Service::android.
Diffstat (limited to 'src/video_core')
| -rw-r--r-- | src/video_core/framebuffer_config.h | 4 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.cpp | 8 | ||||
| -rw-r--r-- | src/video_core/renderer_opengl/renderer_opengl.h | 4 | ||||
| -rw-r--r-- | src/video_core/renderer_vulkan/vk_blit_screen.cpp | 10 | ||||
| -rw-r--r-- | src/video_core/surface.cpp | 8 | ||||
| -rw-r--r-- | src/video_core/surface.h | 2 |
6 files changed, 18 insertions, 18 deletions
diff --git a/src/video_core/framebuffer_config.h b/src/video_core/framebuffer_config.h index 1e75d51ab..93349bb78 100644 --- a/src/video_core/framebuffer_config.h +++ b/src/video_core/framebuffer_config.h | |||
| @@ -20,8 +20,8 @@ struct FramebufferConfig { | |||
| 20 | u32 width{}; | 20 | u32 width{}; |
| 21 | u32 height{}; | 21 | u32 height{}; |
| 22 | u32 stride{}; | 22 | u32 stride{}; |
| 23 | android::PixelFormat pixel_format{}; | 23 | Service::android::PixelFormat pixel_format{}; |
| 24 | android::BufferTransformFlags transform_flags{}; | 24 | Service::android::BufferTransformFlags transform_flags{}; |
| 25 | Common::Rectangle<int> crop_rect; | 25 | Common::Rectangle<int> crop_rect; |
| 26 | }; | 26 | }; |
| 27 | 27 | ||
diff --git a/src/video_core/renderer_opengl/renderer_opengl.cpp b/src/video_core/renderer_opengl/renderer_opengl.cpp index 279421962..f8f29013a 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.cpp +++ b/src/video_core/renderer_opengl/renderer_opengl.cpp | |||
| @@ -323,12 +323,12 @@ void RendererOpenGL::ConfigureFramebufferTexture(TextureInfo& texture, | |||
| 323 | 323 | ||
| 324 | GLint internal_format; | 324 | GLint internal_format; |
| 325 | switch (framebuffer.pixel_format) { | 325 | switch (framebuffer.pixel_format) { |
| 326 | case android::PixelFormat::Rgba8888: | 326 | case Service::android::PixelFormat::Rgba8888: |
| 327 | internal_format = GL_RGBA8; | 327 | internal_format = GL_RGBA8; |
| 328 | texture.gl_format = GL_RGBA; | 328 | texture.gl_format = GL_RGBA; |
| 329 | texture.gl_type = GL_UNSIGNED_INT_8_8_8_8_REV; | 329 | texture.gl_type = GL_UNSIGNED_INT_8_8_8_8_REV; |
| 330 | break; | 330 | break; |
| 331 | case android::PixelFormat::Rgb565: | 331 | case Service::android::PixelFormat::Rgb565: |
| 332 | internal_format = GL_RGB565; | 332 | internal_format = GL_RGB565; |
| 333 | texture.gl_format = GL_RGB; | 333 | texture.gl_format = GL_RGB; |
| 334 | texture.gl_type = GL_UNSIGNED_SHORT_5_6_5; | 334 | texture.gl_type = GL_UNSIGNED_SHORT_5_6_5; |
| @@ -464,8 +464,8 @@ void RendererOpenGL::DrawScreen(const Layout::FramebufferLayout& layout) { | |||
| 464 | const auto& texcoords = screen_info.display_texcoords; | 464 | const auto& texcoords = screen_info.display_texcoords; |
| 465 | auto left = texcoords.left; | 465 | auto left = texcoords.left; |
| 466 | auto right = texcoords.right; | 466 | auto right = texcoords.right; |
| 467 | if (framebuffer_transform_flags != android::BufferTransformFlags::Unset) { | 467 | if (framebuffer_transform_flags != Service::android::BufferTransformFlags::Unset) { |
| 468 | if (framebuffer_transform_flags == android::BufferTransformFlags::FlipV) { | 468 | if (framebuffer_transform_flags == Service::android::BufferTransformFlags::FlipV) { |
| 469 | // Flip the framebuffer vertically | 469 | // Flip the framebuffer vertically |
| 470 | left = texcoords.right; | 470 | left = texcoords.right; |
| 471 | right = texcoords.left; | 471 | right = texcoords.left; |
diff --git a/src/video_core/renderer_opengl/renderer_opengl.h b/src/video_core/renderer_opengl/renderer_opengl.h index e6395b900..aa206878b 100644 --- a/src/video_core/renderer_opengl/renderer_opengl.h +++ b/src/video_core/renderer_opengl/renderer_opengl.h | |||
| @@ -46,7 +46,7 @@ struct TextureInfo { | |||
| 46 | GLsizei height; | 46 | GLsizei height; |
| 47 | GLenum gl_format; | 47 | GLenum gl_format; |
| 48 | GLenum gl_type; | 48 | GLenum gl_type; |
| 49 | android::PixelFormat pixel_format; | 49 | Service::android::PixelFormat pixel_format; |
| 50 | }; | 50 | }; |
| 51 | 51 | ||
| 52 | /// Structure used for storing information about the display target for the Switch screen | 52 | /// Structure used for storing information about the display target for the Switch screen |
| @@ -135,7 +135,7 @@ private: | |||
| 135 | std::vector<u8> gl_framebuffer_data; | 135 | std::vector<u8> gl_framebuffer_data; |
| 136 | 136 | ||
| 137 | /// Used for transforming the framebuffer orientation | 137 | /// Used for transforming the framebuffer orientation |
| 138 | android::BufferTransformFlags framebuffer_transform_flags{}; | 138 | Service::android::BufferTransformFlags framebuffer_transform_flags{}; |
| 139 | Common::Rectangle<int> framebuffer_crop_rect; | 139 | Common::Rectangle<int> framebuffer_crop_rect; |
| 140 | }; | 140 | }; |
| 141 | 141 | ||
diff --git a/src/video_core/renderer_vulkan/vk_blit_screen.cpp b/src/video_core/renderer_vulkan/vk_blit_screen.cpp index 3da16c422..d893c1952 100644 --- a/src/video_core/renderer_vulkan/vk_blit_screen.cpp +++ b/src/video_core/renderer_vulkan/vk_blit_screen.cpp | |||
| @@ -94,11 +94,11 @@ std::size_t GetSizeInBytes(const Tegra::FramebufferConfig& framebuffer) { | |||
| 94 | 94 | ||
| 95 | VkFormat GetFormat(const Tegra::FramebufferConfig& framebuffer) { | 95 | VkFormat GetFormat(const Tegra::FramebufferConfig& framebuffer) { |
| 96 | switch (framebuffer.pixel_format) { | 96 | switch (framebuffer.pixel_format) { |
| 97 | case android::PixelFormat::Rgba8888: | 97 | case Service::android::PixelFormat::Rgba8888: |
| 98 | return VK_FORMAT_A8B8G8R8_UNORM_PACK32; | 98 | return VK_FORMAT_A8B8G8R8_UNORM_PACK32; |
| 99 | case android::PixelFormat::Rgb565: | 99 | case Service::android::PixelFormat::Rgb565: |
| 100 | return VK_FORMAT_R5G6B5_UNORM_PACK16; | 100 | return VK_FORMAT_R5G6B5_UNORM_PACK16; |
| 101 | case android::PixelFormat::Bgra8888: | 101 | case Service::android::PixelFormat::Bgra8888: |
| 102 | return VK_FORMAT_B8G8R8A8_UNORM; | 102 | return VK_FORMAT_B8G8R8A8_UNORM; |
| 103 | default: | 103 | default: |
| 104 | UNIMPLEMENTED_MSG("Unknown framebuffer pixel format: {}", | 104 | UNIMPLEMENTED_MSG("Unknown framebuffer pixel format: {}", |
| @@ -1390,9 +1390,9 @@ void VKBlitScreen::SetVertexData(BufferData& data, const Tegra::FramebufferConfi | |||
| 1390 | auto right = texcoords.right; | 1390 | auto right = texcoords.right; |
| 1391 | 1391 | ||
| 1392 | switch (framebuffer_transform_flags) { | 1392 | switch (framebuffer_transform_flags) { |
| 1393 | case android::BufferTransformFlags::Unset: | 1393 | case Service::android::BufferTransformFlags::Unset: |
| 1394 | break; | 1394 | break; |
| 1395 | case android::BufferTransformFlags::FlipV: | 1395 | case Service::android::BufferTransformFlags::FlipV: |
| 1396 | // Flip the framebuffer vertically | 1396 | // Flip the framebuffer vertically |
| 1397 | left = texcoords.right; | 1397 | left = texcoords.right; |
| 1398 | right = texcoords.left; | 1398 | right = texcoords.left; |
diff --git a/src/video_core/surface.cpp b/src/video_core/surface.cpp index f7d29534e..5f428d35d 100644 --- a/src/video_core/surface.cpp +++ b/src/video_core/surface.cpp | |||
| @@ -190,13 +190,13 @@ PixelFormat PixelFormatFromRenderTargetFormat(Tegra::RenderTargetFormat format) | |||
| 190 | } | 190 | } |
| 191 | } | 191 | } |
| 192 | 192 | ||
| 193 | PixelFormat PixelFormatFromGPUPixelFormat(android::PixelFormat format) { | 193 | PixelFormat PixelFormatFromGPUPixelFormat(Service::android::PixelFormat format) { |
| 194 | switch (format) { | 194 | switch (format) { |
| 195 | case android::PixelFormat::Rgba8888: | 195 | case Service::android::PixelFormat::Rgba8888: |
| 196 | return PixelFormat::A8B8G8R8_UNORM; | 196 | return PixelFormat::A8B8G8R8_UNORM; |
| 197 | case android::PixelFormat::Rgb565: | 197 | case Service::android::PixelFormat::Rgb565: |
| 198 | return PixelFormat::R5G6B5_UNORM; | 198 | return PixelFormat::R5G6B5_UNORM; |
| 199 | case android::PixelFormat::Bgra8888: | 199 | case Service::android::PixelFormat::Bgra8888: |
| 200 | return PixelFormat::B8G8R8A8_UNORM; | 200 | return PixelFormat::B8G8R8A8_UNORM; |
| 201 | default: | 201 | default: |
| 202 | UNIMPLEMENTED_MSG("Unimplemented format={}", format); | 202 | UNIMPLEMENTED_MSG("Unimplemented format={}", format); |
diff --git a/src/video_core/surface.h b/src/video_core/surface.h index 1061b2fa7..5704cf16a 100644 --- a/src/video_core/surface.h +++ b/src/video_core/surface.h | |||
| @@ -460,7 +460,7 @@ PixelFormat PixelFormatFromDepthFormat(Tegra::DepthFormat format); | |||
| 460 | 460 | ||
| 461 | PixelFormat PixelFormatFromRenderTargetFormat(Tegra::RenderTargetFormat format); | 461 | PixelFormat PixelFormatFromRenderTargetFormat(Tegra::RenderTargetFormat format); |
| 462 | 462 | ||
| 463 | PixelFormat PixelFormatFromGPUPixelFormat(android::PixelFormat format); | 463 | PixelFormat PixelFormatFromGPUPixelFormat(Service::android::PixelFormat format); |
| 464 | 464 | ||
| 465 | SurfaceType GetFormatType(PixelFormat pixel_format); | 465 | SurfaceType GetFormatType(PixelFormat pixel_format); |
| 466 | 466 | ||