/* ************************************************************************** */ /* */ /* ::: :::::::: */ /* Fixed.hpp :+: :+: :+: */ /* +:+ +:+ +:+ */ /* By: lfirmin +#+ +:+ +#+ */ /* +#+#+#+#+#+ +#+ */ /* Created: 2025/07/02 12:25:41 by lfirmin #+# #+# */ /* Updated: 2025/07/16 14:41:02 by lfirmin ### ########.fr */ /* */ /* ************************************************************************** */ #ifndef FIXED_HPP # define FIXED_HPP #include #include class Fixed { private: int _fixed_p_n; static const int _number_fractional_bits; public: //const/dest Fixed(); Fixed(const int input); Fixed(const float input); Fixed(const Fixed ©); ~Fixed(); //ol op Fixed &operator=(const Fixed ©); //pub method float toFloat(void)const; int toInt(void)const; //get/set int getRawBits(void) const; void setRawBits(int const raw); }; std::ostream &operator<<(std::ostream &o, Fixed const &fixed); #endif