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 

OSG and C# Users


 
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General
View previous topic :: View next topic  
Author Message
Jason Beverage
Guest





PostPosted: Thu Oct 30, 2008 7:51 pm    Post subject:
OSG and C# Users
Reply with quote

Hi Maya,

As long as you have the appropriate image plugin within your path (osgdb_jpg.dll, osgdb_gif.dll, etc) things should work fine. Make sure you are building these plugins and they are accessible. In theory, if the model works from osgviewer, it should work in your c# application.

Good luck!

Jason


On Thu, Oct 30, 2008 at 3:18 PM, maya leonard < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:


Hello hesicong, OSG and C# Users

I'm trying to get textures to load within osg C# application and nothing happens.
Certain textures such as rgb formats work, but jpg and gif do not work.

You can replicate this problem with the osgnetdemo sample by hesicong and the sample skydome.osg sample.

Do you know how to load jpg and gif textures within C# and osg?

sincerely
maya

Want to read Hotmail messages in Outlook? The Wordsmiths show you how. Learn Now


_______________________________________________
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
Jason Beverage
Guest





PostPosted: Thu Oct 30, 2008 10:34 pm    Post subject:
OSG and C# Users
Reply with quote

Hi Maya,

It's hard to tell what could be going on without some more information about your setup. One thing you should try is setting the OSG_NOTIFY_LEVEL environment variable to DEBUG to help get a clue of what is going on. If you build your app as a Console application you will see all of OSG's debug messages and might point you to the problem.

I'm grasping at straws here and just guessing, but if you are using an OpenFileDialog to load your models, make sure that that RestoreDirectory property is set to true. If not, it will change your applications working directory and OpenSceneGraph won't know where to find your plugins.

Jason

On Thu, Oct 30, 2008 at 6:02 PM, usergroups_email < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:

Jason

The osgdb_jpg.dll and osgdb_gif.dll plugins are in the same location as the osgdb_gif and osgdb_rgb.dll, so I would expect them to work.

Any other hints?

thanks
maya


From: (
Only registered users can see emails on this board!
Get registred or enter the forums!
) [mailto: (
Only registered users can see emails on this board!
Get registred or enter the forums!
)] On Behalf Of Jason Beverage
Sent: Thursday, October 30, 2008 3:46 PM
To: OpenSceneGraph Users
Subject: Re: OSG and C# Users



Hi Maya,

As long as you have the appropriate image plugin within your path (osgdb_jpg.dll, osgdb_gif.dll, etc) things should work fine. Make sure you are building these plugins and they are accessible. In theory, if the model works from osgviewer, it should work in your c# application.

Good luck!

Jason


On Thu, Oct 30, 2008 at 3:18 PM, maya leonard < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Hello hesicong, OSG and C# Users

I'm trying to get textures to load within osg C# application and nothing happens.
Certain textures such as rgb formats work, but jpg and gif do not work.

You can replicate this problem with the osgnetdemo sample by hesicong and the sample skydome.osg sample.

Do you know how to load jpg and gif textures within C# and osg?

sincerely
maya


Want to read Hotmail messages in Outlook? The Wordsmiths show you how. Learn Now



_______________________________________________
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






_______________________________________________
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
Jason Beverage
Guest





PostPosted: Fri Oct 31, 2008 1:47 am    Post subject:
OSG and C# Users
Reply with quote

Hi Maya,

I'm not sure why the osgdb_jpegd.dll would fail to load, hard to say.

One thing to note is that osgviewer works, but what about osgviewerd? From the debug output, you are running your app in debug mode. Try running in release and see if it works. I'll bet that osgviewerd doesn't work.

Thanks,

Jason

On Thu, Oct 30, 2008 at 7:08 PM, usergroups_email < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Quote:

Jason

Thanks for the quick response. Trying debug mode I get

