Polished 3D package for some simulations

107 views
Skip to first unread message

na...@manicmind.earth

unread,
Apr 7, 2021, 10:32:02 PM4/7/21
to racket...@googlegroups.com
Hello. I am exploring some physics ideas and I was thinking about making some 3D simulations to flesh out some of my ideas and to demonstrate them to others. Are there any polished packages for doing 3d stuff in racket? I looked just briefly a while back and didn’t have much luck. I think I found some really old sdl bindings or something and got kinda discouraged in the hunt and quit cuz it wasn’t too pressing.

Performance is not a huge deal as it’s mostly for concepts and not a real time interactive game or anything.

Any recommendations?

kamist...@gmail.com

unread,
Apr 8, 2021, 2:22:10 PM4/8/21
to Racket Users
Have you tried out Pict3D [1]?
There is also a library from Matthew Flatt that can create 3D Text / extruded pathes: [2]

Personally I currently use opengl [3], these bindings support higher opengl versions than the [4]
(which only support opengl 1.5 according to its documentation)

I can't say exactly up to which opengl version [3] has working bindings, these bindings were automatically generated, but that stopped working at some point.
(Apparantly the input that was used for the generation isn't provided for recent opengl versions anymore, so the generator has to be fixed or replaced to work with a different input/description)


Hendrik Boom

unread,
Apr 8, 2021, 3:59:29 PM4/8/21
to Racket Users
On Thu, Apr 08, 2021 at 11:22:10AM -0700, kamist...@gmail.com wrote:
> Have you tried out Pict3D [1]?

Two significant flaws with Pict3D:

* It does not have a mechanism for attaching a texture to an object.

* It does not allow one to cut one #D object out of another.
(such as using a cylinder to drill a round hole in a block of wood)

Otherwise it's an impressive peve of work.

> There is also a library from Matthew Flatt that can create 3D Text /
> extruded pathes: [2]
>
> Personally I currently use opengl [3], these bindings support higher opengl
> versions than the [4]
> (which only support opengl 1.5 according to its documentation)
>
> I can't say exactly up to which opengl version [3] has working bindings,
> these bindings were automatically generated, but that stopped working at
> some point.
> (Apparantly the input that was used for the generation isn't provided for
> recent opengl versions anymore, so the generator has to be fixed or
> replaced to work with a different input/description)

Exactly. I've been struggling with this last year, and I sort of gave up.
I'm thinking of looking at it again.

What happened to the spec is that the entire thing has been recoded from a
completely ad-hoc formalism to a slightly less ad-hoc XML-based formalism.
Everything is different. And the new one is somewhat inconsistent about
the placement of asterisks in the XML phrases that form function prototypes.

I've been using sgl for my own work. I suspect it to be largely
hand-coded, but it seems to work.

There's also a binding for Vulkan, which I don't think has been used vary
much, and so may still pose surprises.

https://docs.racket-lang.org/vulkan/index.html

I don't know how well any of this works on a Mac, which I gather is going
its own way for graphics, perhaps in the cause of incompatibility.

-- hendrik
> --
> You received this message because you are subscribed to the Google Groups "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to racket-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/67072c79-aac7-40a1-8774-2d684c7476d1n%40googlegroups.com.

Nathaniel W Griswold

unread,
Apr 11, 2021, 10:25:53 PM4/11/21
to Hendrik Boom, Racket Users
Thanks all, i’m just going to see if Pict3D works out. I didn’t know about it before. I don’t really need textures for this project as i am starting with just particles moving around and wave superposition.

Nate
> To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/20210408195922.zdq5ruhr4ufvqgc4%40topoi.pooq.com.

Hendrik Boom

unread,
Apr 12, 2021, 7:46:56 AM4/12/21
to Racket Users
On Sun, Apr 11, 2021 at 09:25:48PM -0500, Nathaniel W Griswold wrote:
> Thanks all, i’m just going to see if Pict3D works out. I didn’t know about it before. I don’t really need textures for this project as i am starting with just particles moving around and wave superposition.

It might work for you then. It didn't for me. And I spent a while trying to
figure out how to attach textures, but the internals of Pict3d were too
much for me. Not enough internal documentation. It was easier to use sgl
directly, but I may someday have to go to serious solid modelling.

-- hendrik

Stephen Foster

unread,
Apr 12, 2021, 11:31:39 AM4/12/21
to Racket Users
In the CodeSpells project, we are using Racket + Unreal Engine.  This combo would be my recommendation for doing "3D stuff" and also anything with physics.  As you can see from the first few seconds of this video, we are spawning in Twitch users as 3D physical objects:

Dominik Pantůček

unread,
Apr 12, 2021, 2:00:58 PM4/12/21
to racket...@googlegroups.com
One clicks on your Twitch and the first thing coming from the speakers
is "Do you remember Jack? Jack Firth?"

Everyone does, of course ;-)
> <https://groups.google.com/d/msgid/racket-users/67072c79-aac7-40a1-8774-2d684c7476d1n%40googlegroups.com>.
>
> > >
> > > --
> > > You received this message because you are subscribed to the
> Google Groups "Racket Users" group.
> > > To unsubscribe from this group and stop receiving emails from
> it, send an email to racket-users...@googlegroups.com.
> > > To view this discussion on the web visit
> https://groups.google.com/d/msgid/racket-users/20210408195922.zdq5ruhr4ufvqgc4%40topoi.pooq.com
> <https://groups.google.com/d/msgid/racket-users/20210408195922.zdq5ruhr4ufvqgc4%40topoi.pooq.com>.
>
> >
>
> --
> You received this message because you are subscribed to the Google
> Groups "Racket Users" group.
> To unsubscribe from this group and stop receiving emails from it, send
> an email to racket-users...@googlegroups.com
> <mailto:racket-users...@googlegroups.com>.
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/racket-users/0d79ce2f-433d-4fff-9e06-8025963fb45fn%40googlegroups.com
> <https://groups.google.com/d/msgid/racket-users/0d79ce2f-433d-4fff-9e06-8025963fb45fn%40googlegroups.com?utm_medium=email&utm_source=footer>.

Stephen Foster

unread,
Apr 12, 2021, 2:28:35 PM4/12/21
to Dominik Pantůček, Racket Users
Hehe.  Yeah, we were discussing resyntax.

You received this message because you are subscribed to a topic in the Google Groups "Racket Users" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/racket-users/aMgL43u5icI/unsubscribe.
To unsubscribe from this group and all its topics, send an email to racket-users...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/racket-users/ae01f12b-192b-17f0-e3ba-e92bb53d827a%40trustica.cz.
Reply all
Reply to author
Forward
0 new messages