Added Cycles image texture support for Sketchfab uploader
Open, NormalPublic

Description

Added Cycles image texture support

simple addition of cycles image texture nodes

for mat_slot in ob.material_slots:
    #CYCLES RENDER
    if bpy.context.scene.render.engine == 'CYCLES':
        if not mat_slot.material:
            continue
        if not mat_slot.material.node_tree:
            continue
        imgnodes = [n for n in mat_slot.material.node_tree.nodes if n.type == 'TEX_IMAGE']
        for node in imgnodes:
            if node.image is not None:
                images.add(node.image)
    #BLENDER RENDER
    else:
        if not mat_slot.material:
            continue
        for tex_slot in mat_slot.material.texture_slots:
            if not tex_slot:
                continue
            tex = tex_slot.texture
            if tex.type == 'IMAGE':
                image = tex.image
                if image is not None:
                    images.add(image)

Details

Type
Patch