bitcoincore development – How to serialize data from blkxxxx.dat in bitcoin

I'm writing a blockchain parser for bitcoin core in C ++ and now I want to enrich the data I read with the raw transaction and the hashes of the previous and next blocks.

I've used this library to convert hexadecimal to double sha256, but my problem now is to bring the read data back to the correct format. For example, VarInt is serialized as the corresponding hexadecimal (for example 77 -> 4d).
But on some things, I do not find myself, for example, in the conversion of integers of type uint32 and int32.

I am going to give you an example
the version the genesis block number is 1 and the serialization at the correct hash is 01000000

or the conversion of the nuncio of the genesis block that is 2083236893 but the correct form for the serialization is 42a14695

The same applies to

nbits = 486604799 -> serialization = f2b9441a
timestamp = 1231469665 -> serialization = c7f5d74d

Sorry for my terrible english but I'm learning.