meshlabxml/texture.py
def per_triangle(script, sidedim=0, textdim=1024, border=2, method=1):
    """Trivial Per-Triangle parameterization

    """
    filter_xml = ''.join([
        '  <filter name="Parametrization: Trivial Per-Triangle ">\n',
        '    <Param name="sidedim"',
        'value="%d"' % sidedim,
        'description="Quads per line"',
        'type="RichInt"',
        'tooltip="Indicates how many triangles have to be put on each line (every quad contains two triangles). Leave 0 for automatic calculation"',
        '/>\n',
        '    <Param name="textdim"',
        'value="%d"' % textdim,
        'description="Texture Dimension (px)"',
        'type="RichInt"',
        'tooltip="Gives an indication on how big the texture is"',
        '/>\n',
        '    <Param name="border"',
        'value="%d"' % border,
        'description="Inter-Triangle border (px)"',
        'type="RichInt"',
        'tooltip="Specifies how many pixels to be left between triangles in parametrization domain"',
        '/>\n',
        '    <Param name="method"',
        'value="%d"' % method,
        'description="Method"',
        'enum_val0="Basic"',
        'enum_val1="Space-optimizing"',
        'enum_cardinality="2"',
        'type="RichEnum"',
        'tooltip="Choose space optimizing to map smaller faces into smaller triangles in parametrizazion domain"'
        '/>\n',
        '  </filter>\n'])
    util.write_filter(script, filter_xml)
    return None
def per_triangle(script, sidedim=0, textdim=1024, border=2, method=1):
    """Trivial Per-Triangle parameterization

    """
    filter_xml = ''.join([
        '  <filter name="Parametrization: Trivial Per-Triangle ">\n',
        '    <Param name="sidedim"',
        'value="%d"' % sidedim,
        'description="Quads per line"',
        'type="RichInt"',
        'tooltip="Indicates how many triangles have to be put on each line (every quad contains two triangles). Leave 0 for automatic calculation"',
        '/>\n',
        '    <Param name="textdim"',
        'value="%d"' % textdim,
        'description="Texture Dimension (px)"',
        'type="RichInt"',
        'tooltip="Gives an indication on how big the texture is"',
        '/>\n',
        '    <Param name="border"',
        'value="%d"' % border,
        'description="Inter-Triangle border (px)"',
        'type="RichInt"',
        'tooltip="Specifies how many pixels to be left between triangles in parametrization domain"',
        '/>\n',
        '    <Param name="method"',
        'value="%d"' % method,
        'description="Method"',
        'enum_val0="Basic"',
        'enum_val1="Space-optimizing"',
        'enum_cardinality="2"',
        'type="RichEnum"',
        'tooltip="Choose space optimizing to map smaller faces into smaller triangles in parametrizazion domain"'
        '/>\n',
        '  </filter>\n'])
    util.write_filter(script, filter_xml)
    return None
def per_triangle ( script , sidedim = 0 , textdim = 1024 , border = 2 , method = 1 ) : filter_xml = '' . join ( [ '  <filter name="Parametrization: Trivial Per-Triangle ">\n' , '    <Param name="sidedim"' , 'value="%d"' % sidedim , 'description="Quads per line"' , 'type="RichInt"' , 'tooltip="Indicates how many triangles have to be put on each line (every quad contains two triangles). Leave 0 for automatic calculation"' , '/>\n' , '    <Param name="textdim"' , 'value="%d"' % textdim , 'description="Texture Dimension (px)"' , 'type="RichInt"' , 'tooltip="Gives an indication on how big the texture is"' , '/>\n' , '    <Param name="border"' , 'value="%d"' % border , 'description="Inter-Triangle border (px)"' , 'type="RichInt"' , 'tooltip="Specifies how many pixels to be left between triangles in parametrization domain"' , '/>\n' , '    <Param name="method"' , 'value="%d"' % method , 'description="Method"' , 'enum_val0="Basic"' , 'enum_val1="Space-optimizing"' , 'enum_cardinality="2"' , 'type="RichEnum"' , 'tooltip="Choose space optimizing to map smaller faces into smaller triangles in parametrizazion domain"' '/>\n' , '  </filter>\n' ] ) util . write_filter ( script , filter_xml ) return None
Trivial Per-Triangle parameterization
Trivial Per - Triangle parameterization