/* Network-Integrated Multimedia Middleware (NMM)
 * http://www.motama.com/nmm.html
 *
 * Copyright (C) 2006-2007
 * Motama GmbH, Saarbruecken, Germany
 * http://www.motama.com
 *
 * This file is part of NMM. 
 * 
 * NMM is free software; you can redistribute it and/or modify it    
 * under the terms of the GNU General Public License as published by 
 * the Free Software Foundation; only version 2 of the License.      
 * 
 * NMM is distributed in the hope that it will be useful, but WITHOUT 
 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 
 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public 
 * License for more details.  
 * 
 * You should have received a copy of the GNU General Public License 
 * along with NMM; if not, write to the Free Software Foundation,    
 * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
 *
 */

#ifndef NMM_IVideoDisplay_HPP
#define NMM_IVideoDisplay_HPP

#include "nmm/nmm_prefix.hpp"

#include "nmm/comm/Interface.hpp"
#include "nmm/comm/messaging/Event.hpp"
#include "nmm/comm/messaging/IllegalStateException.hpp"
#include <memory>

#include "nmm/multimedia/INode.hpp"

#include "visibility.hpp"

namespace NMM
{
  /**
   * General display interface.
   * This interface provides all general display methods.
   */

  class DLLEXPORT IVideoDisplay : virtual public NMM::Interface { 
  public:
    IVideoDisplay() : NMM::Interface(IVideoDisplay::IVideoDisplay_type, "NMM") { };

    IVideoDisplay(NMM::NMMObject& parent) : NMM::Interface (parent, IVideoDisplay::IVideoDisplay_type, "NMM") { };

    virtual ~IVideoDisplay() {};

    static const char* IVideoDisplay_type;

    virtual  string getInterfaceType() const { return IVideoDisplay_type; }

    NMM::Interface* copy() const { return new IVideoDisplay(*this); }
    static void used(); 
    static const char* setBenchmarkingEnabled_event;
    static const char* setFullscreen_event;
    static const char* getFullscreen_event;
    static const char* hasFullscreen_event;
    static const char* isFullscreenOnly_event;
    static const char* makeScreenshot_event;
    static const char* setDisplayPosition_event;
    static const char* setLeftWindowAlignment_event;
    static const char* setRightWindowAlignment_event;
    static const char* setCenterWindowAlignment_event;
    /**
     * Enable/disable presentation of fps on title of display/window
     * @param value true for enabling presentation, else false 
     */

    virtual void setBenchmarkingEnabled(const nmm_bool& value)
      throw(const NMM::SerializedException&);
    /**
     * Set fullscreen mode.
     * @param value true for fullscreen, false for windowed display mode
     */

    virtual void setFullscreen(const nmm_bool& value)
      throw(const NMM::SerializedException&);
    /**
     * Get fullscreen mode.
     * @return true if the display is in fullscreen mode, false if it is in windowed mode
     */

    virtual nmm_bool getFullscreen() const
      throw(const NMM::SerializedException&);
    /**
     * test if display has fullscreen support.
     * @return true if fullscreen mode can be turned on, false otherwise
     */

    virtual nmm_bool hasFullscreen() const
      throw(const NMM::SerializedException&);
    /**
     * Test if display is fullscreen only.
     * @return true if fullscren mode is the default and cannot be turned off.
     */

    virtual nmm_bool isFullscreenOnly() const
      throw(const NMM::SerializedException&);

    virtual nmm_bool makeScreenshot(const string& filename) const
      throw(const NMM::SerializedException&);
    /**
     * Set window alignment.
     */

    virtual void setDisplayPosition(const nmm_int32& xPos, const nmm_int32& yPos) /* limited(INode::CONSTRUCTED) */ /* limited(INode::INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);

    virtual void setLeftWindowAlignment() /* limited(INode::CONSTRUCTED) */ /* limited(INode::INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);

    virtual void setRightWindowAlignment() /* limited(INode::CONSTRUCTED) */ /* limited(INode::INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);

    virtual void setCenterWindowAlignment() /* limited(INode::CONSTRUCTED) */ /* limited(INode::INITIALIZED) */
      throw(const NMM::SerializedException&, const NMM::IllegalStateException&);


  };

  typedef auto_ptr<IVideoDisplay> IVideoDisplay_var;




}

#include "nmm/nmm_suffix.hpp"

#endif
