Before getting into any API concepts, I think the first thing to address is the UI itself - how would such a feature be integrated into the existing DOpus DFF UI. Curently you have a "Comparison method" of:
- Filename only
- Filename & size
- MD5 checksum
I think there's room for a fourth option, which I envision as a combo box - labeled something like "Data Type", with entries like Music, Movies, Databases, or what not. The names populated in this combo box could be derived from DFF Plugins with an exposed UI_Name property, along with a GetProcAddress() address and a HMODULE interface to the plugin DLL in question - not hard to make an array of that info after parsing relevant plugin DLLs (with a suitable scanning mechanism).
A DFF-specific plugin could also export a function to define the file extensions that it cares to work with (e.g., ".mp3|mp4|ape|wmv", etc.) Only those extensions would be applied when selecting that particular "Data Type" for duplicate file finding.
As for tag processing, a plugin can surely add their own tag processing, but I don't think that makes a lot of sense from a continuity perspective. DOpus has a very large amount of tag decoding capability and if a DFF-style plugin used different criteria than what DOpus leveraged, it might lead to confusion. As such, it might be beneficial to expose a DVPFileInfoMusic? style object to the file comparator callback, or at the very least some kind of XML-like hierarchical data structure that contains the tags in question. By doing so the plugin will utilize the same decoding logic as DOpus, and can be expanded upon if and when DOpus adds more tag support (via an XML-like concept - not via a static data structure).
As for a DFF API, I'll have to think on this a bit now that I've had a chance to look at the SDK .H headers, but on first blush I'd think it would be advantageous to be able to add a handler into a DFF "Custom Filter Types" hander array (to populate the "Data Types") combo box, as well as a callback mechanism for comparing two file, which would require a file information object to be passes for each file in question as well as any meta data. This could be a list of files, or a simple dual-file comparison callback - depending on how the internal DFF code is structured.
In addition, it would be necessary to hook into the "Select" button so you could auto-tag all files in the DFF list based on various plugin-defined criteria (e.g., "Select lower quality, identical song titles"). The specific capabilities here are plugin-specific. This could require turning the "Select" button into a combo-box button lik you see in the Toolbars.
It might also be necessary to make the "Operations" toolbar, or other similar toolbars.
There could also be a need to tap into the context menu when right-clicking on files.
The commercial software market for duplicate file finders is growing. DOpus could add this capability by some (theortetically) straightforward enhancemets to its existing API infrastructure to handle things like duplicate music file removal (my example), removal of text files that are say 99% similar, but older (another plugin), photos that might have the same filename, but different dimensions (and are older), and other concepts I haven't thought of.
By offering extended plugin architectures, Third Party Developers could theoretically add a number of plugins for DOpus that GPSoft doesn't have the bandwidth to write. Lord knows, there's a lot of engineers out there with good ideas, and Directory Opus provides a rich framework for adding vertical market add-ons. It just requires some code exposue (and a bit of work).
Anything that adds value to DOpus' marketability has my vote!
Jeff Reeder