|
Post by Darkjester on May 13, 2012 1:41:12 GMT -5
Bad news  and i hadnt realize this until i re-added the dll code. any plugin that accesses basic4gls window via the win32 handle will now crash so any dlls that use win32 will have to be replaced with modifications Edit: also decided not to reuse Corona, this turned out to be way to much trouble as theres no findable bugs yet the images fail to load, so im skipping that step and upgrading the texture handling to be pure SDL its simple, it works. 
|
|
|
Post by matthew on May 13, 2012 5:16:22 GMT -5
Remember Corona requires zlib, libjpeg & libpng. Did you build it with those features enabled?
|
|
|
Post by James :) (aka Madcow) on May 13, 2012 7:43:44 GMT -5
I've tried compiling this on a mac but it can't seem to find any of the header files referring to SDL or GT is there something I need to install?
James
|
|
|
Post by matthew on May 13, 2012 8:12:46 GMT -5
If you've already installed SDL it's probably in a different location than it is on Windows. Windows Users usually install it in a separate folder so it's included like the following: #include <SDL\SDL.h>However on Linux the Header files are dumped in your main Include folder so you link: #include <SDL.h>It might be like that on a Mac, if you haven't already got it installed you can get the dmg files here.
|
|
|
Post by angros47 on May 13, 2012 9:52:34 GMT -5
If you are going to drop Corona, you could use stb_image as a replacement: nothings.org/stb_image.cThe code is public domain, it's only one C file, it works under Windows and Linux, and it supports JPEG, PNG, TGA, BMP, PSD,GIF, HDR, PIC. No external libraries are required. I used it in my OpenB3D version, it's really simple. Also, I used a subroutine from your sprite library to be able to load multiple frames from a strip (so, I'm sure that stb_image can be integrated in your code with no effort) A nice feature would be to integrate also an option to use hq4x filter ( www.hiend3d.com/hq4x.html), too: so, when a small sprite is loaded, even a larger version is stored in memory (maybe in the mipmap), and a very smooth zoom would be possible. A small plea: in the new version, could you keep the sprite library separated from the runtime module? I'd like to be able to use it in FreeBasic, too.
|
|
|
Post by Darkjester on May 13, 2012 12:27:05 GMT -5
Remember Corona requires zlib, libjpeg & libpng. Did you build it with those features enabled? Yup i dont get any linker errors, theres just a problem i cant seem to figure out no amount of debugging gives me the answer.
|
|
|
Post by DJLinux on May 13, 2012 15:22:33 GMT -5
1.) use SOIL 2.) don't use SDL use FreeGlut (let the door open for later use of multiply GL windows) 3.) remove net and joystick from compiler also (this is where plugins comes to manage this kind of things if needed) my 3 cents  Joshy
|
|
|
Post by angros47 on May 13, 2012 15:38:34 GMT -5
|
|
|
Post by DJLinux on May 14, 2012 1:01:27 GMT -5
|
|
|
Post by James :) (aka Madcow) on May 14, 2012 1:21:55 GMT -5
One improvement I suggest that we use platform conditional commenting so we don't need to change the headers and other code. I'm just running this past people. In regards to SDL and free glut, I've found a simple library called ultimate++ the syntax looks simple. www.ultimatepp.org/Unfortunately their mac port is in development still (About 85% complete as of now according to them), But I guess for now I could just create some wrapper functions do the same thing for macs or work out what doesn't work with their port so far and modify their code (I don't think we will be using the whole of U++ or any multi-platform library, at least for the existing basic4GL although I know that will change if we decide to add extra features) alternatively we can use the X11 Window Server Emulator in the mac (U++ supports X11) until the native mac port is ready. #ifdef PLATFORM_WIN32 //Windows #endif
#if defined(PLATFORM_POSIX) && !defined(PLATFORM_COCOA) #ifdef CPU_BE //Linux with a Big Endian CPU #else //Linux with a Small Endian CPU #endif #endif
#ifdef PLATFORM_COCOA //#ifdef CPU_BE //Mac with a Big Endian CPU //#else //Mac with a Small Endian CPU //#endif #endif
Obviously this would require us to set up a few profiles when compiling the program that target each platform and define each of these variables (i.e if a "Windows"profile was selected in codeblocks it defines "PLATFORM_WIN32").
|
|
|
Post by Darkjester on May 14, 2012 2:21:08 GMT -5
I appreciate all the ideas, i think im going to go with toms original idea of using wxwidgets, this will allow a-lot of things, im even considering adding a library to the core language to create basic gui applications, as well as multi-window support. I have debated also on the text engine. as true console output would be pretty awesome, although having the original opengl text engine has turned out to be quite handy in the past. Image handling currently works with SDL_image for testing purposes because its quite simple to integrate directly. I haven't decided on which sound lib to integrate something simple preferably. I agree about the joystick removal, but at this time i think a new net socket interface using WXwidgets would be decent. Djlinux, i would love some ideas for the DLL SDK, could you perhaps suggest some changes some simplifications, i think we can all agree you know it best. IF you dont like any of these ideas feel free to let me know im doing this for all of us not just for me i dont want this language to die i learned how to code using this. and i want to bring back the crowd i have alot of things i want to add, and im not even close, but for this week here is my list id like to get close to finishing. 1)finish the last big majority of original functions namely the sprite engine as sound, network, image loading will need all new code at this point. 2)either recreate the basic4gl Ide( something basic) or create a fully function command line interpreter 3)replace all the sdl window code with wxwidgets 4)begin reworking the DLL interface 5) considering working on reintegrating the exe creation portion. Comments, questions, suggests are strongly requested  I appreciate everyones time -darkjester EDIT: Im gonna try to get some binaries zipped up for people to mess with. Ive also changed my main IDE to wxDevC++
|
|
|
Post by James :) (aka Madcow) on May 14, 2012 3:38:35 GMT -5
Yes I think wxwidgets are the way forward, I was just considering alternatives. I'm having problems setting it up atm but their example projects seem to work on my mac which indicates it must be me which is positive. (I think I use using xCode which doesn't playing nicely) In other news I've tried updating the VM and compiler to v2.5.8 which should add support for custom functions, hex etc. Im not sure if it will work on linux but It did for me when I ran it on a iPhone and my Mac. So if people could test it out here by downloading the zip from: github.com/jcampbell05/Basic4GLI agree with darkjester, I want to keep this alive as in my opinion I've found for some people OPP can still be too much to learn programming as a beginner ("Hello World" can still be complicated even in the more refined OOP languages). Network Engine wise we need to make sure it doesn't hang like the original one didn't (if you kept checking the connection too intemittenly then the network engine stopped working so you had to build in a 1 millisecond sleep into the programme). I've found a library for us here which I use in my iOS Games I produce: think-async.com/How are we going to get DLLs to be multi-platform? just out of interest, this is something that interests me as I would love to see them on linux or mac. It would be awesome if we could get it to output applications for other platforms not just exe. IDE wise I think we could redesign it to improve it whilst keeping the simplicity of the original, I would also happily design a help system that we could integrate into it. I'll come up with some designs we can implement. I've been thinking if this multi-platform effort goes well, I might port it to iOS and Android (Could open possibilities to let people code it on their desktop then run it on their phone). Also I've been looking at game engines like cocos2D and cocos3D it would be nice to port one as a DLL library for Basic4GL so people have a easy to use game engine.
|
|
|
Post by Darkjester on May 14, 2012 4:33:27 GMT -5
help system? please elaberate. as for the network engine im going to use wxwidgets. its more than just gui  im trying to elminate dependencies to make it easier to do builds as this was part of the problem in the first place . Edit: wxwidgets has an image loading library as well XD
|
|
|
Post by James :) (aka Madcow) on May 14, 2012 4:59:06 GMT -5
Wxwidgets is defiantly the way forward haha, I knew it did more than GUI but I hadn't realised about the Network. By Help System, I was thinking of having a more clean and well organised documentation, Tom's documentation is very good and helped me a lot but I've found in the more recent basics it can be hard to find what you are looking for. With a help system you could have it searchable, have a page dedicated to each function things like that  . In xCode (which I use when developing on mac and iphone) you can get something like this:  I would like to implement something a lot more simple though for Basic4GL though  I've just found I have a sourceforge page for all the versions of Basic4GL, i'll update it when I have the time.
|
|
|
Post by matthew on May 14, 2012 7:39:02 GMT -5
LOL Thing's seem to be getting complicated. Seriously I think we should be keeping it as simple as possible until we've got a near fully-functioning Windows version running from a Command Prompt.
|
|