[Bf-committers] Images in Panels..

Peter K.H. Gragert pkhgragert at gmail.com
Fri Jul 27 09:06:33 CEST 2012


Hallo
My experience in pictures:
http://www.petergragert.info/pmwiki/uploads/Kilon/bgl_error_2.jpg
This looks ok
but here
http://www.petergragert.info/pmwiki/uploads/Kilon/bgl_error_1.jpg

the file menu is transparent ??? and the small 'lady' is the wrong
picture???

That is a bug or not knowing enough about pictures space in Blender (2.63,
Vista, yesterday compiled)

Peter

2012/7/27 Campbell Barton <ideasman42 at gmail.com>

> On Fri, Jul 27, 2012 at 6:32 AM, Dima Glibitsky <dima.glib at gmail.com>
> wrote:
> >> you can use bgl to load your own textures on top of quads drawn by bgl.
> So yes its possible, but not simple, but also not difficult. Also you will
> also have to handle scrolling, since the bgl draw is separate from Blender
> main GUI , so that means a serious amount of code. But if you don't mind
> the extra works it won't be very hard. Bgl also will give some cooler
> tricks than Blender GUI because bgl is basically opengl 1.1 wrapper, so
> that gives some extra power to the coder.
> >
> > dimitris chloupis, is there any example of such a system? As far as I
> > know, Blender's python API gives no information about panel's
> > scrolling and layout, so even with bgl the addon-developer simply
> > doesn't know *where* to draw the quads.
>
> @Dima as far as I can see you're right, wile BGE can draw images we
> don't provide a way to draw then in panels. Keep in mind pythons
> draw() functions in panel classes in menus will setup the interface to
> draw _after_ - so you can't do any OpenGL drawing there.
>
>
> @dimitris - I dont think your explanation of `bgl` as buggy is really
> correct, bgl just wraps OpenGL - there isnt much to it,
> the issues you have are almost certainly issues dealing with sharing
> an OpenGL context with blender - which will free images from OpenGL
> memory to prevent running out of texture memory for unused textures in
> scenes.
>
>
> @Scott - you can currently draw textures in the 3D viewport so perhaps
> you can get some test script working, but don't think drawing textures
> in panels will be supported from python any time soon.
> _______________________________________________
> Bf-committers mailing list
> Bf-committers at blender.org
> http://lists.blender.org/mailman/listinfo/bf-committers
>


More information about the Bf-committers mailing list