I was just wondering if anyone had figured out how to get AA working in conjuction with the Filtermanager?
Cos Im very close to giving myself mild concussion from repeatedly banging my head against my desk.
For those that are not aware AA doesnt work if you use any of the common filters or set up your own with Filtermanager.
The strange thing is it does work if you set it all up by hand.
i.e turning on AA on Tut-Glow-advance.py seems to work as it doesnt use filterManager and sets up the buffers by hand but Tut-Glow-Basic.py doesnt as it uses CommonFilters.
its a bit of a hack right now and I still need to figure out exactly whats happening. Only works with a few of the Commonfilters like bloom. but defo works with my own shaders.
FilterManager.py
def __init__(self, win, cam, forcex=0, forcey=0):
self.firstbuffer=True
ect.....
def createBuffer(self, name, xsize, ysize, texgroup, depthbits=1):
""" Low-level buffer creation. Not intended for public use. """
winprops = WindowProperties()
winprops.setSize(xsize, ysize)
depthtex, colortex, auxtex0, auxtex1 = texgroup
if self.firstbuffer==True:
props=base.win.getFbProperties()
else:
props=FrameBufferProperties()
props.setRgbColor(1)
props.setDepthBits(depthbits)
if (auxtex0 != None):
props.setAuxRgba(1)
if (auxtex1 != None):
props.setAuxRgba(2)
buffer=base.graphicsEngine.makeOutput(
self.win.getPipe(), name, -1,
props, winprops, GraphicsPipe.BFRefuseWindow | GraphicsPipe.BFResizeable,
self.win.getGsg(), self.win)
if (buffer == None):
return buffer
if (depthtex):
buffer.addRenderTexture(depthtex, GraphicsOutput.RTMBindOrCopy, GraphicsOutput.RTPDepth)
if (colortex):
buffer.addRenderTexture(colortex, GraphicsOutput.RTMBindOrCopy, GraphicsOutput.RTPColor)
if (auxtex0):
buffer.addRenderTexture(auxtex0, GraphicsOutput.RTMBindOrCopy, GraphicsOutput.RTPAuxRgba0)
if (auxtex1):
buffer.addRenderTexture(auxtex1, GraphicsOutput.RTMBindOrCopy, GraphicsOutput.RTPAuxRgba1)
buffer.setSort(self.nextsort)
buffer.disableClears()
buffer.getDisplayRegion(0).disableClears()
self.nextsort += 1
#jedi
#print "filtermanager buffer properties",buffer.getFbProperties()
#endjdi
self.firstbuffer=False
return buffer
ect...