Re: [osg-users] Working with text

2008-04-23 Thread Lucas Goss
  You're only calling -setText on text, not on textSe and textMono.

Whew, thanks, I was losing my mind.

  On a related note: why not just use osgWidget and not worry about all this
 placement stuff? :)

I'm trying to get osgWidget working, but took a break to play around
with some other stuff...

Most of my development is on a Mac so I use the library frameworks,
which none exists for osgWidget at the moment. So I attempted to build
one but I always ran into some problem with linking or finding include
files. I tried going the cmake way, but couldn't get OSG built as I
ran into some errors there. So I took a break and played with
osgText... I love programming... I hate working with make and friends.

Now I'm on Ubuntu... built osg with cmake, but osgWidget errors when
it starts to build the examples (both repositories from svn head):

...
Linking CXX shared library libosgWidget.so
[ 40%] Built target osgWidget
Scanning dependencies of target osgwidgetaddremove
[ 42%] Building CXX object
examples/osgwidgetaddremove/CMakeFiles/osgwidgetaddremove.dir/osgwidgetaddremove.o
Linking CXX executable osgwidgetaddremove
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to
`osgText::Text::setAxisAlignment(osgText::Text::AxisAlignment)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to
`osgText::Text::setAlignment(osgText::Text::AlignmentType)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setFontResolution(unsigned int,
unsigned int)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setRotation(osg::Quat const)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setPosition(osg::Vec3f const)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setCharacterSize(float, float)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setText(std::basic_stringchar,
std::char_traitschar, std::allocatorchar  const)'
collect2: ld returned 1 exit status

Thanks,
Lucas
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text

2008-04-23 Thread Jeremy Moles

On Wed, 2008-04-23 at 10:54 -0400, Lucas Goss wrote:
   You're only calling -setText on text, not on textSe and textMono.
 
 Whew, thanks, I was losing my mind.
 
   On a related note: why not just use osgWidget and not worry about all this
  placement stuff? :)
 
 I'm trying to get osgWidget working, but took a break to play around
 with some other stuff...
 
 Most of my development is on a Mac so I use the library frameworks,
 which none exists for osgWidget at the moment. So I attempted to build
 one but I always ran into some problem with linking or finding include
 files. I tried going the cmake way, but couldn't get OSG built as I
 ran into some errors there. So I took a break and played with
 osgText... I love programming... I hate working with make and friends.
 
 Now I'm on Ubuntu... built osg with cmake, but osgWidget errors when
 it starts to build the examples (both repositories from svn head):
 
 ...
 Linking CXX shared library libosgWidget.so
 [ 40%] Built target osgWidget
 Scanning dependencies of target osgwidgetaddremove
 [ 42%] Building CXX object
 examples/osgwidgetaddremove/CMakeFiles/osgwidgetaddremove.dir/osgwidgetaddremove.o
 Linking CXX executable osgwidgetaddremove
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to
 `osgText::Text::setAxisAlignment(osgText::Text::AxisAlignment)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to
 `osgText::Text::setAlignment(osgText::Text::AlignmentType)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to `osgText::Text::setFontResolution(unsigned int,
 unsigned int)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to `osgText::Text::setRotation(osg::Quat const)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to `osgText::Text::setPosition(osg::Vec3f const)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to `osgText::Text::setCharacterSize(float, float)'
 /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
 undefined reference to `osgText::Text::setText(std::basic_stringchar,
 std::char_traitschar, std::allocatorchar  const)'
 collect2: ld returned 1 exit status

It's not picking up -losgText for some reason, but I can't be sure. I'd
be really certainly everything else built properly, since I've never
seen this and no one else has reported it.

Try editing examples/$EXAMPLE/CMakeLists.txt and changing:

LINK_LIBRARIES(debug osgWidgetd optimized osgWidget)

To:

LINK_LIBRARIES(
debug osgWidgetd optimized osgWidget
debug osgTextoptimized osgText
)

If this fixes it, I may have introduced a bug or something recently I'm
not aware of in my CMake configs.

 Thanks,
 Lucas
 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
 

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text

2008-04-23 Thread Lucas Goss
Yeah it all built properly... but that gave me a clue. So I ran:
cmake .. -DCMAKE_BUILD_TYPE=Release

And got past that part, but got this error (I couldn't find the io_utils file):

Scanning dependencies of target osgwidgetmenu
[ 60%] Building CXX object
examples/osgwidgetmenu/CMakeFiles/osgwidgetmenu.dir/osgwidgetmenu.o
/home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:6:30:
error: osgWidget/io_utils: No such file or directory
/home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:
In member function 'virtual bool ColorLabel::mousePush(double, double,
const osgWidget::WindowManager*)':
/home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:32:
error: no match for 'operator' in 'std::cout  *(ColorLabel*)this'
...

Thanks,
Lucas

On Wed, Apr 23, 2008 at 10:59 AM, Jeremy Moles [EMAIL PROTECTED] wrote:


  On Wed, 2008-04-23 at 10:54 -0400, Lucas Goss wrote:
 You're only calling -setText on text, not on textSe and textMono.
  
   Whew, thanks, I was losing my mind.
  
 On a related note: why not just use osgWidget and not worry about all 
 this
placement stuff? :)
  
   I'm trying to get osgWidget working, but took a break to play around
   with some other stuff...
  
   Most of my development is on a Mac so I use the library frameworks,
   which none exists for osgWidget at the moment. So I attempted to build
   one but I always ran into some problem with linking or finding include
   files. I tried going the cmake way, but couldn't get OSG built as I
   ran into some errors there. So I took a break and played with
   osgText... I love programming... I hate working with make and friends.
  
   Now I'm on Ubuntu... built osg with cmake, but osgWidget errors when
   it starts to build the examples (both repositories from svn head):
  
   ...
   Linking CXX shared library libosgWidget.so
   [ 40%] Built target osgWidget
   Scanning dependencies of target osgwidgetaddremove
   [ 42%] Building CXX object
   
 examples/osgwidgetaddremove/CMakeFiles/osgwidgetaddremove.dir/osgwidgetaddremove.o
   Linking CXX executable osgwidgetaddremove
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to
   `osgText::Text::setAxisAlignment(osgText::Text::AxisAlignment)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to
   `osgText::Text::setAlignment(osgText::Text::AlignmentType)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to `osgText::Text::setFontResolution(unsigned int,
   unsigned int)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to `osgText::Text::setRotation(osg::Quat const)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to `osgText::Text::setPosition(osg::Vec3f const)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to `osgText::Text::setCharacterSize(float, float)'
   /home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
   undefined reference to `osgText::Text::setText(std::basic_stringchar,
   std::char_traitschar, std::allocatorchar  const)'
   collect2: ld returned 1 exit status

  It's not picking up -losgText for some reason, but I can't be sure. I'd
  be really certainly everything else built properly, since I've never
  seen this and no one else has reported it.

  Try editing examples/$EXAMPLE/CMakeLists.txt and changing:

 LINK_LIBRARIES(debug osgWidgetd optimized osgWidget)

  To:

 LINK_LIBRARIES(
 debug osgWidgetd optimized osgWidget
 debug osgTextoptimized osgText
 )

  If this fixes it, I may have introduced a bug or something recently I'm
  not aware of in my CMake configs.



   Thanks,
   Lucas
   ___
   osg-users mailing list
   osg-users@lists.openscenegraph.org
   http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
  

  ___
  osg-users mailing list
  osg-users@lists.openscenegraph.org
  http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text

2008-04-23 Thread Jeremy Moles

On Wed, 2008-04-23 at 12:31 -0400, Lucas Goss wrote:
 Yeah it all built properly... but that gave me a clue. So I ran:
 cmake .. -DCMAKE_BUILD_TYPE=Release
 
 And got past that part, but got this error (I couldn't find the io_utils 
 file):

Alas, the dangers of svn head. :) This is fixed in my local repo
(uncommitted), so an SVN update in about 2 mins should do the trick...

