Thread: Screen buffer
View Single Post
  #12  
Old 02-16-2004, 11:19 PM
G_yoshi G_yoshi is offline
Forbidden
G_yoshi's Avatar
Join Date: Mar 2001
Posts: 7,206
G_yoshi will become famous soon enough
Send a message via AIM to G_yoshi
Quote:
Originally posted by MrGannondorf
It is an intresting idea, and has potentual to be a good one, too. I think that the real problem is that images have a file size. The people with dialup would track you down and light you on fire if this were handled as you sugested.

Oh, and people still use dialup, if you had your doubts.


Anyhow, my idea to making this better, would be to make it so the snapshot isn't captured as image data, but something a little similar to vecter graphics instead (no, I don't mean actual vecters, just continue to read).

Now, I don't mean actual vectors (lest you're using polygons), but instead information only needed to recreate what is seen onscreen. For example, the level's tile data, and npc information to recreate what was onscreen... like level snapshots, but better. (I supose the vecter formats would be much like a gani's format, but with tiledata, etc).

The command would look something like this:
NPC Code:
screencapture p1,p2;



The first parameter would be the filename. The second parameter would be the layer (or layers, in the form of an array) it would capture... or a variable "all layers" or something that represents every screen layer. Other parameters could be things like the area of the level board you want to capture, rather than using the current screen area.

Now, yes that solves the filesize problem, but it sure doesn't make it useable...

this might, though...
NPC Code:
screenmake p1;



The parameter would be the filename. This command would take the said "vecter" data and make it into an image. The actual conversion would happen clientside, even if the command was run serverside... that way the image can be sent in a more compact format, and then inflated into the person's webgifs folder. There is plenty of room for more parameters, like one to inflate it on the server's space so it can be used for a webserver or something.
My idea isn't meant to automattically save it to disk. Its to buffer it into RAM until another image is buffered. Only a saving function should be used for online via the NPC server so that a webpage could load it. Obviously, it could be buffered into memory and use Graal's image color conversion that it uses for generating the map image to reduce the actual amount of data its using. This is also why I had a second command idea that allows you to specify an actual window area. That way you don't have someone dumping in an NPC that takes a 1600x1200 every 0.1 seconds and sending it out (I'd put a limit of 640x480 on it anyway).

I want it to be captured like a regular alt+2 screenshot but kept in memory rather than put on disk.

This feature would have to be used clientside since dbNPCs are not made to deal with graphics. Just allowing something like savelog to save the image to the playerworld's filespace.

And to inform, I am cursed with dialup I don't need any silly lectures.
__________________
Reply With Quote