No WriteableBitmap - How can I add a pixel array to the screen?

edhalsim
Posts: 3
Joined: Thu Dec 10, 2020 2:18 pm

No WriteableBitmap - How can I add a pixel array to the screen?

Postby edhalsim » Sat Dec 19, 2020 2:20 pm

Hi,

I see the class WriteableBitmap isn't implemented yet. I have a function that builds random maps in memory (just an int[][] of pixels). I want to show the map on the Canvas, which in Silverlight I did by:
ImageBrush brush = new ImageBrush();
brush.ImageSource = this._map.Background.ConvertToBitmap(this._map.Palette);
this.Canvas.Background = brush;

How would I do this in OpenSilver?

Thanks
- Ed.

Return to “General Discussion and Other”

Who is online

Users browsing this forum: No registered users and 2 guests

 

 

cron