Browse Source

Sort spans for opacity modifiers

pull/87/head
Darryl Pogue 7 years ago
parent
commit
1ee4c5be51
No known key found for this signature in database
GPG Key ID: CB824715C3E6FD41
  1. 2
      korman/exporter/mesh.py
  2. 4
      korman/properties/modifiers/render.py

2
korman/exporter/mesh.py

@ -83,7 +83,7 @@ class _DrawableCriteria:
if mod.requires_face_sort: if mod.requires_face_sort:
self.criteria |= plDrawable.kCritSortFaces self.criteria |= plDrawable.kCritSortFaces
if mod.requires_span_sort: if mod.requires_span_sort:
self.sort_spans |= plDrawable.kCritSortSpans self.criteria |= plDrawable.kCritSortSpans
self.render_level = _RenderLevel(bo, hsgmat, pass_index, self.blend_span) self.render_level = _RenderLevel(bo, hsgmat, pass_index, self.blend_span)
def __eq__(self, other): def __eq__(self, other):

4
korman/properties/modifiers/render.py

@ -81,6 +81,10 @@ class PlasmaFadeMod(PlasmaModifierProperties):
mod.farOpaq = self.far_opaq mod.farOpaq = self.far_opaq
mod.farTrans = self.far_trans mod.farTrans = self.far_trans
@property
def requires_span_sort(self):
return True
class PlasmaFollowMod(idprops.IDPropObjectMixin, PlasmaModifierProperties): class PlasmaFollowMod(idprops.IDPropObjectMixin, PlasmaModifierProperties):
pl_id = "followmod" pl_id = "followmod"

Loading…
Cancel
Save