[Ves] Questions on ViewerApp shader initialization
Pat Marion
pat.marion at kitware.com
Fri Apr 19 00:07:53 EDT 2013
Hi David,
1. vesKiwiViewerApp serves as the main app logic for KiwiViewer, but it's
not a great general base class, so improvements would be great! I'd like
to see all the shader management removed from vesKiwiViewerApp, and
relocated into a new standalone class.
2. The Uniforms vector, and the other vectors declared there, are relics
from before kiwi and ves libraries used shared_ptr. The vectors were for
ownership. If you are going over this code, please remove them if you can.
Pat
On Fri, Apr 19, 2013 at 1:30 PM, David Thompson
<david.thompson at kitware.com>wrote:
> Hi all,
>
> I have some questions and/or suggestions for the way vesKiwiViewerApp
> handles shaders.
>
> 1. It is great to have a variety of shaders available, but I don't
> understand why the app makes it difficult to have multiple instances of the
> same shader with different uniforms. This is especially important for the
> clip shader as it would be nice to have several actors with different clip
> planes. It would be nice to just call this->newClipShader() on the app and
> get a new shader out. Or have a "clone()" method on vesShaderProgram.
>
> 2. Is there a reason for having shader uniforms collected in
> vesKiwiBaseApp::vesInternal::Uniforms? They appear never to be retrieved
> anywhere in vesKiwiBaseApp.cpp and -- because the vesInternal class is
> private and defined only in that file -- are not accessible elsewhere. I
> ask because if the Uniforms vector was removed, the shader creation
> functions in the viewer could be static methods that returned shader
> programs. Which would be nice.
>
> Thanks,
> David
> _______________________________________________
> Ves mailing list
> Ves at public.kitware.com
> http://public.kitware.com/cgi-bin/mailman/listinfo/ves
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://public.kitware.com/pipermail/ves/attachments/20130419/1dbffdb1/attachment-0001.html>
More information about the Ves
mailing list