function writeBits($value) {
		$this->r = ($this->r & 0xFE) + ($value >> 2 & 1);
		$this->g = ($this->g & 0xFE) + ($value >> 1 & 1);
		$this->b = ($this->b & 0xFE) + ($value >> 0 & 1);
		/* // debug colors
		$this->r = 0;
		$this->g = $value << 5;
		$this->b = 0;
		$this->a = 1;
		/**/
	}