Computer Science Canada

Deleting an image

Author:  faedwards [ Wed Jun 11, 2003 12:12 pm ]
Post subject:  Deleting an image

Question I have been exploring Turing (WINOOT) and came across this interesting forum. Great material.
I did not find any reference to a question I have so I'm posting to see what "the experts" can advise.
I have placed a number of images on screen using Pic.Draw(PicID, x,y,3). PicID is set to a variety of .bmp images.
The program gets user input on which image to move, and where to move this to, and places the appropriate image in a new location. But I can't get rid of the image from its original location! The background is the default Windows white screen.
One way I have tried is to place a "blank" .bmp square over the original image. This works if the blank .bmp is coloured but not if it is white.
I also see from another post that re-drawing the original image with Xor deletes it and restores the background, but this did not work for me (DOS only?).
Do you have any advice?
Also, would there be a difference if there is a checkerboard background .bmp, also placed using Pic.Draw?
(I'm using WINOOT 3.1.1)

Author:  Andy [ Wed Jun 11, 2003 3:21 pm ]
Post subject: 

umm clear the screen?
one of the most used commands

Author:  Mephi [ Wed Jun 11, 2003 3:48 pm ]
Post subject: 

if u want to draw over it with a blank square....make sure your not using picMerge, but u should use picCopy....or u can just use Draw.FillBox

Author:  Tony [ Wed Jun 11, 2003 4:48 pm ]
Post subject: 

Mephi is probly right... I dont know what that 3 stands for there... But my guess its not the same as picCopy.


Author:  Grey_Wolf [ Wed Jun 11, 2003 9:14 pm ]
Post subject: 

if you wanted to put a white pic overtop you can just go into paint and make a custom colour that is a really light blue. it's almost impossible to tell the difference between that and white.

Author:  faedwards [ Thu Jun 12, 2003 9:55 am ]
Post subject: 

Thanks for the comments, light blue - interesting workaround...
I'm surprised there is no "delete" or equivalent command Smile
The 3 in my version of WINOOT I think stands for XOR so that the irregual image can be placed on a background that will continue to show around the image.
Because I only want to delete a single image cls does not help.
I have tried all combinations of 1,2,3, (picXor, piccopy, etc. just give error "not defined"). I have even tried Draw.FillBox with no success, but it seems I had some problems with my coordinates and it was placing a white square elswhere on my white background where I could not see it - and I thought it was not working Embarassed
Tried it again using colour 31 and it works like a charm. Thanks.