0

Is there a possible way to draw an image on an image in a Windows Console Application? I know there is "Graphics", but its available in Windows Forms Application, which I am not looking for. For anyone wondering, i'ts for a Discord bot.

For example, i have a command called Draw which looks like this:

[Command("Draw")]
public async Task drawimage(string imagepath)
{
    string baseimage = "baseimage.png"

    string result = ... // result image
    await Context.Channel.SendFileAsync(result);
} 

When the command is called like: >Draw E:/someimage.png for example it will draw an image on a "base" image.

Base image

After the command is called the E:/someimage.png will draw in the middle and send it to the channel the command is called in:

Result image < my goal

Is there any way to do this? Thanks in advance.

hehexd
  • 21
  • 4
  • There are quite a few interesting post about this.. Do your research!! For [example](http://stackoverflow.com/questions/33538527/display-a-image-in-a-console-application?rq=1) – TaW Apr 23 '17 at 17:24
  • I did, i'ts just that they are all using System.Drawing which i can't use in a Windows Console Application. – hehexd Apr 23 '17 at 17:25
  • 1
    _"they are all using System.Drawing which i can't use in a Windows Console Application"_ -- you are mistaken. Your console program can reference whatever assemblies it needs to in order to get its job done. Just because you aren't actually rendering graphics on the screen, that doesn't mean you can't still use libraries that help with that task and which also include the imaging APIs you want to use. – Peter Duniho Apr 23 '17 at 17:42
  • Yeah i just found out that u can add the reference manually. Rip – hehexd Apr 23 '17 at 17:48

0 Answers0