I run ffmpeg from a windows console. It colors its messages, eg. warnings are (red) yellow and errors are bright red. That's all good, but when I interrupt ffmpeg, it sometimes leaves the console color changed and then all further text in the same console will be written in that color.
The cls command does not restore the color like it used to in some windows versions. Rerunning ffmpeg doesn't help because it checks the console color when it starts and restores that when it exits. I don't wish to close the console and start a new one because that would lose the command history. Thus, I need a separate command to reset the console colors. Here's a simple command to do that (put it into a batch file). Works with ActiveState perl 5.16.1.
perl -we "use Win32::Console; $con = Win32::Console->new(STD_OUTPUT_HA +NDLE()); $con->Attr($ATTR_NORMAL);"
In reply to Restore normal text color in windows console by ambrus
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |