OpenSceneGraph Forum Forum Index OpenSceneGraph Forum
Official forum which mirrors the existent OSG mailing lists. Messages posted here are forwarded to the mailing list and vice versa.
 
   FAQFAQ    SearchSearch    MemberlistMemberlist    RulesRules    UsergroupsUsergroups    RegisterRegister 
 Mail2Forum SettingsMail2Forum Settings  ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 
   AlbumAlbum  OpenSceneGraph IRC ChatOpenSceneGraph IRC Chat   SmartFeedSmartFeed 

When build new project, can not open osgOceanD.lib


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> osgOcean [osgOcean]
View previous topic :: View next topic  
Author Message
wyh891205
Newbie


Joined: 26 Mar 2012
Posts: 4

PostPosted: Mon Mar 26, 2012 3:57 am    Post subject:
When build new project, can not open osgOceanD.lib
Reply with quote

Hi,

I'm a chinese student. I have complied the osgOcean successfully. I can run the oceanExample, and do everything in its "applicantion.cpp". But now, I meet a problem: If I make a new project, when run the code, it alway declare an error:
LINK : fatal error LNK1181: 无法打开输入文件“..\..\lib\Debug\osgOceanD.lib”,
(Cannot open the input file:osgOceanD.lib)

My osgOceanD.lib is located in F:\OSG\osgOcean\build\lib\Debug, and I also add this path to "TOOLS—>Option —>Directories-> Library Files". In the Windows PATH, I add "F:\OSG\osgOcean\build\bin\Debug".

So, I need to know how to solve this problem.

Thank you!

Cheers,
Han


Following is the test code:


#include <osgViewer/Viewer>
#include <osgDB/ReadFile>

#include <osgGA/TrackballManipulator>
#include <osgOcean/OceanScene>
#include <osgOcean/FFTOceanSurface>




int main()
{
osg::ref_ptr<osgViewer::Viewer> viewer =new osgViewer::Viewer;
viewer->setUpViewInWindow(150,150,1024,768,0);//setUpViewInWindow(150,150,1024,768,0);

osg::ref_ptr<osgOcean::FFTOceanSurface> oceanSurface= new osgOcean::FFTOceanSurface(64,256,17,osg::Vec2(1.1f,1.1f),12.0f,1000.0f,0.8f,1e-8,true,2.5,10.f,256);

osg::ref_ptr<osgOcean::OceanScene> oceanScene=new osgOcean::OceanScene(oceanSurface.get());
viewer->addEventHandler(oceanSurface->getEventHandler());
viewer->addEventHandler(oceanSurface->getEventHandler());

osgGA::TrackballManipulator *tb = new osgGA::TrackballManipulator;
tb->setHomePosition(osg::Vec3f(0.0,0.0f,20.0),osg::Vec3f(0.0f,20.0f,20.0f),osg::Vec3f(0,0,1));
viewer->setCameraManipulator(tb);
viewer->setSceneData(oceanSurface);
viewer->run();
return 0;
}

This code is ok when copy to "applicantion.cpp", but can't be use in new any projects.
Back to top
View user's profile Send private message
wyh891205
Newbie


Joined: 26 Mar 2012
Posts: 4

PostPosted: Sat Apr 28, 2012 3:14 pm    Post subject:
When build new project, can not open osgOceanD.lib
Reply with quote

Hi,

I'm a chinese student. I have complied the osgOcean successfully. I can run the oceanExample, and do everything in its "applicantion.cpp". But now, I meet a problem: If I make a new project, when run the code, it alway declare an error:
LINK : fatal error LNK1181: 无法打开输入文件“..\..\lib\Debug\osgOceanD.lib”,
(Cannot open the input file:osgOceanD.lib)

My osgOceanD.lib is located in F:\OSG\osgOcean\build\lib\Debug, and I also add this path to "TOOLS—>Option —>Directories-> Library Files". In the Windows PATH, I add "F:\OSG\osgOcean\build\bin\Debug".

So, I need to know how to solve this problem.

Thank you!

Cheers,
Han


Following is the test code:


#include <osgViewer/Viewer>
#include <osgDB/ReadFile>

#include <osgGA/TrackballManipulator>
#include <osgOcean/OceanScene>
#include <osgOcean/FFTOceanSurface>




int main()
{
osg::ref_ptr<osgViewer::Viewer> viewer =new osgViewer::Viewer;
viewer->setUpViewInWindow(150,150,1024,768,0);//setUpViewInWindow(150,150,1024,768,0);

osg::ref_ptr<osgOcean::FFTOceanSurface> oceanSurface= new osgOcean::FFTOceanSurface(64,256,17,osg::Vec2(1.1f,1.1f),12.0f,1000.0f,0.8f,1e-8,true,2.5,10.f,256);

osg::ref_ptr<osgOcean::OceanScene> oceanScene=new osgOcean::OceanScene(oceanSurface.get());
viewer->addEventHandler(oceanSurface->getEventHandler());
viewer->addEventHandler(oceanSurface->getEventHandler());

osgGA::TrackballManipulator *tb = new osgGA::TrackballManipulator;
tb->setHomePosition(osg::Vec3f(0.0,0.0f,20.0),osg::Vec3f(0.0f,20.0f,20.0f),osg::Vec3f(0,0,1));
viewer->setCameraManipulator(tb);
viewer->setSceneData(oceanSurface);
viewer->run();
return 0;
}

