OgreMagic Library[** MagicPro Ver 0.5 released **]

A place to show off your latest screenshots and for people to comment on them. Only start a new thread here if you have some nice images to show off!
Post Reply
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Ok irrdev.

Hrer is the first post
El Ahly is international Club now.

What a wonderful work that you have done!.

Congratulations this wonderful level
And this is the second one
Thanks for your good words

Is your name Omar or I am incorrect?

Long life for El Ahly Club
Here is an other demo , it is a Credits demo.

Demo feature
=========
1- dark Background Image
2- vertical scrolling text
3- playing movie masked by the scrolling text
4- gradually fading in the lowest scrolling text and fading out the upper scrolling text

Idea of demo
=========
I have rendered a scrolling test to texture , and created an alpha mask sprite so the alpha value is 1.0 in the middle of sprite and it gradually decrease to 0.0 in the upper and lower sprite edge, then I have used the next shader program to make the effect.

Here is the alpha mask sprite

Code: Select all

AlphaMaskSprite = ML.CreateStaticSprite(1,255);
    ML.StartDrawingToSprite(AlphaMaskSprite);
    ML.ClearDrawingArea(0);
    width = ML.GetDrawingWidth();
    height= ML.GetDrawingHeight();
    for(int h=0; h<height; ++h)
     {
          ML.WriteAlphaChannel(0,h,(h>127)?255-2*h:2*h);
     }
    ML.StopDrawingToSprite(AlphaMaskSprite);
Here is the shader program

Code: Select all

ML.EditPixelProgram(HLSLProgram);
ML.AddToProgram("struct PS_OUTPUT                                         ");
ML.AddToProgram("{                                                        ");
ML.AddToProgram("   float4 Diffuse    : COLOR0;                           ");
ML.AddToProgram("};                                                       ");
ML.AddToProgram("sampler2D tex0;                                          ");
ML.AddToProgram("sampler2D tex1;                                          ");
ML.AddToProgram("sampler2D tex2;                                          ");
ML.AddToProgram("PS_OUTPUT  main(  float2 TexCoord : TEXCOORD0)           ");
ML.AddToProgram("{                                                        ");
ML.AddToProgram("       PS_OUTPUT Output;                                 ");
ML.AddToProgram("       float4 col0 = tex2D( tex0, TexCoord);             ");
ML.AddToProgram("       float4 col1 = tex2D( tex1, TexCoord);             ");
ML.AddToProgram("       float4 col2 = tex2D( tex2, TexCoord);             ");
ML.AddToProgram("       Output.Diffuse = float4(col0.rgb,col1.a*col2.a);  ");
ML.AddToProgram("       return Output;                                    ");
ML.AddToProgram("}                                                        ");
ML.CompilePixelProgram(HLSLProgram,"main");
download and see the video of the demo
http://bcxdx.spoilerspace.com/video/Credir.wmv

Here is a screen shots of my demo

Image

Image

Image

Image

Edited:
see the full source code here
http://www.freewebs.com/ogremagic/Credits.html
dr_amr
Halfling
Posts: 65
Joined: Wed Mar 02, 2005 2:22 am

Post by dr_amr »

اسمي عمرو يا باشا

= my name is Amr, pal ( not actually pal but this is the clothest translation :p )
I love OGRE !
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

dr_amr wrote:اسمي عمرو يا باشا

= my name is Amr, pal ( not actually pal but this is the clothest translation :p )
:D عاشت الاسامي يا عمرو باشا

ok , This time I have converted a nice scrolling text with mirror effect Demo from Amos Basic of Amiga Computer.

See full source code
http://www.freewebs.com/ogremagic/MirrorFontDemo.html

Here are a screen shots

Image

Image

Image

Image

Image
imtrobin
Greenskin
Posts: 117
Joined: Mon Jul 10, 2006 5:37 am
Contact:

Post by imtrobin »

You don't provide source for library? What is the licensing for this?
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

the library is closed source , so that there is no scouce code of the library itself , but all the examples these come with it is open source , and you can see them in my site before you download the library.

the licensine is , it is free library , so you can use it as you want and ofcourse the examples too.
User avatar
Game_Ender
Ogre Magi
Posts: 1269
Joined: Wed May 25, 2005 2:31 am
Location: Rockville, MD, USA

Post by Game_Ender »

This is a little off topic but can you give me some insight about why do this (free but not open source)? I can understand not wanting to run an open source project, but what harm is there in giving away the source for something which already give away? By give away I just mean a zip that contains the source right next to the binary download.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Ok.

First what is the conflict or problem about free stuff of project and it is a closed sources, many programs in the net is free to use and in the same time it is a closed source project.

