h a l f b a k e r yGo ahead. Stick a fork in it.
add, search, annotate, link, view, overview, recent, by name, random
news, help, about, links, report a problem
browse anonymously,
or get an account
and write.
register,
|
|
|
When making a web page, you can put
photos on your webpage that aren't in
your server space. But you can only put in
the whole photo (or so I have seen.)
This plug in however will change all of
that. When you are linking to a picture
you can also select what you want of that
picture
with out having to import it into a
photo editor. Other computers will be
instructed to open up that picture, via the
plug in, and only display the coordinates
you have selected.
Later versions, will be like the photo
editors in that you shall be able to select
different photos and place them in your
finished works on different layers or with
different filters added. The original
picture will be unchanged and unharmed.
Image fragments with CSS
http://www.alistapa...m/articles/sprites/ from 'a list apart'. [st3f, Oct 04 2004, last modified Oct 05 2004]
[link]
|
|
Hmm. This could lead to the originals, or master images, being tightly packed collages of images similar to the texture maps you'll find in console games where the textures for just about everything are packed into a single or very few small images to conserve texture memory. When the textures are called they include the coordinates of the exact map within the master image. |
|
|
An interesting idea, sir. |
|
|
Wow, thank you very much. I hadn't
even thought about games. |
|
|
You wouldn't need a plug-in. Instead of
referencing an image on a server, you
call a server-side script with the
parameters you need and the image
fragment is passed to you, i.e. instead
of:
<img src="image.jpg"> |
|
|
you use:
<img src="photopiece.php?
file=image.jpg& x1=125& y1=128&
x2=201& y2=256& scale=1">
(spaces inserted to make this lay out
better) |
|
|
It shouldn't take more than a few lines
of php to create the image on the fly. |
|
|
Well . . . in that case I take back everything. |
|
|
//Well . . . in that case I take back
everything.// |
|
|
(serious note) Could you do the same
with filters, and say non square outlines
like say the lasso tool or would you still
need my plug in? |
|
|
Most server-side scripting languages are fairly complete programming languages. You can do pretty much anything with an image that you are able to program. Bear in mind that all this work is happening on your server so, if you want to do something complex instead of just chopping an image down to save bandwidth, you might want to find some way of pushing the processing back to the client. |
|
|
As browsers aren't yet capable of altering the contents of a bitmap (I doubt it's even supported by the DOM yet) you'd be back to using a plug-in. |
|
|
You can do this with CSS as well, but it is limited to four-sided outlines. |
|
|
"This could lead to the originals, or master images, being tightly packed collages of images..."
Would this be an improvement? Aside from this application, of what other use would this be? |
|
|
Fewer parts flying in close formation. Suppose you only had one image file to handle all of the graphic support elements of a site. Would that be better on the server/content management side? Would it be better on the client/cache side? |
|
|
How about this hack? Create two files in the same folder and use IE to view the later (j.htm)? |
|
|
<html>
<body>
<img src="http://www.halfbakery.com/img/hc.gif" style="position:absolute;left: -50; top: -50; " />
</body>
</html> |
|
|
<html>
<body>
<iframe frameborder=no src="i.htm" width=50 height=50 scrolling=no />
</body>
</html> |
|
|
"Fewer parts flying in close formation"
Yeah, but image management becomes tougher. Mess up the coordinates and you're going to have some confused users. Also, I presume image size and resolution remain the same as in a stand-alone graphic, so I don't see an improvement there. |
|
|
The improvement comes in the number
of server accesses needed to fetch a
page. If you have a page with 10
images, that's 11 fetches to the web
server. If you bundle all the images
together it's only two. That may speed
things up a bit. |
|
|
Another advantage is for image
rollovers -- there is no need to make
sure that the rollover images are
preloaded, since they are a different
part of an image that has already been
displayed on the page. |
|
|
Back when I thought you'd have to chop
the image server-side, I wasn't that
keen. Now that I know that you can do
it client-side using CSS, I like this idea
much more. I may even give it a go. |
|
|
Even thought sartep wasn't the first with
this idea (see link), I don't believe that the
use of it in a web browser was well known
at the time so I'm going to put my
croissant back. [+] |
|
|
great idea [sartep], server side cropping etc. is nice. |
|
|
Thanks, yes I wanted it more like a
server side photoshop, with more than
just cropping but lasso, blurr and
filters. |
|
| |