pasvulkan icon indicating copy to clipboard operation
pasvulkan copied to clipboard

PascalABC Support

Open BareGamer opened this issue 2 years ago • 6 comments

Hello BeRo, I wanted to use Vulkan.pas in PascalABC, however it didn't work out of the box (which wasn't really surprising). So I added preliminary support for it in vkxml2pas.dpr. Would a pull request with patches for PascalABC be accepted/appreciated? Thank you in advance. P.S. PascalABC is .net based, so it can work out of the box on Windows, Mac and Linux and possibly mobile.

BareGamer avatar Nov 04 '21 15:11 BareGamer

You are welcome to share them with me, and I will have a look at them.

BeRo1985 avatar Nov 04 '21 19:11 BeRo1985

I will try to do a pull request during the next day then. Would that be ok?

BareGamer avatar Nov 04 '21 21:11 BareGamer

Yep

BeRo1985 avatar Nov 04 '21 22:11 BeRo1985

I was making sure the program compiles in PascalABC before working on Vulkan patches and suddenly it gave me a compilation error (or rather an "exe not found" error even though the compiler didn't show any issues in the console). Looks like the problem is somewhere in the compiler/runner/whatever and is an unhandled exception. I will try to open an issue on PABC's github, but I'm not hopeful that'll get fixed at all/will be fixed quickly. Worsening the issue is the fact that I can't really pinpoint what specifically disrupts the execution. IMG_20211105_074554

BareGamer avatar Nov 05 '21 06:11 BareGamer

Judging by the response of a contributor, the compiler is crashing because of a Stackoverflow. So looks like that'll have to be fixed first in order for things to progress. Also, there might be issues with sizeof(class) as it doesn't really do anything.

As of 29.11, even though the compiler is (hopefully) fixed, I will be able to start working on the patches again only in about 2 weeks, so progress will still be made, but rather in the department of fixing the incompatibilities with fpc introduced by my changes.

BareGamer avatar Nov 05 '21 13:11 BareGamer

@BeRo1985 for about a week now I have been trying to finalize the patches and encountering more and more functions pabc doesn't have natively and that are either impossible or very difficult to implement. However I think there is still a way: compile the needed functions in fpc as a dll and {$rederence} (load) this dll in the source. Do you think that approach would work?

BareGamer avatar Dec 11 '21 21:12 BareGamer