CALOCUBE: An approach to high-granularity and homogenous calorimetry for space based detectors