[Mono-dev] Bitmap return type remoting problem
buhochileno at gmail.com
buhochileno at gmail.com
Wed Nov 21 20:07:08 EST 2007
Sebastien Pouliot wrote:
> On Wed, 2007-11-21 at 18:01 -0300, buhochileno at gmail.com wrote:
>
>> Hi:
>>
>> I have a class (with the corrsponding interface) that have a method with
>> a Bitmap as a return type, something like:
>>
>> class c
>> {
>> Bitmap GetLastFrame()
>> {
>> return new Bitmap("/tmp/baboon.jpg");
>> }
>> }
>> I'm able to register the object with remoting and call other method,
>> properties, etc, but when I call the "GetLastFrame" method I get a "Null
>> or Invalid object value....", if I call the method without remoting all
>> work ok, but when I make the call from a client with remoting I get this
>> problem, ofcourse the "/tmp/baboon.jpg" file exist on the remoting
>> server....
>>
>> any sugestion?.
>>
>
> Yes, don't remote it.
>
> Seriously Bitmap may be serializable but :
> * it is probably (98%) not compatible with MS;
> * you would be serializing a lot of data since the Bitmap is
> uncompressed where the original JPEG file was much smaller
>
>
ok, I understend your point and I going to search about a small stream
such jpeg or other streaming approach, but for test porpuses, how can I
do something like that?, is posible in some way?.
thanks
Mauricio
> so return a (much smaller) stream/byte[] and rebuild the Bitmap on the
> client side.
>
> Sebastien
>
>
>
More information about the Mono-devel-list
mailing list