Results 1 to 2 of 2

Thread: FlatShadeMaterial with collada object ?

  1. #1
    Junior Member
    Join Date
    May 2009
    Posts
    6

    FlatShadeMaterial with collada object ?

    Hi there

    How is it possible to assign FlatShadeMaterial to collada object ?

    Code :
    light = new PointLight3D(true); 
    light.z = -800; 
    light.y = 300;
    flat = new FlatShadeMaterial(light, 0xFFFFFF, 0x444444);		
    collada60=new Collada("60sided.dae");
    scene.addChild(collada60);

    because normally with primitive, you assign "flat" at this stage.

    Code :
    sphere = new Sphere(flat, 150, 8, 8);

    Thanks

  2. #2
    Junior Member
    Join Date
    May 2009
    Posts
    6

    Re: FlatShadeMaterial with collada object ?

    I fand the answer:

    Code :
    flat = new FlatShadeMaterial(light, 0xFFFFFF, 0x444444);
    var ml60 : MaterialsList = new MaterialsList();
    ml60.addMaterial(flat, "initialShadingGroup"); 
    collada60=new Collada("60sided.dae",ml60);

    Simple no ?

    But now how can I change the texture or color of my collada object ?

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •