Jonathan Polley wrote:

> I am getting closer.  I was able to resolve the link-time errors (added 
> a slew of new files to the MSVC project) and got an executable!  There 
> was one build problem in that MSVC did not like an enumeration being 
> used to define the size of an array:
> 
> .\src\Input/input.hxx(321) : error C2248: 'MAX_MOUSE_BUTTONS' : cannot 
> access private enumerator declared in class 'FGInput'
>         .\src\Input/input.hxx(250) : see declaration of 'MAX_MOUSE_BUTTONS'
> 
> Changing the enumeration to a series of #defines solved that problem.
> 
> Once I tried running, I crashed in main.cxx/fgReshape(), line 1166.  It 
> appears that MSVC does not generate the proper code for:
> 
>     globals->get_viewmgr()->get_view(i)->
>             set_aspect_ratio((float)view_h / (float)width);
> 
> and I wound up using a temp variable in order for it to work:
> 
>     FGViewer *Viewer;
>     ...
>     Viewer = globals->get_viewmgr()->get_view(i);
>     Viewer->set_aspect_ratio((float)view_h / (float)width);
> 
> Finally, I was able to run again and crashed in FGInput::_init_mouse(), 
> FlightGear died in the call to:
> 
> mode_node->getChild("button", k), line 658-ish
> 
> Assigning that to a local did not solve the problem, so I am now stuck, 
> again.  At least the above line was added in version 1.35 of input.cxx, 
> rather than it being a problem with MSVC that was awoken as a side 
> effect of another change.
> 
> Any ideas?
> 
> Thanks,
> 
> Jonathan Polley
> 
> 
> p.s.  Has a solution been decided upon for the MSVC overloading 
> problem?  I was able to work around the issue by renaming the vector 
> methods to have a suffix of _V, but I don't know if that is what is 
> preferred.  My vote, if I may have one, is to not overload.  This is a 
> personal preference from being burned, in the past, by compilers that 
> aren't too smart.  Granted these were older compilers (c. 1985-97), and 
> they weren't C++ compilers (Ada-83 and Ada-95), but I have been made a 
> tad gun shy.



Personally, I think I'd like a cast or typedef better than this.


> 
> 
> _______________________________________________
> Flightgear-devel mailing list
> [EMAIL PROTECTED]
> http://mail.flightgear.org/mailman/listinfo/flightgear-devel
> 



_______________________________________________
Flightgear-devel mailing list
[EMAIL PROTECTED]
http://mail.flightgear.org/mailman/listinfo/flightgear-devel

Reply via email to