diff options
Diffstat (limited to 'src')
| -rw-r--r-- | src/core/hle/service/vi/vi.cpp | 34 |
1 files changed, 27 insertions, 7 deletions
diff --git a/src/core/hle/service/vi/vi.cpp b/src/core/hle/service/vi/vi.cpp index 7c319ee67..d938ef83d 100644 --- a/src/core/hle/service/vi/vi.cpp +++ b/src/core/hle/service/vi/vi.cpp | |||
| @@ -587,7 +587,7 @@ public: | |||
| 587 | {2203, nullptr, "SetLayerSize"}, | 587 | {2203, nullptr, "SetLayerSize"}, |
| 588 | {2204, nullptr, "GetLayerZ"}, | 588 | {2204, nullptr, "GetLayerZ"}, |
| 589 | {2205, &ISystemDisplayService::SetLayerZ, "SetLayerZ"}, | 589 | {2205, &ISystemDisplayService::SetLayerZ, "SetLayerZ"}, |
| 590 | {2207, nullptr, "SetLayerVisibility"}, | 590 | {2207, &ISystemDisplayService::SetLayerVisibility, "SetLayerVisibility"}, |
| 591 | {2209, nullptr, "SetLayerAlpha"}, | 591 | {2209, nullptr, "SetLayerAlpha"}, |
| 592 | {2312, nullptr, "CreateStrayLayer"}, | 592 | {2312, nullptr, "CreateStrayLayer"}, |
| 593 | {2400, nullptr, "OpenIndirectLayer"}, | 593 | {2400, nullptr, "OpenIndirectLayer"}, |
| @@ -637,6 +637,16 @@ private: | |||
| 637 | IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0); | 637 | IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0); |
| 638 | rb.Push(RESULT_SUCCESS); | 638 | rb.Push(RESULT_SUCCESS); |
| 639 | } | 639 | } |
| 640 | |||
| 641 | void SetLayerVisibility(Kernel::HLERequestContext& ctx) { | ||
| 642 | IPC::RequestParser rp{ctx}; | ||
| 643 | u64 layer_id = rp.Pop<u64>(); | ||
| 644 | bool visibility = rp.Pop<bool>(); | ||
| 645 | IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0); | ||
| 646 | rb.Push(RESULT_SUCCESS); | ||
| 647 | LOG_WARNING(Service_VI, "(STUBBED) called, layer_id=0x%x, visibility=%u", layer_id, | ||
| 648 | visibility); | ||
| 649 | } | ||
| 640 | }; | 650 | }; |
| 641 | 651 | ||
| 642 | class IManagerDisplayService final : public ServiceFramework<IManagerDisplayService> { | 652 | class IManagerDisplayService final : public ServiceFramework<IManagerDisplayService> { |
| @@ -668,7 +678,7 @@ public: | |||
| 668 | {4206, nullptr, "SetDefaultDisplay"}, | 678 | {4206, nullptr, "SetDefaultDisplay"}, |
| 669 | {6000, &IManagerDisplayService::AddToLayerStack, "AddToLayerStack"}, | 679 | {6000, &IManagerDisplayService::AddToLayerStack, "AddToLayerStack"}, |
| 670 | {6001, nullptr, "RemoveFromLayerStack"}, | 680 | {6001, nullptr, "RemoveFromLayerStack"}, |
| 671 | {6002, nullptr, "SetLayerVisibility"}, | 681 | {6002, &IManagerDisplayService::SetLayerVisibility, "SetLayerVisibility"}, |
| 672 | {6003, nullptr, "SetLayerConfig"}, | 682 | {6003, nullptr, "SetLayerConfig"}, |
| 673 | {6004, nullptr, "AttachLayerPresentationTracer"}, | 683 | {6004, nullptr, "AttachLayerPresentationTracer"}, |
| 674 | {6005, nullptr, "DetachLayerPresentationTracer"}, | 684 | {6005, nullptr, "DetachLayerPresentationTracer"}, |
| @@ -750,6 +760,16 @@ private: | |||
| 750 | rb.Push(RESULT_SUCCESS); | 760 | rb.Push(RESULT_SUCCESS); |
| 751 | } | 761 | } |
| 752 | 762 | ||
| 763 | void SetLayerVisibility(Kernel::HLERequestContext& ctx) { | ||
| 764 | IPC::RequestParser rp{ctx}; | ||
| 765 | u64 layer_id = rp.Pop<u64>(); | ||
| 766 | bool visibility = rp.Pop<bool>(); | ||
| 767 | IPC::ResponseBuilder rb = rp.MakeBuilder(2, 0, 0); | ||
| 768 | rb.Push(RESULT_SUCCESS); | ||
| 769 | LOG_WARNING(Service_VI, "(STUBBED) called, layer_id=0x%x, visibility=%u", layer_id, | ||
| 770 | visibility); | ||
| 771 | } | ||
| 772 | |||
| 753 | std::shared_ptr<NVFlinger::NVFlinger> nv_flinger; | 773 | std::shared_ptr<NVFlinger::NVFlinger> nv_flinger; |
| 754 | }; | 774 | }; |
| 755 | 775 | ||
| @@ -820,15 +840,15 @@ private: | |||
| 820 | IPC::RequestParser rp{ctx}; | 840 | IPC::RequestParser rp{ctx}; |
| 821 | u64 display_id = rp.Pop<u64>(); | 841 | u64 display_id = rp.Pop<u64>(); |
| 822 | 842 | ||
| 823 | IPC::ResponseBuilder rb = rp.MakeBuilder(4, 0, 0); | 843 | IPC::ResponseBuilder rb = rp.MakeBuilder(6, 0, 0); |
| 824 | rb.Push(RESULT_SUCCESS); | 844 | rb.Push(RESULT_SUCCESS); |
| 825 | 845 | ||
| 826 | if (Settings::values.use_docked_mode) { | 846 | if (Settings::values.use_docked_mode) { |
| 827 | rb.Push(static_cast<u32>(DisplayResolution::DockedWidth)); | 847 | rb.Push(static_cast<u64>(DisplayResolution::DockedWidth)); |
| 828 | rb.Push(static_cast<u32>(DisplayResolution::DockedHeight)); | 848 | rb.Push(static_cast<u64>(DisplayResolution::DockedHeight)); |
| 829 | } else { | 849 | } else { |
| 830 | rb.Push(static_cast<u32>(DisplayResolution::UndockedWidth)); | 850 | rb.Push(static_cast<u64>(DisplayResolution::UndockedWidth)); |
| 831 | rb.Push(static_cast<u32>(DisplayResolution::UndockedHeight)); | 851 | rb.Push(static_cast<u64>(DisplayResolution::UndockedHeight)); |
| 832 | } | 852 | } |
| 833 | } | 853 | } |
| 834 | 854 | ||