@@ -619,7 +619,7 @@ void OutputLayer::writeLutToHWC(HWC2::Layer* hwcLayer,
619619 lutProperties[i].samplingKey )}});
620620 }
621621
622- luts.pfd = ndk::ScopedFileDescriptor (dup (lutFileDescriptor.get ()));
622+ luts.pfd . set (dup (lutFileDescriptor.get ()));
623623 luts.offsets = lutOffsets;
624624 luts.lutProperties = std::move (aidlProperties);
625625 }
@@ -1006,7 +1006,7 @@ void OutputLayer::applyDeviceLayerRequest(hal::LayerRequest request) {
10061006}
10071007
10081008void OutputLayer::applyDeviceLayerLut (
1009- ndk::ScopedFileDescriptor lutFileDescriptor ,
1009+ ::android::base::unique_fd lutFd ,
10101010 std::vector<std::pair<int , LutProperties>> lutOffsetsAndProperties) {
10111011 auto & state = editState ();
10121012 LOG_FATAL_IF (!state.hwc );
@@ -1025,9 +1025,9 @@ void OutputLayer::applyDeviceLayerLut(
10251025 samplingKeys.emplace_back (static_cast <int32_t >(properties.samplingKeys [0 ]));
10261026 }
10271027 }
1028- hwcState.luts = std::make_shared<gui::DisplayLuts>(base::unique_fd (lutFileDescriptor. release () ),
1029- std::move (offsets ), std::move (dimensions ),
1030- std::move (sizes), std::move ( samplingKeys));
1028+ hwcState.luts = std::make_shared<gui::DisplayLuts>(std::move (lutFd), std::move (offsets ),
1029+ std::move (dimensions ), std::move (sizes ),
1030+ std::move (samplingKeys));
10311031}
10321032
10331033bool OutputLayer::needsFiltering () const {
0 commit comments