From: Thomas 'PointedEars' Lahn on
santel_helvis(a)sify.com wrote:

> Could anyone tell me how to rotate the image in javascript.

You cannot do with JavaScript (or any other client-side applied
programming language in a UA environment) what you cannot do with
the UA. Rule of thumb: if the DOM of the UA does not provide the
means, JavaScript cannot provide it.

> Which concepts I should concentrate to rotate the image

HTML DOMs, image filters (IE/Win only, 90? steps only AFAIK), and
your favorite image editor. SVG and the SVG DOMs if you want to
support them.


PointedEars
From: bwucke@gmail.com on

Thomas 'PointedEars' Lahn wrote:
> bwucke(a)gmail.com wrote:
>
> > santel_helvis(a)sify.com napisal(a):
> >> Could anyone tell me how to rotate the image in javascript. Which
> >> concepts I should concentrate to rotate the image
> >
> > Okay, okay, I was cheating. That wasn't really rotation, just flipping.
> > Here you go, real rotation:
> > http://www.kurs.horsesport.pl/inne/rv2.html
> > Passed both Validator and Jigsaw, but tested only in FF1.5, [...]
> It takes more than a minute to be displayed by my Firefox 1.5 and locks
> it afterwards.

What did you expect with 10.000 DIVs acting as pixels? Get a faster
computer :P

> > You need to click "continue running script" when prompted, then wait
> > some...
> Obviously the author of that HTML document does not have any clue.

The question was about rotating the image in Javascript. The script is
a correct answer, no matter how much you don't like it. Of course there
are better methods to rotate an image NOT using Javascript, or using
Javascript just in a support role, doing only some parameters passing
between modules of the browser. This one here performs actual rotation
in JS and uses an ugly, slow hack to display the result.

Suggest a faster, more efficient method of rotating an image in
Javascript. Feel free to use CSS, but don't use experimental features
like Canvas, SVG or non-standard or external ActiveX, Java etc.

> > Could anyone tell me how to rotate the image in javascript.
> You cannot do with JavaScript (or any other client-side applied
> programming language in a UA environment) what you cannot do with
> the UA


But I just did.
Javascript is Turing-complete. That means. given required input and
output techniques, plus enough resources you can do EVERYTHING in it.
Some things are just harder than others, often because of I/O
shortcomings.
Someone talking about clue?

From: cwdjrxyz@yahoo.com on

Thomas 'PointedEars' Lahn wrote:
> santel_helvis(a)sify.com wrote:
>
> > Could anyone tell me how to rotate the image in javascript.
>
> You cannot do with JavaScript (or any other client-side applied
> programming language in a UA environment) what you cannot do with
> the UA. Rule of thumb: if the DOM of the UA does not provide the
> means, JavaScript cannot provide it.
>
> > Which concepts I should concentrate to rotate the image
>
> HTML DOMs, image filters (IE/Win only, 90° steps only AFAIK), and
> your favorite image editor. SVG and the SVG DOMs if you want to
> support them.

Indeed IE filters will work to rotate images along with text in a
division, at least in multiples of 90 degrees. See
http://elouai.com/javascript/javascript-image-rotate.php . You can test
their example on their page or download the code. Their test image is
quite small and simple. I have not tested this method on a large, very
detailed color image. Of course you will need a recent IE browser that
handles filters for this method to work.

From: Thomas 'PointedEars' Lahn on
Bisto Boy wrote:

> 100% JavaScript...

That is (of course) not true.
And it is not even the HTML code that it claims to be.

<URL:http://validator.w3.org/>

> [Top post]

<URL:http://jibbering.com/faq/faq_notes/pots1.html#ps1Post>


PointedEars
From: Bisto Boy on

"Thomas 'PointedEars' Lahn" <PointedEars(a)web.de> wrote in message
news:1589090.THyZZYniyF(a)PointedEars.de...
> Bisto Boy wrote:
>
> > 100% JavaScript...
>
> That is (of course) not true.
> And it is not even the HTML code that it claims to be.
>
> <URL:http://validator.w3.org/>
>
> > [Top post]
>
> <URL:http://jibbering.com/faq/faq_notes/pots1.html#ps1Post>
>
>
> PointedEars

Fine, fine... but the image rotates and gives the original poster enough to
be getting on with to satisfy his question "Could anyone tell me how to
rotate the image in javascript. Which concepts I should concentrate to
rotate the image". Point taken though, Thomas, thanks.
BB


First  |  Prev  |  Next  |  Last
Pages: 1 2 3
Prev: Getting IFRAME text
Next: getElementByName