Jump to content

Reptillian

Members
  • Posts

    908
  • Joined

  • Last visited

  • Days Won

    10

Everything posted by Reptillian

  1. Other than the Lyapunov, I had fixed the Random Gradient Bars, it is now more controllable there. But, this isn't noteworthy here because I had created the CodeLab version of the filter. So, I will show that I made another coloring mode to Lyapunov Fractal. Here's what is missing with the Lyapunov Fracta. 1) Custom coloring support. That means 2 more modes are TODO. One mode for defining colorings of negative/positive, and the other is a map toward the ranges of the Lyapunov Fractal. 2) Grayscale Mode. This means that it'll be the default output or negative output.
  2. New update! Now featuring anti-aliasing! Lower the sublevel for preview, and increase it in the final product.
  3. @Pixey , and @lynxster4 : Thank you for the feedback! Also, I edited first post. The reseed button on the first GUI element does not work until after you press it twice. I think you both already noticed that.
  4. Generates random gradient bars onto the canvas. It can be seen as a upgrade of Gradient Bars made by @pyrochild though the code for both are very much different. Random Gradient Bars plugin offers being able to define multiple color modes, symmetry, origin, randomized inversion, differing random modes. This is very near completely identical port of the gmic version. Plugin Download -> Random Gradient Bars.zip After installation, you will see Random Gradient Bars under Effects->Render. Note: Reseed Button does not work until after you press it twice. I don't know how to fix that bug or even if it is fixable. Preview of output: - Source Codes - License: CeCILL v2.0 - http://cecill.info/licences/Licence_CeCILL_V2-en.html C# Codelab G'MIC-QT
  5. As soon as I have figured out how to work with HSV in content of PDN C# development, I was able to almost complete the plugin. For now, I am releasing as a test plugin, and there is only one more thing to complete functionality-wise (No, I won't bother getting the plugin to automatically disable colors on circumstances), and that is getting the seed to work. I don't know how to fix that. Here's the current build of the Random Gradient Bars plugin. Let me know if there is any bugs outside of those two I mentioned. Random Gradient Bars.zip Source Code:
  6. Made random color mode #1. Random color mode #2 will come next.
  7. Here's the codelab code for starters. You can use 1/zoom instead for zoom out. #region UICode DoubleSliderControl zoom = 4; // [1,10] Zoom Level #endregion void Render(Surface dst, Surface src, Rectangle rect) { // Delete any of these lines you don't need Rectangle selection = EnvironmentParameters.SelectionBounds; double cx = (src.Width - 1) / 2; double cy = (src.Height - 1) / 2; double ix,iy,nx,ny,tx,ty; int fx,fy; for (int y = rect.Top; y < rect.Bottom; y++) { if (IsCancelRequested) return; for (int x = rect.Left; x < rect.Right; x++) { ix=(double)(x)-cx; iy=(double)(y)-cy; nx=ix*zoom; ny=iy*zoom; tx=nx-ix; ty=ny-iy; fx=Math.Min(Math.Max(x+(int)(tx),0),src.Width - 1 ); fy=Math.Min(Math.Max(y+(int)(ty),0),src.Height - 1 ); dst[x,y] = src[fx,fy]; } } }
  8. No, I won't do these, it would take a different method to support these features. Particularly, a interactive filter, and that's way too much work. Here, I did it for gmic. One can tell how the source code works easily. - https://github.com/dtschump/gmic-community/commit/9bc859ffe83cb73de0c4a0f9ff3505d4705fe089
  9. I think what @Cioss is to use pixel size instead of divisions by canvas. I made a quick code to do what @Cioss wants. Though, I'm not sure if @Cioss would be ok with installing extra dependency for g'mic-pdn plugins or g'mic. I don't know how to do pure c# version. So, my question to the OP: Is the below picture is what you're looking for. 24,24 are inputs, and they're based in px rather than division. Input: gmic sp cat +rep_jumble_by_px 24,24 Output:
  10. Just leaving this here - More work in Lyapunov.
  11. I think it is spam. Nothing seem to be about trying to stimulate Diamond Painting in Paint.NET.
  12. Paint.NET may be the name of the program, but it isn't specifically for diamond painting. However, it is possible to make a plugin to stimulate the aesthetics of it.
  13. Someone requested that I release Dungeon Tiles filter. I released it. Here's the preview:
  14. G'MIC - > Testing -> Reptorian -> Transfer Colors [Reduced Colors] Never mind, it doesn't do self-color reduction. I could however make a g'mic filter that does that.
  15. Strange color with the original code. Change color_space into 1, and you'll see what I mean. I'm not getting the desired result with this. dst[x,y]=ColorBgra.FromBgr( (byte)((int)(lerp((double)(sc_a_B),(double)(sc_b_B),final_gradient))), (byte)((int)(lerp((double)(sc_a_G),(double)(sc_b_G),final_gradient))), (byte)((int)(lerp((double)(sc_a_R),(double)(sc_b_R),final_gradient))) ); There is suppose to be a transition. There is not a transition. This code does work better than the first one, however, see what I mean? : EDIT : I solve it. lerp formula was wrong. So sorry about that. This is the fix. double lerp(double a, double b, double t){ return a * (1 - t) + b * t ; }
  16. This is more of a continuation of the other thread as that problem has been solved. This is the complete line of code that is giving me a problem dst[x,y]=ColorBgra.FromBgra((byte)(lerp((double)(space_color_a.B),(double)(space_color_b.B),final_gradient)),(byte)(lerp((double)(space_color_a.G),(double)(space_color_b.G),final_gradient)),(byte)(lerp((double)(space_color_a.R),(double)(space_color_b.R),final_gradient)),(byte)(spaces ? 255 : 0)); What I"m trying to achieve is a colored gradient effect depending on final_gradient. Also, HsvColor.ToRgb() would the correct route for converting HSV (The code has random Hue as option)? There's also the observation that reseed does nothing, but that's for another day.
  17. I had released several gmic-c# projects here in the plugin section. Search Author:Reptillian in plugin index, and you'll see my released gmic c# projects. Which one are you looking for?
  18. @toe_head2001 @MJW Thank you both for your help and insight, I just finally got a working code. Not working like I wanted to, but needs tweaks.
  19. I know that line is questionable. It is positive only in context of gmic which internal is c++. -1 should be the end of index rather than less than 0. -1 % 3 = 2 basically. So, my solution is to create my own function to get around this problem? Ok, I think I will do that.
  20. Well, there seem to be a error after fixing that. System.IndexOutOfRangeException: Index was outside the bounds of the array. at PaintDotNet.Effects.UserScript.Render(Surface dst, Surface src, Rectangle rect) at PaintDotNet.Effects.UserScript.Render(EffectConfigToken parameters, RenderArgs dstArgs, RenderArgs srcArgs, Rectangle[] rois, Int32 startIndex, Int32 length) at PaintDotNet.Effects.CodeLab.Render(EffectConfigToken parameters, RenderArgs dstArgs, RenderArgs srcArgs, Rectangle[] rois, Int32 startIndex, Int32 length) Seem to be within Render though bar should always be within the index ranges. After that I think the random gradient will appear.
  21. @toe_head2001 After doing that, it creates this error. 'int' does not contain a definition for 'Max' Never mind, the fix is MaxValue.
  22. Ok, looks like I'm near completion. Problem: System.NullReferenceException: Object reference not set to an instance of an object. at PaintDotNet.Effects.UserScript.PreRender(Surface dst, Surface src) at PaintDotNet.Effects.UserScript.OnSetRenderInfo(EffectConfigToken token, RenderArgs dstArgs, RenderArgs srcArgs) at PaintDotNet.Effects.CodeLab.OnSetRenderInfo(EffectConfigToken parameters, RenderArgs dstArgs, RenderArgs srcArgs)
  23. How did you get the value of number_of_bars? The formula should be const number_of_bars=((trimmed_ang>=cut_ang)&&(trimmed_ang<cut_ang2))?ceil((abs(1/sin(ang))*ww)/total_width):ceil((abs(1/cos(ang))*hh)/total_width); And that doesn't lead -214758.... There must be something I did wrong. EDIT: Ah, yes, the stupid divide by 0 error. I just fixed it by adding min of bar size to 1.
×
×
  • Create New...