title: Error: function Camera::operator=(const Camera&) (declared implicitly) cannot be referenced -- it is a deleted function
body: <p>Camera.h:</p>
  <pre><code>#include &quot;math_headers.h&quot;
  #include &quot;GLContext.h&quot;
  
  static const float YAW = -90.0f;
  static const float PITCH = 0.0f;
  static const float SPEED = 2.5f;
  static const float SENSITIVITY = 0.1f;
  static const float ZOOM = 45.0f;
  
  class Camera
  {
  public:
      Camera(glm::vec3 position = glm::vec3(0.0f, 0.0f, 0.0f),
          glm::vec3 up = glm::vec3(0.0f, 1.0f, 0.0f), float yaw = YAW, float pitch = PITCH)
          : m_Front(glm::vec3(0.0f, 0.0f, -1.0f)), m_MovementSpeed(SPEED),
          m_MouseSensitivity(SENSITIVITY), m_Zoom(ZOOM),
          m_Position(position), m_WorldUp(up), m_Yaw(yaw), m_Pitch(pitch),
          m_Context(GLContext::getTnstance())
      {
          updateCameraVectors();
      }
      Camera(float posX, float posY, float posZ, float upX, float upY, float upZ,
          float yaw, float pitch)
          : m_Front(glm::vec3(0.0f, 0.0f, -1.0f)), m_MovementSpeed(SPEED), 
          m_MouseSensitivity(SENSITIVITY), m_Zoom(ZOOM),
          m_Position(glm::vec3(posX, posY, posZ)), m_WorldUp(glm::vec3(upX, upY, upZ)), 
          m_Yaw(yaw), m_Pitch(pitch),
          m_Context(GLContext::getTnstance())
      {
          
          updateCameraVectors();
      }
      
      inline void MoveForward() { m_Position += m_Front * Velocity(); }
      inline void MoveBackward() { m_Position -= m_Front * Velocity(); }
      inline void MoveLeft() { m_Position += m_Right * Velocity(); }
      inline void MoveRight() { m_Position -= m_Front * Velocity(); }
  
      glm::mat4 GetViewMatrix()
      {
          return glm::lookAt(m_Position, m_Position + m_Front, m_Up);
      }
  
      inline const glm::vec3&amp; Position() const { return m_Position; }
      inline const glm::vec3&amp; Up() const { return m_Up; }
      inline const glm::vec3&amp; Front() const { return m_Front; }
      inline const glm::vec3&amp; Right() const { return m_Right; }
      
  
      ~Camera() {}
  private:
      void updateCameraVectors();
      inline const float Velocity() const { return m_MovementSpeed * m_Context.DeltaTime(); }
  
      GLContext&amp; m_Context;
  
      glm::vec3 m_Position;
      glm::vec3 m_Up;
      glm::vec3 m_Front;
      glm::vec3 m_Right;
      glm::vec3 m_WorldUp;
  
      float m_Yaw;
      float m_Pitch;
  
      float m_MovementSpeed;
      float m_MouseSensitivity;
      float m_Zoom;
  
      
  };
  </code></pre>
  <p>InputManager.h:</p>
  <pre><code>#pragma once
  #include &lt;vector&gt;
  
  #include &quot;GLContext.h&quot;
  #include &quot;Keybind.h&quot;
  #include &quot;Camera.h&quot;
  
  class InputManager
  {
  private:
      using cursor_pos_callback = void (*)(GLFWwindow* window, double xpos, double ypos);
  public:
      static InputManager&amp; getTnstance(cursor_pos_callback = NULL);
  
      void ProcessInput() const;
      void SetCamera(Camera&amp; camera) { m_Camera = camera; }
      inline void SetCursor(const float x, const float y) { m_CursorX = x; m_CursorY = y; }
      inline void GetCursor(float&amp; x, float&amp; y) { x = m_CursorX; y = m_CursorY; }
  
  
      template&lt;typename T&gt;
      void RegisterKeybind(int keyId);
  
      ~InputManager();
      InputManager(InputManager const&amp;) = delete;
      void operator=(InputManager const&amp;) = delete;
  private:
      InputManager(cursor_pos_callback);
  
      void SetGlobalSettings();
  
      Camera&amp; m_Camera;
      GLContext&amp; m_Context;
      float m_CursorX;
      float m_CursorY;
      std::vector&lt;Keybind*&gt; m_Keybinds;
      cursor_pos_callback m_CursorPosCallback;
  };
  </code></pre>
  <p>This line in InputManager.h that is causing the error:</p>
  <pre><code>void SetCamera(Camera&amp; camera) { m_Camera = camera; }
  </code></pre>
  <p>Adding some more details because it won't let me post the question otherwise because there is too much code. Adding some more details because it won't let me post the question otherwise because there is too much code. Adding some more details because it won't let me post the question otherwise because there is too much code.</p>