I have used Microangelo before, and it had one feature which I cannot find in RealWorld: The option to paint alternate pixels.
You could paint or fill an area and it would only affect the odd or even pixels, alternating on each line.
This means that by filling in background colour you could dim the icon.
Any comparable tool in RealWorld to achieve the same effect?
Thanks
Matt Brown
You are right, this feature is not present in RWIE. You have these options:
1) Use background color, set alpha to 1/2 ( 128 ) and use the Paint Over mode (the default one). Then draw any shape or fill an area. This will dim the affected pixels, but the result will be different form Microangelo - the image will be smooth in high color depths, and dithered in low color depths (but there will not be a regular pattern).
2) Create a custom script, that replaces every other pixel with given color. The script would only be able to affect the entire image or the selected area, so no flood-filling and such.
Wow, scripts look like the answer, but I'm not sure I'm up to writing one from scratch!
Could anyone post he code required to do this?
Thanks for your help.
MB
The simples way to run a custom script is to click on "Custom Operation" in the "Effect" menu and replace the script with the following one:
var sizeX = RasterImage.sizeX;
var sizeY = RasterImage.sizeY;
var color = 0xff0000ff;
for(x=0; x<sizeX; x++)
for(y=0; y<sizeY; y++)
if ((x+y)&1)
RasterImage.SetPixel(x, y, 0, 0, color);
Note the color variable on 3rd line. By changing it, you may select different color. The color is in hexadecimal ABGR encoding, if you are not sure what that means, use the following line, but with actual color values (in range 0-255):
var color = (ALPHA<<24)|(BLUE<<16)|(GREEN<<8)|(RED);
There are other ways how to define and run scripts, but this is the easiest one.
Thanks for that.
I can follow the code and kind of see what it does. However, the syntax is incomplete. If anyone could alter the code ({ } and correct number of brackets etc) I would very much appreciate it.
Thanks all.
MB
Oh, there was a problem with html encoding, I forgot to use < instead of < and part of the code was not visible. It should be all right now.
THANKS VLASTA!!!
You are a star.
The colour code for transparent background, var color = 0xff0000ff;, achieves exactly what I wanted!
This creates a dimmed icon for any coloured backdrop.
Thanks for all you help.
Best Regards,
MB
Actually 0xff0000ff should be red . To erase pixels use just color = 0.
oooooooooooo your my pikcur
it says "expected ')'" when i input it.
please post the updated code.
Fixed...
Now it says 'RasterImage is undefined'
(im trying to use this in paint)
It will only work with a older versions of the apps. In newer ones, Document.RasterImage must be used instead of just RasterImage
There is an updated version in another topic.
Find out how Vista icons differ from XP icons.
See how RealWorld Icon Editor handles Vista icons.