Hello,
currently I am working on the following scenario:
There is a device connected to my application. That device has a 256x256 pixel display showing graphics and text.
Now for each pixel of that display I receive a flag whether the pixel is to be drawn or not.
Furthermore to display text you can imagine the surface as divided in 21 columns and 16 rows. Now for each cell I get information whether some letter is to be displayed in that cell or not.
By combining these two information I shall be able to draw the device display in any .NET application as if the user was directly watching the device itself.
Now of course it is easy to restrict the application to a client size of 256x256 and just draw every pixel. Once I found a font and font size to fit 21 columns and 16 rows I am good.
But that wont do it as the user wants to be able to scale the display infinitely(howe ver I will force him to keep the aspect ratio).
Now I am evaluating what approach might be the best.
The easiest I can imagine is just draw that 256x256 image and then scale that bitmap using .NETs build in methods. But that might get pretty ugly.. especially for the text artefacts.
I dont know if WPF offers some handy way to manage this?
Thank you!
Kevin
currently I am working on the following scenario:
There is a device connected to my application. That device has a 256x256 pixel display showing graphics and text.
Now for each pixel of that display I receive a flag whether the pixel is to be drawn or not.
Furthermore to display text you can imagine the surface as divided in 21 columns and 16 rows. Now for each cell I get information whether some letter is to be displayed in that cell or not.
By combining these two information I shall be able to draw the device display in any .NET application as if the user was directly watching the device itself.
Now of course it is easy to restrict the application to a client size of 256x256 and just draw every pixel. Once I found a font and font size to fit 21 columns and 16 rows I am good.
But that wont do it as the user wants to be able to scale the display infinitely(howe ver I will force him to keep the aspect ratio).
Now I am evaluating what approach might be the best.
The easiest I can imagine is just draw that 256x256 image and then scale that bitmap using .NETs build in methods. But that might get pretty ugly.. especially for the text artefacts.
I dont know if WPF offers some handy way to manage this?
Thank you!
Kevin