xuzhit...@163.com
unread,Nov 1, 2017, 10:23:28 PM11/1/17Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to cesium-dev
1. A concise explanation of the problem you're experiencing.
I created a model using CINEMA 4D which has some colors like green,gray,red...,and exported as obj format.Then I converted the obj file to gltf format file using obj2gltf tool,and load gltf file on cesium like this,
var position = Cesium.Cartesian3.fromDegrees(-123.0744619, 44.0503706, height);
var heading = Cesium.Math.toRadians(10000);
var pitch = 0;
var roll = 0;
var hpr = new Cesium.HeadingPitchRoll(heading, pitch, roll);
var orientation = Cesium.Transforms.headingPitchRollQuaternion(position, hpr);
entity = viewer.entities.add({
name : url,
position : position,
orientation : orientation,
model : {
uri : url,
minimumPixelSize : 128,
maximumScale : 20000,
}
});
viewer.trackedEntity = entity;
But on the chrome browser,the model's color is completely black.
When I disabled the chrome GPU acceleration option,it is normal.
Then I checked my graphics card is NVIDIA Gefore GTX,but on another notebook compute with AMD graphics card,it works normaly.
I tried some other obj file which size less than the obj(about 44M),and they worked normaly.
Did any body have the same problem?
Please help me to issue it.
Thanks very much and forgive my poor chinese english!
2. A minimal code example. If you've found a bug, this helps us reproduce and repair it.
var position = Cesium.Cartesian3.fromDegrees(-123.0744619, 44.0503706, height);
var heading = Cesium.Math.toRadians(10000);
var pitch = 0;
var roll = 0;
var hpr = new Cesium.HeadingPitchRoll(heading, pitch, roll);
var orientation = Cesium.Transforms.headingPitchRollQuaternion(position, hpr);
entity = viewer.entities.add({
name : url,
position : position,
orientation : orientation,
model : {
uri : url,
minimumPixelSize : 128,
maximumScale : 20000,
}
});
viewer.trackedEntity = entity;
3. Context. Why do you need to do this? We might know a better way to accomplish your goal.
4. The Cesium version you're using, your operating system and browser.
The lastest version of Cesium+Win10+Chrome