This code is ok when copy to "applicantion.cpp", but can't be use in new any projects.

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=46579#46579




Attachments:
http://forum.openscenegraph.org//files/ll_334.png




------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
kcbale
User


Joined: 04 Mar 2011
Posts: 68

PostPosted: Sun Apr 29, 2012 10:00 am    Post subject:
When build new project, can not open osgOceanD.lib
Reply with quote

Hi Han,

In visual studio 2008 I usually add library directories and bin variables on a per project basis, by right clicking on the project name in the solution explorer selecting properties and editing the linker settings.


Without going through your visual studio settings it's hard to say where you've gone wrong, but I would double check the path to the library that you've specified because this appears to be a simple case of Visual Studio not being able to find the lib file.


K.

On 26 March 2012 04:58, Han Wang < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:
Hi,

I'm a chinese student. I have complied the osgOcean successfully. I can run the oceanExample, and do everything in its "applicantion.cpp". But now, I meet a problem: If I make a new project, when run the code, it alway declare an error:
LINK : fatal error LNK1181: 无法打开输入文件&ldquo;....libDebugosgOceanD.lib&rdquo;,
(Cannot open the input file:osgOceanD.lib)

My osgOceanD.lib is located in F:OSGosgOceanbuildlibDebug, and I also add this path to "TOOLS&mdash;>Option &mdash;>Directories-> Library Files". In the Windows PATH, I add "F:OSGosgOceanbuildbinDebug".

So, I need to know how to solve this problem.

Thank you!

Cheers,
Han


Following is the test code:


#include <osgViewer/Viewer>
#include <osgDB/ReadFile>

#include <osgGA/TrackballManipulator>
#include <osgOcean/OceanScene>
#include <osgOcean/FFTOceanSurface>




int main()
{
osg::ref_ptr<osgViewer::Viewer> viewer =new osgViewer::Viewer;
viewer->setUpViewInWindow(150,150,1024,768,0);//setUpViewInWindow(150,150,1024,768,0);

osg::ref_ptr<osgOcean::FFTOceanSurface> oceanSurface= new osgOcean::FFTOceanSurface(64,256,17,osg::Vec2(1.1f,1.1f),12.0f,1000.0f,0.8f,1e-8,true,2.5,10.f,256);

osg::ref_ptr<osgOcean::OceanScene> oceanScene=new osgOcean::OceanScene(oceanSurface.get());
viewer->addEventHandler(oceanSurface->getEventHandler());
viewer->addEventHandler(oceanSurface->getEventHandler());

osgGA::TrackballManipulator *tb = new osgGA::TrackballManipulator;
tb->setHomePosition(osg::Vec3f(0.0,0.0f,20.0),osg::Vec3f(0.0f,20.0f,20.0f),osg::Vec3f(0,0,1));
viewer->setCameraManipulator(tb);
viewer->setSceneData(oceanSurface);
viewer->run();
return 0;
}

This code is ok when copy to "applicantion.cpp", but can't be use in new any projects.

------------------
Read this topic online here:
http://forum.openscenegraph.org/viewtopic.php?p=46579#46579




Attachments:
http://forum.openscenegraph.org//files/ll_334.png


_______________________________________________
osg-users mailing list
(
Only registered users can see emails on this board!
Get registred or enter the forums!
)
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


------------------
Post generated by Mail2Forum
Back to top
View user's profile Send private message
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> osgOcean [osgOcean] All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You cannot download files in this forum

Similar Topics
Topic Author Forum Replies Posted
No new posts Open Flight d_a_heitbrink Plugins [osgPlugins] 1 Fri Sep 08, 2017 4:45 pm View latest post
No new posts How to add hello world/additional pro... tipking General 3 Mon Jun 12, 2017 10:25 am View latest post
No new posts Choosing a game engine for an open Ro... Duncan Cragg General 3 Wed Apr 26, 2017 8:52 pm View latest post
No new posts iOS build guide locked/checked out on... tomhog General 2 Fri Apr 21, 2017 10:43 pm View latest post
No new posts osg build (master) failed with VS2013... Trajce Nikolov NICK General 1 Thu Feb 09, 2017 2:26 pm View latest post


Board Security Anti Bot Question MOD - phpBB MOD against Spam Bots
Powered by phpBB © 2001, 2005 phpBB Group
Protected by Anti-Spam ACP