# Path for fout

**URL:** <https://forum.csound.com/t/path-for-fout/979>\
**Category:** General\
**Created:** [December 1, 2022, 11:21pm UTC](https://forum.csound.com/t/path-for-fout/979 "2022-12-01T23:21:04Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Cordelia](https://forum.csound.com/user_avatar/forum.csound.com/cordelia/32/279_2.png) [@Cordelia](https://forum.csound.com/u/Cordelia)\
**Post date:** [December 1, 2022, 11:21pm UTC](https://forum.csound.com/t/path-for-fout/979/1 "2022-12-01T23:21:04Z")

</div>

How can I set the path for fout opcode in order to record my wav file directly inside the same .csd file directory?  
I tried to set:

```csound
--env:SSDIR+=../
--env:SFDIR+=../

```

and than send this instruction to my fout instrument: `schedule "mnemosine", 0, -1, "./corfile.wav"`, but it did not work, it still record inside my home directory.

---

<div class="post-metadata">

**Author:** ![rory](https://forum.csound.com/user_avatar/forum.csound.com/rory/32/7_2.png) [@rory](https://forum.csound.com/u/rory)\
**Post date:** [December 2, 2022, 9:45am UTC](https://forum.csound.com/t/path-for-fout/979/2 "2022-12-02T09:45:11Z")

</div>

I don’t bother with any SSDIR flags, but simply pass the filename to fout, i.e.,

`fout "output.wav", 15, asig`

For me this results in the file going to the current csd directory.

p.s. I’m talking about running Csound outside of a frontend…

---

<div class="post-metadata">

**Author:** ![Cordelia](https://forum.csound.com/user_avatar/forum.csound.com/cordelia/32/279_2.png) [@Cordelia](https://forum.csound.com/u/Cordelia)\
**Post date:** [December 2, 2022, 10:36am UTC](https://forum.csound.com/t/path-for-fout/979/3 "2022-12-02T10:36:26Z")

</div>

Yap, u’re right. I mean, I just had to open csound inside the directory and not with the absolute path:  
e.g.  
Here, it’ll save inside home dir:  
`csound path/path/path/csound.csd`  
And here it’ll save in the desired dir:  
`cd path/path/path/ & csound csound.csd`

Thank you!

---

<div class="post-metadata">

**Author:** ![joachim](https://forum.csound.com/letter_avatar_proxy/v4/letter/j/a87d85/32.png) [@joachim](https://forum.csound.com/u/joachim)\
**Post date:** [December 2, 2022, 5:50pm UTC](https://forum.csound.com/t/path-for-fout/979/4 "2022-12-02T17:50:30Z")

</div>

the pwd() opcode can perhaps also be useful?
