Making distro package for my GLMorphic package

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
7 messages Options
Reply | Threaded
Open this post in threaded view
|

Making distro package for my GLMorphic package

Igor Stasenko
Hello everybody!

My work which replaces squeak rendering mechanisms to use HW
accelerated OpenGL instead of memory blitting attained interest of
more and more people.
Some of you asking to publish a code to be able to play with it.

But there's a problem:

my code works only, if VM contains GLPlugin internal plugin (and
currently runs only on Windows, because i need to port plugin code to
other platforms).

To build plugin you need a C source files (platform dependent code)
and VMMaker, but i don't know how to publish C sources with my
packages.
I was directed to use SAR packages, but i never used them before and
don't know what tools i need to make them. I know that they are just
.zip files, just with special conventions - where i can read tutorial
how to make this package? Can i use them with Monticello and place on
squeaksource?

There are couple of ways, how i can distribute my code:

- accompany my code with C source files, so people can build own VM
with GLPlugin
- accompany with pre-built DLL as external plugin
- place pre-built VM executable on some site.

And final notes about plugin:
its a small piece of code which enables use GL rendering context for
main squeak window.
There's only 4 primitive functions in it!

Current VM already links GL libraries by default, and already having
primitives to create GL rendering contexts, but only for new OS
windows. I wonder why there's no support for main window and i was
forced to write this code myself. It would be nice (in future maybe)
to add my code to SurfacePlugin core platform VM files, so no extra
plugin will be required.

Also, i tried to plugin build it as external DLL, but since my plugin
using GL, it requires to be linked with opengl library. And without
modifications of make files which using for building plugins this is
not possible.
Anyways, I think its overkill to link with GL twice, since main
executable already uses it, so its better to make plugin internal.

Since we all are lazy i doubt that there many people who will to spend
their time building new VM just to be able to try my hacks and i think
i must provide an option to download binaries from somewhere. But i
don't know where i can place them to make available to all of you :)
Is there are place for hosting in squeak community where i can put my
pre-built VM executable, so people can try it with GLMorphic?

Also, i would be glad if someone will help me porting code to other
platforms. There's really not much to code, only 4 functions.

--
Best regards,
Igor Stasenko AKA sig.

Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Andreas.Raab
Hi Igor -

Igor Stasenko wrote:
> My work which replaces squeak rendering mechanisms to use HW
> accelerated OpenGL instead of memory blitting attained interest of
> more and more people.
> Some of you asking to publish a code to be able to play with it.

Nice job. I'm looking forward to giving this a try.

> There are couple of ways, how i can distribute my code:
>
> - accompany my code with C source files, so people can build own VM
> with GLPlugin
> - accompany with pre-built DLL as external plugin
> - place pre-built VM executable on some site.

All of them are fine choices. I think you should start with a binary
that allows people to try out things just for curiosity and also provide
the source code for those who want to have a closer look.

> Current VM already links GL libraries by default, and already having
> primitives to create GL rendering contexts, but only for new OS
> windows. I wonder why there's no support for main window and i was
> forced to write this code myself. It would be nice (in future maybe)
> to add my code to SurfacePlugin core platform VM files, so no extra
> plugin will be required.

The problem with this approach (and the reason why something like has
not been supported for generic 3D rendering and likely never will be) is
that you can't change the pixel format of a window once it is set. In
other words, the first bit of code that sets a pixel format freezes that
once and forever. That's a *huge* issue for use in real life situations
where you need to be able to change pixel formats for different
rendering targets.

> Also, i tried to plugin build it as external DLL, but since my plugin
> using GL, it requires to be linked with opengl library. And without
> modifications of make files which using for building plugins this is
> not possible.

Oh, but it is. Check out platforms/win32/plugins/FloatMathPlugin and
platforms/win32/plugins/MPEG3Plugin which both have non-standard
Makefiles. If you take the MPEG3Plugin as an outline it is trivial to
add the appropriate libraries to the makedll link target.

Cheers,
   - Andreas


Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Edgar J. De Cleene
In reply to this post by Igor Stasenko



El 8/23/07 6:50 AM, "Igor Stasenko" <[hidden email]> escribió:

> I was directed to use SAR packages, but i never used them before and
> don't know what tools i need to make them. I know that they are just
> .zip files, just with special conventions - where i can read tutorial
> how to make this package?

Igor.
Mading .sar with 3.10 is piece of cake.
I attach a tape made in fresh 3.10 so could or not work on distinct .image.
In case not, you need grab the Zip tool in the Tools flap.
Press first button made new archive.
Start adding any files you need into your distribution.
When ready, save and put "distribution.sar"  (or approriate name) in the
window.
If you need , could add preamble and postscript, as in .cs.

Hope this helps.

Edgar




MadeSar.tape (25K) Download Attachment
Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Igor Stasenko
In reply to this post by Andreas.Raab
On 23/08/07, Andreas Raab <[hidden email]> wrote:

