At scale, digital piracy largely boils down to:
1. People who do it for fun
2. Would-be consumers who are priced out or locked out
The first group is, if anything, only encouraged by attempts to stop them, and generally won't pay no matter what. The second group would pay, if it were possible and economical for them to do so.
Focusing on the second group, you can say that every pirated copy is a "lost sale" but the sale that you've "lost" would only happen on terms favorable to the consumer. In other words, supposing you sold a product for $50 in developed countries, you're not going to get the equivalent at any significant volume in developing countries. But if you were to cut the price to the local equivalent of say $10, you'll probably get lots of sales. Refusing to market-adjust your prices, or even more so, refusing to sell in a market altogether, is a great recipe for piracy. Yet estimating that piracy at top-shelf price times number of downloads is grossly unrealistic. The piracy cost you what you should have sold it for; but of course, if you had done that, you wouldn't have seen so much piracy.
There are some exceptions to this, of course. Certain categories of media are extra prone to piracy (adult/restricted content in particular) regardless of price. Piracy also happens because of factors the publisher can control besides price; for example, anti-piracy measures in some PC video games have gotten so onerous that pirates are getting a better quality product; Switch games (in)famously run a lot better on PC than the console they were actually designed for; Blu-rays are so chock full of dated advertisements and anti-piracy warnings that can't be skipped that a torrented MKV is preferable; etc.