More eyes--is more testing--is more good!

 Scanning dependencies of target osgwidgetmenu
 [ 60%] Building CXX object
 examples/osgwidgetmenu/CMakeFiles/osgwidgetmenu.dir/osgwidgetmenu.o
 /home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:6:30:
 error: osgWidget/io_utils: No such file or directory
 /home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:
 In member function 'virtual bool ColorLabel::mousePush(double, double,
 const osgWidget::WindowManager*)':
 /home/lgoss/Development/Lab/osgWidget/osgwidget/examples/osgwidgetmenu/osgwidgetmenu.cpp:32:
 error: no match for 'operator' in 'std::cout  *(ColorLabel*)this'
 ...
 
 Thanks,
 Lucas
 
 On Wed, Apr 23, 2008 at 10:59 AM, Jeremy Moles [EMAIL PROTECTED] wrote:
 
 
   On Wed, 2008-04-23 at 10:54 -0400, Lucas Goss wrote:
  You're only calling -setText on text, not on textSe and textMono.
   
Whew, thanks, I was losing my mind.
   
  On a related note: why not just use osgWidget and not worry about all 
  this
 placement stuff? :)
   
I'm trying to get osgWidget working, but took a break to play around
with some other stuff...
   
Most of my development is on a Mac so I use the library frameworks,
which none exists for osgWidget at the moment. So I attempted to build
one but I always ran into some problem with linking or finding include
files. I tried going the cmake way, but couldn't get OSG built as I
ran into some errors there. So I took a break and played with
osgText... I love programming... I hate working with make and friends.
   
Now I'm on Ubuntu... built osg with cmake, but osgWidget errors when
it starts to build the examples (both repositories from svn head):
   
...
Linking CXX shared library libosgWidget.so
[ 40%] Built target osgWidget
Scanning dependencies of target osgwidgetaddremove
[ 42%] Building CXX object

  examples/osgwidgetaddremove/CMakeFiles/osgwidgetaddremove.dir/osgwidgetaddremove.o
