Go to main content

Textpattern CMS support forum

You are not logged in. Register | Login | Help

#1 2006-12-13 20:24:20

TheEric
Plugin Author
From: Wyoming
Registered: 2004-09-17
Posts: 566

ebl_imageEdit

I’ve begun work on a new plugin that replaces the native txp image_edit functions and adds a bunch more features. Currently, I’m stumped on the main feature and debating if I should go with a Javascript, or a Flash method.

There are two options I’ve been debating:

The first, and the one which I’ve gone farthest with, is one with a slick javascript cropper. The problem with this one is it requires several files to be dropped into specific locations, and my experience has shown that people tend to have a difficult time placing files in the correct location. The files total more than 160kb Note: This is the one shown in the semi-functioning demo.

The second, is one that uses flash, and embeds the 23kb flash file into the database upon installing the plugin. No extra files need to be uploaded, no folders made, simple and quick. While quicker and easier to install, it is a bit limited in its functionality.

What are everyone’s thoughts? Simple and quick 25kb flash installation, or a more involved 160kb javascript solution?

————
The basic cropping demo can be found here

Username: Demo
Password: m0fqn6

Once logged on, choose an image and you’ll be taken to ebl_imageEdit.

Planned Features

  • Image Cropping
  • Thumbnail Snippet / Crop / Keyhole (what’s the term to describe this concept? Think of it like this: Take a 100 × 100 snapshot of an interesting part of the image, and save it as a thumbnail.
  • Image Rotate
  • Flip Horizontal
  • Flip Vertical
  • Gamma Correct / Brightness
  • Contrast
  • Hue
  • Desaturate
  • Delete Thumbnail

Last edited by TheEric (2006-12-13 20:28:40)

Offline

#2 2006-12-13 21:15:59

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: ebl_imageEdit

Eric, Does the javascript need to be in specific locations or does it just need to be callable? Could the javascript be integrated into the plugin code and called using callbacks? If it’s small enough that tends to work.


Shoving is the answer – pusher robot

Offline

#3 2006-12-13 21:20:21

TheEric
Plugin Author
From: Wyoming
Registered: 2004-09-17
Posts: 566

Re: ebl_imageEdit

It’s about 163kb worth of javascript, plus two image files. I’m a bit hesistant to embed that much worth of javascript into the db.

Offline

#4 2006-12-14 00:02:20

Vitruvius
Plugin Author
Registered: 2004-09-21
Posts: 125

Re: ebl_imageEdit

Had a quick log Eric – it looks to be a good start. My vote would be for Javascript – the only real reason being that the plugin is then more in the public domain – some of us hacks can hack (and break :) as needed.

just my 2c worth…

S

Offline

#5 2006-12-14 00:48:34

truist
Plugin Author
From: Ohio, USA
Registered: 2004-11-09
Posts: 257
Website

Re: ebl_imageEdit

Why does the choice of technology (javascript vs. flash) dictate the choice of storage location (file vs. db)? It seems like either technology should work in either place.

Offline

#6 2006-12-14 00:50:10

hakjoon
Member
From: Arlington, VA
Registered: 2004-07-29
Posts: 1,634
Website

Re: ebl_imageEdit

I like the idea of it being JS if possible as well. What I found has worked pretty well with TinyMce is to have a default location but allow users to change the location through an admin panel. I haven’t had to much trouble with that specially if they are all together in a folder already.

“Place the ebl_imagedit folder in your textpattern folder” for example I have found to be fairly problem free directions. At least it hasn’t really caused many support issues with hak_tinymce. upm_quicktags does it like that too.


Shoving is the answer – pusher robot

Offline

#7 2006-12-14 02:29:23

TheEric
Plugin Author
From: Wyoming
Registered: 2004-09-17
Posts: 566

Re: ebl_imageEdit

truist wrote:

Why does the choice of technology (javascript vs. flash) dictate the choice of storage location (file vs. db)? It seems like either technology should work in either place.

Both can be stored within the db, I’m just hesistant to place 160k in a database when most plugins are under 40k. The flash file is significantly smaller than the javascript.

hakjoon wrote:

I like the idea of it being JS if possible as well. What I found has worked pretty well with TinyMce is to have a default location but allow users to change the location through an admin panel. I haven’t had to much trouble with that specially if they are all together in a folder already.

I prefer the javascript myself as well. Much more advanced than the flash I’ve been tinkering with.

Offline

#8 2006-12-14 08:07:47

colak
Admin
From: Cyprus
Registered: 2004-11-20
Posts: 9,011
Website GitHub Mastodon Twitter

Re: ebl_imageEdit

I would also go with the js. If size in the db is an issue, it could be distributed as an external file to be uploaded and then called.


Yiannis
——————————
NeMe | hblack.art | EMAP | A Sea change | Toolkit of Care
I do my best editing after I click on the submit button.

Offline

Board footer

Powered by FluxBB