MCPcopy Create free account
hub / github.com/HO-COOH/FastCopy / GetHBitmapFromFile

Function GetHBitmapFromFile

FastCopy/ImageUtils.cpp:31–37  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

29}
30
31HBITMAP GetHBitmapFromFile(std::wstring_view path)
32{
33 winrt::com_ptr<IShellItem> item = CreateItemFromParsingName(ToBackslash(path).data());
34 HBITMAP bitmap{};
35 item.as<IShellItemImageFactory>()->GetImage({ 96, 96 }, SIIGBF_BIGGERSIZEOK, &bitmap);
36 return bitmap;
37}
38
39winrt::Microsoft::UI::Xaml::Media::Imaging::WriteableBitmap HBitmapToWriteableBitmap(HBITMAP hBitmap, HBITMAP hMask)
40{

Callers 1

BitmapMethod · 0.85

Calls 3

ToBackslashFunction · 0.85
dataMethod · 0.80

Tested by

no test coverage detected