Il 22/10/2012 19:27, jeremy rosen ha scritto:
> Hello everybody
>
> A couple of month ago I sent a mail about the lua branch I was starting.
>
> At that time I was not really sure where I was going or what the point
> of Lua in DT would be.
>
> Well this branch is slowly maturating and it's time for a small update
> on the suject
>
>
> First, just to be clear, lua will not be in the next stable release.
> It's much too soon, and the lua API isn't stable enough. However the
> lua branch has reached the point where it can already be usefull and I
> think it's for people to start thinking what they could do with lua.
>
>
> The main point of lua in DT will be to make digital assets management
> smoother. It will allow each of you to customize the way DT handles
> your assets to make your workflow as bumpless as possible.
>
> To do that you will write small lua scripts that darktable will run in
> particular circumstances and that will tweak the images for you. Such
> tweaks could includ things like setting particular colorlabels
> automatically for some images on import, changing the lens-related
> metadata on import to help lensfun, run exiv2, jpegtools or
> imagemagick on export, reload the database when DT is started, all
> that sort of stuff
>
> Basically if you need something for your workflow that would greatly
> speed you up, but your usage is special enough that we don't want to
> change DT mainline to accomodate your workflow, Lua will give you the
> tools you need.
>
> right now there are only a couple of places where lua scripts are triggered
>
> * on DT start
> * after an image has been added to the database (you know which image
> was added and can manipulate it)
> * before export, when the button is clicked but nothing has been done
> yet. You can know which images will be exported by looking at which
> images are selected
> * during export, after the image was created but before it was
> exported to picasa/facebook/etc... (you know what image was added and
> can modify it in the DB, you also have the name of the temporary file
> where the image was exported, so you can run commands on it)
> * you can register new shortcuts that will trigger lua scripts
>
> and there are only a few actions that can be done (I only list actions
> that can be done on DT, you can always use lua to run commands/access
> the database directly etc... though some of these actions might void
> your warranty)
>
> on images
> you can read and write the following  data
> * exposure
> * aperture
> * iso
> * focal length
> * focal distance
> * crop
> * maker
> * model
> * lens id
> * image date
> * longitude
> * latitude
> * rating
> * colorlabels
> * creator
> * publisher
> * title
> * copyright information
>
> you can read the following data
> * filename of the associated RAW
> * image width
> * image height
> * index of duplicate
>
> you can also do the following through lua calls
> * add  images to the database
> * duplicate images
> * change the set of selected images in the light table UI
>
> here are a couple of use-cases that can already be satisfied via Lua
> * on export, modify exif data using external tools, apply different
> modifications depending on rating and/or colorlabels
> * change lens metadata on import to work around duplicates id/new
> lenses in lensfun
> * automatically set colorlabels depending on image metadata (to tag
> high iso images, for example)
> * reload a directory on DT startup to automatically add new images to database
> * call gimp on modified images before uploading them to
> facebook/etc... (note that there is a proper advanced exporter in the
> making that will do a better job for that... but lua can do it too as
> a proof of concept)
>
>
> here are a couple of use case I intend to satisfy before merging lua,
> but arn't done yet
> * export an image multiple times at once (currently you can't export
> an image from lua)
> * export with different quality depending on colorlabels (currently
> you can't export from lua)
> * add tags when an image is exported (currently you can't manipulate
> tags from lua)
> * add exported images to database (only makes sense for the disk
> exporter, which you can't filter from lua)
> * automatically apply a style on export (currently can't manipulate
> styles from lua)
>
> I also intend to add a way to add Light Table side modules (that is :
> right panel sections)
>
> I am very interested in how you would use such possibility and what it
> would allow you to do, I am not documenting the API at this point
> because it is still too much in flux, but if you really want to test
> it, contact me on IRC and I can show you how it's done...
>
>
> Cheers
> Boucman
>
> ------------------------------------------------------------------------------
> Everyone hates slow websites. So do we.
> Make your web apps faster with AppDynamics
> Download AppDynamics Lite for free today:
> http://p.sf.net/sfu/appdyn_sfd2d_oct
> _______________________________________________
> darktable-devel mailing list
> darktable-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/darktable-devel

Wow! Sounds great! Thanks for your great work, Boucman!

I'm very interested about this feature to solve some feature requests 
without put the hands in the main code.

My main problem is I don't know Lua so I don't know how easy could be 
develop a script.

I think the easy way is to read&study a Lua script for darktable.

Next day I will think about a specific case where to use Lua. If you 
already have some script to use as starting point, could be great.

Imo will be important create a space where to share and tag our scripts.

Now I stop here and I will take a look at your branch and at Lua 
documentation.

Ivan





------------------------------------------------------------------------------
Everyone hates slow websites. So do we.
Make your web apps faster with AppDynamics
Download AppDynamics Lite for free today:
http://p.sf.net/sfu/appdyn_sfd2d_oct
_______________________________________________
darktable-devel mailing list
darktable-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/darktable-devel

Reply via email to