Skip to content

Commit

Permalink
import multi-cursor plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
D3mh4 committed Feb 26, 2025
1 parent 2270408 commit 13e0349
Show file tree
Hide file tree
Showing 8 changed files with 780 additions and 0 deletions.
34 changes: 34 additions & 0 deletions src/plugins/MultiCursor/CMakeLists.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,34 @@
cmake_minimum_required(VERSION 3.13 FATAL_ERROR)

if(NOT TARGET score_lib_base)
include("${SCORE_SOURCE_DIR}/cmake/ScoreExternalAddon.cmake")
endif()

if(NOT TARGET score_plugin_avnd)
return()
endif()

project(score_addon_multicursormanager LANGUAGES CXX)

score_common_setup()

avnd_score_plugin_init(
BASE_TARGET score_addon_multicursormanager
)

avnd_score_plugin_add(
BASE_TARGET score_addon_multicursormanager
SOURCES
MultiCursor/MultiCursor.hpp
MultiCursor/MultiCursorModel.hpp
MultiCursor/MultiCursorModel.cpp
TARGET multicursormanager
MAIN_CLASS MultiCursorManager
NAMESPACE Example
)

avnd_score_plugin_finalize(
BASE_TARGET score_addon_multicursormanager
PLUGIN_VERSION 1
PLUGIN_UUID "20f771a1-0e9a-4db2-bb7c-011467d84ded"
)
661 changes: 661 additions & 0 deletions src/plugins/MultiCursor/LICENSE

Large diffs are not rendered by default.

3 changes: 3 additions & 0 deletions src/plugins/MultiCursor/MultiCursor/MultiCursor.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
#pragma once

#include <MultiCursor/MultiCursorModel.hpp>
10 changes: 10 additions & 0 deletions src/plugins/MultiCursor/MultiCursor/MultiCursorModel.cpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
#include "MultiCursor.hpp"


namespace Example
{
void MultiCursorManager::operator()(halp::tick t)
{
outputs.out.value = inputs.pos.value;
}
}
51 changes: 51 additions & 0 deletions src/plugins/MultiCursor/MultiCursor/MultiCursorModel.hpp
Original file line number Diff line number Diff line change
@@ -0,0 +1,51 @@
#pragma once

#include <halp/audio.hpp>
#include <halp/controls.hpp>
#include <halp/meta.hpp>


namespace Example
{

class MultiCursorManager
{
public:
halp_meta(name, "Multi-Cursor Manager")
halp_meta(category, "Control/Spatialization")
halp_meta(c_name, "multicursormanager")
halp_meta(uuid, "20f771a1-0e9a-4db2-bb7c-011467d84ded")

struct ins
{
struct
{
halp_meta(name, "Position")
struct range {
float min = 0;
float max = 1;
float init = 0.5;
};
enum widget { multi_slider_xy };
std::vector<ossia::value> value;
} pos;
} inputs;

struct
{
halp::val_port<"out", std::vector<ossia::value>> out;
} outputs;

using setup = halp::setup;
void prepare(halp::setup info)
{
// Implementation for prepare method
}

using tick = halp::tick;

void operator()(halp::tick t);

};

}
2 changes: 2 additions & 0 deletions src/plugins/MultiCursor/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# MultiCursor
A new and wonderful [ossia score](https://ossia.io) add-on
11 changes: 11 additions & 0 deletions src/plugins/MultiCursor/addon.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
{
"src": "<url to the .zip file created by the release script>",
"name": "MultiCursorManager",
"raw_name": "score-addon-my-avnd-effect",
"version": "1.0",
"kind": "addon",
"short": "Multi Cursor Manager effect add-on",
"long": "This addon provides an example audio effect",
"small": "https://raw.githubusercontent.com/OSSIA/score-addon-tutorial/master/Deployment/icon.png",
"key": ""
}
8 changes: 8 additions & 0 deletions src/plugins/MultiCursor/release.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
#!/bin/bash
rm -rf release
mkdir -p release

cp -rf MultiCursor *.{hpp,cpp,txt,json} LICENSE release/

mv release score-addon-multicursor
7z a score-addon-multicursor.zip score-addon-multicursor

0 comments on commit 13e0349

Please sign in to comment.