|
From: James T. <ja...@fl...> - 2019-02-05 12:41:21
|
> On 5 Feb 2019, at 12:30, Nikolai Verner Christensen <emp...@gm...> wrote:
>
> I sorta gave up on making this. My C++ is not good enough to do it.
> So, I am hoping somebody else will step up and make this method.
> This is how far I got (inside simgear/canvas/elements/CanvasImage.cxx)
>
> //----------------------------------------------------------------------------
> void Image::setPixelBlock(int s, int t, int w, int h, float [] *data)
> {
> osg::Image img = _texture->getImage();
> osg::Image subImg = new osg::Image();
> subImg->setImage(w,h,1, GL_RGBA, GL_RGBA, GL_FLOAT, data, osg::Image::AllocationMode->USE_MALLOC_FREE,1);
> img->copySubImage(s,t,1,subImg);
> }
I’m wanting to take this forward since I’ve love to get a working TERRain mode on the 737 MAP display.
Is this one function the only API you need added, or is there more context? Especially, so I can test?
Kind regards,
James |