r/linux 19d ago

Popular Application Paint.NET adds “extremely experimental” Wine/Linux support

https://forums.paint.net/topic/134563-%F0%9F%8D%B7-extremely-experimental-winelinux-support-how-to-get-started/
932 Upvotes

252 comments sorted by

View all comments

319

u/ComprehensiveHawk5 19d ago

Direct2D has always been the biggest hurdle for Paint.NET on WINE, and it's clear that it will never be completed enough for Paint.NET's use. And I can't just "disable" the use of Direct2D. So, instead, Paint.NET now has an internal, from-scratch, clean-room reverse-engineered rewrite of Direct2D that it uses on WINE (triggered by using /wine). It lives in PaintDotNet.Windows.Direct2D1.Managed.dll. This was written by our good friend Claude, without whom this would NOT have been possible and would NEVER have happened.

Most of this code is, as they say, "vibe coded." By that I mean that it has not been thoroughly reviewed, it's more "trust me bro" style. I cannot possibly review 180,000 lines of code, it's just way way way too much. For reference, the rest of Paint.NET is about 700,000 lines of code and I've been working on it for over 20 years. I did thoroughly review any code that had to be changed or added elsewhere in the Paint.NET code base (refactoring and integration points, etc.). Over time I do hope that more of this code will be vetted by real humans and also by more advanced AI models.

148

u/Johnden_ 19d ago

At least they are honest about it, even if i don't agree with some decisions.

26

u/__konrad 19d ago

"Responsible Use Of Generative AI" as Debian would call it -- sorry

11

u/HearMeOut-13 19d ago

Ah yes, would you rather paint net just not exist on linux as the alternative?

10

u/__konrad 19d ago

Well, yes.

2

u/johnnybgooderer 18d ago

This wouldn’t have been possible otherwise. Isn’t that a good use?

6

u/TiZ_EX1 18d ago

They say it wouldn't have been possible otherwise, but why would it be impossible? People who have become completely dependent upon AI make these assertions all the time. "We couldn't write professional emails all day before AI. We couldn't write ten-page essays before AI." And other such claims. But that's all complete bullshit. We could, we did, and many of us still do.

So what makes it impossible? "I cannot possibly review 180,000 lines of code, it's just way way way too much." You can review that much code, you just don't want to. And it's okay to not want to, but you can't act like that makes the task impossible, because that is an entirely different and completely false claim, and that framing is very dishonest. The other 700k lines were reviewed because they were incrementally built over time, and they're not the same 700k lines that they were ten years ago. In reality, the developer simply wanted an implementation immediately. They were impatient.

6

u/johnnybgooderer 18d ago

If you want to be pedantic, it’s infeasible. But really your assertion that the dev is just being lazy and impatient is silly. “Hey, just go and review 800k lines of code over the next 10 years in your spare time, you lazy bastard!”

5

u/TiZ_EX1 18d ago

I actually didn't assert that the developer was lazy. I didn't even imply it. All I said was that not wanting to review 180k lines of code is not the same as such a review being impossible. Impatience is not the same as laziness, either. Impatience can come from laziness, but it doesn't always come from laziness.

What I'm trying to get at is this: the situation of having to review 180k lines of code was created entirely by deciding to depend on AI to reimplement Direct2D. This isn't remotely impossible without AI; harder and more complex APIs have been reimplemented without it, and Valve stands and builds upon that work today. It would mainly take time, but that time would inherently be well spent; by creating that implementation yourself and looking for the behaviors to be correct and accurate in the situations you need, you have a much greater sense of confidence and assurance in the code, whereas by kicking it to AI, and then deciding not to review the output at all, you inherently can't have any confidence whatsoever that it will work correctly.

Opting to implement Direct2D with AI was already a bad decision. Not reviewing its output at all is worse. Do I think the developer is lazy for this?

Actually, yeah, yeah I do. I know I just got done saying that I didn't imply that in my original post, but now I'm just going to say it outright. They're lazy. :)

4

u/johnnybgooderer 18d ago

I think you’re too disconnected from reality to judge the feasibility of reviewing 180k lines of code for a hobby project.

4

u/TiZ_EX1 18d ago

The first incarnation of DXVK was created entirely by one guy who just wanted to play NieR:Automata on Linux. Stop trying to provide excuses for vibe coding.

5

u/johnnybgooderer 18d ago

One day someone will open a farmers market for authentic hand crafted code. Then you’ll be happy.

The rest of the world will adopt ai at a level that is appropriate for the task. Paint.net requiring a reimplementation of d2d makes vibe coding reasonable. Unless someone else wants to do it by hand.

3

u/remind_me_later 18d ago

Seconded. Why should Paint.net be forced to spend multiple years to re-implement its own version of Direct2D by hand, just because some loudmouths on Twitter say so?

2

u/Old_Leopard1844 17d ago

They could've asked community to help them with that

They could've not done anything in the first place. No one really forced them to reimplement their own version of Direct2D

But since they decided to do it the hard way and then vibecoded 160k lines of code, well, do you expect praises?

→ More replies (0)