Search the Community

Showing results for tags 'color'.



More search options

  • Search By Tags

    Type tags separated by commas.
  • Search By Author

Content Type


Forums

  • Information
    • Forum Rules
    • Paint.NET Search
    • Official Paint.NET website
    • Help Files (the official paint.net documentation)
  • Paint.NET
    • Paint.NET Discussion and Questions
    • The Pictorium
    • Tutorials - Publishing ONLY!
    • Competitions
    • Plugins - Publishing ONLY!
    • Troubleshooting & Bug Reports
  • Off-Topic
    • Grand Theory of Everything
  • Paint.NET Programming / Development
    • Plugin Developer's Central
    • Preview Center
    • Translation and Localization

Find results in...

Find results that contain...


Date Created

  • Start

    End


Last Updated

  • Start

    End


Filter by number of...

Joined

  • Start

    End


Group


Website URL


AIM


MSN


ICQ


Yahoo


Jabber


Skype


Location


Interests

Found 34 results

  1. AdvDith-en.zipAdvDith - dithering effect used 2 color (black & white). Interface (ENG lang avaliable) Avaliable desaturation algorithms: ITU-R BT.2100; ITU-R BT.709; ITU-R BT.601; MAXMIN2; Pifagor; Only red; Only green; Only blue; Average. Dithering algorithms: Ordered 2x2, 3x3, 4x4, 8x8 - Bayer dither. Mpre(i,j) = (Mint(i,j)+1) / n^2 - 0.5; Lines vertical/horizontal; Floyd-Steinberg, Floyd false; Jarvis-Judice-Ninke; Stucki; Burkes; Sierra3, Sierra2, Sierra2-4A; Atkinson; Random. For Paint.net v4.2.12. Download Supprot me for more plugins :3
  2. Plugin for converting images to old style tile-based graphic. Video demo Example: Interface (ENG ver avaliable): Avaliable palettes: CGA - 3 pal's; MSX1 - screen mode 1; MSX2 - 4 color palette; ZX Spectrum - standart graphic; Posterization 1-3 bit. For paint.net version 4.2.10 Download Supprot me for more plugins :3
  3. Back with my second plugin. This time I made a plugin that can be used to easily and quickly create a gradient mapping effect using 2 colors. I know pyrochild already made a gradient mapping tool, but this is just a simplified version using only 2 colors for dark and light tones. I added some options for post processing as well, like contrast and blending mode. Download: DuotoneGradientMap.zip Preview: Code: (I’m still a beginner in C#, please don’t hurt me) // Name: Duotone Gradient Map // Submenu: Color // Author: Pascal // Title: Duotone Gradient Map // Version: 1.0 // Desc: Easy and quick way of gradient mapping // Keywords: // URL: // Help: #region UICode ColorWheelControl Amount1 = ColorBgra.FromBgr(0, 0, 0); // Dark ColorWheelControl Amount2 = ColorBgra.FromBgr(255, 255, 255); // Light IntSliderControl Amount3 = 100; // [0,100] Amount IntSliderControl Amount4 = 0; // [0,1000] Contrast ListBoxControl Amount5 = 0; // Blending mode|Normal|Multiply|Darken|Lighten|Additive #endregion void Render(Surface dst, Surface src, Rectangle rect) { ColorBgra Primary = Amount1; ColorBgra Secondary = Amount2; ColorBgra Cp; //current pixel ColorBgra Np; //new pixel for (int y = rect.Top; y < rect.Bottom; y++) { if (IsCancelRequested) return; for (int x = rect.Left; x < rect.Right; x++) { Cp = src[x,y]; //control parameters double A = ((double)Amount3)/100; //amount double C = (double)Amount4; //contrast int M = Amount5; //blending mode //get rgb double R = Cp.R; double G = Cp.G; double B = Cp.B; //value double P = ((R+G+B)/3)/255; //luminosity //get colors double Rp = Primary.R; double Rs = Secondary.R; double Gp = Primary.G; double Gs = Secondary.G; double Bp = Primary.B; double Bs = Secondary.B; //calculate new color R = Norm((P*Rs + (1-P)*Rp)*A + (1-A)*R, 255); G = Norm((P*Gs + (1-P)*Gp)*A + (1-A)*G, 255); B = Norm((P*Bs + (1-P)*Bp)*A + (1-A)*B, 255); //apply new color and contrast Np = ColorBgra.FromBgra( (byte)Norm(Con(B, C), 255), (byte)Norm(Con(G, C), 255), (byte)Norm(Con(R, C), 255), Cp.A); //BLENDING MODES //multiply if(M == 1){ Cp.R = (byte)Norm((Cp.R * Np.R/255)*A + Cp.R*(1-A), 255); Cp.G = (byte)Norm((Cp.G * Np.G/255)*A + Cp.G*(1-A), 255); Cp.B = (byte)Norm((Cp.B * Np.B/255)*A + Cp.B*(1-A), 255); } //darken else if(M == 2){ if(Np.R < Cp.R){ Cp.R = Np.R; } if(Np.G < Cp.G){ Cp.G = Np.G; } if(Np.B < Cp.B){ Cp.B = Np.B; } } //lighten else if(M == 3){ if(Np.R > Cp.R){ Cp.R = Np.R; } if(Np.G > Cp.G){ Cp.G = Np.G; } if(Np.B > Cp.B){ Cp.B = Np.B; } } //additive else if(M == 4){ Cp.R = (byte)Norm(Cp.R + Np.R*A, 255); Cp.G = (byte)Norm(Cp.G + Np.G*A, 255); Cp.B = (byte)Norm(Cp.B + Np.B*A, 255); } //normal else{ Cp = Np; } dst[x,y] = Cp; } } } //normalize double Norm(double x, int i){ if(x > i){ x = i; } if(x < 0){ x = 0; } return x; } //contrast double Con(double x, double c){ x /= 255; double y; if(x <= 0.5){ y = 0.5 * Math.Pow(2*x, (c/500)+1); } else{ y = 1 - 0.5 * Math.Pow(2 - 2*x, (c/500)+1); } return y*255; }
  4. I made my first plugin using CodeLab. It can be used to simulate different types of colorblindness. I always liked the tritanopia effect, but couldn’t find a plugin for it online, so I just made it myself. It is not scientifically accurate, but it comes very close. My source code is a mess, so I won’t share it. I hope you like it. Download: Colorblindness2.zip Can be found in Effects > Color > Colorblindness Demo: Interface:
  5. Color > Color Magic It's been a while since I've posted here. I'm currently in the process of reorganizing/revamping my plugins as well as developing new ones. Color Magic This plugin lets you recolor an image in a pretty wide variety of ways with a lot of fine-tuning. It's designed in such a way to keep colors at reasonable proportions to one another, meaning that unlike other coloring effects (including even the regular Hue adjustment) , these hue shifts look quite natural. While it will probably take a lot of experimentation to get something in particular, the controls make minor changes which allow you to tweak things very easily. In any case, let's take a look at what the plugin looks like: Use -- Feeds different things into the Hue. The default setting is the normal image, which still allows you to use the other sliders for different effects. Smoothness -- Determines how "smooth" the recoloring is. Values smaller than 1 will have much wider gulfs between hues, allowing you to make things be 2-color or 3-color pretty easily, while values higher than 1 make the effect more pronounced, and at high values will make things take on a "heat map" or psychedelic appearance. Filter -- Filters out a specific range of hues from appearing. At 360, all hues *can* appear (they won't necessarily because of how the plugin works). The setting starts at purple and slowly removes hue ranges, going to blue, to green, to yellow, to orange and eventually at 0 only red will appear. Hues that have been "filtered" will bounce around inside the allowed range, maintaining their proportionality with other hues and not wrapping around randomly. As a result you get some pretty smooth transitions, though artifacts will appear sometimes. Final Hue -- Lets you adjust the final hue of the image after all the other effects are done. Now then, let's look at what some of these settings actually do. We'll start with a normal image of Barack Obama. I tried to keep the image size set to what other tutorials use here, but it has been a while since I posted here, so mods tell me if I need to resize anything. Adjusting the Smoothness slider will do things like this. You're basically recoloring hues in proportionate ways -- red/brown things change very little while blue things change a lot. There are some artifacts on the image to the right, which we can fix with the Filter setting: No artifacts in either of these cases, though the hue of Obama's suit is also different. With a lot of tweaking, it is possible to find a dark green variant that does what you want it to do. That tends to be where the Use setting comes in. Here's a tall image comparing different Use settings, with the normal image on the left for comparison. In a couple cases I've also adjusted the smoothness because the default values need some tweaking still. Again, mods let me know if the image is too tall or something (I still have all the originals). What these different settings do is basically proportionately transform some element(s) of the image into a hue. So for example, in the saturation setting, parts of the image that are less saturated will turn red while parts of the image which are more saturated will become blue or purple. From here you can adjust the Smoothness setting to spread those proportions out or bunching them together, the Filter setting to constrain specific hues and the Final Hue setting to get a final result. In any case, if nothing else this plugin should be fun to experiment around with. Here's a link to the DLL: https://github.com/Xhin23/Paint.net-Plugins/blob/master/Color_Magic.dll
  6. During a frustrating run of having to swap and replace 20+ colors and potentially more in the future to give my pixel art a better look and feel, I made a plugin that allows you to swap and change colors though typing them in a list. The plugin also has the ability to manipulate annoying alpha colors that plugins sometimes generate. Setting alpha to 255 reveals all of those ugly alpha leftovers! There is also the option of using an incremental palette, which clamps RGB colors to increments of a value. Useful for limiting colors to a known value that you can manipulate easier such as feeding those values back to the list to be changed again or for converting images to be processed for pixel art with various other plugins. Can be found in Effects -> Color -> Replace Colors + Palette This does not replace selective palette plugins or color reducing plugins as this is different from those. Using certain increment counts will give a good visual style to your images. It will not work well with artifacts and graininess as you can see from these images. Pixelart is the best choice if you want to make use of this feature to its fullest. The incremental palette clamps colors to an increment of a value. For example, using 50 will transform 54 to 50 and 165 to 150. This is the simplest way to convert an image to a simple palette which also gives you some room to manipulate colors more. Be sure to use a color picker program in case you want to change the colors created from it. Example: --black becomes 10 10 10 0,0,0=10,10,10 --uses commas and no spaces --20 20 20 becomes black 20 20 20=0 0 0 --spaces instead of commas --you can keep going affecting colors as you go Proper Regex was used in the text window to allow you to change one color to another. You can use spaces, no spaces, or commas to your liking. If you have to use multiple lists to change colors I recommend using a text editor to manage them then copy and paste what you want. Using a large list of too many color changes may cause slowdowns. Replace Colors + Palette.dll
  7. RGB Compositor Effects -> Color -> RGB Compositor Description This will use a single channel from each photo to compose a full RGB value for the final image. The 8-Bit Guy on YouTube explains it well. NOTE: All three photos need to be the same size as your canvas. NOTE: No, this will not magically turn a Black and White photo to a color photo. Before (An image for each color channel) Red Green Blue After (Composed) Changelog v1.0 (Jan 6, 2019) Initial release Download RGBCompositor.zip Source Code https://github.com/toehead2001/pdn-rgb-compositor
  8. This is a very simple plugin originally intended to erase pixels in the canvas that don't match the clipboard, but extended so that it can optionally keep them instead. The clipboard image must be the same size as the canvas; otherwise, the effect does nothing. For no particularly good reason, other than I couldn't think of anything better, it's in the Color menu. The plugin: MismatchEraser.zip It's a CodLab plugin. Here is the source code:
  9. Description: This effect converts each pixel brightness to hue spectrum color. Plugin has one slider to set spectrum offset. Plugin: Effects > Color > Trippy rainbow Examples: Github: https://github.com/PavielKraskouski/PaintDotNetPlugins/tree/master/TrippyRainbow Download: TrippyRainbow.dll
  10. Hi All, This plugin is an improvement on Jotaf's Grim Color Reaper. I use this plugin a lot but wanted some improvements, suddenly I realized that the since I can code a little and I can use the skill (?) . As, Jotaf has mentioned in his post that it is opensource, so I made one mine on Codelab version 3.3. The enhancement it has that It lets you now to choose color through UI instead of going through selecting primary color. It also has an option for keeping color i.e. while Grim Color Reaper 'kills' a specific color, Kill Color Keeper has an option to preserve specific color while killing every other one. User Interface: UI is similar to Grim reaper. It has options for tolerance and cut off value. But as a significant improvement, that it has Color Wheel inside UI so you can pick up color as desired. Default is still Primary Color. There are two option for Keep color and Kill color. There are two sliders which are dedicated to these two functions. I could have made it work with same slider, but default value for kill Color always turned out to make whole image transparent for Keep Color Option. Also, there was a need of different slider description . So, I made two dedicated sliders for them with their own default value and own description. In version 1.1, there are two sliders: Function Kill Color has only one slider for it while Keep Color has two sliders dedicated to it. 1. Original Image: 2. Kill color white i.e. background. 3. Keep Color Blue i.e. for dresses here. (Please ignore mistakes in UI name & values, this screen print was taken before final DLL was built.) Versions 1.1 In Keep Color Option if the original image pixel were transparent like this Then Keep Color Options would turn transparent pixels in white color (i.e there were given some opacity while running effect). So new version checks that if Alpha is less than given threshold values. I used first sliders to ignore less opaque pixels. UI is changed, now both sliders will active for Keep Color and only first slider is active for Kill Color. Versions 1.2 Updated UI to select Color. Source Code: Kill Color Keeper.cs I personally call it 'Color keeper' but didn't wanted to leave word 'Kill', I choose one between these two candidates: "Keep Color Killer" and "Kill Color Keeper". I hope you all will find it useful. Download here: Download
  11. Change Extreme Colors From this to this What's this? I wanted a way to change the colors by selecting the extreme values (the darkest or the brightest). Here is the effect I just created for that. This plugin was made using CodeLab v3.2. Download it! Plugin ChangeExtremeColors.dll Here is the DLL http://jcljay.free.fr/pdn/ChangeExtremeColors.zip The MadJik's All plugins package is available! http://forums.getpaint.net/index.php?showtopic=7186 How to install Close Paint.net Classic version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: C:/Program Files/Paint.NET/Effects (please reverse / for correct path) Microsoft Store version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: My Documents/paint.net App Files/Effects (please reverse / for correct path) You have to adapt for your language My Documents How to use it This image is created to test the effect. I suggest you to copy and paste it in paint.net to run the plugin and get familiar with the settings. The sliders per channel define the range of colors to modify. And for each selected color you could increase/decrease with the amount for darkest or brightest. The range around 128 is just between darkest and brightest. Default values of the interface make no modification to the image. You have to change something. The User interface This plugin is added to the menu Effects, submenu Color. Limit for Red/Green/Blue Set the values per channel to define the range of colors to modify. Same values (Red) Checked by default. If checked the slider Red is used for all the sliders. Unchecked to be able to change Green and Blue. Dark Colors Checked by default. If checked the colors in the darkest range are modified. Dark adjustment Add/subtract the value to the colors in the darkest range are modified on each channel. Light Colors Checked by default. If checked the colors in the brightest range are modified. Light adjustment Add/subtract the value to the colors in the brightest range are modified on each channel. Average/Maximum of channels When “Same values” is checked the test of the color is made on the average of the channel or on the maximum value of each channel. Maximum is better for monochrome colors when one channel is 255 and others are 0. The Examples: Voilà! Enjoy! Let me see what you could do with it! update 2018-01-27 (thanks to @ReMake - Visual studio version - Linked sliders (instead greyed). - Translation to French and Russian
  12. Expand color What's this? This effect was a bonus in the bottom list of my pack of plugins. Now with the Russian version (thank you @ReMake) it is time to have its own post. This effect compare the colors of the canvas with the primary (PC) and the secondary (SC) colors. Based on the ratio of the gap the color will be replace either by PC, SC or unchanged. It could be useful to reduce the weight of the image (less colors) and to turn the image in bicolored picture. Just a tool for fun. Download it! Plugin ExpandColor.dll Here is the DLL http://jcljay.free.fr/pdn/ExpandColor.zip The MadJik's All plugins package is available! http://forums.getpaint.net/index.php?showtopic=7186 How to install Close Paint.net Classic version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: C:/Program Files/Paint.NET/Effects Microsoft Store version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: /My Documents/paint.net App Files/Effects/ You have to adapt for your language My Documents The User interface This plugin is added to the menu Effects, submenu Color. Tolerance mini/maxi Range between the source color must be to be replace. Check with primary/secondary color The source color is compared with PC, SC or both depending on these checkboxes. Invert changed colors The colors of replacement are PC and SC inverted. Apply on Color channel Unchecked color channel is preversed from any change. The Examples: Before (photo from my own stock) After Before After Voilà! Enjoy! Let me see what you could do with it!
  13. Recolor gray What's this? This is not a realistic recoloring black & white image! Just a tool for fun. This is a (re)color plugin to recolor grey, gray or any color with a formula. It uses the values of each channels of the source within a formula to transform into fully colored image. Download it! Plugin RecolorGray.dll Here is the DLL http://jcljay.free.fr/pdn/RecolorGray.zip The MadJik's All plugins package is available! http://forums.getpaint.net/index.php?showtopic=7186 How to install Close Paint.net Classic version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: C:/Program Files/Paint.NET/Effects Microsoft Store version of Paint.net Unzip and (re)place the DLL in your Effect folder usually: /My Documents/paint.net App Files/Effects/ You have to adapt for your language My Documents The User interface This plugin is added to the menu Effects, submenu Color. % Red/Green/Blue Tunable weight per channel in%: Angle This angle is used in the color calculation (not available in color mode 2 RGB). Color Mode The result of the formula serves as the base to determine the color. Four modes are possible: -Rainbow (Sinus) Color formula using Sinus calculation -RGB hexadecimal transformation to obtain R G and B channels. -Green-purple (Tang) Color formula using Tangent calculation (camaïeu of green and purple/rose) -Gray (Black, gray and white) The Examples: Before After Before After Before After Voilà! Enjoy! Let me see what you could do with it!
  14. This plugin is admittedly quite similar to TR's Custom Palette Matcher, but may be useful. It's in the Color menu. The Plugin: Recolor Using Palette.zip As the Help menu says: Recolor Using Palette replaces each pixel color with the nearest color from a specified range of the current palette. The Euclidean distance is used. This minimizes the sum of the squared differences of the red, green, and blue color components. The controls are: Starting Palette Index: The number of the first palette color to use. Palette colors are numbered from 1 to 96. Ending Palette Index: The number of the last palette color to use. Ignore Opacity When Comparing Colors: When this option is enabled, only the red, green, and blue color components are compared; the alpha value is ignored. The original alpha is preserved in the replaced color. When this option is disabled, the image and palette colors are adjusted to account for their alpha values before being compared. The distance between colors is the distance between the colors when blended with the background color that maximizes the distance. The original alpha is replaced by the alpha of the nearest palette color. Show Original Image: When enabled, the original, unmodified image is displayed. The UI: Instead of managing palettes like TR's effect, it relies on PDN's built-in palette handling, which I think is fairly easy to use. Recolor Using Palette allows a subrange of the current palette to be used. (Note the color-entry numbering is one-based, not zero-based.) On interesting (which is not necessarily the same as useful) feature is that it can take opacity into account when doing the comparison. When opacity is used in the comparison, the entire palette color, including alpha, replaces the image color; otherwise, the image alpha is preserved, and only the red, green, and blue are replaced. Here's a demonstration, using the default palette. Original image: With Ignore Opacity When Comparing Colors enabled: With Ignore Opacity When Comparing Colors disabled: (To be useful in this mode, the palette would likely need to be better suited to the image than it is in this case.) Ignore Opacity When Comparing Colors is disabled by default.
  15. The Color Clearer plugin makes pixels that match the selected color transparent, and modifies the transparency and color of the other pixels to maximize their transparency while still producing the original color when blended with the normal blending mode to a background set to the selected color. It some sense, it removes as much of the selected color as possible from each pixel. Here is the (still simple) user interface: The Make Transparent Pixels Transparent White check box specifies that transparent pixels will be set to transparent white, rather than have their colors remain unchanged. I was careful to try to make the blended image after Color Clearer exactly match the original blended image, even when the original pixels are partially transparent. I hope I succeeded. Interestingly (I think), all the math is done using integer arithmetic. I attempted to do the same thing in HSV Eraser, but I didn't take into account the precise way PDN alpha-blends layers, so there were many cases where the resultant blended pixels were off by one. Here's an example, using an image from a previous discussion. The original image is: After using the Color Picker to choose the red background color, then running Color Clearer, the result is: If the second image is placed on top of a layer filled with the background color, the merged layers match the original image. Here is the DLL: ColorClearer.zip Maximilian has a 3.5.11 version. Here is the CodeLab code: EDIT: As noted next to the DLL, I intend to modify the plugin to choose better replacement colors. The current values work, in that the produce the proper colors when blended with the background color, but they are sometimes somewhat illogical choices. EDIT 2: A new version. I changed the color used when a number of colors will produce the correct blended result. I now choose the color that's nearest to the original color. For consistency, I left completely transparent pixels unchanged (except for alpha), unless an option is selected to make them transparent white.
  16. This is a rather minor plugin, but it might be useful. It's in the Effects>Color menu. (It was developed for creating my SOTW fire image.) Quoting the Help menu: Hot Metal Glow converts each pixel's color value into a color intended to mimic incandescent heated metal. The colors go from black, to red, to orange, to yellow, and finally to white. The color transition is only approximate. No attempt is made to imitate actual physics. An input pixel's color value is simply the largest of its RGB components. Brighter pixels are considered to be hotter, unless the Invert Color Range option is selected. The controls are: Celsius Temperature at Zero Value is the temperature assigned to 0 value pixels. Celsius Temperature at Maximum Value is the temperature assigned to 255 value pixels. Incandescence Threshold Temperature is the temperature at which the pixel will begin to turn red. Red Temperature is the temperature at which the pixel will be full-intensity red. (The behavior is modified by Red to Orange Shift.) Yellow Temperature is the temperature at which the hue of the pixel will be yellow. White Temperature is the temperature at which the pixel will be white. Red to Orange Shift specifies the point at which red shifts towards orange as the intensity increases. When 0, the hue remains red until the red is full intensity. When 1, the hue immediately begins to shift towards orange. (This control is useful for producing fire colors.) Orange Desaturation specifies the point at which orange will be desaturated. When 0, orange and yellow are fully saturated. When 1, orange begins to be desaturated at the Red Temperature. Invert Color Range specifies that the range of color values should be inverted, so black pixels are hottest. The Threshold, Red, Yellow, and White Temperature values must be in increasing order. If not, the values are clamped to force the order to increase, but the resulting colors are not likely to be useful. The user interface looks like this: Here is the DLL: HotMetalGlow.zip There's also 3.5.11 version, courtesy of Maximilian. Here is the CodeLab code: Hidden Content: // Name: Hot Metal Glow // Submenu: Color // Author: MJW // Title: Hot Metal Glow // Version: 1.2.* // Desc: Convert pixel color values into incandescence colors // Keywords: incandescence colors // URL: http://forums.getpaint.net/index?/topic/108875-hot-metal-glow/ // Help: #region UICode IntSliderControl Amount1 = 500; // [0,1400] Celsius Temperature at Zero Value IntSliderControl Amount2 = 1315; // [0,1400] Celsius Temperature at Maximum Value IntSliderControl Amount3 = 425; // [0,1400] Incandescence Threshold Temperature IntSliderControl Amount4 = 825; // [0,1400] Red Temperature IntSliderControl Amount5 = 1175; // [0,1400] Yellow Temperature IntSliderControl Amount6 = 1315; // [0,1400] White Temperature DoubleSliderControl Amount7 = 0.0; // [0,1] Red to Orange Shift DoubleSliderControl Amount8 = 0; // [0,1] Yellow Desaturation CheckboxControl Amount9 = false; // [0,1] Invert Color Range #endregion // This could be done with a 255 entry color table, but it doesn't work especially // well for CodeLab. int cMask; void Render(Surface dst, Surface src, Rectangle rect) { int minTemp = Amount1; int maxTemp = Amount2; if (minTemp >= maxTemp) maxTemp = minTemp + 1; int minRedTemp = Amount3; int redTemp = Math.Max(Amount4, minRedTemp+ 1); int yellowTemp = Math.Max(Amount5, redTemp + 1); int whiteTemp = Math.Max(Amount6, yellowTemp + 1); double redOrangeShift = Amount7; double yellowDesat = Amount8; double colorScale = 255.0 / (double)(maxTemp - minTemp); // (The "min" values are where the value is zero, but will change to non-zero.) int minRed = (int)(colorScale * (double)(minRedTemp - minTemp) + 0.5); int fullRed = (int)(colorScale * (double)(redTemp - minTemp) + 0.5); int minGreen = (int)(fullRed + redOrangeShift * (minRed - fullRed) + 0.5); double fullGreen = Math.Round(colorScale * (double)(yellowTemp - minTemp)); int minBlue = (int)(fullGreen + yellowDesat * (fullRed - fullGreen) + 0.5); int fullBlue = (int)(colorScale * (double)(whiteTemp - minTemp) + 0.5); double scaleRed = 255.0 / (double)(fullRed - minRed); double scaleGreen = 255.0 / (double)(fullGreen - minGreen); double scaleBlue = 255.0 / (double)(fullBlue- minBlue); cMask = Amount9 ? 255 : 0; // Optionally invert tohe color range for (int y = rect.Top; y < rect.Bottom; y++) { if (IsCancelRequested) return; for (int x = rect.Left; x < rect.Right; x++) { // Get the value, which is just the maximum RGB value. int value = ColorValue(src[x, y]); byte r = 0, g = 0, b = 0; if (value > minRed) { r = (byte)Math.Min(scaleRed * (double)(value - minRed) + 0.5, 255); } if (value > minGreen) { g = (byte)Math.Min(scaleGreen * (double)(value - minGreen) + 0.5, 255); } if (value > minBlue) { b = (byte)Math.Min(scaleBlue * (double)(value - minBlue) + 0.5, 255); } dst[x, y] = ColorBgra.FromBgra(b, g, r, src[x, y].A); } } } int ColorValue(ColorBgra color) { return Math.Max(Math.Max(cMask ^ color.R, cMask ^ color.G), cMask ^ color.; } EDIT: Added Desaturate Yellow feature. I noticed in many examples of hot metal, the yellow was never fully saturated. EDIT 2: Fixed Help Menu to match UI. Control is called "Yellow Desaturation" not "Desaturate Yellow." EDIT 3: Added Red to Orange Shift feature. EDIT 4: In plugin, renamed Yellow Desaturation to Orange Desaturation. (Man, do I get tired of all the updates I have to make each time I change the interface!)
  17. This plugin can be useful for selecting objects in the image or for creation a color mask of object. The plugin is based on the script of Color Target plugin by rwp80. You can find it: Effects -> Color -> Color Range Previous downloads - 1605 ColorRange.zip This effect allows you to create a color mask of object in the image. You can then select the object using Magic Wand ( ) for further work with him. See short tutorial and examples of effect's work in the Color Range Test topic. CodeLab script: and icon: Examples of effect's technique you can found in How To Use Color Range effect topic. Примеры работы эффекта и приемы работы с ним вы можете посмотреть в уроке Как использовать эффект 'Цветовой диапазон'.
  18. This is very simple effect which allows to eliminate dark or light areas of the image. Good deletes black or white color (as a special case of dark or light, respectively). The effect has a very simple interface. You can find it under Effects-> Color-> Eliminate Dark/Light. EliminateDarkLight.zip Original image: Eliminate dark areas: Eliminate light areas: Below the sourse code for CodeLab. This is аn icon for the effect: P.S. I decided to start a new topic, because the former name of the topic Eliminate Black/Eliminate White was wrong.
  19. TechnoRobbo's Intense Filtration v 1.3 PDN 3.5 compatible Based on a Topic conversation about Hue It's not a hue adjustment it's a color filter and augmenter v1.3 has an anti-clipping algorithm Menu: Effects->Color Demo Video CodeLab Source Code Hidden Content: // Submenu: Color // Name: TR's Intense Filtration // Title: TR's Intense Filtration- v1.3 // Author: TechnoRobbo // URL: http://www.technorobbo.com #region UICode int Amount1 = 4700; // [0,5999] Hue double Amount2 = .90; // [0,2] Gain int Amount3 = 0; // [0,2000] Filter Intensity byte Amount4 = 0; // [1] Fade To -|Base Image|B&W|Hue #endregion void Render(Surface dst, Surface src, Rectangle rect) { // Delete any of these lines you don't need Rectangle selection = EnvironmentParameters.GetSelection(src.Bounds).GetBoundsInt(); int CenterX = ((selection.Right - selection.Left) / 2)+selection.Left; int CenterY = ((selection.Bottom - selection.Top) / 2)+selection.Top; ColorBgra PrimaryColor = (ColorBgra)EnvironmentParameters.PrimaryColor; ColorBgra SecondaryColor = (ColorBgra)EnvironmentParameters.SecondaryColor; int BrushWidth = (int)EnvironmentParameters.BrushWidth; float[,] hues = {{1,0,0,1,1,0}, {1,1,0,0,1,0}, {0,1,0,0,1,1}, {0,1,1,0,0,1}, {0,0,1,1,0,1}, {1,0,1,1,0,0}}; ColorBgra CP; for (int y = rect.Top; y < rect.Bottom; y++) { if (IsCancelRequested) return; for (int x = rect.Left; x < rect.Right; x++) { float coeff = (float)Amount2; float mix =1f - (float)Amount3 / 2000f ; //hues int hueIdx= Amount1/1000; float hueshift = (float)(Amount1 % 1000)/1000f; float r,g,b; r = hues[hueIdx ,3] * hueshift + hues[hueIdx,0] - hues[hueIdx,0] * hueshift ; g = hues[hueIdx ,4 ] * hueshift + hues[hueIdx ,1] - hues[hueIdx ,1] * hueshift ; b = hues[hueIdx ,5] * hueshift + hues[hueIdx , 2] - hues[hueIdx , 2] * hueshift ; CP = src[x,y]; //hue filtration * gain float tmpr = (float)CP.R * coeff * r; tmpr = (tmpr > 255) ? 255: tmpr; float tmpg = (float)CP.G * coeff * g; tmpg = (tmpg>255) ? 255: tmpg; float tmpb = (float)CP.B * coeff * b; tmpb = (tmpb>255) ? 255: tmpb; //grayscale float gray = (float)(CP.R + CP.G + CP.B)/3f * coeff ; gray = (gray >255) ? 255: gray ; //base image * gain float thresh = (coeff>1) ? 128: 255 ; float himax = 255f * coeff - thresh ; float CPR = (float)CP.R * coeff; CPR = (CPR >thresh ) ? (CPR - thresh ) * (255-thresh) /himax + thresh : CPR; float CPG = (float)CP.G * coeff; CPG = (CPG >thresh ) ? (CPG - thresh ) * (255-thresh)/himax + thresh : CPG; float CPB = (float)CP.B * coeff; CPB = (CPR >thresh ) ? (CPB - thresh ) * (255-thresh)/himax + thresh : CPB; //gray * gain float graymix = gray/255f; float gr = r * graymix * 255 * coeff ; gr = (gr >255) ? 255: gr ; float gg = g * graymix * 255 * coeff ; gg = (gg >255) ? 255: gg ; float gb = b * graymix * 255 * coeff ; gb = (gb >255)? 255: gb ; if (Amount4==0) { tmpr = CPR * mix + tmpr - tmpr * mix; tmpg = CPG * mix + tmpg - tmpg * mix; tmpb = CPB * mix + tmpb - tmpb * mix; }else if (Amount4==1){ tmpr = gray * mix + tmpr - tmpr * mix; tmpg = gray * mix + tmpg - tmpg * mix; tmpb = gray * mix + tmpb - tmpb * mix; }else if (Amount4==2){ tmpr = gr * mix + tmpr - tmpr * mix; tmpg = gg * mix + tmpg - tmpg * mix; tmpb = gb * mix + tmpb - tmpb * mix; } CP .R = (byte)tmpr; CP .G = (byte)tmpg; CP .B = (byte)tmpb; CP.A = (byte)CP.A; dst[x,y] = CP; } } } TRsIntenseFilteration.zip
  20. TechnoRobbo's Color Reducer (and palette maker) v1.0.2 Scale down the color count in your image. Greatly reduce file sizes. Use the selection to limit the area modified, If reduced to less than 1000 Colors you can edit the color table. If 96 colors or less you can save a Custom Palette!!! Menu: Effect -> Color version 1.02 small UI fix version 1.01 includes brightness control and preview for Plugin Browser Plugin was originally written to reduce the size of the help file in The Plugin Browser. The Plugin TRsColorReducer.zip The VS Source Code for Programmers https://www.dropbox.com/s/rnhhfatjqgvoepk/TRsColorReducerSrc.zip?dl=0
  21. TechnoRobbo's HDR-ish HDR style results - smooths out the transitions between light and dark. makes a dull picture less dull PDN 3.5 compatible (updated) Menu: Effects->Colors The Codelab Code Hidden Content: // Submenu: Color // Name: TR's HDR-ish // Title: TR's HDR-ish- v1.0 // Author: TechnoRobbo // URL: http://www.technorobbo #region UICode int Amount1 = 2; // [1,5] Intensity double Amount2 = 0; // [0,20] High Limit #endregion void Render(Surface dst, Surface src, Rectangle rect) { ColorBgra CP; int tmp =0; for (int y = rect.Top; y < rect.Bottom; y++) { for (int x = rect.Left; x < rect.Right; x++) { double accum = 0; double divider = 0; for (int i = 1 - Amount1 ;i <Amount1; i++) { for (int j = 1 - Amount1 ;j <Amount1; j++) { CP = src.GetBilinearSampleClamped(x + j,y + i); HsvColor hsv = HsvColor.FromColor(CP.ToColor()); accum += hsv.Value; divider++; } } CP = src[x,y]; HsvColor hsv2 = HsvColor.FromColor(CP.ToColor()); divider += Amount2; divider = (divider <= 1) ? 1 : divider; double newV = accum / divider; newV -= (1-hsv2.Value); newV = (newV < 0) ? 0 : (newV > 100) ? 100: newV; hsv2 = new HsvColor(hsv2.Hue,hsv2.Saturation,(int)newV); ColorBgra NP = ColorBgra.FromColor(hsv2.ToColor()); dst[x,y] = NP; } } } TRsHDRish.zip
  22. TechnoRobbo's Custom Palette Matcher v1.0.5 Conforms your image colors to your custom palette by finding the nearest color match. Version 1.0.5 Fixes Crash When No Palette Directory Exists Version 1.0.4 Browser system lets you sample palettes quickly. Version 1.03 add instant preview and interpolate option Update Version 1.0.2 Shows Transparency correctly in Palette Preview. Update Version 1.0.1 Allows manually created palettes(with errors) to be parsed and used. Manually created palettes should be loaded into PDN then saved again to correct the format. TR's Custom Palette Matcher will warn you of a bad palette but will try it's best to uses what it's given.. Menu: Effects->Color Video includes palettes posted by artists on this forum topic http://forums.getpaint.net/index.php?/topic/2947-color-palettes-go-here/?p=22185 Video Tutorial : New Browser The VS Source Code The Plugin TRsCustomPaletteMatch.zip
  23. TechnoRobbo's Contour Filler V1.5.2 A gradient fill plugin that follows the contour of the Alpha Channel Make sure to deselect before using. Larger images take longer to render. Choose from smooth (zero slices) and stepped gradient Version 1.5.2 minor code cleanup Version 1.5.1 My apologies uploaded wrong version Version 1.5 has a smoothing component and new high speed code. Version 1.1 Updated for Paint.net 4.0 Menu: Effects -> Color Text Demo Quick Example on you Tube music by TechnoRobbo CHAPLIN Bogey1 https://www.dropbox.com/s/ioixkivgokaox9s/Bogart.png?raw=1 The VS Source Code The Plug-In TRsContourFiller.zip
  24. TR's B&W Photo Back in the day B&W Photographers used Color Filters to reinterpret the way color became greyscale. Photographers like Ansel Adams shooting with huge accordian View Cameras used high F-Stops which produced realy cool hotspots in the center of the B&W Image. (Ansel Adams was also quite partial to using red and yellow filters to darken the sky). This plugin simulates the use of color filters and hot spots in B&W photography. Menu: Effect->Color Demo Video Filter Examples untouched Original B&W with Red Filter w/hotspot The Code // Submenu: Color // Name: TR's B&W Photo // Title: TR's B&W Photo - v1.0 // Author: TechnoRobbo // URL: http://www.technorobbo #region UICode byte Amount1 = 0; // [1] Color Filters|Red Filter|Green Filter|Blue Filter|Cyan Filter|Magenta|Yellow Filter double Amount2 = 0.75; // [0,1] Hot Spot Effect #endregion void Render(Surface dst, Surface src, Rectangle rect) { Rectangle selection = EnvironmentParameters.GetSelection(src.Bounds).GetBoundsInt(); int CenterX = ((selection.Right - selection.Left) / 2)+selection.Left; int CenterY = ((selection.Bottom - selection.Top) / 2)+selection.Top; double maxrad = Math.Sqrt(CenterX * CenterX + CenterY * CenterY); ColorBgra CP; for (int y = rect.Top; y < rect.Bottom; y++) { for (int x = rect.Left; x < rect.Right; x++) { double fade = Math.Sqrt((x-CenterX) * (x-CenterX) + (y-CenterY) * (y-CenterY))/ maxrad; fade *=fade; fade = (1-fade) * Amount2 + 1 - Amount2; CP = src[x,y]; switch (Amount1){ case 0: CP.G= CP.R; break; case 1: CP.R=CP.G; break; case 2: CP.R=CP.B; break; case 3: CP.R= Int32Util.ClampToByte((CP.B + CP.G)/2); break; case 4: CP.R=Int32Util.ClampToByte((CP.R + CP.B)/2); break; case 5: CP.R=Int32Util.ClampToByte((CP.R + CP.G)/2); break; } byte newbyte = Int32Util.ClampToByte((int)(fade * (double)CP.R)); CP.R = newbyte; CP.G =newbyte ; CP.B = newbyte ; CP.A = CP.A; dst[x,y] = CP; } } } TRsBWPhoto.zip
  25. Pseudo Greyscale from Pseudo-Random Noise. The plugin takes your color image and de-saturates it by shifting the pixel colors randomly. I included a Span and Offset control to adjust the hue and intensity of the de-saturation, Sorry no video instructions - this ones too easy to use. Under the Effects->Color->Noise Bleacher Bug Fix Version 1,1 Span Zero crash fixed. 1:27 AM Tuesday, June 11, 2013 (UTC) Interesting when zoomed: The Code: Hidden Content: // Submenu: Color // Name: Noise Bleacher // Title: Noise Bleacher - v1.1 // Author: TechnoRobbo // URL: http://www.technorobbo #region UICode int Amount1 = 1; // [1,360] Span int Amount2 = 0; // [0,180] Offset #endregion void Render(Surface dst, Surface src, Rectangle rect) { Random rndm = new Random((int)Guid.NewGuid().GetHashCode()); ColorBgra CP; int tmp =0; for (int y = rect.Top; y < rect.Bottom; y++) { for (int x = rect.Left; x < rect.Right; x++) { CP = src[x,y]; tmp= rndm.Next() % Amount1; HsvColor hsv = HsvColor.FromColor(CP.ToColor()); int H = (hsv.Hue + tmp + Amount2) % 360; int S = hsv.Saturation; int V = hsv.Value; hsv = new HsvColor(H,S,V); ColorBgra NP = ColorBgra.FromColor(hsv.ToColor()); NP.A = CP.A; dst[x,y] = NP; } } } NoiseBleach.zip