From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Blake Shaw Newsgroups: gmane.lisp.guile.user Subject: Re: good papers on graphics in scheme/lisp? Date: Fri, 04 Mar 2022 02:10:15 +0700 Message-ID: <871qzilunc.fsf@nonconstructivism.com> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="14156"; mail-complaints-to="usenet@ciao.gmane.io" Cc: guile-user@gnu.org To: Olivier Dion Original-X-From: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Thu Mar 03 20:16:09 2022 Return-path: Envelope-to: guile-user@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1nPqvo-0003Ua-J7 for guile-user@m.gmane-mx.org; Thu, 03 Mar 2022 20:16:09 +0100 Original-Received: from localhost ([::1]:57408 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1nPqvn-0000zF-2g for guile-user@m.gmane-mx.org; Thu, 03 Mar 2022 14:16:07 -0500 Original-Received: from eggs.gnu.org ([209.51.188.92]:58920) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nPqqW-0002tm-2T for guile-user@gnu.org; Thu, 03 Mar 2022 14:10:43 -0500 Original-Received: from out2.migadu.com ([188.165.223.204]:18855) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1nPqqT-0006aq-GN for guile-user@gnu.org; Thu, 03 Mar 2022 14:10:39 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=nonconstructivism.com; s=key1; t=1646334632; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding; bh=hK+5ia4lrIBv5Uqf9UAkkN2HCf6bEnN7dFFxiFC+Ca0=; b=R7bFwCE6r0F5rS2utX7xKIVTt/kBwEcqMh7l395udvBHgG73D0Hv6CkBx8xqN0SJJ9HRsq ykICwAtPfF2lv00hu9VTT02cOK0jZB2EucBd58Ee844vDhlPO4Q7SYDZ8oPIixxsF5Zi5W pOGypfu8iRFJWdnk2FDcrr8c/U5dsAQ= Gcc: nnimap+imap.migadu.de:sent.2022 X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. User-Mail-Address: blake@nonconstructivism.com X-Migadu-Flow: FLOW_OUT X-Migadu-Auth-User: nonconstructivism.com Received-SPF: pass client-ip=188.165.223.204; envelope-from=blake@nonconstructivism.com; helo=out2.migadu.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: guile-user@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: General Guile related discussions List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guile-user-bounces+guile-user=m.gmane-mx.org@gnu.org Original-Sender: "guile-user" Xref: news.gmane.io gmane.lisp.guile.user:18157 Archived-At: Olivier Dion writes: > On Wed, 02 Mar 2022, Blake Shaw wrote: > >> Next week I will start working on my installation /Scribble Jam/ for >> iLight Singapore[2], and I'm planning to do it all in Guile OpenGL + >> GLSL. I've started fiddling with Guile OpenGL and it seems pretty >> complete and performant (I haven't experienced any GC hiccups from the >> small stress tests I've put it through, but its still only minor >> stuff). > >> There is still a chance I might choose to create a Guile >> interface to a subset of the C++ OpenFrameworks[3] library > > FFI for C++ is a real pain to do. You can't juste use plain Scheme (at > least I don't know how for C++). If you go that route, I have C++ > templates that can help you for the glue between Scheme and C++ > (e.g. std::vector, std::map, std::string). Thanks for this heads up, I've been curious about the C++ FFI experience in Guile (while less excited about actually getting into the weeds). If I go this route, I'll probably wind up approaching it from using libguile, adding a guile interpreter as an abstraction layer over the creative coding I'm doing in C++, as my experience with that has so far been pretty straight forward (in pure C). But I also worry that if I go down this route, out of habit and familiarity I'll for the most part just end up doing the whole thing in C++, with Guile acting as more of a sort of controller for livecoding. Which could end up really great! I'll be putting a couple days aside this coming week to take it for a test drive with old projects to see how it feels. But after some hacking tonight I'm feeling pretty excited about the pure-Scheme route, so if it appears feasible after weighing my options it will certainly be the direction I head in. > >> Also, one last thing, I'm considering attempting to create a DSL that >> compiles to a subset of GLSL like Chicken's GLLS library[4], as I'm >> becoming more and more interested in compilation. I remember reading >> somewhere about a Guile library that allows you to write C in Guile, > > I think you are refering to > . > Yes! thank you so much, this is it. And looking through the code base I can see there are already some pieces there that seem to illustrate how to work out formatting issues I was confused by as a newcomer to srfi-159 (which is amazing, I might add for folks searching the archive. go check it out ASAP:). I've also come across srfi-166, which is Alex Shinn (same author)'s monadic formatting procedure that deprecates fmt/srfi-159 in order to improve accuracy and safety, which apparently caused some minor headaches in glls. so I'll probably be porting srfi-166 to guile as well :) I've actually gone ahead and started porting GLLS to Guile and to my astonishment its been a piece of cake so far. If I keep up this pace I could even have a working prototyp by the end of the weekend -- but that just seems to good to be true (am I finally acquiring the famed lisp super powers? tbd) > There's also that can be helpful if > you're familiar with LALR(1) parsers. > > Regards, > old yes! nyacc has been extremely helpful. great software, my thanks to the authors, I was even able to use it to wrap glValidateProgram, which seems to be fine "out of the box", so to speek. thanks! b -- “In girum imus nocte et consumimur igni”