INNER CODE UNIT · Python

g3

bernhardstrobl/Pico3D · Blender/pico3d_blender_exporter.py:383

                    g3 = hex(int((colors.data[tri.loops[2]].color[1]) * 15))
                    b3 = hex(int((colors.data[tri.loops[2]].color[2]) * 15))
                    

                                    
                    #Shader ID
                    #if all the colors are the same, we can use shader id 1 for simple flat shading
                    if (r1 == r2 == r3 and g1 == g2 == g3 and b1 == b2 == b3):
                        if glow:
                            shader_id = 11
                        else:
                            shader_id = 1
                    else:
                        if glow:
                            shader_id = 12
                        else:    
                            shader_id = 2
                    

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…