The immediately obvious idea is to use Pedersen commitments. The idea here is that, in some group where the DLog problem is hard, we have two generators of unknown relation $g, h$, and a commitment to $x$ is the value $g^x h^r$ (for some random $r$).
To reveal the commitment is easy; you just give the values $x, r$ (and the verifier can check).
To prove that a value $x'$ is not the committed value to a commitment $g^x h^r$, the prover selects random values $s, t$, and publishes the value $h^t$, along with a zero knowledge proof that he knows the dlog of $h^t$ to the base $h$ (a standard cut-and-choose proof works). Then, both sides compute $g^{-x'} h^t (g^x h^r) = g^{x - x'} h^{r+t}$, which we will call $j$. Now, the prover computes $j^s = g^{s(x-x')} h^{s(r+t)}$, and outputs that, along with the values $s(x-x')$, $s(r+t)$. He also outputs a zero knowledge proof that he knows the discrete log of $j^s$ to the base $j$.
The verifier can check that $s(x-x') \ne 0$, that the values $s(x-x')$, $s(r+t)$ make up the outputted value $j^s$, and that the proofs of knowledge of $s, t$ are valid.
Then, the verifier knows that the prover knows the value $s(x - x')$ and that it's not zero, hence $x - x' \ne 0$ and so whatever $x$ is, it ain't $x'$
There are also standard range techniques that would also work; I believe that this is more straight-forward...
C = H(BF | H(BF | X))
$\endgroup$