FindFileInPath() : trying XXXOpenSceneGraphbinosgPlugins-2.7.3osgdb_jpegd.dll ...
FindFileInPath() : USING XXXOpenSceneGraphbinosgPlugins-2.7.3osgdb_jpegd.dll
DynamicLibrary::failed loading "osgPlugins-2.7.3/osgdb_jpegd.dll"

Trying
osgviewer --image skymap.jpg

worked fine.

I'm using osgCppCLIDemo/osgNETDemo.exe as an example to get started using C# and OSG I got this file from
http://www.openscenegraph.org/projects/osg/wiki/Community/LanguageWrappers

The scenefile I'm trying is skydome.osg from the example osg dataset and it works fine with osgviewer.
So obviously the error issue relates to the C#/OSG configuration.

Are you using the example osgCppCLIDemo?

Cheers
Maya


From: (
Only registered users can see emails on this board!
Get registred or enter the forums!
) [mailto: (
Only registered users can see emails on this board!
Get registred or enter the forums!
)] On Behalf Of Jason Beverage
Sent: Thursday, October 30, 2008 6:34 PM

To: OpenSceneGraph Users
Subject: Re: OSG and C# Users





Hi Maya,

It's hard to tell what could be going on without some more information about your setup. One thing you should try is setting the OSG_NOTIFY_LEVEL environment variable to DEBUG to help get a clue of what is going on. If you build your app as a Console application you will see all of OSG's debug messages and might point you to the problem.

I'm grasping at straws here and just guessing, but if you are using an OpenFileDialog to load your models, make sure that that RestoreDirectory property is set to true. If not, it will change your applications working directory and OpenSceneGraph won't know where to find your plugins.

Jason
On Thu, Oct 30, 2008 at 6:02 PM, usergroups_email < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Jason

The osgdb_jpg.dll and osgdb_gif.dll plugins are in the same location as the osgdb_gif and osgdb_rgb.dll, so I would expect them to work.

Any other hints?

thanks
maya


From: (
Only registered users can see emails on this board!
Get registred or enter the forums!
) [mailto: (
Only registered users can see emails on this board!
Get registred or enter the forums!
)] On Behalf Of Jason Beverage
Sent: Thursday, October 30, 2008 3:46 PM
To: OpenSceneGraph Users
Subject: Re: OSG and C# Users


Hi Maya,

As long as you have the appropriate image plugin within your path (osgdb_jpg.dll, osgdb_gif.dll, etc) things should work fine. Make sure you are building these plugins and they are accessible. In theory, if the model works from osgviewer, it should work in your c# application.

Good luck!

Jason
On Thu, Oct 30, 2008 at 3:18 PM, maya leonard < (
Only registered users can see emails on this board!
Get registred or enter the forums!
)> wrote:
Hello hesicong, OSG and C# Users

I'm trying to get textures to load within osg C# application and nothing happens.
Certain textures such as rgb formats work, but jpg and gif do not work.

You can replicate this problem with the osgnetdemo sample by hesicong and the sample skydome.osg sample.

Do you know how to load jpg and gif textures within C# and osg?

sincerely
maya


Want to read Hotmail messages in Outlook? The Wordsmiths show you how. Learn Now



_______________________________________________
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







_______________________________________________
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






_______________________________________________
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
Display posts from previous:   
Post new topic   Reply to topic    OpenSceneGraph Forum Forum Index -> General 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 Happy New Year to all OSG Users Chris Hanson General 0 Mon Jan 07, 2019 10:17 am View latest post
No new posts osg-users Digest, Vol 138, Issue 27 Zachary1234 General 0 Tue Jan 01, 2019 1:16 am View latest post
No new posts osg-users Digest, Vol 137, Issue 14 poweruserm@live.com.au General 0 Fri Nov 16, 2018 11:16 pm View latest post
No new posts General Users starting questions in O... A Z General 1 Mon Oct 15, 2018 3:59 am View latest post
No new posts osg-users Digest, Vol 136, Issue 8 jonasydy General 0 Wed Oct 10, 2018 12:40 am 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