title: Ambiguous base with multiple inheritance
body: <p>I am trying to write some subclasses of classes in a big library. I am getting an "ambiguous base" error. Here is a compilable example of the problem:</p>
  
  <pre><code>#include &lt;iostream&gt;
  
  // I can't change these because they are in the library:
  class InteractorStyle {};
  class InteractorStyleCamera : public InteractorStyle {};
  class InteractorStyleImage : public InteractorStyle {};
  
  // These are my subclasses (so I can change them):
  class PointSelector : public InteractorStyle {};
  class PointSelector2D : public InteractorStyleCamera, public PointSelector
  {
    // This function has to exist exactly like this (a requirement of the library):
    static PointSelector2D* SafeDownCast(InteractorStyle *o)
    {
      return static_cast&lt;PointSelector2D *&gt;(o);
    } 
  };
  
  
  int main()
  {
  
    return 0;
  }
  </code></pre>
  
  <p>The error is</p>
  
  <blockquote>
    <p>error: ‘InteractorStyle’ is an ambiguous base of ‘PointSelector2D’.</p>
  </blockquote>
  
  <p>Is there anything I can do in this case?</p>