Including an sprite
|
Here’s a sprite: [edit: no, not like this] [edit: hm, nor this] [edit: Okay, a sprite won’t display, but a PNG will) |
|
What, you mean on the forum? Standard web formats – JPEG, PNG, or GIF… (there are others, with varying degrees of support, best stick with one of the main three) |
|
Yes, I see. But since this forum is exclusively aimed at RISC OS, I thought that maybe it will display sprites too. Well, this just shows my broadly extended ignorance. |
|
I like the idea! Lets make an RFC for Sprites in browsers! ;) |
|
It’s the browser that does the display. Does it work in Netsurf on RiscOS I wonder? Probably not, since that would be a RiscOS only feature of a cross-platform browser, but easier to implement on RiscOS as the rendering code already exists. |
|
Yes – it works in Netsurf on RISC OS … but not in FF on Win10. |
|
So the solution for Windows (and Mac and Linux) users is to run RPCEmu and run NetSurf in that :) |
|
I wonder whether it works in Netsurf on other platforms. My guess would be not… |
|
The NetSurf developers produced LibROSprite, which looks a lot like a generic Sprite decoding library. So my guess would be yes. |
|
It works if netsurf is reading a local file. But, I have failed to make it work when fetching a sprite file from a web server, even when I can alter the headers given by the web server to give the file type image/sprite. HTTP/1.0 200 OK should it be something else? |
|
Try Content-Type: image/x-riscos-sprite I haven’t tried it myself, but the suggestion comes from looking at my MimeMap file. |
|
That works on my LAN. But not when I use EE Mobile to access the Internet |
|
Try You could give |
|
That works on my Local Area Network. But, when the PNG in the first post is converted to a sprite, the size is 340K! And I do not have a public facing web server which will serve a 340K graphic. And as they will only work with with Netsurf on RISC OS, I am going to borrow the phrase from the Dragon’s Den and say “I’m Out”. |
|
Now you know one of the reasons the PNG format was created, portability and compression being in the remit. Difficult bit – use of images. |
|
Not so important nowadays, but this was the initial rationale behind the development of my Pic_Index – though it still has many other useful features! In the days of old-fashioned dial-up modems, though… |
|
That’s the problem attitude “oh the network is faster now, so it doesn’t matter”, but it does. “Not so important” ?? There’s plenty of info on optimising pages, the developers I deride just don’t look at or simply don’t understand. Just in these pages I’ve seen people complaining about the amount of code that Google put into the entry page. Think how much swifter all the things we do on the net could be if the idle developers cleaned up their act. |
|
and if you put photos or videos onto Facebook, you can save yourself time and/or failures to load by scaling down the image sizes first. It won’t reduce the quality of the image the users see,, as Facebook scales them down anyway. |
|
I think you could substitute many other social media platforms for Facebook in that statement. I say “think” in that since the ROOL site is about as near to social media as I come. |
|
A colleague of mine once happily included raw camera images, the largest a 25 mb jpeg, in customer facing web-application, meant for use under conditions where internet speed is restricted. I managed to get all of them under 500k/image, which is still too large, but at least a considerable improvement… |
|
Factor of 50 reduction and probably similar increase in download speed, and the thanks you got? |
|
Approximately a 50th of what I deserved? ;) |
|
|