problems with buffer~ writing to raw

luisherranz's icon

I'm trying to write raw files using buffer. Something pretty simple, but I'm getting the following error:jsoundfile_writefloats: bogus format specified
buffer~: could not create file:

Not sure what may be going on. This is the patch:

----------begin_max5_patcher----------
{
    "boxes" : [         {
            "box" :             {
                "maxclass" : "newobj",
                "text" : "prepend samptype",
                "fontname" : "Arial",
                "numinlets" : 1,
                "numoutlets" : 1,
                "fontsize" : 12.0,
                "patching_rect" : [ 209.0, 150.0, 110.0, 20.0 ],
                "id" : "obj-25",
                "outlettype" : [ "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "live.menu",
                "varname" : "live.menu[2]",
                "numinlets" : 1,
                "numoutlets" : 3,
                "fontsize" : 13.0,
                "patching_rect" : [ 236.0, 89.0, 63.0, 18.0 ],
                "id" : "obj-11",
                "parameter_enable" : 1,
                "outlettype" : [ "", "", "float" ],
                "saved_attribute_attributes" :                 {
                    "valueof" :                     {
                        "parameter_longname" : "live.menu[2]",
                        "parameter_shortname" : "live.menu",
                        "parameter_type" : 2,
                        "parameter_enum" : [ "int8", "int16", "int24", "int32", "float32", "float64", "mulaw", "alaw" ],
                        "parameter_initial_enable" : 1,
                        "parameter_initial" : [ 1 ]
                    }

                }

            }

        }
,         {
            "box" :             {
                "maxclass" : "newobj",
                "text" : "prepend format",
                "fontname" : "Arial",
                "numinlets" : 1,
                "numoutlets" : 1,
                "fontsize" : 13.0,
                "patching_rect" : [ 258.0, 114.0, 99.0, 21.0 ],
                "id" : "obj-2",
                "outlettype" : [ "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "live.menu",
                "varname" : "live.menu[1]",
                "numinlets" : 1,
                "numoutlets" : 3,
                "fontsize" : 13.0,
                "patching_rect" : [ 187.0, 34.0, 63.0, 18.0 ],
                "id" : "obj-85",
                "parameter_enable" : 1,
                "outlettype" : [ "", "", "float" ],
                "saved_attribute_attributes" :                 {
                    "valueof" :                     {
                        "parameter_longname" : "live.menu[1]",
                        "parameter_shortname" : "live.menu",
                        "parameter_type" : 2,
                        "parameter_enum" : [ "aiff", "wave", "au", "raw" ],
                        "parameter_initial_enable" : 1,
                        "parameter_initial" : [ 0 ]
                    }

                }

            }

        }
,         {
            "box" :             {
                "maxclass" : "newobj",
                "text" : "prepend filetype",
                "fontname" : "Arial",
                "numinlets" : 1,
                "numoutlets" : 1,
                "fontsize" : 13.0,
                "patching_rect" : [ 209.0, 59.0, 104.0, 21.0 ],
                "id" : "obj-84",
                "outlettype" : [ "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "message",
                "text" : "writeraw",
                "fontname" : "Arial",
                "numinlets" : 2,
                "numoutlets" : 1,
                "fontsize" : 12.0,
                "patching_rect" : [ 126.0, 59.0, 55.0, 18.0 ],
                "id" : "obj-8",
                "outlettype" : [ "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "waveform~",
                "numinlets" : 5,
                "numoutlets" : 6,
                "patching_rect" : [ 15.5, 226.0, 393.0, 157.0 ],
                "id" : "obj-5",
                "buffername" : "raw",
                "outlettype" : [ "float", "float", "float", "float", "list", "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "message",
                "text" : "read",
                "fontname" : "Arial",
                "numinlets" : 2,
                "numoutlets" : 1,
                "fontsize" : 12.0,
                "patching_rect" : [ 51.0, 59.0, 35.0, 18.0 ],
                "id" : "obj-4",
                "outlettype" : [ "" ]
            }

        }
,         {
            "box" :             {
                "maxclass" : "newobj",
                "text" : "buffer~ raw",
                "fontname" : "Arial",
                "numinlets" : 1,
                "numoutlets" : 2,
                "fontsize" : 12.0,
                "patching_rect" : [ 98.0, 183.0, 71.0, 20.0 ],
                "id" : "obj-1",
                "outlettype" : [ "float", "bang" ]
            }

        }
],
    "lines" : [         {
            "patchline" :             {
                "source" : [ "obj-25", 0 ],
                "destination" : [ "obj-1", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-11", 1 ],
                "destination" : [ "obj-25", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-4", 0 ],
                "destination" : [ "obj-1", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-8", 0 ],
                "destination" : [ "obj-1", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-84", 0 ],
                "destination" : [ "obj-1", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-2", 0 ],
                "destination" : [ "obj-1", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-11", 1 ],
                "destination" : [ "obj-2", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
,         {
            "patchline" :             {
                "source" : [ "obj-85", 1 ],
                "destination" : [ "obj-84", 0 ],
                "hidden" : 0,
                "disabled" : 0
            }

        }
],
    "appversion" :     {
        "major" : 6,
        "minor" : 1,
        "revision" : 3,
        "architecture" : "x86"
    }

}
-----------end_max5_patcher-----------

julienrobert's icon

same problem, have you found a solution?

luisherranz's icon
Ben Bracken's icon

There are some known issues regarding raw audio file write. We hope to address some of the issues in the next update.

Thanks,
-Ben

woyteg's icon

I just ran into this too, is this solved? Any news on this?