Hey, is it possible to have a javascript feature to shear an image and not to just resize it, so I could change the perspective of an image? -- greetings, benni. -SDG- --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Hey there, Benjamin Mack a écrit :> is it possible to have a javascript feature to shear an image and not to > just resize it, so I could change the perspective of an image?AFAIK, there''s no API to manipulate image contents. There certainly isn''t anything towards that in standard JS. There *might* be something proprietary, but your best bet towards this is to use some Flash. -- Christophe Porteneuve aka TDD tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Hey, thanks for your reply. Christophe Porteneuve aka TDD wrote:> AFAIK, there''s no API to manipulate image contents. There certainly > isn''t anything towards that in standard JS. There *might* be something > proprietary, but your best bet towards this is to use some Flash.yes, but I think for shearing one needs only to modify the corner points of an image, but yes, I haven''t found anything on this yet. Yes, Flash is a possibility of course, but I would love to make this happen with Javascript and avoid flash. -- greetings, benni. -SDG- --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Hey Benjamin, Benjamin Mack a écrit :> yes, but I think for shearing one needs only to modify the corner points > of an image, but yes, I haven''t found anything on this yet.Yes, but there''s no such thing as a non-rectangular box in JS/CSS/DOM, except for image map areas, which is beside our issue.> Yes, Flash is a possibility of course, but I would love to make this > happen with Javascript and avoid flash.I''m pretty confident you won''t. Even SVG doesn''t offer much for this, I believe, at least SVG Tiny. And many browsers, including IE, don''t support SVG anyway. A lightweight Flash, like you see these days for audio playback and the like, is probably your best bet. And this, from a guy who avoids Flash as much as possible :-) -- Christophe Porteneuve aka TDD tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
It can be done, but it''s heavy and hackish. (And no, I don''t know whether there is a public API for it.) You would need to use js and css, create an absolutely positioned div for every visible pixel of the image, and offset the background image to the pixel you wish to display. With such a scheme, you could do any kind of manipulation you wished! One example (others exist too if you can find the right Google query): http://www.walterzorn.com/rotate_img/rotate_img.htm?A=30 If you''re not afraid of IE-only, then something like this may work for you: http://elouai.com/javascript/javascript-image-rotate.php TAG On Oct 10, 2006, at 6:05 AM, Christophe Porteneuve aka TDD wrote:> > Hey Benjamin, > > Benjamin Mack a écrit : >> yes, but I think for shearing one needs only to modify the corner >> points >> of an image, but yes, I haven''t found anything on this yet. > > Yes, but there''s no such thing as a non-rectangular box in JS/CSS/DOM, > except for image map areas, which is beside our issue. > >> Yes, Flash is a possibility of course, but I would love to make this >> happen with Javascript and avoid flash. > > I''m pretty confident you won''t. Even SVG doesn''t offer much for > this, I > believe, at least SVG Tiny. And many browsers, including IE, don''t > support SVG anyway. > > A lightweight Flash, like you see these days for audio playback and > the > like, is probably your best bet. And this, from a guy who avoids > Flash > as much as possible :-) > > -- > Christophe Porteneuve aka TDD > tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Hey Tom, Tom Gregory a écrit :> You would need to use js and css, create an absolutely positioned div > for every visible pixel of the image, and offset the background image > to the pixel you wish to display. With such a scheme, you could do > any kind of manipulation you wished!Man! You should be *lapidated* for suggesting people should even attempt this! :-) I can imagine this, even on medium-size images, bringing the rendering engine to a grinding halt. -- Christophe Porteneuve aka TDD tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
<grin> In my defense, he asked how to do it in Javascript, and that''s the only way it could be entirely client-side. (A better solution with server-side interaction would be to pass the manipulation arguments in an AJAX call and let a server with a real graphics library do the manipulation.) For those of you, like me, who had to look up "lapidate" (and couldn''t find it in the first couple of dictionaries I checked): Dictionary.com Unabridged (v 1.0.1) lap‧i‧date /ˈlæpɪˌdeɪt/ Pronunciation Key - Show Spelled Pronunciation[lap-i-deyt] Pronunciation Key - Show IPA Pronunciation –verb (used with object), -dat‧ed, -dat‧ing. 1. to pelt with stones. 2. to stone to death. [Origin: 1615–25; < L lapidātus ptp. of lapidāre to stone. See lapidary, -ate1] —Related forms lap‧i‧da‧tion, noun Dictionary.com Unabridged (v 1.0.1) Based on the Random House Unabridged Dictionary, © Random House, Inc. 2006. On Oct 10, 2006, at 11:01 AM, Christophe Porteneuve aka TDD wrote:> > Hey Tom, > > Tom Gregory a écrit : >> You would need to use js and css, create an absolutely positioned div >> for every visible pixel of the image, and offset the background image >> to the pixel you wish to display. With such a scheme, you could do >> any kind of manipulation you wished! > > Man! You should be *lapidated* for suggesting people should even > attempt this! :-) > > I can imagine this, even on medium-size images, bringing the rendering > engine to a grinding halt. > > -- > Christophe Porteneuve aka TDD > tdd-x+CfDp/qHev2eFz/2MeuCQ@public.gmane.org > > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Have a look at the following: http://www.kawa.net/works/js/animation/cube-e.html On 10/10/06, Benjamin Mack <bmack-mZxRKsT3+loAvxtiuMwx3w@public.gmane.org> wrote:> > > Hey, > > thanks for your reply. > > Christophe Porteneuve aka TDD wrote: > > AFAIK, there''s no API to manipulate image contents. There certainly > > isn''t anything towards that in standard JS. There *might* be something > > proprietary, but your best bet towards this is to use some Flash. > > yes, but I think for shearing one needs only to modify the corner points > of an image, but yes, I haven''t found anything on this yet. > > Yes, Flash is a possibility of course, but I would love to make this > happen with Javascript and avoid flash. > > -- > greetings, > benni. > -SDG- > > > >-- Thanks, -Steve http://www.stevelongdo.com --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
Animation.Raster is crazy, too: http://www.kawa.net/works/js/animation/raster-e.html On 10/10/06, Steve Longdo <steve.longdo-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> Have a look at the following: > http://www.kawa.net/works/js/animation/cube-e.html >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN"> <html> <head> <meta content="text/html;charset=ISO-8859-1" http-equiv="Content-Type"> </head> <body bgcolor="#ffffff" text="#000000"> That''s pretty cool that people have actually done that stuff with pure javascript. Despite what naysayers think, I think it is good that people try to do all that is possible with a platform even though it wasn''t designed for such things. Granted, the skewing is low resolution and the aliasing is horrible, but cool nonetheless. It practically uses full CPU utilization on my system which is pretty fast but it *does* work.. What about pre-generated animated gifs?<br> <br> Colin<br> <br> Steve Longdo wrote: <blockquote cite="midcc4e85f30610101607o4e27ed95q26e3bbf54c4ec32-JsoAwUIsXosN+BqQ9rBEUg@public.gmane.org" type="cite">Have a look at the following:<br> <a href="http://www.kawa.net/works/js/animation/cube-e.html">http://www.kawa.net/works/js/animation/cube-e.html</a><br> <br> <br> <div><span class="gmail_quote">On 10/10/06, <b class="gmail_sendername"> Benjamin Mack</b> <<a href="mailto:bmack-mZxRKsT3+loAvxtiuMwx3w@public.gmane.org">bmack-mZxRKsT3+loAvxtiuMwx3w@public.gmane.org</a>> wrote:</span> <blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br> Hey,<br> <br> thanks for your reply.<br> <br> Christophe Porteneuve aka TDD wrote:<br> > AFAIK, there''s no API to manipulate image contents. There certainly<br> > isn''t anything towards that in standard JS. There *might* be something <br> > proprietary, but your best bet towards this is to use some Flash.<br> <br> yes, but I think for shearing one needs only to modify the corner points<br> of an image, but yes, I haven''t found anything on this yet.<br> <br> Yes, Flash is a possibility of course, but I would love to make this<br> happen with Javascript and avoid flash.<br> <br> --<br> greetings,<br> benni.<br> -SDG-<br> <br> <a class="moz-txt-link-freetext" href="http://www.stevelongdo.com">http://www.stevelongdo.com</a> <br> <br> </blockquote> </div> </blockquote> <br> --~--~---------~--~----~------------~-------~--~----~<br> You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. <br> To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org <br> To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org <br> For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs <br> -~----------~----~----~----~------~----~------~--~---<br> </body> </html> <br>
Hey Steve, thanks! That is really a good thing to start from! greetings, benni. -SDG- Steve Longdo wrote:> Have a look at the following: > http://www.kawa.net/works/js/animation/cube-e.html > > > On 10/10/06, * Benjamin Mack* <bmack-mZxRKsT3+loAvxtiuMwx3w@public.gmane.org <mailto:bmack-mZxRKsT3+loAvxtiuMwx3w@public.gmane.org>> > wrote: > > > Hey, > > thanks for your reply. > > Christophe Porteneuve aka TDD wrote: > > AFAIK, there''s no API to manipulate image contents. There certainly > > isn''t anything towards that in standard JS. There *might* be > something > > proprietary, but your best bet towards this is to use some Flash. > > yes, but I think for shearing one needs only to modify the corner points > of an image, but yes, I haven''t found anything on this yet. > > Yes, Flash is a possibility of course, but I would love to make this > happen with Javascript and avoid flash. > > -- > greetings, > benni. > -SDG- > > http://www.stevelongdo.com > >--~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Ruby on Rails: Spinoffs" group. To post to this group, send email to rubyonrails-spinoffs-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org To unsubscribe from this group, send email to rubyonrails-spinoffs-unsubscribe-/JYPxA39Uh5TLH3MbocFFw@public.gmane.org For more options, visit this group at http://groups.google.com/group/rubyonrails-spinoffs -~----------~----~----~----~------~----~------~--~---