[Gambas-user] Image handling ...

Laurent Carlier lordheavym at ...626...
Fri Jul 13 08:18:37 CEST 2007


On Friday 13 July 2007 01:55:27 Gareth Bult wrote:
> Hi,
>
> Ok the drawing area cracked it .. :-)
>
> On another note .. I'm using a Httpclient connection ..
> This opens a connection to a web server which streams video shots ... works
> great.
>
> I've yet to discover how to close the channel tho'.
>
> If I do http.Close, then exit back to the ide, the program is still
> running. (I'm assuming the http port is still active hence holding the
> program open)
>
> How do I force a close of the http connection from the client end ?
>
> Gareth.
>
> --
> Gareth Bult, Encryptec Limited
> Tel: 0845 25 77033, Mob: 07891 389657
> Email: gareth at ...1689...
> Statements made are at all times subject to Encryptec's Terms and
> Conditions of Business, which are available upon request.
>
> ----- Original Message -----
> From: "Benoit Minisini" <gambas at ...1...>
> To: "mailing list for gambas users" <gambas-user at lists.sourceforge.net>
> Sent: Thursday, July 12, 2007 9:31:20 PM (GMT) Europe/London
> Subject: Re: [Gambas-user] Image handling ...
>
> On jeudi 12 juillet 2007, Gareth Bult wrote:
> > Sorry, SVN .. recompiled this week ...
> >
> > --
> > Gareth Bult, Encryptec Limited
> > Tel: 0845 25 77033, Mob: 07891 389657
> > Email: gareth at ...1689...
> > Statements made are at all times subject to Encryptec's Terms and
> > Conditions of Business, which are available upon request.
> >
> > ----- Original Message -----
> > From: "Benoit Minisini" <gambas at ...1...>
> > To: "mailing list for gambas users" <gambas-user at lists.sourceforge.net>
> > Sent: Thursday, July 12, 2007 9:15:43 AM (GMT) Europe/London
> > Subject: Re: [Gambas-user] Image handling ...
> >
> > On jeudi 12 juillet 2007, Gareth Bult wrote:
> > > Hi,
> > >
> > > I'm working on a CCTV application using AXIS IP cameras and I've
> > > managed to display a moving video feed from the camera in a Gambas
> > > application.
> > >
> > > I have two questions if anyone can help;
> > >
> > > a. Is there any way of getting a chunk of data acquired off the network
> > > into an image without doing; File.Save("/tmp/temp")
> > > obj.Picture.Flush
> > > obj.Picture = Picture["/tmp/temp"]
> > > (i.e. directly)
>
> Not at the moment. But you should do it this way:
>
> DIM hPict AS Picture
>
> File.Save("/tmp/xxxx")
> hPict = Picture.Load("/tmp/xxxx")
>
> By using "/tmp", and a tmpfs system file, you don't lose too much time
> writing a file and read it back.
>
> > > b. If I display the picture in the root of a Window, it's perfect.
> > > If I display the image in a PictureBox or a Button, if flickers very
> > > badly. Is there a trick to double buffering objects inside a window so
> > > they don't flicker on update ?
>
> Don't put a big picture inside a Button: the Button actually stores two
> versions of the picture you set: one normal, and one for the disabled
> version of the normal picture.
>
> The PictureBox will flicker less if its alignment property is set to
> TopLeft.
>
> But the ideal is using a DrawingArea with Cached = FALSE, and drawing the
> picture in the Draw event. Or with Cached = TRUE if your picture is not too
> big.
>
> > > (if it helps I'm running @ 5fps)
>
> Tell me if you can do better with my advices.
>
> Regards,

I just fixed the problem and commit in the svn see  
http://svn.sourceforge.net/gambas/?rev=436&view=rev

Regards,

-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 189 bytes
Desc: This is a digitally signed message part.
URL: <http://lists.gambas-basic.org/pipermail/user/attachments/20070713/1f3f5ac4/attachment.sig>


More information about the User mailing list