Merge pull request #393 from ChrisMickelson/unstable_current

Fix for issue #383
This commit is contained in:
Wes Cravens 2018-02-02 08:42:20 -06:00 committed by GitHub
commit de7f7b308b
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -197,17 +197,24 @@ public abstract class RocketRenderer {
}
private void renderTree( GL2 gl, final Collection<Geometry> geometryList){
//cycle through opaque components first, then transparent to preserve proper depth testing
for(Geometry geom: geometryList ) {
if( geom.active ) {
if( isDrawnTransparent( (RocketComponent)geom.obj) ){
// Draw T&T front faces blended, without depth test
renderComponent(gl, geom, 0.2f);
}else{
renderComponent(gl, geom, 1.0f);
if( geom.active ) {
//if not transparent
if( !isDrawnTransparent( (RocketComponent)geom.obj) ){
renderComponent(gl, geom, 1.0f);
}
}
}
for(Geometry geom: geometryList ) {
if( geom.active ) {
if( isDrawnTransparent( (RocketComponent)geom.obj) ){
// Draw T&T front faces blended, without depth test
renderComponent(gl, geom, 0.2f);
}
}
}
}
}
private void renderMotors(GL2 gl, FlightConfiguration configuration) {
// FlightConfigurationId motorID = configuration.getFlightConfigurationID();