Linking CXX executable osgwidgetaddremove
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to
`osgText::Text::setAxisAlignment(osgText::Text::AxisAlignment)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to
`osgText::Text::setAlignment(osgText::Text::AlignmentType)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setFontResolution(unsigned int,
unsigned int)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setRotation(osg::Quat const)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setPosition(osg::Vec3f const)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setCharacterSize(float, float)'
/home/lgoss/Development/Lab/osgWidget/osgwidget/build/libosgWidget.so:
undefined reference to `osgText::Text::setText(std::basic_stringchar,
std::char_traitschar, std::allocatorchar  const)'
collect2: ld returned 1 exit status
 
   It's not picking up -losgText for some reason, but I can't be sure. I'd
   be really certainly everything else built properly, since I've never
   seen this and no one else has reported it.
 
   Try editing examples/$EXAMPLE/CMakeLists.txt and changing:
 
  LINK_LIBRARIES(debug osgWidgetd optimized osgWidget)
 
   To:
 
  LINK_LIBRARIES(
  debug osgWidgetd optimized osgWidget
  debug osgTextoptimized osgText
  )
 
   If this fixes it, I may have introduced a bug or something recently I'm
   not aware of in my CMake configs.
 
 
 
Thanks,
Lucas
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
   
 
   ___
   osg-users mailing list
   osg-users@lists.openscenegraph.org
   http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
 
 

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text (osgWidget)

2008-04-23 Thread Lucas Goss
  More eyes--is more testing--is more good!

OK, well here's some testing notes on osgWidget head:

* osgwidgetaddremove
  -I get: Warning: font file fonts/Calibri1.ttf not found

  -I get a blank screen.. looked at the code and seems to go with
mouse push/release

* osgwidgetbox
  -I get a blank screen for this one too

* osgwidgetinput
  -Clicking the button gives an error:
   osgWidget: Window [frame] couldn't find the Widget [Widget_2] in
it's object list.

  -Input doesn't work with the numpad, feature request :)

  -Tabbing to next control works, but it doesn't go to button.
   Some way it would be nice to hit button with keyboard
   (whether enter on any control or tab to enter and select...
   (some kind of default accept button and default cancel button
   for a container control/window would be nice)

* osgwidgetlabel
  -I get: Warning: font file fonts/Calibri1.ttf not found.

  -I only see a small green box at the top of the screen

* osgwidgetmenu
  -Warning: font file fonts/Calibri1.ttf not found.
osgWidget: Window [Menu_andy_mckee] can't call resizeAdd() with the
values -56 and 0
...
osgWidget: Window [Menu_common] can't call resizeAdd() with the values -88 and 0
...
osgWidget: Window [Menu_lol] can't call resizeAdd() with the values -112 and 0

  -No menu shows up?

* osgwidgetnotebook (seems to work alright, but..)
  -osgWidget: Window [notebook] couldn't find the Widget [Tab_2] in
it's object list.
osgWidget: Window [notebook] couldn't find the Widget [Tab_1] in it's
object list.
osgWidget: Window [notebook] couldn't find the Widget [Tab_0] in it's
object list.
osgWidget: Window [notebook] couldn't find the Widget [Tab_3] in it's
object list
...

* osgwidgetscrolled
  -Looks nice, but part of the scroll window is off screen (top chopped off)

Thanks,
Lucas
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text (osgWidget)

2008-04-23 Thread Jeremy Moles
These errors are all the result of using SVN, some of which I have an
answer in the works for and some of which I do not. Also, most of your
errors are caused by not having the font I use installed, which you can
remedy by changing the examples to use your font of choice. :) Widgets
and Windows use the size of their labels to resize themselves, so not
being able to render fonts will give you lots of 0, 0 sized objects.

On Wed, 2008-04-23 at 15:44 -0400, Lucas Goss wrote:
   More eyes--is more testing--is more good!
 
 OK, well here's some testing notes on osgWidget head:
 
 * osgwidgetaddremove
   -I get: Warning: font file fonts/Calibri1.ttf not found
 
   -I get a blank screen.. looked at the code and seems to go with
 mouse push/release
 
 * osgwidgetbox
   -I get a blank screen for this one too
 
 * osgwidgetinput
   -Clicking the button gives an error:
osgWidget: Window [frame] couldn't find the Widget [Widget_2] in
 it's object list.
 
   -Input doesn't work with the numpad, feature request :)
 
   -Tabbing to next control works, but it doesn't go to button.
Some way it would be nice to hit button with keyboard
(whether enter on any control or tab to enter and select...
(some kind of default accept button and default cancel button
for a container control/window would be nice)
 
 * osgwidgetlabel
   -I get: Warning: font file fonts/Calibri1.ttf not found.
 
   -I only see a small green box at the top of the screen
 
 * osgwidgetmenu
   -Warning: font file fonts/Calibri1.ttf not found.
 osgWidget: Window [Menu_andy_mckee] can't call resizeAdd() with the
 values -56 and 0
 ...
 osgWidget: Window [Menu_common] can't call resizeAdd() with the values -88 
 and 0
 ...
 osgWidget: Window [Menu_lol] can't call resizeAdd() with the values -112 and 0
 
   -No menu shows up?
 
 * osgwidgetnotebook (seems to work alright, but..)
   -osgWidget: Window [notebook] couldn't find the Widget [Tab_2] in
 it's object list.
 osgWidget: Window [notebook] couldn't find the Widget [Tab_1] in it's
 object list.
 osgWidget: Window [notebook] couldn't find the Widget [Tab_0] in it's
 object list.
 osgWidget: Window [notebook] couldn't find the Widget [Tab_3] in it's
 object list
 ...
 
 * osgwidgetscrolled
   -Looks nice, but part of the scroll window is off screen (top chopped off)

Can you send me an e-mail off the lists of this? :)

 Thanks,
 Lucas
 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
 

___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org


Re: [osg-users] Working with text

2008-04-22 Thread Jeremy Moles

On Tue, 2008-04-22 at 20:35 -0400, Lucas Goss wrote:
 I must be blind, but I can't figure out what is wrong with this small
 text example (attached). I wanted to load 3 fonts side by side to
 compare them, but the viewer only shows that last font that was
 loaded. I compared the code to the osgtext.cpp example and even
 stripped it down to just font loading and it worked fine, but it looks
 almost exactly like mine (which doesn't work, only shows one font).
 
 The text example that is attached loads 3 different fonts, but it
 doesn't matter which font you use (you can use three of the same or
 even the null font it still only shows one line of text instead of 3).
 I just want to know, why does only one show up?

You're only calling -setText on text, not on textSe and textMono.

On a related note: why not just use osgWidget and not worry about all
this placement stuff? :)

 Thanks,
 Lucas
 ___
 osg-users mailing list
 osg-users@lists.openscenegraph.org
 http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org
___
osg-users mailing list
osg-users@lists.openscenegraph.org
http://lists.openscenegraph.org/listinfo.cgi/osg-users-openscenegraph.org