Comments (4)
when use setURL() method,get the model displayed.
#if 0
mp->setNode(model);
#else
mp->setURL("axes.osgt.1000000.scale");
#endif
from osgearth.
When I put the model under the GeoTransform node and make the location, the model is displayed in the specified location.
At the same time, whether or not the setLocation() of the ModelLayer is set, it does not affect the display position of the model under the GeoTransform node.
//this is OK
GeoPoint gp(srs, -90.8, 0.33);
GeoTransform* gt = new GeoTransform;
gt->setPosition(gp);
gt->addChild(model);
mp->setNode(gt);
mp->setLocation(GeoPoint(srs, -100.0, 5.0)); //has no effect
The model set via setURL() is affected by setLocation() and adjusts position. Is this the result of the design, or is it a bug?
from osgearth.
Sounds like a bug - I will tag it and we'll take a look when we get a chance.
Thanks.
from osgearth.
And the methord setOrientation() has no effect either.
mp->setLocation(GeoPoint(srs, -100.0, 5.0));
mp->setOrientation(osg::Vec3(120.0, 22.0, 48.0));
The .earth file config by orientation also has no effect.
<Model name="axes in sea" paged="true" max_rang="50000">
<url>axes.osgt.1000.scale.osgearth_shadergen</url>
<location lat="-2.3717" long="-85.018" alt="200.2"/>
<orientation>78.0, 35.6, 163.2</orientation>
</Model>
I use a PAT node to make it.
GeoTransform* gt = new GeoTransform;
gt->setPosition(gp);
osg::PositionAttitudeTransform* pta = new osg::PositionAttitudeTransform;
pta->setAttitude(osg::Quat(45.0, osg::Z_AXIS));
pta->addChild(model);
gt->addChild(pta);
mp->setNode(gt);
from osgearth.
Related Issues (20)
- Crash while launching a hello world program HOT 6
- docs: forum site not updated
- Why not support NVGL HOT 3
- 3D tiles with shadow?
- FadeEffect does not impact model layer with point data HOT 1
- What's the best practice to changing vertex on the fly? HOT 2
- Can not display when try to draw path FeatureNode in osgearth3.3 HOT 4
- Map data is not yet available - "no data image" is being ignored
- osgearth_annotation - exits on startup
- Osgearth with Intel uhd graphics 630 HOT 1
- Nullify elevation in GDALImageLayer HOT 1
- Zoom to mouse makes map disappear HOT 2
- [osgEarth]* [Capabilities] Warning, OpenSceneGraph does not define OSG_GL3_AVAILABLE; the application may not function properly HOT 13
- Logarithmic depth integration with SilverLining is broken. HOT 18
- Add Model by FeatureModelLayer HOT 2
- About support opengl version HOT 1
- Update FeatureModelLayer on the fly failed
- Feature with ModelSymbol with model node created from a FeatureSource not displayed HOT 3
- Fog not available in 3.x HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from osgearth.