Re: [visad] Save modified Images

Hi Devanshi,

> I have tried to use save method of loci.formats.out.AVIWriter
...
> So, byte[] will store the single file only. what if I want to store
animated
> series of images in .avi form.

Do not use loci.formats.* API. Use this method:

visad.data.bio.LociForm.save(String, Data, boolean)

> 2) And how to capture and save rotating image.

See Test50, Test51 and Test52 for examples of capturing the displayed image
of a Java2D or Java3D window or offscreen rendering.

But hooking these two things together (capturing an AVI movie of a rotating
display) is not trivial to do. You would need to capture the BufferedImages
and wrap them back into a VisAD Data object again using a
visad.ImageFlatField. There is no existing code to make this easier.

It might be easier to record your rotating image with an external screen
capture / screencast tool, depending what you need it for.

Regards,
Curtis


On Wed, May 21, 2014 at 11:56 PM, Devanshi Prajapati <
prajapati.devanshi@xxxxxxxxx> wrote:

> Hello Sir,
>
> I have tried to use save method of loci.formats.out.AVIWriter in Example,
> P5_10, by Ugo Taddei sir.
> The format is : public void saveBytes(int no,  byte[] buf,int x,
> int y,int w, int h)
>                throws 
> FormatException<http://downloads.openmicroscopy.org/bio-formats/5.0.1/api/loci/formats/FormatException.html>,
> IOException<http://docs.oracle.com/javase/6/docs/api/java/io/IOException.html?is-external=true>
>
> So, byte[] will store the single file only. what if I want to store
> animated series of images in .avi form.
>
>
> 2) And how to capture and save rotating image. I have rotate it using
> viewpointControl.
>
>
> On Fri, May 9, 2014 at 1:07 AM, Curtis Rueden <ctrueden@xxxxxxxx> wrote:
>
>> Hi Devanshi,
>>
>> > Is it possible to save , modified images and animation (in .avi form)
>> > in visAD??
>>
>> You can use the visad.data.bio.LociForm's save method to save a data
>> object to one of the Bio-Formats-supported formats, which includes AVI.
>> Note that this is only uncompressed AVI though. If you are trying to
>> "seriously" work with AVIs using any modern codec, you will be much better
>> off leaning on a tool like FFMPEG or similar.
>>
>> > how to get the content rendered in display screen
>>
>> Note that the solution above saves VisAD Data objects. See Test50, Test51
>> and Test52 for examples of capturing the displayed image of a Java2D or
>> Java3D window or offscreen rendering.
>>
>> Regards,
>> Curtis
>>
>>
>> On Thu, May 8, 2014 at 4:39 AM, Devanshi Prajapati <
>> prajapati.devanshi@xxxxxxxxx> wrote:
>>
>>>
>>> Hello All,
>>>
>>> Is it possible to save , modified images and animation (in .avi form) in
>>> visAD??
>>>
>>> I have tried by capturing the scalarmaps on display but how to get the
>>> content rendered in display screen and how to save it.
>>>
>>> Is there any adapters there to save data objects?
>>>
>>> Currently I am trying to find this in loci.formats and displayMaster
>>> classes.
>>>
>>> --
>>> Thank you
>>>  Devanshi U. Prajapati
>>> LJIET(MCA)
>>>
>>> _______________________________________________
>>> visad mailing list
>>> visad@xxxxxxxxxxxxxxxx
>>> For list information, to unsubscribe, visit:
>>> http://www.unidata.ucar.edu/mailing_lists/
>>>
>>>
>>
>
>
> --
> Devanshi U. Prajapati
> LJIET(MCA)
>
  • 2014 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the visad archives: