Jump to content

MJW

Members
  • Content Count

    2,221
  • Joined

  • Last visited

  • Days Won

    50

Everything posted by MJW

  1. I believe offsetting is possible. Whether it will work exactly as you wish is hard to say. The part I was having difficulty with is using the edge transparency of antialiased objects to adjust the distance in a way that reduces jagginess. It could be that when I take a fresh look at it, a solution will be clear. That sometimes happens.
  2. Sorry about the long, long delay. I will get back on it. I really wanted to add the type of smoothing Red Ochre referred to here: I tried a number of approaches, but so far haven't found anything satisfactory. As I unfortunately sometimes do in that situation, I sort of put it aside in frustration, and worked on other things. If I can't come up with a solution to that problem soon, I'll release a version without it, then try to solve the smoothing problem, so I can release an update with it.
  3. That seems like a pretty significant detail. What are the PNG settings when you save the file in Paint.NET? The settings are displayed in a dialog titled "Save Configuration" (or the German equivalent) just before the image is saved
  4. I should have said that you need to clear the array when you don't allocate it. Otherwise it will have the left-over image from the previous time. if (Popcorn_Array == null) Popcorn_Array = new int [w,h]; else Array.Clear(Popcorn_Array, 0, w*h);
  5. I suggest you change Popcorn_Array = new int [w,h]; to if (Popcorn_Array == null) Popcorn_Array = new int [w,h]; I don't see any reason for reallocating the array each time a control is changed. Though it probably wont have major consequences performance-wise, it does force more garbage collection.
  6. I'm not sure why that would be, unless it's a limitation in the CodeLab UI designer. My Texture Merger plugin has quite a few more controls than than the 16 or so in your plugin
  7. I obviously didn't look at the code as closely as @toe_head2001 did. He's correct. The reason it's slow is that you're redoing a lot of once-per-frame stuff for each ROI. PreRender will fix that.
  8. Using a switch statement is certainly a respectable way to do it; though it would probably be somewhat more efficiently done with delegates. I see from the code that func_x1, etc., are selected by the UI, so having them be delegates, external to Render() should pose no problem. As a very minor detail, I'd write the switch statement as: double func_v(double v,int c){ switch(c){ case 0: return Math.Sin(v); case 1: return Math.Cos(v); case 2: return Math.Tan(v); default: return Math.Atan(v); } } That seems a little clearer to me.
  9. It appears to me that what you want may be delegates. Delegates are more or less what in C and C++ would be called function pointers. Certainly for func_a and func_b you need to use delegates. What's being done there, assigning the various trig functions to func_a, is exactly what delegates do. You'd define a delegate with one double argument, returning a double, then assign the trig functions to it. I'll try to explain in more detail when I have time later. EDIT: Removed stuff about lambda expressions, which I think may not be necessary. I think delegates
  10. I made a small change. I increased the Offset precision to 4 decimal places. It was 3. I wasn't sure 3 would be enough in some situations. The version is now 1.1.0. (My version number system is basically that the first number changes for a large revision, with a major change in functionality. The second number changes for more modest changes in functionality, or if the user interface changes. The third number changes for bug fixes and for minor revisions of the Help menu.)
  11. Mise En Abyme creates a recursive picture-within-a-picture, like on the Quaker Oats box, often also referred to as the Droste effect. The plugin DLL (versions 1.1.0, 24 Oct 2020): Mise En Abyme_1.1.0.zip The region in which the canvas image is copied is determined by the selection. The plugin is in the Selection (not the Distort) menu for two reasons. First it requires a selection; second, the Distort menu is getting quite crowded -- at least mine is. The Help Menu: Mise En Abyme recursively copies the canvas image into a selection to achie
  12. My most sincere thanks to @Pixey!
  13. You may perhaps wince at the suggestion, but there is CodeLab. If you haven't programmed before, it can be intimidating, but with it you can quite easily accomplish what would otherwise be impossible.
  14. Many thanks to whoever is responsible for updating the SOTW Past Themes list. It occurred to me that it'd been ages since I updated it, but when I went to do so, I was very surprised and pleased to see it was current.
  15. Not certain what "select area with S means," but in any event, I've never seen a white edge after deleting something, so unless you can explain the steps to reproduce the problem, you're unlikely to get an useful response. Frankly, the terseness of your response struck me as suggesting you were offended that I asked for more details. Perhaps it wasn't meant that way.
  16. Not quite clear to me. By "remove" do you mean make them invisible, or do you mean change the number of nodes? If you mean change the number of nodes, I don't think that can happen unless the the Line/Cure Tool is rewritten, which would, I expect, be a major change -- which is to say, probably a difficult change. The Line/Curve Tool currently produces cubic curves, which by their nature have four nodes. EDIT: Though I probably should avoid offering opinions on things I only vaguely understand, I'll do so anyway. GDI+ can draw splines with an arbitrary number of nodes, which seems l
  17. I'm not clear on what you mean. What were the operations you used to cut the edges? Was the image originally PNG, or was it some other format? Was it saved directly as a PNG (with the white edges), or was it saved in some other format, then reloaded and combined to form the image saved as a PNG? Finally, what is a "restrained area"? I'm not familiar with that term.
  18. Are you sure the right layer is active? Usually when something like that happens to me, it's because the thing I want to delete isn't in the active layer.
  19. I find Auto Level woks best when combined with UnDo. (Which is to say, I don't recall any time when it's changed an image in a desirable way.)
  20. That might be advisable, but I just mean the second comment.
  21. I''m releasing version 2.0.1, which (I hope) fixes a problem with the centering of the pasted image in the canvas or selection. In some cases it was about half a pixel off.
  22. I think it might be better if the selection tools followed the "Finish" model of the some other tools, such as Shape. What I propose is that instead of being different selection modes, such as Replace, Union, etc., there would be different ways of finishing the selection. When the selection was made, it would be separate from the existing selection, and would be editable, as if in the Move Selection tool. To finish the selection and merge it with the current selection, the user would click one of the Finish buttons, which would consist of the usual merge choices of Replace, Union,
  23. That's sort of what I would have thought, but it doesn't seem to fit with the following sentence. I'd guess if it's anything like your hypothesis, the individual images are separated by a constant-color or transparent background. In any event, I think it's the responsibility of the one asking the question to explain the situation clearly. However, in the case where a number of separate images are on a transparent background, I will offer a procedure of selecting one of them. - With a Selection Mode of Replace, use the Magic Wand with a low toleran
×
×
  • Create New...