more /root/Help/Writing an Image Effects Plugin.thread
2008-12-25 02:54:27Bob the BlueBerry
I want to write a plug-in that allows fancy image effects in images like that Game Maker's image editor allows.
What would be the best way to implement this? Would I clone Game Maker's sprite/image editor and you could just set LateralGM's image editor to the one provided by the Plug-in?

Thanks (for the help I will not receive),
- Bob
2008-12-25 04:39:46IsmAvatar
You should consider helping out with our image editor, JEIE.

The best way... hmm.
Probably the best way would be to extend org.lateralgm.subframes.SpriteFrame and implement org.lateralgm.subframes.SubframeInformer.SubframeListener (and then of course register it with SubframeInformer).
Use all of SpriteFrame's default methods, but override the editSubimage method.

Of course the big goal of the subimage editor is to just open an image and edit it, and then return an edited image, so it shouldn't even need to interface with LGM much. Once we have a working subimage editor that is relatively small, we'll most likely add it directly to LGM, so it doesn't need to function as a plugin.