FLTK logo

Change an image when already loaded as Fl_()_Image

FLTK matrix user chat room
(using Element browser app)   FLTK gitter user chat room   GitHub FLTK Project   FLTK News RSS Feed  
  FLTK Apps      FLTK Library      Forums      Links     Login 
 All Forums  |  Back to fltk.general  ]
 
Previous Message ]New Message | Reply ]Next Message ]

Change an image when already loaded as Fl_()_Image Zoltan Phelps Mar 16, 2008  
 
I searched the forum but didn't find any suitable thread.
In my application i would like to show two images, one "original" version and one "altered" version (e.g. after LUT conversion).
My question is - how can i access the pixel data of an Fl_RGB_Image directly? The source code reveals only the "const char * const *data();" member function but as it is constant i'm not able to change anything. Is there another suitable way? Or is it better to just keep an unsigned char array with the pixel data, change it as desired and redraw it with the fl_draw_image function without creating any Fl_()_Image object? I'm a bit confused because with different libraries i used to create an image object and to alter its pixel data there had always been an access member function.
Thanks in advance!
ZP
Direct Link to Message ]
 
     
Previous Message ]New Message | Reply ]Next Message ]
 
 

Comments are owned by the poster. All other content is copyright 1998-2024 by Bill Spitzak and others. This project is hosted by The FLTK Team. Please report site problems to 'erco@seriss.com'.