Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations IamaSherpa on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

How does GET store info?

Status
Not open for further replies.

qbasicking

Programmer
Aug 19, 2001
628
US
In what format does GET store the image. I want to be able to use GET and to take an image and then play with it, such as take a piece of it and take every other pixil to make a faded effect. How do I do this, using POINT is too slow.
 
GET stores the image in some kinda binary code. But when u save the file using BSAVE it stores in a definate format. You can search for this format on google. or or ask some one else for help.
 
TheBigBasicQ:
I couldn't find the file that you told me about at Also, I would much rather use GET/PUT, it is much faster and speed is everything on my 486 machine
 
In many ways, the contents of an array filled with the GET statement are just like the contents of any-old single-precision array. And, to a point, you can modify them and write them back to the screen.

Try it.... This captures a square, modifies the contents and puts it back on the screen.
[tt]
DIM PutArray(1 TO 52)
DIM OldArray(1 TO 52)
SCREEN 7
'[/tt]
Put some lines on the screen[tt]
FOR X = 0 TO 15
LINE (X, 0)-(X, 15), Co
Co = Co + 1
IF Co > 15 THEN Co = 0
NEXT
'[/tt]
Get a portion of the screen[tt]
'[/tt]
and place it in an array[tt]
GET (0, 0)-(16, 16), OldArray
DO
FOR Modifier = 0 TO 255
PutArray(1) = OldArray(1)
'[/tt]
Change the elements of the array[tt]
'[/tt]
and store them in a new array.[tt]
FOR Re = 2 TO UBOUND(PutArray)
PutArray(Re) = OldArray(Re) OR Modifier
NEXT
'[/tt]
"PUT" the new array to the screen[tt]
PUT (0, 0), PutArray, PSET
'[/tt]
Press a key to end the program[tt]
I$ = INKEY$
IF I$ <> &quot;&quot; THEN
SCREEN 0
WIDTH 80, 25
END
END IF
NEXT
LOOP
[/tt]

VCA.gif
 
I'm having another problem with GET and PUT. I want to move a window, I was thinking that I would GET the border of it, using 4 different variables :movea(100),moveb(100),movec(100),and moved(100),make a dotted red line, and then PUT the PSET of the image back onto the screen.
It gets past the first GET statement fine, but when it gets to the second it gives me an error. All of the variables have been declared before hand, all the same size yet it won't let me do the rest of them, what should I do?

Here's my exact code:

DIM SHARED movea(100)
DIM SHARED moveb(100)
DIM SHARED movec(100)
DIM SHARED moved(100)
.....
WHILE lb% = -1
mousestatus lb%,rb%,mb%,x%,y%
GET (x%,y%)-(x%+xlen,y%),movea
GET (x%+xlen,y%)-(x%+xlen,y%+ylen),moveb
GET (x%+xlen,y%+ylen)-(x%,y%+ylen),movec
GET (x%,y%+ylen)-(x%,y%),moved
LINE (x%,y%)-(x%+xlen,y%+ylen%),4,B,&H5555
PUT [I'm tired of typeing, the smae placement of the GETs]
&quot;
&quot;
&quot;
WEND
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top