So why is the examples are open source, for example just take any language that you can found in the net , you will see that , it contains the bins , the libs and the Open source examples to allow the users of this language to learn how to use this language and in the same time the compiler and the Libs of the language are closed source , also some of this language is for free.

So that , I made the examples to be open source just for learning purpose , the users of my library will learn that how to use the library and how to combine it with Ogre Source code from the Open Source examples.

Finally it is for free because , I do not want to gain any money from my programming work , it is my favorite habit.

Hope that shade some light.
imtrobin
Greenskin
Posts: 117
Joined: Mon Jul 10, 2006 5:37 am
Contact:

Post by imtrobin »

The reason to give out source so users can recompile with their environment. Like recently, I noticed that after I installed VSNet 2005 SP1, all the older libraries compiled without SP1 will not work due to manifest file check(e.g. the precompiled dependencies in Ogre too), so I need to recompile those libraries sometime.

Even in advanced cases, where I may use a different STL library like STLPort or Dinkumware, it would be required to compile all the libraries to use the same environment.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Are you saying that you download my magic DLL bin file, libs bin file and tried to compile any example and then it refused to run because of manifest file of my DLL?

I really do not know a lot about manifest file but I have include it with my dll in bin_zip_file.
User avatar
pjcast
OGRE Retired Team Member
OGRE Retired Team Member
Posts: 2543
Joined: Fri Oct 24, 2003 2:53 am
Location: San Diego, Ca
x 2
Contact:

Post by pjcast »

Emil_halim wrote:Are you saying that you download my magic DLL bin file, libs bin file and tried to compile any example and then it refused to run because of manifest file of my DLL?

I really do not know a lot about manifest file but I have include it with my dll in bin_zip_file.
Well, there are several difference compiler + stl options for just Windows. Do you really want to support them all (stlport, ms stl, VC7, VC8, CodeBlocks, etc etc)? By opening sourcing it, since it is free already, you can just say: "heh, you have the source, compile it yourself and find the problem." ;) Plus, there is the issue of multi-platform compatibility - do you really want to support multiple platforms yourself? I think I recall you mentioning that your lib uses DirectX itself, so maybe it is not a concern for you. However, I am sure there are crossplatform ways to do what you are doing.
Have a question about Input? Video? WGE? Come on over... http://www.wreckedgames.com/forum/
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

pjcast wrote: Well, there are several difference compiler + stl options for just Windows. Do you really want to support them all (stlport, ms stl, VC7, VC8, CodeBlocks, etc etc)? By opening sourcing it, since it is free already, you can just say: "heh, you have the source, compile it yourself and find the problem." ;)
Yes , I want to support all kind of compilers , and it seems that the only way to make that is to release the source code of the library it self and this will take some times to clean and document the source of library and I will include the licensing of it .
pjcast wrote: Plus, there is the issue of multi-platform compatibility - do you really want to support multiple platforms yourself? I think I recall you mentioning that your lib uses DirectX itself, so maybe it is not a concern for you. However, I am sure there are crossplatform ways to do what you are doing.
A few days ago , there was a contact between me and Mr xabila for porting the library to linux system , already implemented a lot of features under OpneGL but I have some problem with movie stuff.

Edited

I have a question.

If I want to make the purpose of releasing source code of the library itself for compiling it only and only use the DLL , and not to use any part of it , so what can I do ?
User avatar
Game_Ender
Ogre Magi
Posts: 1269
Joined: Wed May 25, 2005 2:31 am
Location: Rockville, MD, USA

Post by Game_Ender »

Make the license LGPL same as Ogre's. That will for all intents and purposes make the it so that your code will not be used included in other closed source projects. Yet still allows people to use the DLLs. Note other LGPL projects, such as Ogre could use your code, but you would still be acknowledged as the author.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Ok, thanks Game_Ender I will do it as you said.

Now back to my work, this time I have converted an other Amiga Demo , it was writing in 1990 with DevPac Assembly for Amiga Computer , and I converted it last year to work with my Magic Library For Irrlicht.

Now it is works with Ogre , it is one of my favorite Amiga demo in that time.

Here is the source code

http://www.freewebs.com/ogremagic/AmigaZoweeDemo.html

Here are a screen shots

Image

Image

Image

Image
User avatar
johnhpus
Platinum Sponsor
Platinum Sponsor
Posts: 1186
Joined: Sat Apr 17, 2004 2:49 am
x 3

Post by johnhpus »

Porting old demos is a cool way to make a demo for your library. It looks really useful, and if I weren't locked into an existing solution for my current project, I would give it a try.

I'll definitely keep the magic library in mind for my next project. Good luck and congrats!
imtrobin
Greenskin
Posts: 117
Joined: Mon Jul 10, 2006 5:37 am
Contact:

