p-v-o-s / infragram-js

A web application for producing NDVI and other composites from DIY multispectral cameras
http://infragram.org
GNU General Public License v2.0
25 stars 11 forks source link

Rewrite to separate web app & interface from image processor #78

Open jywarren opened 9 years ago

jywarren commented 9 years ago

It'd work like this:

// Initialize
var ig = new Infragram({webgl: false});

// Load an image:
ig.load('img.jpg');

// OR load an image object:
var img = new Image();
// stuff
ig.load(img);

// Now set an infragrammar expression: 
ig.apply('(R+G)/(R-G)');

// Get the resulting image back out as an Image object or otherwise:
ig.export();
ig.exportDataUrl();

// All in one step:
ig.filter('(R+G)/(R-G)', img);

// Or to filter and automatically replace an image element on a web page:
ig.filter('(R+G)/(R-G)', 'elementId');

And use https://github.com/Automattic/node-canvas to make runnable in NodeJS, and maybe even WebGL: https://github.com/mikeseven/node-webgl

If we did this, we'd be able to:

nbarry202 commented 7 years ago

This would be very cool!

jywarren commented 7 years ago

This is happening, actually! at https://github.com/publiclab/image-sequencer -- almost complete!

On Tue, Aug 22, 2017 at 7:26 AM, nbarry101 notifications@github.com wrote:

This would be very cool!

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/p-v-o-s/infragram-js/issues/78#issuecomment-323998022, or mute the thread https://github.com/notifications/unsubscribe-auth/AABfJ7vwxfFOlfDmKJNgaImr5h82cSD6ks5sarrmgaJpZM4F0E7N .

nbarry202 commented 7 years ago

Sounds good. I've not much experience with Js, but hopefully I can work out how to run this from command line. I've got a little python script that currently uses infrapix_single to convert a batch images for a timelapse, but would love something that looks a bit more like infragram.

Hopefully I can work out how to call the Js from python!

Cheers

jywarren commented 7 years ago

Actually the js lib will be runnable from the command line directly!

On Aug 22, 2017 5:51 PM, "nbarry101" notifications@github.com wrote:

Sounds good. I've not much experience with Js, but hopefully I can work out how to run this from command line. I've got a little python script that currently uses infrapix_single to convert a batch images for a timelapse, but would love something that looks a bit more like infragram.

Hopefully I can work out how to call the Js from python!

Cheers

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/p-v-o-s/infragram-js/issues/78#issuecomment-324161950, or mute the thread https://github.com/notifications/unsubscribe-auth/AABfJzfiBbiTu1VW3TXJfaD41rb5Yt9Iks5sa01GgaJpZM4F0E7N .

nbarry202 commented 7 years ago

Fantastic, all the best with completing the project :)

jywarren commented 7 years ago

@ccpandhare - note potential interested party here! :-)

nbarry202 commented 7 years ago

Hopefully I can improve on this type of video https://youtu.be/Dx_P4b4Q8w8

ccpandhare commented 7 years ago

Integration with Infragram sounds pretty interesting! Never knew this is where the idea for Image Sequencer came from 😅 Or maybe not? 🤔

jywarren commented 7 years ago

one of the origins, but not the only one!

On Thu, Aug 24, 2017 at 11:08 AM, Chinmay Pandhare <notifications@github.com

wrote:

Integration with Infragram sounds pretty interesting! Never knew this is where the idea for Image Sequencer came from 😅

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/p-v-o-s/infragram-js/issues/78#issuecomment-324663876, or mute the thread https://github.com/notifications/unsubscribe-auth/AABfJwYnWGBk_UYa0xck02gE3SLIuUldks5sbZIDgaJpZM4F0E7N .

jywarren commented 6 years ago

Also, did this here! https://github.com/publiclab/infragram -- tore out the processor there and separated it from the server-side app!