Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/caps.c
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const gchar *get_audio_sink_cap(unsigned int type) {
format =
GST_AUDIO_CAPS_MAKE("audio/x-raw, "
"format = (string) " GST_AUDIO_NE(
S16) ", "
F32) ", "
"layout = (string) interleaved, "
"channels = (int) { 2 }, "
"rate = (int) { 44100 }, "
Expand Down
4 changes: 2 additions & 2 deletions src/plugin.c
Original file line number Diff line number Diff line change
Expand Up @@ -336,8 +336,8 @@ static gboolean gst_projectm_render(GstGLBaseAudioVisualizer *glav,
// audioMap.size / 8, audio->offset, audio->offset_end,
// bscope->ainfo.rate, bscope->vinfo.fps_n, bscope->req_spf);

projectm_pcm_add_int16(plugin->priv->handle, (gint16 *)audioMap.data,
audioMap.size / 4, PROJECTM_STEREO);
projectm_pcm_add_float(plugin->priv->handle, (gfloat *)audioMap.data,
audioMap.size / 8, PROJECTM_STEREO);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should it be like sizeof(float)

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

yes, that's better


// GST_DEBUG_OBJECT(plugin, "Audio Data: %d %d %d %d", ((gint16
// *)audioMap.data)[100], ((gint16 *)audioMap.data)[101], ((gint16
Expand Down
Loading