pd4web 2.2.0__tar.gz → 2.2.2__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {pd4web-2.2.0 → pd4web-2.2.2}/PKG-INFO +2 -2
- {pd4web-2.2.0 → pd4web-2.2.2}/README.md +1 -1
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/libpd.cmake +21 -3
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Builder.py +10 -10
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Pd4Web.py +10 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/pyproject.toml +1 -1
- {pd4web-2.2.0 → pd4web-2.2.2}/LICENSE +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/.clang-format +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/.prettierrc +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/.yamlftm +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/Libraries.yaml +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/ambi~.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/cyclone.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/earplug.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/else.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/o.scofo~.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/.git +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/.github/workflows/c-cpp.yml +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/.gitignore +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/CMakeLists.txt +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/.clang-format +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/CMakeLists.txt +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/fft~/fft~-help.pd +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/fft~/fft~.cpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/simple/simple-help.pd +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/simple/simple-patch.pd +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/simple/simple.cpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/simple~/simple~-help.pd +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Examples/simple~/simple~.cpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/LICENSE +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/README.md +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Tests/01.Deprecated-Functions/CMakeLists.txt +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/Tests/CMakeLists.txt +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pd.cmake/pd.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/pmpd.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Libraries/timbreIDLib.cmake +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/1/bula.md +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/1/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/2/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/2/sketch.js +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/3/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/4/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/4/sketch.js +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/5/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/Templates/5/tutorial.md +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/__init__.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/cmake-format.yaml +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/config.h +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/externals.cpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/favicon.ico +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/index.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/nogui.html +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Compilers.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Libraries.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Objects.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/Patch.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web/__init__.py +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.cpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.gitignore +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.gui.js +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.hpp +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.midi.js +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.style.css +0 -0
- {pd4web-2.2.0 → pd4web-2.2.2}/Sources/pd4web.threads.js +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: pd4web
|
|
3
|
-
Version: 2.2.
|
|
3
|
+
Version: 2.2.2
|
|
4
4
|
Summary: pd4web compiles PureData patches with external objects for Wasm, allowing to run entire patches in web browsers.
|
|
5
5
|
Home-page: https://charlesneimog.github.io/pd4web
|
|
6
6
|
Author: Charles K. Neimog
|
|
@@ -43,7 +43,7 @@ Description-Content-Type: text/markdown
|
|
|
43
43
|
</p>
|
|
44
44
|
|
|
45
45
|
<p align="center">
|
|
46
|
-
<a href="https://github.com/charlesneimog/pd4web/actions/workflows/
|
|
46
|
+
<a href="https://github.com/charlesneimog/pd4web/actions/workflows/Release.yml"><img src="https://github.com/charlesneimog/pd4web/actions/workflows/Release.yml/badge.svg" alt="Tests"></a>
|
|
47
47
|
</p>
|
|
48
48
|
|
|
49
49
|
`pd4web` lets you run PureData patches directly in web browsers. It stands out from alternatives like [hvcc](https://github.com/Wasted-Audio/hvcc) and [WebPd](https://github.com/sebpiq/WebPd) by compiling the source code of [libpd](https://github.com/libpd/libpd), thanks to the work of [claudeha](https://github.com/claudeha). With `pd4web`, you can compile any PureData Vanilla patch, along with a list of more than 800 externals and abstractions.
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
</p>
|
|
21
21
|
|
|
22
22
|
<p align="center">
|
|
23
|
-
<a href="https://github.com/charlesneimog/pd4web/actions/workflows/
|
|
23
|
+
<a href="https://github.com/charlesneimog/pd4web/actions/workflows/Release.yml"><img src="https://github.com/charlesneimog/pd4web/actions/workflows/Release.yml/badge.svg" alt="Tests"></a>
|
|
24
24
|
</p>
|
|
25
25
|
|
|
26
26
|
`pd4web` lets you run PureData patches directly in web browsers. It stands out from alternatives like [hvcc](https://github.com/Wasted-Audio/hvcc) and [WebPd](https://github.com/sebpiq/WebPd) by compiling the source code of [libpd](https://github.com/libpd/libpd), thanks to the work of [claudeha](https://github.com/claudeha). With `pd4web`, you can compile any PureData Vanilla patch, along with a list of more than 800 externals and abstractions.
|
|
@@ -3,13 +3,31 @@ project(libpd C)
|
|
|
3
3
|
|
|
4
4
|
set(ENABLE_TILDE_TARGET_WARNING off)
|
|
5
5
|
|
|
6
|
-
if
|
|
7
|
-
|
|
6
|
+
if(LSP_SUPPORT)
|
|
7
|
+
set(PD_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/build/pure-data/src/)
|
|
8
8
|
else()
|
|
9
|
-
|
|
9
|
+
set(PD_SOURCE_DIR ${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/pure-data/src/)
|
|
10
10
|
endif()
|
|
11
11
|
set(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} -pthread -matomics -mbulk-memory")
|
|
12
12
|
|
|
13
|
+
# ╭──────────────────────────────────────╮
|
|
14
|
+
# │ Remove print of sys_vgui │
|
|
15
|
+
# ╰──────────────────────────────────────╯
|
|
16
|
+
# Função para adicionar 'return;' após o comentário específico, se ainda não existir
|
|
17
|
+
function(AddReturnAfterComment file start_block return_statement)
|
|
18
|
+
file(READ ${file} FILE_CONTENTS)
|
|
19
|
+
string(FIND "${FILE_CONTENTS}" "${start_block}\n return;" POSITION)
|
|
20
|
+
if(POSITION EQUAL -1)
|
|
21
|
+
string(REPLACE "${start_block}" "${start_block}\n return;" FILE_CONTENTS
|
|
22
|
+
"${FILE_CONTENTS}")
|
|
23
|
+
file(WRITE ${file} "${FILE_CONTENTS}")
|
|
24
|
+
endif()
|
|
25
|
+
endfunction()
|
|
26
|
+
|
|
27
|
+
addreturnaftercomment(
|
|
28
|
+
${PD_SOURCE_DIR}/s_inter.c "{ /* if there's no TK process just throw it to stderr */"
|
|
29
|
+
" return;")
|
|
30
|
+
|
|
13
31
|
# ╭──────────────────────────────────────╮
|
|
14
32
|
# │ PureData Sources │
|
|
15
33
|
# ╰──────────────────────────────────────╯
|
|
@@ -60,18 +60,18 @@ class GetAndBuildExternals:
|
|
|
60
60
|
else:
|
|
61
61
|
self.ProjectName = os.path.basename(self.Pd4Web.PROJECT_ROOT)
|
|
62
62
|
self.cmakeFile.append("cmake_minimum_required(VERSION 3.25)")
|
|
63
|
-
self.cmakeFile.append(f
|
|
63
|
+
self.cmakeFile.append(f'project("{self.ProjectName}")\n')
|
|
64
64
|
|
|
65
65
|
# Pd Sources
|
|
66
66
|
self.cmakeFile.append("# Pd sources")
|
|
67
67
|
self.cmakeFile.append('set(CMAKE_CXX_FLAGS "${CMAKE_CXX_FLAGS} -pthread -matomics -mbulk-memory")')
|
|
68
|
-
self.cmakeFile.append(
|
|
69
|
-
self.cmakeFile.append(
|
|
68
|
+
self.cmakeFile.append('include("${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/libpd.cmake")')
|
|
69
|
+
self.cmakeFile.append('include("${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/Externals/pd.cmake")')
|
|
70
70
|
self.cmakeFile.append('set(PDCMAKE_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/Externals/" CACHE STRING "" FORCE)')
|
|
71
71
|
self.cmakeFile.append(
|
|
72
72
|
'set(PD4WEB_EXTERNAL_DIR "${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/Externals/" CACHE STRING "" FORCE)'
|
|
73
73
|
)
|
|
74
|
-
self.cmakeFile.append(
|
|
74
|
+
self.cmakeFile.append('include_directories("${CMAKE_CURRENT_SOURCE_DIR}/Pd4Web/pure-data/src")')
|
|
75
75
|
self.cmakeFile.append("add_definitions(-DPDTHREADS)")
|
|
76
76
|
self.cmakeFile.append("")
|
|
77
77
|
|
|
@@ -106,7 +106,7 @@ class GetAndBuildExternals:
|
|
|
106
106
|
|
|
107
107
|
targetProperties = [
|
|
108
108
|
"set_target_properties(pd4web PROPERTIES",
|
|
109
|
-
|
|
109
|
+
' RUNTIME_OUTPUT_DIRECTORY "${CMAKE_CURRENT_SOURCE_DIR}/WebPatch"',
|
|
110
110
|
")",
|
|
111
111
|
]
|
|
112
112
|
linkOptions = [
|
|
@@ -268,23 +268,23 @@ class GetAndBuildExternals:
|
|
|
268
268
|
|
|
269
269
|
def AddFilesToWebPatch(self):
|
|
270
270
|
self.cmakeFile.append("\n# FileSystem for the Patch")
|
|
271
|
-
string = 'set_target_properties(pd4web PROPERTIES LINK_FLAGS "--preload-file ${CMAKE_CURRENT_SOURCE_DIR}/WebPatch/index.pd@/index.pd")'
|
|
271
|
+
#string = 'set_target_properties(pd4web PROPERTIES LINK_FLAGS "--preload-file \"${CMAKE_CURRENT_SOURCE_DIR}/WebPatch/index.pd@/index.pd\"")'
|
|
272
|
+
string = 'set_target_properties(pd4web PROPERTIES LINK_FLAGS "--preload-file \\"${CMAKE_CURRENT_SOURCE_DIR}/WebPatch/index.pd@/index.pd\\"")'
|
|
272
273
|
self.cmakeFile.append(string)
|
|
273
|
-
|
|
274
274
|
if os.path.exists(self.Pd4Web.PROJECT_ROOT + "/Audios"):
|
|
275
275
|
self.cmakeFile.append("get_target_property(EMCC_LINK_FLAGS pd4web LINK_FLAGS)")
|
|
276
276
|
self.cmakeFile.append(
|
|
277
|
-
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file ${CMAKE_CURRENT_SOURCE_DIR}/Audios@/Audios
|
|
277
|
+
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file \\"${CMAKE_CURRENT_SOURCE_DIR}/Audios@/Audios/\\"")'
|
|
278
278
|
)
|
|
279
279
|
if os.path.exists(self.Pd4Web.PROJECT_ROOT + "/.tmp"):
|
|
280
280
|
self.cmakeFile.append("get_target_property(EMCC_LINK_FLAGS pd4web LINK_FLAGS)")
|
|
281
281
|
self.cmakeFile.append(
|
|
282
|
-
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file ${CMAKE_CURRENT_SOURCE_DIR}/.tmp@/Libs
|
|
282
|
+
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file \\"${CMAKE_CURRENT_SOURCE_DIR}/.tmp@/Libs/\\"")'
|
|
283
283
|
)
|
|
284
284
|
if os.path.exists(self.Pd4Web.PROJECT_ROOT + "/Extras"):
|
|
285
285
|
self.cmakeFile.append("get_target_property(EMCC_LINK_FLAGS pd4web LINK_FLAGS)")
|
|
286
286
|
self.cmakeFile.append(
|
|
287
|
-
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file ${CMAKE_CURRENT_SOURCE_DIR}/Extras@/Extras
|
|
287
|
+
'set_target_properties(pd4web PROPERTIES LINK_FLAGS "${EMCC_LINK_FLAGS} --preload-file \\"${CMAKE_CURRENT_SOURCE_DIR}/Extras@/Extras/\\"")'
|
|
288
288
|
)
|
|
289
289
|
|
|
290
290
|
def CreateCppCallsExternalFile(self):
|
|
@@ -362,6 +362,8 @@ class Pd4Web:
|
|
|
362
362
|
type=str,
|
|
363
363
|
help="Pure Data version to use",
|
|
364
364
|
)
|
|
365
|
+
|
|
366
|
+
# Pd Object
|
|
365
367
|
parser.add_argument(
|
|
366
368
|
"--pd-external",
|
|
367
369
|
required=False,
|
|
@@ -369,6 +371,14 @@ class Pd4Web:
|
|
|
369
371
|
action="store_true",
|
|
370
372
|
help="If is it pd4web external",
|
|
371
373
|
)
|
|
374
|
+
|
|
375
|
+
parser.add_argument(
|
|
376
|
+
"--pd-external-version",
|
|
377
|
+
required=False,
|
|
378
|
+
default=importlib_metadata.version("pd4web"),
|
|
379
|
+
type=str,
|
|
380
|
+
help="Version of the pd4web external being used",
|
|
381
|
+
)
|
|
372
382
|
|
|
373
383
|
## User
|
|
374
384
|
parser.add_argument(
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[tool.poetry]
|
|
2
2
|
name = "pd4web"
|
|
3
|
-
version = "2.2.
|
|
3
|
+
version = "2.2.2"
|
|
4
4
|
description = "pd4web compiles PureData patches with external objects for Wasm, allowing to run entire patches in web browsers."
|
|
5
5
|
authors = ["Charles K. Neimog <charlesneimog@outlook.com>"]
|
|
6
6
|
readme = "README.md"
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|