Jump to content
Search In
  • More options...
Find results that contain...
Find results in...


  • Content Count

  • Joined

  • Last visited

Blog Comments posted by AnniXa

  1. Hi Rick


    The whole gui uses just 1 image in my case, of course you can use more than one if its neccesary, every guicore can have its own "skin" and you can have as much gui cores as you want (in my project i have differend cores for the main menu, the edit mode, the simulation mode, so that i dont need to turn on/off a bunch of windows when i switch between those modes)


    The buttons, window borders,and all the stuff that the gui needs (expect text) are on this image file (to reduce the needed bindtexture()) calls, also the most stuff is a builded Array for the openGL draw arrays thingy / VBO (so they need to be all on the same texture also for this reason).


    so on the image there are areas of the image, that i call "frames" even when they are not frames in the classic sence like they was in original max2d timage type, since they can all have a individual size, and position, also overlapping is possible.


    The language is bmx, its just a .bmx file to include, not really a library for now, maybe when i get more further into it and i think that its worth to share this with other ppl then i would make it as blitz-module or something.


    The "events" are not really existing i think, you can do 2 things for now with buttons:


    give them an int ptr that they are modifing, depending on the settings of the button, the variable behind the int ptr will be modified, there are differede modes:


    1 - Increase/Decrease the int by given values, for example +5,-1 or something, also with max and min values that the int can have.


    2 - "swapmode" , the int is switchting between 0 and 1 on each click (and also the button shows itselfs "pressed" when the int is 1"


    3 - "setmode", the int is setted to a specified value when the button is clicked, (also the button shows itself "pressed" when this value is settted.



    Also you can give the button function pointers, the functions will be called when the button was clicked, in combination with the int ptr stuff you can do alot things (i think i can do everything i need with this system):


    Just increase/decrease a value, without need for any function

    Modify a value und call a function that do something with it.

    Modify objects fields by just give the fields as int ptr

    Also its pretty nice to make more buttons that modify the same int variable, every button with "setmode", and then you can make easy category switch thingies with this (on button click -> set int to a value, and run a function that do stuff depending on the int)

Facebook Twitter Youtube Github Steam
  • Create New...