Ignore:
Timestamp:
01/24/17 17:55:00 (8 years ago)
Author:
epyon
Message:
  • temporary_proxy implemented
  • table_guard now uses temporary_proxy as main read functionality
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/engine/material_manager.cc

    r535 r539  
    6161        material* m = new material;
    6262
    63         if ( table.is_string( "path" ) )
     63        if ( table["path"].is_string() )
    6464        {
    65                 m->id = table.get_string128( "id" );
    66                 string128 path = table.get_string128( "path" );
     65                m->id = table["id"].get_string128();
     66                string128 path = table["path"].get_string128();
    6767                for ( uint32 i = 0; i < 5; ++i )
    6868                        m->paths[i] = path;
     
    8585        else
    8686        {
    87                 m->paths[ TEX_DIFFUSE ]  = table.get_string128( "diffuse" );
    88                 m->paths[ TEX_NORMAL ]   = table.get_string128( "normal" );
    89                 m->paths[ TEX_METALLIC]  = table.get_string128( "metallic" );
    90                 m->paths[ TEX_ROUGHNESS] = table.get_string128( "roughness" );
    91                 m->paths[ TEX_EMISSIVE ] = table.get_string128( "emissive" );
     87                m->paths[ TEX_DIFFUSE  ] = table[ "diffuse"   ].get_string128();
     88                m->paths[ TEX_NORMAL   ] = table[ "normal"    ].get_string128();
     89                m->paths[ TEX_METALLIC ] = table[ "metallic"  ].get_string128();
     90                m->paths[ TEX_ROUGHNESS] = table[ "roughness" ].get_string128();
     91                m->paths[ TEX_EMISSIVE ] = table[ "emissive"  ].get_string128();
    9292        }
    9393        add( id, m );
Note: See TracChangeset for help on using the changeset viewer.