Code Monkey home page Code Monkey logo

photodemon's People

Contributors

arisohandriputra avatar audioglider avatar decimalturn avatar epmatsw avatar felixonmars avatar jpbro avatar kroc avatar ljhcage avatar manfromarce avatar rajch avatar tannerhelland avatar wqweto avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

photodemon's Issues

On sketchy Internet connections, checking for software updates locks the UI

This is especially obnoxious when the program is first loaded, as the whole interface will seize and Windows will gray out the main window as if the program has frozen. This is a problem with the wininet.dll functions I'm using... but there must be a way to either perform the check asynchronously (messy in VB) or to set an automatic timeout of a few seconds.

Viewport not drawn correctly after leaving .Maximized

Proposed solution: track window state in pdImages(). When leaving .Maximized, call PrepareViewport on all windows. (This is especially important if the images were loaded in the .Maximized state, as the new window size assigned to them by VB is likely to be too small for the viewport size.)

Implement "most-used commands" section of left-hand pane.

The current plan for the unused space on the left-hand bar is to dynamically populate it with buttons for the user's most-used commands. This isn't especially difficult to implement, since PhotoDemon can track commands through its software processor. The problem is storing this information in a safe, private way. Key features include:

  • There has to be a way to turn on/off the feature, and to clear any existing data
  • Per PhotoDemon's portability requirements, all command tracking needs to be done in the INI. This could get messy quickly, as there are a LOT of commands.
  • Does it make sense to populate the INI dynamically as commands are used...? This would mean a smaller INI size, but it will also require some unique code to read from the INI file (since the current functions assume that Get requests always exist).
  • For performance reasons, it would be better to track the most-used commands in their own array, rather than scanning the full list of commands every time the program is loaded.
  • Regardless of the tracking system, a sorting algorithm will be needed to sort commands from most- to least-used.

Add "Apply" option to Preferences dialog

This will also require some re-engineering to make sure that options are only set when OK or Apply is pressed, and that Cancel ignores all changes from that session.

Support drag + drop loading

You cannot drag file(s) from explorer and drop them into PhotoDemon.
There is a way to receive drop handlers in VB, but I've never used them myself.

Implement HasBeenSaved tracking

I don't like "you haven't saved this image" prompts, but if others are going to use PhotoDemon, it probably needs this option. Implementing a .HasBeenSaved property and checking it upon image and/or program close should be trivial; the Undo handler already tracks this as part of enabling/disabling the Undo/Redo buttons, so I should be able to tap into that.

Implement "Smart Resize"

Right now, image resizing only works on fixed image sizes. It has no respect for aspect ratios - for example, if you tell it to convert a set of photographs to 800x600, it will force all images to that regardless of whether they're in portrait or landscape mode. This is how most image resize tools work - and it's not incorrect - but macros require something more nuanced.

The current plan is a "smart resize" that compares an image's aspect ratio to the requested size, and automatically determines whether the user means (for example) 800x600 or 600x800. This will allow for conversion of photographs from mixed aspect ratios.

Additionally, it might be nice for the smart resize to offer some standard image sizes for the user to choose from, alongside custom size text boxes.

Finally, while recording macros it would be nice to warn the user that "smart resize" is more appropriate then just "image resize." (This may not appear in the initial implementation.)

Cannot begin selection outside of image

To make it easier to start a selection from a corner, it should be possible to begin drawing the selection from outside the image. Clicking and dragging inwards from outside the image should begin the selection in the nearest corner.

32bpp PNG/BMP/TIFF may not render alpha channel properly

Per Herman:

"I have a series of small 32 BPP files of various file formats, used
to test the effectiveness of a program on loading 32 BPP files. I
use these files because more often than not the ordinary ones do not
easily reflect the defect, if any, of the program [because (i) defect
is hidden in a black ground used and/or (ii) the alpha is not strong
enough as to be seen with naked eyes]. Attached are two of such
"Test32x32x32" files which I use, one is PNG and the other TIFF.

In PhotoDemon, you wouldn't see the alpha effects of the said files
when you load them, this means the program is not quite yet in
handling 32BPP stuff. (However, if you test them on my
FreeImageTest, you would see the alpha effect clearly)."

Implement "GetNameOfProcess"

Right now, PhotoDemon's software processor deals only in numerical constants. It has no way of knowing that process command #416 is "Gaussian Blur", for example. The plan is to implement a "GetNameOfProcess" function; pass it the numerical constant of a Process call, and it returns a string describing that action. That string could then be used to populate all sorts of things - like the Undo/Redo/Repeat Last Action/Fade Last Filter commands.

Note that this feature is a prerequisite for the planned visual macro editor.

Add "Duplicate image" option

Per the suggestion from PSC user Achmad - "I suggest you add function to duplicate the image. I usually make a duplicate and work with them, so that the original image intact."

If plugins are missing, menu icons are misaligned

Import menu - if eztw32.dll isn't found, PhotoDemon automatically disables the scanner option (as it should). But because the menu icons are generated programmatically, this misaligns the import menu icons.

Display recently used Macros in the Tools menu

As a sort of "quick list" feature for Macros. The problem with this solution is if the user decides to create TONS of macros... in that case it would be nice to do the last 10 or something, but that's a bit messier to code.

For now, let's just go with the entire contents of the folder.

Do not include the .exe in the repo

