Fabien,
thank you for your tips. I cannot remove
fr.cached = True
before the file open dialog comes up:
Dialog.Title = "Save image file..."
...
If I do remove the line, the file dialog comes to halt, taking minutes to
display a single file entry. Maybe may Gambas application is refreshing i
Thanks for the link to sourceforge.
-
Before you criticise someone, you should walk a mile in his shoes. Because,
when you criticize then, and he gets angry, you'll be a mile away - and have
his shoes.
--
View this message in context:
http://gambas.8142.n7.nabble.com/Paint-an-image-tp4434
works fine? I suspect that on the first run, you see some sort of blue-ish
stripes, and what happens after "Load" and selecting a PPM image? On my
system, nothing happens if I use "Paint.DrawImage". Only if use the
Paint.brush method, it works, and the loaded image is displayed.
??
Regards,
ukimi
work fine here
2013/11/24 Fabien Bodard :
> remove all the occurence on fr.cached... this is not needed at all
> (there is some with = true)
>
> remove fr.clear (this is slow and uneeded in the _draw event)
>
> 2013/11/24 Tobias Boege :
>> On Sun, 24 Nov 2013, ukimiku wrote:
>>> Hi Tobi,
>>>
>>> t
remove all the occurence on fr.cached... this is not needed at all
(there is some with = true)
remove fr.clear (this is slow and uneeded in the _draw event)
2013/11/24 Tobias Boege :
> On Sun, 24 Nov 2013, ukimiku wrote:
>> Hi Tobi,
>>
>> this is very kind of you. Your sample project works like a
On Sun, 24 Nov 2013, ukimiku wrote:
> Hi Tobi,
>
> this is very kind of you. Your sample project works like a charm: I see the
> pixels update and change color randomly.
>
> The problem with my project is: After I fill my image with color data, it
> gets displayed correctly. Then I fill in new co
Hi Tobi,
this is very kind of you. Your sample project works like a charm: I see the
pixels update and change color randomly.
The problem with my project is: After I fill my image with color data, it
gets displayed correctly. Then I fill in new color data, and it is not being
updated anymore. Whi
Monsieur,
here is a demo project I uploaded:
Link: https://www.dropbox.com/s/aztacpsshfo3h4i/Fr002DrawImage.zip
Basically, click on "Load", and you are prompted for a binary PPM or PGM
file. The picture is then displayed. If you click on "Save", you can select
a new filename and save the picture
On Sun, 24 Nov 2013, ukimiku wrote:
> No, I am not calling "Refresh" in the mousemove event, only once after the
> image data has been read in.
>
> I set "cached" to "False". Still, the image does not appear with
> "DrawImage". But with painted brushes, it works. I can live with that. I
> just wis
Le 24/11/2013 19:14, ukimiku a écrit :
> No, I am not calling "Refresh" in the mousemove event, only once after the
> image data has been read in.
>
> I set "cached" to "False". Still, the image does not appear with
> "DrawImage". But with painted brushes, it works. I can live with that. I
> just w
No, I am not calling "Refresh" in the mousemove event, only once after the
image data has been read in.
I set "cached" to "False". Still, the image does not appear with
"DrawImage". But with painted brushes, it works. I can live with that. I
just wished I understood the logic behind why some of th
are you calling the refresh in the mousemove event ?
2013/11/24 Fabien Bodard :
> set cached to false !!
>
>
> 2013/11/24 ukimiku :
>> Hi Tobias,
>>
>> thanks for looking into this:
>>
>> In the fr.Draw() event handler, when I plot my image pixel by pixel, using
>> this code:
>>
>> For y = 0 To
set cached to false !!
2013/11/24 ukimiku :
> Hi Tobias,
>
> thanks for looking into this:
>
> In the fr.Draw() event handler, when I plot my image pixel by pixel, using
> this code:
>
> For y = 0 To img.Height - 1
> For x = 0 To img.Width - 1
> Draw.Foreground = img[x, y]
>
Hi Tobias,
thanks for looking into this:
In the fr.Draw() event handler, when I plot my image pixel by pixel, using
this code:
For y = 0 To img.Height - 1
For x = 0 To img.Width - 1
Draw.Foreground = img[x, y]
Draw.Point(x, y)
Next
Next
the image appears. But this
On Sun, 24 Nov 2013, ukimiku wrote:
> Hi Fabien,
>
> thank you for your prompt reply. I must be missing something, I guess. It
> still does not display the image.
>
> In the Form_open event, I set
>fr.cached = false
>
> I see the effect when I drag the window with the mouse. It is slow and a
Hi Fabien,
thank you for your prompt reply. I must be missing something, I guess. It
still does not display the image.
In the Form_open event, I set
fr.cached = false
I see the effect when I drag the window with the mouse. It is slow and a bit
jerky as, I guess, the redrawing is taking place
> Public Sub fr_Draw()
> Paint.Begin(fr)
> fr.Background = Color.RGB(100, 140, 180)
>
> Paint.Image(img, 0, 0)
>
> paint.End
>
> End
cached must be false
and never set this property in the draw event ... but before... then
if you put the cached property to true, the draw event is not fir
Dear list members,
in my program I seemingly cannot get an image to be painted.
I have a DrawingArea called "fr".
In memory I keep an image named "img".
In my form code, I declare
public img as image
In the Form_Open handler, I instantiate "img" with
img = New Image(fr.Width, fr.Height
18 matches
Mail list logo