Jump to content

MJW

Members
  • Posts

    2,856
  • Joined

  • Last visited

  • Days Won

    70

Everything posted by MJW

  1. I know this is a naive question, but is OnSetRenderInfo part of the UI thread?
  2. I know that, but wasn't considering calling the clipboard routines from the Render routine. My comment referred to toe_head2001's example where it's called at the end of OnRender.
  3. I thought the trick is that instead of directly calling the clipboard routine, the OnRender thread starts a STA thread that does the actual clipboard calls, then waits for it to complete. I think that's what toe_head2001 had in mind..
  4. I hadn't considered using SingleThreaded (which I tend to forget about). Is the advantage of running single threaded over doing the computations in OnSetRenderInfo, that the progress indicator will be updated correctly? I have no idea how that works. What updates the progress bar, anyway? How do it know? EDIT: I think that before doing the final operation, IsCancelRequeted should be checked to make sure the operation wasn't aborted.
  5. At the risk of showing how little I know about PDN's multithreading, I was under the impression that the OnRender routine was run separately on multiple threads, so that the completion of the loop could occur multiple times for a frame.
  6. Let me explain more what I have in mind, just to make sure Rick Brewster considers it kosher. I don't want to create a plugin that can't be distributed. What I intend to do is write a plugin that takes the selected image, transforms it into an image of a different size, and places that image in the clipboard. Then the user would use Paste into New Image to create the transformed image. The original image would be unchanged.
  7. I have another question which is more pertinent. Suppose I want to save the destination image in the clipboard -- which, in fact, I do. The obvious solution is to do all the rendering in OnSetRenderInfo, then copy it to the clipboard when finished. Is there any way to let the normal render loops run, then when they're complete with the entire image, have some routine copy the result to the clipboard. I don't know of a way to recognize that the complete image has been successfully rendered, and I think I'd know it there were, but hope springs eternal.
  8. Though for the particular use I have in mind, preserving transparency isn't necessary, I do have a couple of questions in that regard: 1) Is it possible to preserve transparency? 2) (Mostly out of curiosity) What is it about the given code that prevents it from preserving transparency?
  9. Thank you, null54! I won't neglect the error handling, Rick.
  10. I hope that's not the standard format. All that shading may make for an attractive image, but it's not ideal for automatic processing. It would take a colorimeter to distinguish between Orange and Dark Orange. EDIT: Because of the way it's shaded, sampling the Dark Orange bead image at multiple locations with the Color Picker never resulted in the actual color, FF8C00.
  11. We all know how to copy an image from the clipboard in a plugin (swipe the CodeLab clipboard code), but is it possible for a plugin to copy an image to the clipboard? If so, I would very much appreciate any information on how to do it.
  12. @LionsDragon, what is the usual format for the grided design the plugin would process to create a numbered grid? Is it one pixel per bead/stitch/etc., or is it a graph consisting of multiple-pixel colored squares?
  13. Thanks for the input, @LionsDragon. One thing I don't want to do is spend time writing a plugin that's not useful. I welcome other responses from LionsDragon on anyone else on what features would be needed to make a numbering plugin useful. BTW, what does it mean to "graph out" something? I know nothing about crocheting. EDIT: I did a web search for " Crocheted Coral Reef ." Very impresive, but far beyond anything I'd endeavor to support with a PDN plugin.
  14. Perhaps I should mention that any solution I come up with will be limited to 96 colors, which is the number of colors in the PDN palette. I somewhat expect that most art or craft projects use fewer than 96 different colors.
  15. Someone else requested this a while ago. Unfortunately, I don't believe there's currently anything in Paint.Net to do that. I think it would be an interesting plugin to write. I've got a backlog of ideas I'm working on, so I can't guarantee anything, but if I can find the time, I'll try to come up with something.
  16. Thank you! The Texture Merger should help in combining shapes. The usual method is to use the Maximum merge mode. Make sure to set the Merged Height Alpha Source to Composite Alpha, so both height maps are visible.
  17. The example should make it clearer. As additional explanation, I added: "For the most common case of an object that's symmetric about the vertical axis, it produces a height map for the object of rotation. For example, it will convert a filled circle to a spherical height map, and a filled rectangle to a cylindrical height map."
  18. Texture Object Rounder converts objects to rounded height maps. It's in the Height Map subfolder. For the most common case of an object that's symmetric about the vertical axis, it produces a height map for the object of rotation. For example, it will convert a filled circle to a spherical height map, a filled isosceles triangle to a conical height map, and a filled rectangle to a cylindrical height map. The plugin (Version. 1.0.6464.41586): Texture Object Rounder.zip The Help Menu description: The UI: An example: Original object: The height map: The shaded height map: ----------------------------------------------------------------------------------------- The initial version is imperfect. The height maps produced are sometimes quite ridgy when shaded. The ridges result from errors in computing the outer silhouette of the object. To produce a smooth height map, the object's edge must be determined with subpixel accuracy. This is accomplished by using the alpha values of the edge pixels. My current algorithm isn't as accurate as I would like. I have some ideas to improve it, but they're somewhat complex. I decided to release the current version, as is. I hope to provide a better version in not too long. The Texture Smoother may help smooth the ridges. The objects to be rounded are normally produced using the Shape and Line/Curve tools. For example, you can draw a shape with the Line/Curve tool, duplicate the layer, horizontally reflect the layer, merge the layers, then fill with the Paint Bucket. Fill with care so that all the interior pixels are filled. A well-antialised edge is necessary for a smooth texture.
  19. I suggest looking through the tutorials to find ones that do the type of things you're interested in doing. You can then download the plugins those tutorials use. For certain type of objects, my height map plugins, such as the Texture Shader and Texture Merger, are useful, but generally not so much for things like people and trees. Maybe try the Brush Factory, since that sort of thing pretty much has to be done by hand painting.
  20. I probably should have assumed @Maximilian had some purpose in mind with the cut-off letters. My brother and his wife are big fans of Game of Thrones, but I don't subscribe to HBO, so I was ignorant of the letters' significance. Letters or no letters, the shield was impressive.
  21. Congratulations to @welshblue for his very stylish winning entry. Congratulations to @Pixey, also. That shield shape is interesting and attractive, and the shading is very effective. Two additional entries I'd like to single out for praise are @MadJik's red dragon shield and @Maximilian's round, off-angle shield. I'm sort of surprised MadJik's shield didn't get more votes. I really like that dragon insignia. The 3D shape of Maximilian's shield is excellently done, as is the metal surface texture (I do question the chopped-off letters around the circumference, which don't quite make sense to me). There were quite a few other good entries.
  22. That does seem strange. I was going to tell you to press Finish before beginning the second resize, but discovered that even after pressing Finish, the selection reverts to the initial proportion when Shift is held down.
  23. A very useful and thorough tutorial! I'd like to see more people (including me) explain how they made their comp entries. Especially their OOTF entries, since that's when we pull out our best tricks.
  24. If you want more flexibility, you might try my Paste From Clipboard plugin. You copy the original image to the clipboard using Ctrl+C (or Ctrl+Shift+C for the merged image), then run the plugin in the layer you want to transfer the original image to. If you want only part of the original image, you can use a selection. Also, please make your comment titles more specific. It's the rule:
×
×
  • Create New...