An approach to emerging optical and optoelectronic applications based on NiO micro- and nanostructures