Direct2d: convert a bitmap to a matrix

asked 2021-10-30T13:32:19.787+00:00
SuperSéhane 1 Reputation point

Hello.
I have a ID2D1Bitmap object, and I'd like to make operations on it that require an access to the matrix containing the colors of the points (like make a particulat pixel black, or double the intensity of a pixel). How do I do that?

Windows API - Win32
Windows API - Win32
A core set of Windows application programming interfaces (APIs) for desktop and server applications. Previously known as Win32 API.
1,890 questions
No comments
{count} votes

2 answers

Sort by: Most helpful
  1. answered 2021-10-30T17:00:15.593+00:00
    Castorix31 65,331 Reputation points

    Use Direct2D effects

    like : Color matrix effect

    No comments

  2. answered 2021-11-01T08:05:21.377+00:00
    Xiaopo Yang - MSFT 5,831 Reputation points Microsoft Employee

    Operate the pixels data in fours like array.
    There are some ways which manipulate pixels you can refer to. How to Modify the Pixels of a Bitmap Source, Setting the Alpha Values of Individual Pixels, a related question

    No comments