NB & Squeak (Re: [squeak-dev] Opengl and Squeak)

Igor Stasenko siguctua at gmail.com
Mon Aug 20 22:59:37 UTC 2012


On 21 August 2012 00:31, Levente Uzonyi <leves at elte.hu> wrote:
> On Sat, 18 Aug 2012, Igor Stasenko wrote:
>
>> On 17 August 2012 08:51, dimitris chloupis <thekilon at yahoo.co.uk> wrote:
>>>
>>> Well if FFI works okish in squeak I dont have a need for nativeboost,
>>> since
>>> I prefer to code in smalltalk than assembly.
>>>
>> You don't have to learn assembly to use OpenGL with Nativeboost.
>> Also, replying to previous post, it supports all 3 major platforms -
>> mac, unix and windows.
>>
>> As for making NB working on Squeak, except from VM there's only one
>> significant change
>> made in Pharo but not in Squeak (afaik) is to improve the debugger
>> support for custom primitives.
>
>
> Can you give us some pointers where to look for these changes?
>
>
Mainly it consists of two parts,
originally started by Mariano and then somewhat polished by me..
http://code.google.com/p/pharo/issues/detail?id=5459
(Mariano, can you please give a link to the issue for your changes,
because i don't remember it).

Also for a full context, where everything is started from please google for
"is there a way to avoid all the #tryNamedPrimitive:with: * in ProtoObject"
topic in pharo mailing list.

> Levente
>
>>
>>> I decided to continue my project 'Ephestos' is squeak, since Blender
>>> python
>>> has been a complete failure, the opengl implementation is buggy , still
>>> stuck to version 1.1 and it consumes CPU cycles like crazy (simple hand
>>> morph system  consume 50% of my dual core) so fingers crossed it will
>>> works
>>> with squeak. I dont care for fancy features like nativevboost if its
>>> buggy,
>>> non cross platform and slow.
>>>
>>> Seems I am not getting replies from other than you lawson , I assume
>>> something is wrong with my squeak-dev subscription.
>>>
>>> Anyway, will test FFI from CroquetGL and hopefully it will work for me
>>> too.Thanks for the help.
>>> ________________________________
>>> From: Lawson English <lenglish5 at cox.net>
>>> To: squeak-dev at lists.squeakfoundation.org
>>> Sent: Thursday, 16 August 2012, 23:07
>>>
>>> Subject: Re: [squeak-dev] Opengl and Squeak
>>>
>>> thanks Hans-Martin. I'll update my videos with that bit of info too.
>>>
>>> I have been playing quite a bit with NativeBoost lately and it offers
>>> some
>>> very nice features that anyone wanting to make a game or other
>>> realtime-ish
>>> application will find beneficial, including the ability to create a
>>> "cascade" of foreign file calls within a single method, or even program a
>>> bit of custom x86 assembler. I don't know what will be involved to port
>>> it
>>> to Squeak, but Igor's talk suggests that the only "special" bit is
>>> already
>>> present in the VM, which should work with either Pharo or Squeak. The
>>> rest
>>> is just glue code at the Smalltalk level, which means that it is
>>> perfectly
>>> doable to get it working on Squeak, in theory at least.
>>>
>>> Native boost also offers a way of passing an arbitrary  ByteArray to an
>>> external function as though it were a normal pointer to a bit of
>>> malloc-ed
>>> memory, which can be VERY useful with certain libraries, that and the
>>> ability to actually malloc memory for a ByteArray from the OS level heap,
>>> opens up all sorts of possibilities like having an external lib render
>>> directly into a BitMap object asynchronously from its own OS level thread
>>> so
>>> that each update can show the library's progress in a morph without any
>>> further coding.
>>>
>>> I'm actually working on a simple MandelBrot Set generator lib in C to
>>> demo
>>> this.
>>>
>>> L.
>>>
>>>
>>>
>>> On 8/16/12 12:38 PM, Hans-Martin Mosner wrote:
>>>>
>>>> The Squeak OpenGL bindings are on squeaksource.com. Here is an older
>>>> mail
>>>> exchange describing the installation procedure:
>>>> http://forum.world.st/OpenGL-in-4-1-or-later-td3794639.html I have just
>>>> tried it in a 4.3 image, and after fixing three small glitches it
>>>> worked: -
>>>> somehow the method OGLUnix>>#openGLLibraryName has an illegal character
>>>> at
>>>> the end (it's probably being handled as whitespace in other Squeak/Pharo
>>>> images) - the method Point>>#area does not exist. I implemented it as
>>>> returning x*y, which works. - the method printShowingMaxDecimalPlaces:
>>>> does
>>>> not exist. I used printString instead. That should get you started.
>>>> Cheers,
>>>> Hans-Martin
>>>
>>>
>>>
>>> -- Squeak from the very start (introduction to Squeak and Pharo Smalltalk
>>> for the (almost) complete and compleate beginner).
>>> https://www.youtube.com/playlist?list=PL6601A198DF14788D&feature=view_all
>>>
>>>
>>>
>>>
>>>
>>>
>>>
>>
>>
>>
>> --
>> Best regards,
>> Igor Stasenko.
>>
>>
>



-- 
Best regards,
Igor Stasenko.


More information about the Squeak-dev mailing list