3 ms·
How do you define a diff or merge for such files? Having a history available and branches (e.g. alternative versions of the same image) that can't be merged bac
by pvitz 5y ago
How do you define a diff or merge for such files? Having a history available and branches (e.g. alternative versions of the same image) that can't be merged back seems to me to be still a version-control system.
- darkstarsys 5y agoIt depends on how deep the file parser is. For 2d, the zero-level feature would just be pixelwise image diff of the rendered result. For photoshop or inkscape, you could diff layers, show added/deleted/changed adjustments, etc. For 3d, to take Blender as an example, a zero-level diff feature would be to export (e.g. as glTF) and show which scene objects differ (meshes, textures, lights, etc.) More detailed parsing would give more details, e.g. image-diffing modified textures. As I noted, merging is nontrivial. But it seems important -- if I save a branch, go back to the trunk and do more work, how do I add in the changes I made on the branch? Or even know what those changes were? Good diffs would help of course. Merging would certainly have to be product-specific. For some open-source tools one could imagine hooking into their undo/redo logic, or parsing the product files into a temporary line-based format, but from outside it seems much more challenging than line-based merge in git (which is already imperfect for many applications).
- pvitz 5y agoI think this is one of those things that superficially sound not that complicated but when you look closer, it is a gargantuan complex task. If I think only about Photoshop and PSD, this seems terrible to implement and maintain. Also, I guess that the need is not really there, because otherwise, Adobe or some other company would have implemented this in the past 30 years.