It bloats the repo history, of which you have limited storage space on github, and it makes things hard for those submitting patches / pull requests &c. because I don't know if I should be including a freshly compiled exe or not and it greatly confuses matters when it comes to branches / merging.

Add Selections

Rectangular selections come first. Once that full framework is in place, other selection tools can be added.

Delayed crash possible when invalid PCX file is loaded

Per Herman:

"In Alfred Koppold's project (attached), if I change "On Error Resume
Next" in "Sub SortPlans" of LoadPCX.cls to "On Error Goto
allesfertig", then the crash on loading the file which Robert sent you
(being resent here) is avoided."

Merge core and preview versions of all image filters

I have tested this with the newly added grayscale previewing (see b303e91 and 5218ab1) and it works very well.

This will be a massive undertaking that requires the rewrite of hundreds of functions... but the end result should be worth it as it will allow any image filter to be applied anywhere in the program - not just to the standard user interface forms. It also reduces total code size and maintenance by not requiring duplicate functions (one for previewing, one for running the actual effect).

This is also a prerequisite for an interactive macro editor capable of previewing any effect.

Decouple image loading from user interface (MDI child generation, viewport prep, etc)

At present, image loading is deeply integrated with the creation of a new MDI child form. This was intentional - images are only loaded as part of the primary interface, and it takes a lot of work to get an image on-screen and ready for editing.

Unfortunately, this tight integration has hampered the development of other features, including an "image preview" in the planned batch conversion wizard. One solution is to use the current code but render each image to an invisible MDI child as necessary. I don't like this solution - it's hackish, and overkill, because most of the UI integration is unnecessary if all we need to do is get an image loaded into memory.

So my proposal is to rewrite each format-specific load routine to be independent of a destination picture box. The current PreLoadImage routine will need to be modified to request rendering to FormMain.ActiveForm. A new routine will need to be built that mimicks the format detection capabilities of PreLoadImage, but then requests loading to an invisible picture box. That box could then be used to populate a batch conversion preview or even an image browser.

Add Preference for "Remember Last Save Format" (or similar)

At present, PhotoDemon defaults the file format of the Save dialog to whatever format you saved last. This is my preferred behavior, as I tend to work exclusively with JPEG files, and I want to save everything as JPEGs.

For other users, this may not be the case. So there should be an option for the Save common dialog to automatically select either:

  1. the last-used save format
  2. the format of the image-to-be-saved

Move all hotkeys to the accelerator user control

For some reason, intrinsic VB accelerators (like Ctrl+O or Ctrl+S) fail to fire at unpredictable times. It makes sense to have all hotkeys on the same system, so all intrinsic hotkeys should be moved over to the user control.

Animated PNGs don't render properly

Per Herman:

"Attached is a PNG which is an animated PNG (as you know, animated PNG can be
displayed as a normal single frame PNG or a series of PNG frames).

I found that PhotoDemon does not seem to show a correct image of this
file, despite FreeImage is capable of displaying it correctly (you can
test it usng the FreeImageTest project which I sent you in my previous
mail)."

Add Preference for "Color Depth on Save" (or similar)

At present, PhotoDemon only saves to 24 or 32bpp files. It determines the proper depth automatically, based on the format being used (e.g. JPEG vs PNG) and the color-depth of the present image.

That said, the user may want to export to some other depth (such as saving a 32bpp PNG to 24bpp, which is not possible at present). The program also supports the importing of 8bpp images, so it stands to reason that there should also be a way to save those 8bpp images post-editing.

FreeImage provides mechanisms for all this, but what is needed is an interface to present the user at save-time. For some formats (such as JPEG) this is irrelevant, but for others it makes sense.

Most users won't give a shit about color depth, as they'll be using PhotoDemon for its intended purpose - photos - so there should be a preference for this, namely: "when saving, prompt for desired color depth" vs "always save to original color depth" vs "save non-alpha images to 24bpp, and alpha images to 32bpp".

Provide icons for recent documents list

I'm already generating these icons for use on the MDI child forms - so why not save them and use them in the Recent Files list? I'd need a place to save the icon files, but the current icon-to-menu code should work just fine...

Custom on-canvas image borders

With the recent rewrite of the viewport code, it should be relatively simple to add support for custom image borders. The plan is to include a color selector (like the current canvas background selector) in Edit -> Preferences, with support for light and dark colors based off the current system theme.

Improve selection handling in Image menu actions

Namely:

  1. Resize should resize the selection to match the new image
  2. Rotation should also rotate the selection
  3. Flip / Mirror should Flip / Mirror the selection
  4. Isometric... can just remove the selection. There's not a good way to make that happen until pixmap selections are implemented.
  5. Duplicate should duplicate the selection as well.

Color reduction is another problem. Manual color reduction obeys the selection, but automatic does not. This needs to be changed - but it present a problem for 32bpp images, because the transformation will only return 24bpp data. So... I think we'll need to make a temporary copy of the alpha data, reduce the colors, merge the alpha data back in, then apply the selection.

Or, just force color reduction to operate on the whole image.

Dynamically generate child form icons

Child form icons should be a miniature version of the current image.

Implementing this requires some caution - in theory, the icon should update whenever 1) an image is loaded 2) Undo is created (because that means the image is changing in some way, right?) 3) Undo is clicked.

Also, I haven't made up my mind as to whether or not the main PhotoDemon title bar (and/or the start bar icon) should also be updated with the active image. Right now I'm leaning toward updating the child form's icon only, though I'm open to outside input.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.