Changeset 348 for cpp/frams/_demos


Ignore:
Timestamp:
04/09/15 23:51:28 (9 years ago)
Author:
Maciej Komosinski
Message:
  • explicit c_str() in SString instead of (const char*) cast
  • genetic converters and GenMan? are now thread-local which enables multi-threaded simulator separation
Location:
cpp/frams/_demos
Files:
20 edited

Legend:

Unmodified
Added
Removed
  • cpp/frams/_demos/f0_variants_test.cpp

    r286 r348  
    7979DefaultGenoConvManager gcm;
    8080gcm.addDefaultConverters();
    81 Geno::useConverters(gcm);
     81Geno::useConverters(&gcm);
    8282
     83Geno::Validators validators;
     84Geno::useValidators(&validators);
    8385ModelGenoValidator model_validator;
    84 Geno::addValidator(&model_validator); //This simple validator handles all cases where a converter for a particular format is available but there is no genetic operator. Converters may be less strict in detecting invalid genotypes but it is better than nothing
     86validators+=&model_validator; //This simple validator handles all cases where a converter for a particular format is available but there is no genetic operator. Converters may be less strict in detecting invalid genotypes but it is better than nothing
    8587
    8688SString gen(argc>1?argv[1]:"X[|G:1.23]");
    87 if (!strcmp(gen,"-"))
     89if (!strcmp(gen.c_str(),"-"))
    8890        {
    8991        gen=0;
     
    9294        }
    9395Geno g(gen);
    94 printf("\nSource genotype: '%s'\n",(const char*)g.getGene());
     96printf("\nSource genotype: '%s'\n",g.getGene().c_str());
    9597printf("                  ( format %c %s)\n",
    96        g.getFormat(), (const char*)g.getComment());
     98       g.getFormat(), g.getComment().c_str());
    9799
    98100Model m(g);//.getConverted('0'));
     
    112114save_as_f0(f0_no_skipping_defaults,m,false);
    113115
    114 printf("\n==== with defdata (skips default values) ======\n%s\n",(const char*)f0_skipping_defaults);
    115 printf("\n==== without defdata (saves all fields) ======\n%s\n",(const char*)f0_no_skipping_defaults);
     116printf("\n==== with defdata (skips default values) ======\n%s\n",f0_skipping_defaults.c_str());
     117printf("\n==== without defdata (saves all fields) ======\n%s\n",f0_no_skipping_defaults.c_str());
    116118
    117119return 0;
  • cpp/frams/_demos/full_props.cpp

    r286 r348  
    9797Geno f0_g;
    9898m.makeGeno(f0_g,NULL,reverse);//third arg is "handle_defaults" == whether f0 should omit default property values
    99 puts((const char*)f0_g.toString());
     99puts(f0_g.toString().c_str());
    100100
    101101return 0;
  • cpp/frams/_demos/geno_test.cpp

    r286 r348  
    2424        }
    2525SString gen(argv[1]);
    26 if (!strcmp(gen,"-"))
     26if (!strcmp(gen.c_str(),"-"))
    2727        {
    2828        gen=0;
  • cpp/frams/_demos/genoconv_test.cpp

    r286 r348  
    7777{
    7878SString dst;
    79 const char* src=in;
     79const char* src=in.c_str();
    8080const char* t;
    8181int insideneuron=0;
     
    112112{
    113113printf("Genotype:\n%s\nFormat: %c\nValid: %s\nComment: %s\n",
    114         (const char*)g.getGene(),g.getFormat(),g.isValid()?"yes":"no",(const char*)g.getComment());
     114        g.getGene().c_str(),g.getFormat(),g.isValid()?"yes":"no",g.getComment().c_str());
    115115}
    116116
     
    124124gcm.addConverter(new GenoConv_Test2());
    125125gcm.addConverter(new GenoConv_Test3());
    126 Geno::useConverters(gcm);
     126Geno::useConverters(&gcm);
    127127
     128Geno::Validators validators;
    128129ModelGenoValidator model_validator;
    129 Geno::addValidator(&model_validator);
     130validators+=&model_validator;
     131Geno::useValidators(&validators);
    130132
    131133const char* src=(argc>1)?argv[1]:"X";
  • cpp/frams/_demos/genomanipulation.cpp

    r291 r348  
    3434        const char* type=pi.type(i);
    3535        if (*type=='p') continue;
    36         printf("%2d. %8s = %-20s %-3s %-10s  %-10s\n",i,pi.id(i),(const char*)pi.get(i),pi.type(i),pi.name(i),pi.grname(pi.group(i)));
     36        printf("%2d. %8s = %-20s %-3s %-10s  %-10s\n",i,pi.id(i),pi.get(i).c_str(),pi.type(i),pi.name(i),pi.grname(pi.group(i)));
    3737        }
    3838}
     
    4747pi.getMinMax(i,minprop,maxprop,def);
    4848printf("      Change property #%d to random value from range [%g..%g]\n",i,minprop,maxprop);
    49 printf("      Current value of '%s' (%s) is '%s'\n",pi.id(i),pi.name(i),(const char*)pi.get(i));
     49printf("      Current value of '%s' (%s) is '%s'\n",pi.id(i),pi.name(i),pi.get(i).c_str());
    5050char t[100];
    5151sprintf(t,"%g",minprop+(rnd01)*(maxprop-minprop));
    5252printf("      Setting new value... [ using ParamInterface::set() ]\n");
    5353pi.set(i,t);
    54 printf("      The value is now '%s'\n",(const char*)pi.get(i));
     54printf("      The value is now '%s'\n",pi.get(i).c_str());
    5555}
    5656
     
    7979CHANGE_ONE_PROPERTY(p->extraProperties());
    8080p->getModel().close();
    81 printf("\nLet's see f0... (check out part #%d !)\n\n%s\n", p->refno, (const char*)p->getModel().getF0Geno().getGene());
     81printf("\nLet's see f0... (check out part #%d !)\n\n%s\n", p->refno, p->getModel().getF0Geno().getGene().c_str());
    8282}
    8383
     
    9191j->getModel().close();
    9292printf("The Part's position is changed, but everything else stays intact:\n\n%s\n",
    93        (const char*)j->getModel().getF0Geno().getGene());
     93       j->getModel().getF0Geno().getGene().c_str());
    9494}
    9595
     
    104104j->getModel().close();
    105105printf("Position of the second Part referenced by this joint (part #%d) is now changed:\n\n%s\n",
    106        j->part2->refno, (const char*)j->getModel().getF0Geno().getGene());
     106       j->part2->refno, j->getModel().getF0Geno().getGene().c_str());
    107107printf("If no delta fields are defined, they will be computed automatically.\n"
    108108       "You can always delete existing delta values by using Joint::resetDelta().\n"
     
    112112j->resetDelta();
    113113j->getModel().close();
    114 printf("As you can see, Joint's delta fields have altered:\n\n%s\n", (const char*)j->getModel().getF0Geno().getGene());
     114printf("As you can see, Joint's delta fields have altered:\n\n%s\n", j->getModel().getF0Geno().getGene().c_str());
    115115}
    116116
     
    123123j->getModel().close();
    124124printf("f0 is now:\n\n%s\n...so this is %s joint.\n",
    125        (const char*)j->getModel().getF0Geno().getGene(), option?"a delta":"an absolute");
     125       j->getModel().getF0Geno().getGene().c_str(), option?"a delta":"an absolute");
    126126
    127127}
     
    155155CHANGE_ONE_PROPERTY(j->extraProperties());
    156156j->getModel().close();
    157 printf("And after that we have this genotype:\n\n%s\n", (const char*)j->getModel().getF0Geno().getGene());
     157printf("And after that we have this genotype:\n\n%s\n", j->getModel().getF0Geno().getGene().c_str());
    158158}
    159159
     
    178178printf("\nThe most unusual thing is 'details' field (d).\n"
    179179       "It is something like separate object with its own set of properties.\n"
    180        "Currently the value of 'd' is '%s'.\n",(const char*)n->getDetails());
     180       "Currently the value of 'd' is '%s'.\n",n->getDetails().c_str());
    181181
    182182{
    183183NeuroClass* cl=n->getClass();
    184184if (!cl)
    185         printf("It should contain the class name but the meaning of '%s' is unknown\n",(const char*)n->getDetails());
     185        printf("It should contain the class name but the meaning of '%s' is unknown\n",n->getDetails().c_str());
    186186else
    187187{
    188188
    189189printf("'%s' is the class name (Neuro::getClassName() == '%s') and means '%s'.\n",
    190        (const char*)cl->getName(),(const char*)cl->getName(),(const char*)cl->getLongName());
     190       cl->getName().c_str(),cl->getName().c_str(),cl->getLongName().c_str());
    191191printf("Neuro::getClass() gives you information about basic characteristic\n"
    192192       "of the class, that can be analyzed automatically.\n");
     
    208208        p.update();
    209209        n->getModel().close();
    210         printf("After that, 'details' contains the new object: '%s'.\n",(const char*)n->getDetails());
     210        printf("After that, 'details' contains the new object: '%s'.\n",n->getDetails().c_str());
    211211        }
    212212else
     
    224224        NeuroClass* cl=n->getClass(i);
    225225        Param p=cl->getProperties();
    226         printf("%2d.%6s  %-20s  %2d\n",i,(const char*)cl->getName(),(const char*)cl->getLongName(),p.getPropCount());
     226        printf("%2d.%6s  %-20s  %2d\n",i,cl->getName().c_str(),cl->getLongName().c_str(),p.getPropCount());
    227227        }
    228228int cl=rand() % n->getClassCount();
    229 printf("\nLet's change the Neuro's class to '%s'...\n",(const char*)n->getClassName(cl));
     229printf("\nLet's change the Neuro's class to '%s'...\n",n->getClassName(cl).c_str());
    230230n->getModel().open();
    231231n->setClass(n->getClass(cl));
     
    242242if (n->getInputCount()>0)
    243243{
    244         printf("Info for input #0 = \"%s\"\n",(const char*)n->getInputInfo(0));
    245         printf("Info for input #0, field \"%s\" = \"%s\"\n", "abc", (const char*)n->getInputInfo(0,"abc"));
     244        printf("Info for input #0 = \"%s\"\n",n->getInputInfo(0).c_str());
     245        printf("Info for input #0, field \"%s\" = \"%s\"\n", "abc", n->getInputInfo(0,"abc").c_str());
    246246        n->setInputInfo(0,"test",44);
    247247        n->setInputInfo(0,"abc","yeah");
     
    250250n->getModel().close();
    251251printf("The final object description will be then: '%s'\nAnd the full f0 genotype:\n\n%s\n",
    252        (const char*)n->getDetails(), (const char*)n->getModel().getF0Geno().getGene());
     252       n->getDetails().c_str(), n->getModel().getF0Geno().getGene().c_str());
    253253
    254254
     
    257257void findingConverters()
    258258{
    259 GenoConverter *gc=Geno::getConverters().findConverters(0,'1');
     259GenoConverter *gc=Geno::getConverters()->findConverters(0,'1');
    260260if (gc) printf("found converter accepting f1: \"%s\"\n",gc->name);
    261261SListTempl<GenoConverter*> found;
    262 Geno::getConverters().findConverters(&found,-1,'0');
     262Geno::getConverters()->findConverters(&found,-1,'0');
    263263printf("found %d converter(s) producing f0\n",found.size());
    264264}
     
    274274
    275275SString gen(argc>1?argv[1]:"X[|G:1.23]");
    276 if (!strcmp(gen,"-"))
     276if (!strcmp(gen.c_str(),"-"))
    277277        {
    278278        gen=0;
     
    281281        }
    282282Geno g(gen);
    283 printf("\nSource genotype: '%s'\n",(const char*)g.getGene());
     283printf("\nSource genotype: '%s'\n",g.getGene().c_str());
    284284printf("                  ( format %c %s)\n",
    285        g.getFormat(), (const char*)g.getComment());
     285       g.getFormat(), g.getComment().c_str());
    286286
    287287Model m(g);//.getConverted('0'));
     
    292292        return 2;       
    293293        }
    294 printf("Converted to f0:\n%s\n",(const char*)m.getF0Geno().getGene());
     294printf("Converted to f0:\n%s\n",m.getF0Geno().getGene().c_str());
    295295
    296296printf("Model contains: %d part(s)\n"
     
    340340                NeuroItem *ni=n->getNeuroItem(j);
    341341                printf("        item #%d - '%s', conn=%d, weight=%g\n",
    342                        j,(const char*)ni->getDetails(),ni->conn_refno,ni->weight);
     342                       j,ni->getDetails().c_str(),ni->conn_refno,ni->weight);
    343343                }
    344344        }
  • cpp/frams/_demos/genooper_test.cpp

    r286 r348  
    99{
    1010        printf("Genotype: %s\nFormat: %c\nValid: %s\nComment: %s\n",
    11                 (const char*)g.getGene(), g.getFormat(), g.isValid() ? "yes" : "no", g.getComment().len() == 0 ? "(empty)" : (const char*)g.getComment());
     11                g.getGene().c_str(), g.getFormat(), g.isValid() ? "yes" : "no", g.getComment().len() == 0 ? "(empty)" : g.getComment().c_str());
    1212}
    1313
     
    4747        printGenAndTitle(gvalidated, "validated");
    4848
    49         printf("\nHTMLized: %s\n", (const char*)genetics.genman.HTMLize((const char*)gvalidated.getGene()));
     49        printf("\nHTMLized: %s\n", genetics.genman.HTMLize(gvalidated.getGene().c_str()).c_str());
    5050
    5151        return 0;
  • cpp/frams/_demos/geometry/apices_test.cpp

    r286 r348  
    4747        // Finishing result Model and printing its genotype.
    4848        resultModel.close();
    49         puts((const char*)resultModel.getF0Geno().toString());
     49        puts(resultModel.getF0Geno().toString().c_str());
    5050}
    5151
  • cpp/frams/_demos/geometry/geometrytestutils.cpp

    r318 r348  
    2525               
    2626                fprintf(stderr, "%d. (%6d chars) %s\n", count, genotype->genotype.len(),
    27                         (const char*)genotype->name);
     27                        genotype->name.c_str());
    2828        }
    2929       
    3030        if (loader.getStatus() == MiniGenotypeLoader::OnError)
    3131        {
    32                 fprintf(stderr, "Error: %s\n", (const char*)loader.getError());
     32                fprintf(stderr, "Error: %s\n", loader.getError().c_str());
    3333                return 2;
    3434        }
     
    5858                count++;
    5959               
    60                 if ((genoIndex == count) || (strcmp((const char*)genotype->name, genoName) == 0))
     60                if ((genoIndex == count) || (strcmp(genotype->name.c_str(), genoName) == 0))
    6161                {
    6262                        Model model(genotype->genotype);
     
    7575        if (loader.getStatus() == MiniGenotypeLoader::OnError)
    7676        {
    77                 fprintf(stderr, "Error: %s\n", (const char*)loader.getError());
     77                fprintf(stderr, "Error: %s\n", loader.getError().c_str());
    7878                return 2;
    7979        }
     
    156156                "GENO_ID - either genotype name or index (1-based)\n"
    157157                "SHAPE - 1=ellipsoid, 2=cuboid, 3=cylinder, others or none=random\n",
    158                 (const char*)header);
     158                header.c_str());
    159159        return 1;
    160160}
     
    220220                "DENSITY - minimal number of samples per unit\n"
    221221                "SHAPE - 1=ellipsoid, 2=cuboid, 3=cylinder, others or none=random\n",
    222                 (const char*)header);
     222                header.c_str());
    223223        return 1;
    224224}
  • cpp/frams/_demos/geometry/info_test.cpp

    r286 r348  
    7272        // Finishing result Model and printing its genotype.
    7373        resultModel.close();
    74         puts((const char*)resultModel.getF0Geno().toString());
     74        puts(resultModel.getF0Geno().toString().c_str());
    7575       
    7676        // Printing calculated values.
  • cpp/frams/_demos/geometry/surface_test.cpp

    r286 r348  
    4747        // Finishing result Model and printing its genotype.
    4848        resultModel.close();
    49         puts((const char*)resultModel.getF0Geno().toString());
     49        puts(resultModel.getF0Geno().toString().c_str());
    5050}
    5151
  • cpp/frams/_demos/geometry/volume_test.cpp

    r286 r348  
    3939        // Finishing result Model and printing its genotype.
    4040        resultModel.close();
    41         puts((const char*)resultModel.getF0Geno().toString());
     41        puts(resultModel.getF0Geno().toString().c_str());
    4242}
    4343
  • cpp/frams/_demos/loader_test.cpp

    r299 r348  
    4545                else
    4646                        {
    47                         if (strcmp((const char*)loaded->name,selected))
     47                        if (strcmp(loaded->name.c_str(),selected))
    4848                                continue;
    4949                        }
    50                 puts((const char*)loaded->genotype);
     50                puts(loaded->genotype.c_str());
    5151                return 0;
    5252                }
    53         fprintf(stderr,"%d. %s\t(%d characters)\n",count,(const char*)loaded->name,loaded->genotype.len());
     53        fprintf(stderr,"%d. %s\t(%d characters)\n",count,loaded->name.c_str(),loaded->genotype.len());
    5454        }
    5555// the loop repeats until loaded==NULL, which could be beacause of error
    5656if (loader.getStatus()==MiniGenotypeLoader::OnError)
    57         fprintf(stderr,"Error: %s",(const char*)loader.getError());
     57        fprintf(stderr,"Error: %s",loader.getError().c_str());
    5858// (otherwise it was the end of the file)
    5959if (selected)
  • cpp/frams/_demos/loader_test_param.cpp

    r330 r348  
    8484                {
    8585                case MultiParamLoader::OnComment:
    86                         fprintf(stderr, "comment: '%s'\n", (const char*)loader.getComment());
     86                        fprintf(stderr, "comment: '%s'\n", loader.getComment().c_str());
    8787                        break;
    8888
     
    9292                        // In fact, this method is used not just for truly unknown objects but also for
    9393                        // dynamic objects that cannot be added using MultiParamLoader.addObject().
    94                         fprintf(stderr, "unknown object found: '%s' (will be skipped)\n", (const char*)loader.getObjectName());
     94                        fprintf(stderr, "unknown object found: '%s' (will be skipped)\n", loader.getObjectName().c_str());
    9595                        break;
    9696
     
    9898                        fprintf(stderr, "loaded:\n");
    9999                        for (int i = 0; i < param.getPropCount(); i++)
    100                                 fprintf(stderr, "%s=%s\n", param.id(i), (const char*)param.getText(i));
    101                         fprintf(stderr, "type of 'x1' is: %s\n", (const char*)data.x1.typeDescription());
    102                         fprintf(stderr, "type of 'x2' is: %s\n", (const char*)data.x2.typeDescription());
     100                                fprintf(stderr, "%s=%s\n", param.id(i), param.getText(i).c_str());
     101                        fprintf(stderr, "type of 'x1' is: %s\n", data.x1.typeDescription().c_str());
     102                        fprintf(stderr, "type of 'x2' is: %s\n", data.x2.typeDescription().c_str());
    103103                        fprintf(stderr, "-----\n\n");
    104104                        param.save(&virt_stdout);
     
    112112
    113113                case MultiParamLoader::OnError:
    114                         fprintf(stderr, "Error: %s", (const char*)loader.getError());
     114                        fprintf(stderr, "Error: %s", loader.getError().c_str());
    115115                }
    116116        }
  • cpp/frams/_demos/multiline_f0_test.cpp

    r286 r348  
    1919
    2020SString gen(argc>1?argv[1]:"X[|G:1.23]");
    21 if (!strcmp(gen,"-"))
     21if (!strcmp(gen.c_str(),"-"))
    2222        {
    2323        gen=0;
     
    2626        }
    2727Geno g(gen);
    28 printf("\nSource genotype: '%s'\n",(const char*)g.getGene());
     28printf("\nSource genotype: '%s'\n",g.getGene().c_str());
    2929printf("                  ( format %c %s)\n",
    30        g.getFormat(), (const char*)g.getComment());
     30       g.getFormat(), g.getComment().c_str());
    3131
    3232Model m(g);//.getConverted('0'));
     
    3737        return 2;       
    3838        }
    39 printf("Converted to f0:\n%s\n",(const char*)m.getF0Geno().getGene());
     39printf("Converted to f0:\n%s\n",m.getF0Geno().getGene().c_str());
    4040
    4141printf("\nusing Param::save() to create the \"expanded\" form of the f0 genotype...\n(MultiParamLoader should be able to load this)");
     
    8787        }
    8888
    89 printf("\n============================\n%s\n",(const char*)f.getString());
     89printf("\n============================\n%s\n",f.getString().c_str());
    9090
    9191return 0;
  • cpp/frams/_demos/neuro_layout_test.cpp

    r317 r348  
    9494        }
    9595SString gen(argv[1]);
    96 if (!strcmp(gen,"-"))
     96if (!strcmp(gen.c_str(),"-"))
    9797        {
    9898        gen=0;
     
    116116        {
    117117        int *xywh=nn_layout.GetXYWH(i);
    118         printf("#%-3d %s\t%d,%d\t%dx%d\n",i,(const char*)m.getNeuro(i)->getClassName(),
     118        printf("#%-3d %s\t%d,%d\t%dx%d\n",i,m.getNeuro(i)->getClassName().c_str(),
    119119               xywh[0],xywh[1],xywh[2],xywh[3]);
    120120        }
     
    130130        {
    131131        int *xywh=nn_layout.GetXYWH(i);
    132         SString label=SString::sprintf("%d:%s",i,(const char*)m.getNeuro(i)->getClassName());
    133         screen.put(xywh[0],xywh[1],(const char*)label);
     132        SString label=SString::sprintf("%d:%s",i,m.getNeuro(i)->getClassName().c_str());
     133        screen.put(xywh[0],xywh[1],label.c_str());
    134134        }
    135135screen.print();
  • cpp/frams/_demos/neuro_test.cpp

    r288 r348  
    6969        }
    7070SString gen(argv[1]);
    71 if (!strcmp(gen,"-"))
     71if (!strcmp(gen.c_str(),"-"))
    7272        {
    7373        gen=0;
     
    9898                        {
    9999                        if (no_impl) no_impl_names+=',';
    100                         no_impl_names+=SString::sprintf("#%d.%s",i,(const char*)n->getClassName());
     100                        no_impl_names+=SString::sprintf("#%d.%s",i,n->getClassName().c_str());
    101101                        no_impl++;
    102102                        }
     
    104104                        {
    105105                        if (init_err) init_err_names+=',';
    106                         init_err_names+=SString::sprintf("#%d.%s",i,(const char*)n->getClassName());
     106                        init_err_names+=SString::sprintf("#%d.%s",i,n->getClassName().c_str());
    107107                        init_err++;
    108108                        }
    109109                }
    110110        printf("\n");
    111         if (no_impl) printf("%d x missing implementation (%s)\n",no_impl,(const char*)no_impl_names);
    112         if (init_err) printf("%d x failed initialization (%s)\n",init_err,(const char*)init_err_names);
     111        if (no_impl) printf("%d x missing implementation (%s)\n",no_impl,no_impl_names.c_str());
     112        if (init_err) printf("%d x failed initialization (%s)\n",init_err,init_err_names.c_str());
    113113        }
    114114int steps=1;
     
    119119        {
    120120        n=m.getNeuro(i);
    121         printf("\t#%d.%s",i,(const char*)n->getClassName());
     121        printf("\t#%d.%s",i,n->getClassName().c_str());
    122122        }
    123123printf("\n");
  • cpp/frams/_demos/part_shapes.cpp

    r319 r348  
    5252
    5353        m.close();
    54         puts((const char*)m.getF0Geno().toString());
     54        puts(m.getF0Geno().toString().c_str());
    5555        // the genotype can be fed directly to the genotype viewer, like this:
    5656        // part_shapes | theater -g -
  • cpp/frams/_demos/printconvmap.cpp

    r286 r348  
    5656SString g2=gen2;
    5757stripstring(g2);
    58 const char* g=g1;
     58const char* g=g1.c_str();
    5959y=0;
    6060MultiRange *mr;
    6161MultiRange emptyrange;
    6262printN(' ',GEN1MAX);
    63 printf("   %s\n",(const char*)g2);
     63printf("   %s\n",g2.c_str());
    6464int begin=map.getBegin();
    6565int end=map.getEnd();
     
    8383        if ((y2-y) > GEN1MAX) y2=y+GEN1MAX;
    8484        if (y2>(y+len1)) y2=y+len1;
    85         printmapping(g+y,y2-y,*mr,g2,g2.len());
     85        printmapping(g+y,y2-y,*mr,g2.c_str(),g2.len());
    8686        y=y2;
    8787        }
  • cpp/frams/_demos/serial_test.cpp

    r319 r348  
    6060                                {
    6161                                printIndent(indent+3);
    62                                 printf("key \"%s\"\n",(const char*)it->key);
     62                                printf("key \"%s\"\n",it->key.c_str());
    6363                                print((ExtValue*)it->value,indent+6,&next_trace);
    6464                                }
     
    6767                }
    6868        }
    69 puts((const char*)v->getString());
     69puts(v->getString().c_str());
    7070}
    7171
  • cpp/frams/_demos/shapeconvert.cpp

    r286 r348  
    8787
    8888        Geno f0_g = newmodel.getF0Geno();
    89         puts((const char*)f0_g.toString());
     89        puts(f0_g.toString().c_str());
    9090
    9191        return 0;
Note: See TracChangeset for help on using the changeset viewer.