A method for manufacturing an optoelectronic device comprising an array of light-emitting diodes , including the following steps: - forming the array of light-emitting diodes on a support face of a substrate , this step being carried out so that each light-emitting diode has an elongated wire shape along a longitudinal axis extending along a transverse direction (Z) of the optoelectronic device oriented transversely to the support face of the substrate , - forming spacer walls made of a first dielectric material transparent to the light radiation coming from the light-emitting diodes , the formed spacer walls being such that the lateral sidewalls of each light-emitting diode , over its entire height (H) considered in the transverse direction (Z), are surrounded by at least one of the spacer walls , - forming light confinement walls formed of a second material adapted to block the light radiation coming from the light-emitting diodes , the formed light confinement walls directly covering the lateral sidewalls of the spacer walls while being in contact with them, so that the light radiation coming from each light-emitting diode and directed in the direction of the adjacent light-emitting diodes is blocked by the light confinement wall which covers the spacer wall which surrounds said light-emitting diode , characterized in that the step of forming light confinement walls comprises a step of depositing a thin layer of the second material implemented so that this thin layer of the second material directly covers the lateral sidewalls of the spacer walls while being in contact with them and covers the upper edge of the light-emitting diodes and in that the step of depositing the thin layer of the second material comprises a step of filling, by said thin layer of the second material, the empty spaces delimited between the spacer walls at the level of the areas between the light-emitting diodes . - forming the array of light-emitting diodes on a support face of a substrate , this step being carried out so that each light-emitting diode has an elongated wire shape along a longitudinal axis extending along a transverse direction (Z) of the optoelectronic device oriented transversely to the support face of the substrate , - forming spacer walls made of a first dielectric material transparent to the light radiation coming from the light-emitting diodes , the formed spacer walls being such that the lateral sidewalls of each light-emitting diode , over its entire height (H) considered in the transverse direction (Z), are surrounded by at least one of the spacer walls , - forming light confinement walls formed of a second material adapted to block the light radiation coming from the light-emitting diodes , the formed light confinement walls directly covering the lateral sidewalls of the spacer walls while being in contact with them, so that the light radiation coming from each light-emitting diode and directed in the direction of the adjacent light-emitting diodes is blocked by the light confinement wall which covers the spacer wall which surrounds said light-emitting diode , characterized in that the step of forming light confinement walls comprises a step of depositing a thin layer of the second material implemented so that this thin layer of the second material directly covers the lateral sidewalls of the spacer walls while being in contact with them and covers the upper edge of the light-emitting diodes and in that the step of depositing the thin layer of the second material comprises a step of filling, by said thin layer of the second material, the empty spaces delimited between the spacer walls at the level of the areas between the light-emitting diodes . <EOS>