Questions tagged [wic]

Windows Imaging Component

The Windows Imaging Component (WIC) provides an extensible framework for working with images and image metadata. WIC makes it possible to develop image codecs and get the same platform support as standard image formats. A single, consistent set of interfaces is used for all image processing, regardless of image format, so any application using the WIC gets automatic support for new image formats as soon as the codec is installed. The extensible metadata framework makes it possible for applications to read and write their own proprietary metadata directly to image files, so the metadata never gets lost or separated from the image.

171 questions
0
votes
1 answer

Tiff Windows Imaging Component c++

I am trying to replace libtiff into WIC (since libtiff is not able to pass Black Duck Analysis tool anymore) I have used their example https://learn.microsoft.com/en-us/windows/win32/wic/-wic-creating-encoder And I was able to create a tiff. I also…
Gilad
  • 6,437
  • 14
  • 61
  • 119
0
votes
0 answers

the procedure deal with WM_PAINT didn't draw anything on the window with Direct2D

I am doing a program with Direct2D and I want to paint a flower on the window. However, I could only see a white window with nothing except the menu. I tested, and then I found that the code which deal with the message WM_PAINT didn't work. I added…
Sam-zhuang
  • 24
  • 5
0
votes
1 answer

Function calling in WIC codecs

Im trying to create a WIC codec in c. As far as i am concerned, the functions that the different interfaces implement, are recognized and called by them having a specific name. In this case i am trying to implement the function GetPixelFormat from…
Laplace
  • 1
  • 1
0
votes
0 answers

Does WIC support AVIF files?

My understanding is that Windows has an AVIF codec. I would like to read AVIF files using WIC, but don't see GUID_ContainerFormatAVIF (or anything similar) defined anywhere. Without this information I can't add AVIF support to my program. Anyone…
JMS
  • 1
0
votes
2 answers

TWICImage: how to save transparent BMP?

I'm using Delphi 10.4.2 and I have an application that scales images (BMP, GIF, PNG, ...). My problem is that if the input image is a transparent BMP the output BMP is not transparent, instead it has a black backgound. This also happens when the…
0
votes
1 answer

If i don`t release WICFactory(IWICImagingFactory*), What happen?

I'm learning DirectX 2D. When i close my application, i have noticed there is a problem in IWICImagingFactory* type variable. I use only one IWICImagingFactory* variable in whole program. So i initiate it once when i start program and…
0
votes
1 answer

The result of loading image from stream using WIC is flipped upside down

I try to load images from the IStream and render them onto a dc. The code below works fine pub fn to_GDI_bitmap(&mut self, ctx: *mut HDC__, hMEM_BUFF: &MEM_BUFF, (flip_hor, flip_vert): (bool, bool)) -> *mut HBITMAP__ { let hStream: HIStream…
Nikolai Savulkin
  • 697
  • 5
  • 12
0
votes
0 answers

UWP how to configure VT_LPSTR in BitmapTypedValue

NOTE: this is UWP-specific, please do not reply with what works in WPF, WinForms, C++, etc. we have already looked at these. Trying to encode iTXt metadata block into a PNG in UWP/WIC but having an issue with the Keyword field. Encoding metadata…
escape-llc
  • 1,295
  • 1
  • 12
  • 25
0
votes
1 answer

How to map a texture to the default cube utilising the Direct X11 XAML UWP, C++?

I'm relatively new C++/DX11- although I've been researching a lot on the subject to get myself up to speed. Anyway, my issue is that with the default DX11 XAML UWP Template (I'm using VS 2017)- I'm having trouble applying a texture onto the mesh.…
Williams
  • 19
  • 8
0
votes
1 answer

How to check if image has an alpha channel

I'm loading an image using the Windows Imaging Component. I can easily find out the pixel format of the image by calling IWICBitmapSource::GetPixelFormat(). I can also easily find out the number of bits per pixel and the number of channels by using…
Andreas
  • 9,245
  • 9
  • 49
  • 97
0
votes
1 answer

How to write an image to STDOUT with Wincodec.h (WIC)

I came across this example and couldn't figure out how to change stream->InitializeFromFilename to something that outputs to STDOUT, inside the HRESULT SavePixelsToFile32bppPBGRA(UINT width, UINT height, UINT stride, LPBYTE pixels, LPWSTR filePath,…
hawaii
  • 328
  • 4
  • 12
0
votes
1 answer

JPEG Decoding problems with WIC

I am currently trying to load images from disk into memory using WIC. I used the MSDN documentation here to write my code. Everything works fine for loading PNG images. Loading JPEG images works without any error but does not produce the correct…
Ohjurot
  • 47
  • 9
0
votes
2 answers

Encoding animated gif with WIC Imaging Component -> Infinite loop

I have a std::vector<> of IWICBitmapSource and trying to create an animated gif: void SaveGif() { CComPtr wicBitmapEncoder; auto hr = fact->CreateEncoder( GUID_ContainerFormatGif, nullptr, …
Michael Chourdakis
  • 10,345
  • 3
  • 42
  • 78
0
votes
0 answers

how to insert a class including ComPtr value to a container in C++?

this is the class that I want to insert. it has constructor initializes 'm_bitmap'. In fact, Initializing m_bitmap doesn't cause problem. I inserted for detail. #pragma once #include "D2DApp.h" class Image { public: ComPtr
0
votes
1 answer

How to write WIC XMP people tags to jpg?

I have images with people tagging information in xml format. I wish to edit this information and also add it to pictures that do not yet have it. By looking at the xml I assume it is based on the people tagging used in the microsoft imaging…
findusl
  • 2,454
  • 8
  • 32
  • 51