The premise of this movie is that almost the entirety of the world's population has been turned into vampires by a virus. Whatever humans haven't been turned into vampires are used as food by the new society. I think the movie focuses on a vampire that finds some uninfected humans and decided to harbor them. Later on, it is discovered that a vampire's blood that has somehow been treated is the cure for the virus.
Sounds like Daybreakers (2009).
Daybreakers is a 2009 science-fiction action horror film written and directed by Michael and Peter Spierig. The film takes place in a futuristic world overrun by vampires, and centers around a vampiric corporation which sets out to capture and farm the remaining humans while researching a substitute for human blood. Ethan Hawke plays vampire hematologist Edward Dalton, whose work is interrupted by human survivors led by former vampire "Elvis" (Willem Dafoe), who has a cure that can save the human species.
In 2009, a plague caused by an infected bat transforms most of the world's population into immortal vampires. The human population plummets, leaving vampires with a severe shortage of blood; vampires deprived of blood degenerate into psychotic, bat-like "subsiders". Most humans are captured and harvested in laboratory farms while scientists research a synthetic blood substitute. As sunlight is deadly to vampires, underground passages and UV-filtered cars are built for safe travel, while the few free humans travel by day, hiding in open spaces.
In 2019, Edward Dalton is the head hematologist for Bromley Marks, a pharmaceutical company which is the largest supplier of human blood in the US. Edward and colleague Christopher Caruso are developing a blood substitute.
Driving home from a failed experiment, Dalton accidentally runs another vehicle off the road. Discovering the occupants are humans, Dalton hides them from police. Before they part ways, their leader, Audrey, learns Edward's name and occupation from his ID badge.
At home, Edward is surprised by his estranged brother Frankie. Frankie's gift of a bottle of pure human blood reignites a long-standing argument – Edward refuses to drink human blood and uses animal blood instead, while Frankie enjoys his vampire status. A subsider, a gardener from Edward’s neighborhood, invades the house, forcing the brothers to kill it.
The next morning, Audrey visits Edward's home, giving him instructions for a meeting. There, Edward is introduced to Lionel "Elvis" Cormac, a human who was once a vampire. Before he can explain his reversion, a military team arrives with Frankie, who followed Edward and intends to capture Cormac and Audrey. Audrey knocks Frankie unconscious and the three escape. Cormac reveals that he was cured of vampirism when a car crash ejected him from his sun-proof vehicle. Elvis burst into flames in the sunlight but landed in a river, having been exposed to the sun for a precise length of time to turn him human again. Edward agrees to help Cormac find a way to recreate the cure and prevent human genocide.
At a vineyard that night, Edward meets more humans and Senator Wes Turner, a vampire secretly helping the colony develop a cure. An approaching convoy of humans is captured, and vampire soldiers track the location of the vineyard, forcing Turner and the humans to flee. Audrey, Cormac, and Edward stay behind, and together they recreate the method by which Cormac reverted to human form, curing Edward of vampirism. They later find Turner and all the humans dead.
Alison, one of the captured humans, is revealed to be the daughter of Charles Bromley (CEO of Bromley Marks) who refused to become a vampire. Charles has Frankie forcibly turn her into a vampire, but she refuses to drink human blood. Devolving into a subsider, Alison and others are executed by being burnt to death by sunlight. Upset at witnessing Alison's death, Frankie seeks out his brother. The military imposes martial law to control the subsider population.
Edward, Cormac, and Audrey break into Christopher's home and ask him to help spread the cure. Having finally discovered a viable blood substitute, and feeling overshadowed by Edward, Christopher is uninterested in a cure and summons soldiers, who capture Audrey while Cormac and Edward escape. They are found by Frankie, who agrees to help. He attacks Cormac, but drinking his blood turns Frankie human, revealing that the sunlight cure is unnecessary.
Trying to save Audrey, Edward turns himself in to Charles, who gloats about Bromley Marks' new monopoly on the blood substitute. Charles reveals his plan to continue hunting humans and sell their blood for exorbitant prices, as "people are always willing to pay extra for the real thing." Edward taunts Charles into biting him, turning Charles human.
Edward leaves Charles at the mercy of soldiers on the brink of becoming subsiders. Frankie arrives and draws the soldiers’ attention to allow Edward and Audrey to escape. In the ensuing feeding frenzy, only six soldiers are left standing, now cured. To conceal the cure, Christopher shoots the soldiers and is about to shoot Edward and Audrey when Cormac kills him with a crossbow.
The three survivors drive off into the sunrise. In a voiceover, Edward announces the cure will change the general population back to restore humanity as a subsider flies overhead, suggesting that it may already be too late.