> Hi Igor -
>
> Igor Stasenko wrote:
> > My work which replaces squeak rendering mechanisms to use HW
> > accelerated OpenGL instead of memory blitting attained interest of
> > more and more people.
> > Some of you asking to publish a code to be able to play with it.
>
> Nice job. I'm looking forward to giving this a try.
>
> > There are couple of ways, how i can distribute my code:
> >
> > - accompany my code with C source files, so people can build own VM
> > with GLPlugin
> > - accompany with pre-built DLL as external plugin
> > - place pre-built VM executable on some site.
>
> All of them are fine choices. I think you should start with a binary
> that allows people to try out things just for curiosity and also provide
> the source code for those who want to have a closer look.
>

Fine, i can upload then at the moment, just say me where :)
I used sourceforge before, but it takes too much time to register
project, manage it and upload files which conform they rules. I just
need to put file to be able for downloading by anyone. Can you
recommend me where i can do this without messing with gory details
such as registering, filling tons of forms e.t.c.?

> > Current VM already links GL libraries by default, and already having
> > primitives to create GL rendering contexts, but only for new OS
> > windows. I wonder why there's no support for main window and i was
> > forced to write this code myself. It would be nice (in future maybe)
> > to add my code to SurfacePlugin core platform VM files, so no extra
> > plugin will be required.
>
> The problem with this approach (and the reason why something like has
> not been supported for generic 3D rendering and likely never will be) is
> that you can't change the pixel format of a window once it is set. In
> other words, the first bit of code that sets a pixel format freezes that
> once and forever. That's a *huge* issue for use in real life situations
> where you need to be able to change pixel formats for different
> rendering targets.
>

Well, currently i don't care about pixel format :)
I'm using rigid format , 24bpp + stencil + accum buffer + choice -
double buffering or single buffering.
If platform can't give me such format, it just silently fails and user
left with default squeak software blitting.
I built my code in such way, that you must run command to enable GL
rendering and you can always fall back to default software blitting.


> > Also, i tried to plugin build it as external DLL, but since my plugin
> > using GL, it requires to be linked with opengl library. And without
> > modifications of make files which using for building plugins this is
> > not possible.
>
> Oh, but it is. Check out platforms/win32/plugins/FloatMathPlugin and
> platforms/win32/plugins/MPEG3Plugin which both have non-standard
> Makefiles. If you take the MPEG3Plugin as an outline it is trivial to
> add the appropriate libraries to the makedll link target.
>

Thanks, lets see if i can do own makefile, then i can distribute just
.dll with my packages. Of course, this is waste of system resources,
but fine choice to download and run for people who don't want/care to
run with different VM executable.


> Cheers,
>    - Andreas
>
>
>


--
Best regards,
Igor Stasenko AKA sig.

Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Igor Stasenko
In reply to this post by Edgar J. De Cleene
On 23/08/07, Edgar J. De Cleene <[hidden email]> wrote:

>
>
>
> El 8/23/07 6:50 AM, "Igor Stasenko" <[hidden email]> escribió:
>
> > I was directed to use SAR packages, but i never used them before and
> > don't know what tools i need to make them. I know that they are just
> > .zip files, just with special conventions - where i can read tutorial
> > how to make this package?
>
> Igor.
> Mading .sar with 3.10 is piece of cake.
> I attach a tape made in fresh 3.10 so could or not work on distinct .image.
> In case not, you need grab the Zip tool in the Tools flap.
> Press first button made new archive.
> Start adding any files you need into your distribution.
> When ready, save and put "distribution.sar"  (or approriate name) in the
> window.
> If you need , could add preamble and postscript, as in .cs.
>
Thanks, i'll try this out. Is it possible to upload it to squeaksource via MC?
or i can put it only to squeakmap? never used squeak map.

> Hope this helps.
>
> Edgar
>
>
>
>
>
>


--
Best regards,
Igor Stasenko AKA sig.


Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Edgar J. De Cleene



El 8/23/07 7:42 AM, "Igor Stasenko" <[hidden email]> escribió:

> Thanks, i'll try this out. Is it possible to upload it to squeaksource via
> MC?
or i can put it only to squeakmap? never used squeak map.

Not to squeaksource, until now only you could upload .mcz.
In squeakmap you don't have any problem and you could go via Universes for
3.10/
A quick way of put your code for all people try is the swiki

 http://wiki.squeak.org/squeak

You could put some starting page here and complete later .
Also could put the files in this place.
But remember in swiki you could't delete old files and could lost any
numbering scheme as by example "distribution.1.sar" etc

Edgar



Reply | Threaded
Open this post in threaded view
|

Re: Making distro package for my GLMorphic package

Göran Krampe
In reply to this post by Igor Stasenko
Hi Igor and all!

> or i can put it only to squeakmap? never used squeak map.

You can upload any kind of file to SqueakMap in fact. And if you want some
other "space" like say an ftp area or so - I can give it to you on my
server. Just email me in private.

regards, Göran