Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.clipper.visual-objects > #12460

Re: bBrowser Image

From Franz Rachbauer <office@rachbauer.org>
Newsgroups comp.lang.clipper.visual-objects
Subject Re: bBrowser Image
Date 2019-04-28 09:43 +0200
Organization Aioe.org NNTP Server
Message-ID <qa3lih$i0$1@gioia.aioe.org> (permalink)
References <q9ujvf$qsd$1@gioia.aioe.org> <n809cepdeh6bmrgi2163sqhsq6i2ulg8uo@4ax.com> <2o69cehi3len561ava9h0qu85gqq6aa825@4ax.com> <qa3i8c$1ivm$1@gioia.aioe.org>

Show all headers | View raw


Got it, oImage shows in bBrowser, thanks to all!
Franz

LOCAL oBild AS FabPaintLib
LOCAL cString as STRING
LOCAL oImage as Bitmap

oBild := FabPaintLib { cFileJpg , SELF }
oBild:ResizeBilinear(150, 200)
oBild:AsStringFileFormat := "BMP"
cString := oBild:AsString
oImage := bBitmap{bimgCreateBitmapFromDibString(, cString)}

Am 28.04.2019 um 08:46 schrieb Franz Rachbauer:
> Hi Karl, hi Dirk,
> do you say with this examples that's not possible to convert an extern 
> JPG to bBrowser bBitmap with VO only code? Would it help if the files 
> are BMP instead of JPG?
> 
> Franz
> 
> Am 27.04.2019 um 20:12 schrieb Karl Faller:
>>> Converting a JPG to a BMP would be such a thing; this is all it takes
>>> in C#:
>>>
>>> public Bitmap ConvertToBitmap(string fileName)
>>> {
>>>     Bitmap bitmap;
>>>     using(Stream bmpStream = System.IO.File.Open(fileName,
>>> System.IO.FileMode.Open ))
>>>     {
>>>          Image image = Image.FromStream(bmpStream);
>>>
>>>          bitmap = new Bitmap(image);
>>>
>>>     }
>>>     return bitmap;
>>> }
>> And this is the X# Version, less braces  ;)
>>
>> FUNC ConvertToBitmap(fileName AS  STRING ) AS Bitmap
>>     VAR     bmpStream := System.IO.File.Open(fileName,;
>> System.IO.FileMode.Open )
>>     VAR  myImage := Image.FromStream(bmpStream)
>>     VAR myBitmap :=Bitmap{myImage}
>>   // mybitmap:Save( "C:\Users\Karl\Pictures\Screenshots\test.bmp")
>> //  to write it back...
>> Return myBitmap
>> Regards
>>
>> Karl
>>
> 

Back to comp.lang.clipper.visual-objects | Previous | Next — Previous in thread | Find similar | Unroll thread


Thread

bBrowser Image Franz Rachbauer <office@rachbauer.org> - 2019-04-26 11:45 +0200
  Re: bBrowser Image D.J.W. van Kooten <vankooten@removethis.ic2.com> - 2019-04-27 18:21 +0200
    Re: bBrowser Image Karl Faller <mail_withoutthat_@_drei-f_andthat_.de> - 2019-04-27 20:12 +0200
      Re: bBrowser Image Franz Rachbauer <office@rachbauer.org> - 2019-04-28 08:46 +0200
        Re: bBrowser Image Franz Rachbauer <office@rachbauer.org> - 2019-04-28 09:43 +0200

csiph-web