Welcome, Guest. Please login or register. Did you miss your activation email?

Author Topic: (SSML) Simple & Slow Multimedia Library  (Read 4449 times)

0 Members and 1 Guest are viewing this topic.

tomvidm

  • Newbie
  • *
  • Posts: 15
    • View Profile
(SSML) Simple & Slow Multimedia Library
« on: October 05, 2018, 12:44:09 pm »
    (SSML) Simple & Slow Multimedia Library

    I have been working on a hobby project, with the aim of using it for developing simple games using SFML. Currently, it is a collection of unfinished features and some working features. There is nothing that this library can do, that other solutions don't do better, but for me it has been an incredible learning experience so far.

    https://gitlab.com/tomvidm/ssml

    If you feel interested, I believe the README.md explains how to compile. Tested using VS17 on windows and gcc on Ubuntu. Compilation requires CMAKE.

    Documentation:
    https://tomvidm.gitlab.io/ssml/

    Currently, the project includes a showcase of the CompositeTilemap. I am continually updating the project and adding features and fixes.


    The image showcases the CompositeTilemap class, but with colors instead of texture rects. The red rectangle shos the visibility bounds, and all tilemaps whose bounds intersect with it, will be visible. The subtilemaps are stored in a hash map, so "holes" are allowed.

    SSML classes and functions are in the namespace ss::graphics, ss::system, ss::math and so on. Some SFML objects are aliased to look like part of SSML , because I want the public interface to be as clean as possible.

    I would love to hear suggestions for improvements. And I do not shy away from criticism. This has been worked on as a personal project without input, and it is only healthy to have someone point out the smelly stuff.

    Below is a non-exhaustive list of features and planned features. A more ambitious list of planned features is found in the README.md in the git repository. The GitLab reposity also has a list of issues detailing some of the design process and things I need (or just want) to do.

    Graphics
    Current features:
    • Custom sprites with built in sprite animation system.
    • Tileset, allowing the user to add texture rects to a vector, with additional string mapping for comfortable use of spritesheets. Possibility to load tilesets using JSON with a specific format. Undocumented! Yay!
    • Tilemaps which maps indices to the corresponding texture rects in a Tileset, with no member methods to do so yet!
    • Composite Tilemap, to let the user compose a world from individual tilemaps. Only renders the visible submaps.
    • An abstract class Renderable which inherits from both sf::Drawable and sf::Transformable, with added methods for obtaining local and global bounds. Good for visibility checks.
    • Simple renderer. Simply attach a sf::drawable or a ss::Renderable to the renderer and tell it to renderAll().
    • A TextureManager to keep your rectangles non-white, textures safe and accessible through a string alias

    Planned features:
    • Implement ordered rendering layers, allowing easy switching of what is rendered. For example for pause menus or other things.
    • Automatic resolution of draw order per render layer
    • Built in GUI and
    • Support isometric tilemaps! Ok, they are just transformed rectangular tilemaps, but the SFML transform class does not provide methods for isometric transforms.

    Math module
    Current features:
    • Convenient functions for dealing with vectors and computational geometry.
    • Linear and bilinear interpolation (Lerp and blerp!).
    • Heightmap. A 2d array of values that can be operated upon. Slow and badly named.

    Planned features:
    • Bezier curves and B-splines for drawing curves and interpolation
    • Simple graphs with implementations of the usual algorithms
    • Whatever is needed to do what I want.

    Event system
    Current features:
    • Translating SFML input events into SSML input events. SSML input events have sligthtly more detail that SFML events and makes it easy to check for hold time, last position of a press or release and to check the distance dragged while holding a button.

    Planned features:
    • To allow the user to define keystrokes and allow other objects to listen for these events.
    • To allow the user to optionally track button mashing or mouse shaking.
    [/list]
    « Last Edit: October 09, 2018, 07:41:01 pm by tomvidm »