Post by imtrobin »

Emil_halim wrote:Are you saying that you download my magic DLL bin file, libs bin file and tried to compile any example and then it refused to run because of manifest file of my DLL?

I really do not know a lot about manifest file but I have include it with my dll in bin_zip_file.
Maybe I will try to explain about manifest files. In VC 8, MS tries to fix DLL hell problem by putting a hash check for the dlls the exe uses. Most programs uses the dll version of the runtime library.

This problem happens if we install a new service pack and recompile our application, it will be a different signature from the libraries who are compiled before the service pack is applied. This is not a problem before VC 8 because there is no hash check for the runtime dll and we can use runtime dlls with VC 7.1 with any service packs interchangeably.

So if you are doing a prebuilt version with VC8, you need to state which SP you are using.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

@johnhpus:
thank you.

@imtrobin:
now I have seen , any way I will release the source code of the library with LGPL license as soon as I can, thanks you for your explaination.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Hi all

Just I want to know your Own Opinion about my LGPL license , what do you suggest?

Code: Select all

/***************************************************************************
                  This source file is part of
                     Magic Library For Ogre
                       beta version 0.40
                         by Emil Halim

  Copyright (c) 2006-2007 to Emil Halim

  this purpose of releaseing source code is only for supporting all kind of compilers these
  you may use with Magic Library , so copy any part of this isnot allowed , just
  compile it and use the DLL only with your project.

  This program is free software; you can redistribute it and/or modify it under
  the terms of the GNU Lesser General Public License as published by the Free Software
  Foundation; either version 2 of the License, or (at your option) any later
  version.

  This program is distributed in the hope that it will be useful, but WITHOUT
  ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
  FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more details.

  You should have received a copy of the GNU Lesser General Public License along with
  this program; if not, write to the Free Software Foundation, Inc., 59 Temple
  Place - Suite 330, Boston, MA 02111-1307, USA, or go to
  http://www.gnu.org/copyleft/lesser.txt.

/***************************************************************************/

User avatar
Levia
Halfling
Posts: 45
Joined: Fri Feb 03, 2006 9:56 pm
Location: The Netherlands

Post by Levia »

Its not as simple as that. Making it LGPL, basically mean you dont have any control over what the user can do with it, as long as they inherit the license aswell.

this is not allowed:
so copy any part of this isnot allowed , just
compile it and use the DLL only with your project.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Ok , I got it .

What about the first paragraph only , I.e. without the LGPL License?
User avatar
haffax
OGRE Retired Moderator
OGRE Retired Moderator
Posts: 4823
Joined: Fri Jun 18, 2004 1:40 pm
Location: Berlin, Germany
x 7
Contact:

Post by haffax »

Not exactly lawyer-speak, but it is clear what you mean. But you should rephrase it in a positive way. Don't tell the user what he is not allowed to do, tell him what is allowed and that all other rights are reserved.
team-pantheon programmer
creators of Rastullahs Lockenpracht
imtrobin
Greenskin
Posts: 117
Joined: Mon Jul 10, 2006 5:37 am
Contact:

Post by imtrobin »

Perhaps it is easier to state why you would want the user to not copy or modify the code? Are you intending for a commercial license or just want to protect people from cloning it?
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

@haffax:

what about this

Code: Select all

This program is distributed in the hope that it will be using
With all kinds of Compilers , so Compile the library and only 
Use the DLL with your own Project. 
@imtrobin:

Surely , no commercial intention , just as you said , protect people from cloning it.
Shadow007
Gremlin
Posts: 185
Joined: Sat May 07, 2005 3:27 pm

So, basically

Post by Shadow007 »

So, basically what you want to tell is this :

Redistribution is permitted in binary form ONLY ie. NO source code redistribution is allowed.

Is that it ?
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

yes , also use the DLL itself not part of the source code.
User avatar
Emil_halim
Gnome
Posts: 337
Joined: Fri Oct 27, 2006 8:56 am
Location: Alex, Egypt
x 1
Contact:

Post by Emil_halim »

Ok here is the final one.

Code: Select all

/***************************************************************************
                  This source file is part of
                     Magic Library For Ogre
                       beta version 0.40
                         by Emil Halim

  Copyright (c) 2006-2007 to Emil Halim

  This Source code is distributed in the hope that it will be using With all
  kinds of Compilers , so Compile the library and only Use the DLL with your
  own Project. If you make any Improvement to  The library please let me know.

  all rights are reserved.

/***************************************************************************/
And I have Uploaded the source code of the library to my website and here is the direct Link .

http://bcxdx.spoilerspace.com/Ogre/Magi ... er0.40.zip

try to compile it with your own compiler.

Enjoy it.
Post Reply