Esi Juli@ + OSS

OSS specific Linux discussion (x86/amd64)

Moderators: hannu, dev, cesium

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Thu Jan 07, 2016 1:37 pm

ossuserr wrote:I edited the ebuild to have such lines:
sed -e "s;grc_max=6;grc_max=6;g" \
-i "${S}/setup/srcconf.c" || die
sed -e "s;GRC_MAX_QUALITY=6;GRC_MAX_QUALITY=6;g" \
-i "${S}/configure" || die
cd "${WORKDIR}/build" && "${S}/configure" ${oss_config} || die

sed -e "s;'#define CONFIG_OSS_GRC_MAX_QUALITY 6';'#define CONFIG_OSS_GRC_MAX_QUALITY 6';" \
-i "${WORKDIR}/build/kernel/framework/include/local_config.h" || die
}

And recompiled. But in ossxmix i still have the drop-down choice between several resamplers.

Also can you explain, does oss has two resamplers? As u could see in the pictures of ossxmix i have src checkbox and vmix0-src dropdown menu. Do they use different resamplers? Or src checkbox = to switch cooked_mode to ON? And if src checkbox is set to OFF then there is no any resampling and vmix0-src is ignored?


You do have two different resamplers:

Code: Select all

envy24.src ON|OFF (currently ON)
vmix0-src <Fast|High|High+|Production|OFF> (currently Production)


The first one is an internal hardware resampler of your Juli@ soundcard.
The second is a software resampler of OSS4.

Do not fool yourself with vmix0-src.
If vmix0-src checkbox is set to OFF, the default OSS4 resampler is secretly enabled by COOKEDMODE.
And this default OSS4 resampler is the crappy FAST resampler.
The only way to get rid of this "secret service" is to disable COOKEDMODE in /usr/lib/oss/conf/osscore.conf and reload OSS.

Petrov's "exclusive mode" and "ossplay -R" also disable COOKEDMODE, see "man ossplay".

In fact, OSS4 provides two software resamplers (which are, actually, the same "GRC").
One of them is a "secret resampler", another is a "non-secret resampler".

This seems to be a normal way to fool the naive consumers.
Since resampler is a kind of "service", it might be a "secret service", or "non-secret service".
For example: _https://en.wikipedia.org/wiki/United_States_Secret_Service
If the "non-secret service" is disabled, the "secret service" might be enabled.

ossuserr wrote:I edited the ebuild...
And recompiled. But in ossxmix i still have the drop-down choice between several resamplers.


You should also change "GRC_MIN_QUALITY=3" to "GRC_MIN_QUALITY=6" with "sed".
For Arch Linux, it might be something like this:

Code: Select all

# Create build directory and configure
mkdir build && cd build
sed -e 's/GRC_MIN_QUALITY=3/GRC_MIN_QUALITY=6/g' ${srcdir}/${_dir}/configure
sed -e 's/GRC_MAX_QUALITY=3/GRC_MAX_QUALITY=6/g' ${srcdir}/${_dir}/configure
${srcdir}/${_dir}/configure --enable-libsalsa=NO || return 1


See: _http://www.opensound.com/forum/viewtopic.php?f=3&t=3543&start=30#p15711

You can do this step-by-step:

1. Edit the "configure" script:

Code: Select all

# Set GRC3 min/max conversion quality setting to 3 to conserve space.
# TODO: Add support for configurable quality settings.
GRC_MIN_QUALITY=6
GRC_MAX_QUALITY=6
export GRC_MIN_QUALITY GRC_MAX_QUALITY


2. Execute the "configure" script.

3. Check .../src/build/kernel/framework/include/local_config.h
It should look like this:

Code: Select all

#define CONFIG_OSS_GRC_MIN_QUALITY 6
#define CONFIG_OSS_GRC_MAX_QUALITY 6


If not, you can edit it.

4. Then rebuild OSS as usual.

See also: _http://www.opensound.com/forum/viewtopic.php?f=3&t=3790&start=15#p15987

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 12:03 am

It seems that vmix checkbox of ossxmix really works overriding the osscore.conf file, Igor.
I had vmix activated in osscore.conf but unchecked in ossxmix and i had no sound while trying to play a movie file.
mpv --ao=oss:device=/dev/dsp movie.avi

As soon as i checked vmix in ossxmix, sound immediately appeared. So ossxmix in contrast to my earlier supposition works quite well, overriding osscore.conf.

By the way unlike with audigy 2 zs i have not had so far any terrible sounds with juli@. If sampling rate was mismatched then playback changed its speed but i had no terrible noise.

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 11:20 am

The thing is that on gen2 you can't modify configure file because you install software via .ebuild file. When you issue emerge -av command it reads ebuild file and according to settings of that file starts configuring and then making and installing. I also searched all my hdds for local_config.h file. That file was found only in the folder with OSS source code taken from this site. But i install from fun2 overlay and this code does not have that file and that file is not produced during compilation. Maybe my editing ebuild file has helped to activate only 6? Do you have any other options in the drop-down menu of ossxmix?

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Fri Jan 08, 2016 11:56 am

ossuserr wrote:The thing is that on gen2 you can't modify configure file because you install software via .ebuild file. When you issue emerge -av command it reads ebuild file and according to settings of that file starts configuring and then making and installing. I also searched all my hdds for local_config.h file. That file was found only in the folder with OSS source code taken from this site. But i install from fun2 overlay and this code does not have that file and that file is not produced during compilation. Maybe my editing ebuild file has helped to activate only 6? Do you have any other options in the drop-down menu of ossxmix?


If you made it right, you should have only "Production quality" resampler of OSS4.
The "fast crap" should be removed.
Now you can test COOKEDMODE. It should be using "Production quality".

You can disable the HW resampler of Juli@, and try to play something through COOKEDMODE.

Since your jackd enables COOKEDMODE, you may not want crappy resamplers to be available in your sound system
_http://manuals.opensound.com/developer/SNDCTL_DSP_COOKEDMODE.html

You can search the source code of jackd for "COOKEDMODE".

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 12:16 pm

I have a suspicion that on the contrary i disabled production quality because the default ebuild file had the lines like sed -e /quality 3/quality6. But i changed all 3 to 6. So now those 3s are were not substituted by 6s. So I activated low-quality.

See this is the original ebuild:
cat funtoo-media/media-sound/oss/oss-4.2.2011.ebuild
# Distributed under the terms of the GNU General Public License v2

EAPI="5"

inherit eutils flag-o-matic versionator linux-mod

MY_P="oss-v$(get_version_component_range 1-2)-build$(get_version_component_range 3)-src-gpl"

DESCRIPTION="Open Sound System - portable, mixing-capable, high quality sound system for Unix"
HOMEPAGE="http://developer.opensound.com"
SRC_URI="http://www.4front-tech.com/developer/sources/stable/gpl/${MY_P}.tar.bz2"

LICENSE="GPL-2"
SLOT="0"
KEYWORDS="~*"

DEPRECATED_CARDS="allegro als3xx als4k digi32 maestro neomagic s3vibes vortex"

CARDS="ali5455 atiaudio audigyls audiocs audioloop audiopci cmi878x cmpci cs4281 cs461x
digi96 emu10k1x envy24 envy24ht fmedia geode hdaudio ich imux madi midiloop
midimix sblive sbpci sbxfi solo trident usb userdev via823x via97 ymf7xx
${DEPRECATED_CARDS}"

IUSE="alsa gtk midi ogg pax_kernel vmix_fixedpoint"

for card in ${CARDS} ; do
IUSE+=" oss_cards_${card}"
done

RESTRICT="mirror"

DEPEND="!media-sound/oss-devel
alsa? ( media-libs/alsa-lib )
gtk? ( x11-libs/gtk+:2 )
ogg? ( media-libs/libvorbis )
sys-apps/gawk
sys-kernel/linux-headers"

RDEPEND="${DEPEND}"

S="${WORKDIR}/${MY_P}"

src_prepare() {
mkdir "${WORKDIR}/build"

einfo "Replacing init script with funtoo friendly one ..."
cp "${FILESDIR}/init.d/oss" "${S}/setup/Linux/oss/etc/S89oss" || die

if ! use ogg ; then
sed -e "s;OGG_SUPPORT=YES;OGG_SUPPORT=NO;g" \
-i "${S}/configure" || die
fi

if use pax_kernel ; then
epatch "${FILESDIR}/pax_kernel.patch"
fi

# Adding Linux Kernel 4.x support for oss-4.2.2011
epatch "${FILESDIR}/${P}-linux-4.x.patch"

for deprecated_card in ${DEPRECATED_CARDS} ; do
ln -s "${S}/attic/drv/oss_${deprecated_card}" "${S}/kernel/drv/oss_${deprecated_card}"
done

sed -e "s/-Werror//g" \
-i "phpmake/Makefile.php" "setup/Linux/oss/build/install.sh" "setup/srcconf_linux.inc" || die

sed -e "s;grc_max=3;grc_max=6;g" \
-i "${S}/setup/srcconf.c" || die
sed -e "s;GRC_MAX_QUALITY=3;GRC_MAX_QUALITY=6;g" \
-i "${S}/configure" || die

# Build at the "build" directory instead of /tmp
sed -e "s;/tmp/;${WORKDIR}/build/;g" \
-i "${S}/setup/Linux/build.sh" || die

# Remove bundled libflashsupport. Deprecated since 2006.
rm ${S}/oss/lib/flashsupport.c || die
sed -e "/^.*flashsupport.c .*/d" \
-i "${S}/setup/Linux/build.sh" \
-i "${S}/setup/Linux/oss/build/install.sh" || die
}

src_configure() {
local oss_config="$(use alsa && echo || echo --enable-libsalsa=NO)
--config-midi=$(use midi && echo YES || echo NO)
--config-vmix=$(use vmix_fixedpoint && echo FIXEDPOINT || echo FLOAT)
--only-drv=osscore"

for card in ${CARDS} ; do
if use oss_cards_${card} ; then
oss_config+=",oss_${card}"
fi
done

cd "${WORKDIR}/build" && "${S}/configure" ${oss_config} || die

sed -e "s;'#define CONFIG_OSS_GRC_MAX_QUALITY 3';'#define CONFIG_OSS_GRC_MAX_QUALITY 6';" \
-i "${WORKDIR}/build/kernel/framework/include/local_config.h" || die
}

src_compile() {
filter-flags -fPIC # FL-1536

cd "${WORKDIR}/build" && emake build || die
}

src_install() {
newinitd "${FILESDIR}/init.d/oss" oss || die
doenvd "${FILESDIR}/env.d/99oss" || die

cp -R "${WORKDIR}"/build/prototype/* "${D}" || die

local libdir=$(get_libdir)
insinto /usr/${libdir}/pkgconfig
doins "${FILESDIR}"/OSSlib.pc || die

local oss_libs="libOSSlib.so libossmix.so"
use alsa && oss_libs+=" libsalsa.so.2.0.0"

for oss_lib in ${oss_libs} ; do
dosym oss/lib/${oss_lib} /usr/${libdir}/${oss_lib} || die
done

dosym /usr/${libdir}/oss/include /usr/include/oss || die
}

pkg_postinst() {
UPDATE_MODULEDB=true
linux-mod_pkg_postinst

ewarn "In order to use OSSv4 you must run"
ewarn "/etc/init.d/oss start"
ewarn "If you are upgrading from a previous build of OSSv4 you must run"
ewarn "/etc/init.d/oss restart"
ewarn "In case of upgrading from a previous build or reinstalling current one"
ewarn "You might need to remove /lib/modules/${KV_FULL}/kernel/oss"
}

pkg_postrm() {
linux-mod_pkg_postrm
}


Pay attention to the lines:

sed -e "s;grc_max=3;grc_max=6;g" \
-i "${S}/setup/srcconf.c" || die
sed -e "s;GRC_MAX_QUALITY=3;GRC_MAX_QUALITY=6;g" \
sed -e "s;'#define CONFIG_OSS_GRC_MAX_QUALITY 3';'#define CONFIG_OSS_GRC_MAX_QUALITY 6';" \

Don't they mean that fun2 devs try to activate quality 6 via ebuild?

Also you can see in the ebuild they use $WORKDIR Where is that damn directory located i can't figure out. But when i make emerge ebuild downloads the soucre code from the site into that WORKDIR and does all manipulations for building.

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 12:22 pm

jackd people told me (if they don't lie) that jackd does not do resampling on its own. It uses the system-wide resamplers or those resamplers which are configured inside jackd clients or are part of jackd clients.
It seems everything coincides. Jackd does not work without a mixer! If u disable vmix you disable resampling and jackd can't work directly with the hw resampler of the card and jackd won't start without vmix! As for alsa, alsa can't work without alsamixer and you can't switch off alsa mixer completely! It's not difficult to guess that alsamixer can do both SECRET and NONSECRET resampling! I bet alsamixer has a secret resampler like vmix has. Why? BECAUSE if u compile your system without any resamplers like sox, speex or libsamplerate, resampling is still done! And who does that secret resampling? Only alsa is left as a candidate. So it does the resampling evidently via alsamixer since alsa even won't work without alsamixer.
let's return to jackd. Why does it need the system-wide mixer? why can't it use the resamplers of its clients? Evidently because SOME CLIENTS DON'T HAVE OWN RESAMPLERS AND USE THOSE OF THE SYSTEM. It's a wellknown fact that you can set alsa via asound.conf to use third-party resamplers like speex or libsamplerate. It also means that when those THIRD PARTY RESAMPLERS ARE NOT INSTALLED ALSA DOES ITS OWN RESAMPLING VIA ALSAMIXER. So JACKD NEEDS EXTERNAL SYSTEM-WIDE RESAMPLER WHICH IS PROVIDED BY MIXERS OF THE DRIVER.

Hey, we came closer to the figuring out audio systems of linux :)
Last edited by ossuserr on Fri Jan 08, 2016 12:39 pm, edited 1 time in total.

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Fri Jan 08, 2016 12:32 pm

If you have problems with "ebuilds" and cannot understand how to use "sed" editor, you may better try Ubuntu.

Code: Select all

$ cat /usr/lib/oss/conf/osscore.conf | grep quality
# The src_quality setting defines the precision of the software based sample
# quality setting gives better quality while lower settings consume less
# 0 - D lowest quality (normally equals to 1=low quality)
# 1 - L  low quality    (spline interpolation)
# 2 - M  medium quality (lagrange interpolation)
# 3 - H  high quality   (DEFAULT)
# 4 - HX high quality   (high quality with extra precision)
# 5 - P  production quality
# 6 - PX production quality (prod quality with extra precision)
#src_quality=3

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 12:45 pm

igorzwx wrote:If you have problems with "ebuilds" and cannot understand how to use "sed" editor, you may better try Ubuntu.

I hate the niggers' system ubuntu. I would better use jewish gen2. Thanks for proposal though. I know how to use sed. But generally it uses formula 's/aaa/bbb/g' while in ebuild there is no / sign. Perhaps ebuilds have own syntax. I would better enquire from gen2 users about ebuild than switch to another os.

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Fri Jan 08, 2016 12:57 pm

ossuserr wrote:
igorzwx wrote:If you have problems with "ebuilds" and cannot understand how to use "sed" editor, you may better try Ubuntu.

I hate the niggers' system ubuntu. I would better use jewish gen2. Thanks for proposal though. I know how to use sed. But generally it uses formula 's/aaa/bbb/g' while in ebuild there is no / sign. Perhaps ebuilds have own syntax. I would better enquire from gen2 users about ebuild than switch to another os.


If you know how to use "sed", it should not be difficult to fix the configure script with two "sed" commands.

For Arch, it may look like this:

Code: Select all

# Create build directory and configure
mkdir build && cd build
sed -e 's/GRC_MIN_QUALITY=3/GRC_MIN_QUALITY=6/g' ${srcdir}/${_dir}/configure
sed -e 's/GRC_MAX_QUALITY=3/GRC_MAX_QUALITY=6/g' ${srcdir}/${_dir}/configure
${srcdir}/${_dir}/configure --enable-libsalsa=NO || return 1


You may not need to modify /src/build/kernel/framework/include/local_config.h with "sed", because this file should be produced by the configure script.
It should look like this:

Code: Select all

#define CONFIG_OSS_GRC_MIN_QUALITY 6
#define CONFIG_OSS_GRC_MAX_QUALITY 6


It seems that you are not deaf, but you might be semi-blind.
That is why, perhaps, you do not read my answers, and the OSS4 documentation as well.

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 1:06 pm

It's because i have to do several things at a time. But you advices to create some directories are senseless.
ebuild creates own directories during building and overwrites the previous configure and make files. I think this was kind of not difficult to guess. The only thing i can modify is ebuild itself.
You did not have to repeat your info. It's not me who does not understand your code. You don't want to understand how ebuilds work....

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Fri Jan 08, 2016 1:39 pm

ossuserr wrote:It's because i have to do several things at a time. But you advices to create some directories are senseless.
ebuild creates own directories during building and overwrites the previous configure and make files. I think this was kind of not difficult to guess. The only thing i can modify is ebuild itself.
You did not have to repeat your info. It's not me who does not understand your code. You don't want to understand how ebuilds work....


Which "directories"?

It seems that Gentoo might be harmful for brains.

If you do not know how to use the "sed" editor, you can simply modify the configure script of OSS4 with ordinary text editor.
Even Ubuntu/Linux newbies can do this without any problems.

Read this: _http://www.opensound.com/forum/viewtopic.php?f=3&t=3790&start=15#p15987
and this:

igorzwx wrote: _http://www.opensound.com/forum/viewtopic.php?f=3&t=5812&p=21415#p21405

1. Edit the "configure" script:

Code: Select all

# Set GRC3 min/max conversion quality setting to 3 to conserve space.
# TODO: Add support for configurable quality settings.
GRC_MIN_QUALITY=6
GRC_MAX_QUALITY=6
export GRC_MIN_QUALITY GRC_MAX_QUALITY


2. Execute the "configure" script.

3. Check .../src/build/kernel/framework/include/local_config.h
It should look like this:

Code: Select all

#define CONFIG_OSS_GRC_MIN_QUALITY 6
#define CONFIG_OSS_GRC_MAX_QUALITY 6


If not, you can edit it.

4. Then rebuild OSS as usual


For Gentoo:

Step 1:

Code: Select all

ebuild your_oss_ebuild unpack


Step 2:

Code: Select all

cd [your_oss_build_directory, e.g. /var/tmp/portage/...]


Step 3: Edit the configure script of OSS4 to make it look like this:

Code: Select all

# TODO: Add support for configurable quality settings.
GRC_MIN_QUALITY=6
GRC_MAX_QUALITY=6
export GRC_MIN_QUALITY GRC_MAX_QUALITY


Step 4: Go back to the ebuild directory

Step 5:

Code: Select all

ebuild your_oss_ebuild compile
ebuild your_oss_ebuild install
ebuild your_oss_ebuild qmerge


Read this: _http://www.opensound.com/forum/viewtopic.php?f=3&t=3790&start=15#p15987

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 1:57 pm

funto ebuild activates quality 6 by default as people confirmed it.
fun2|gen2 rule!

Your arch sucks, man. Another jew os by the way. Make the right choice, man! I am just a bit old for that shit, that's why i have a tired vision regularly and have to ask the younger to check large code portions.

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 1:58 pm

Please, no more code so far! I need to get some drugs now. feel too foggy

igorzwx
Known Member
Posts: 1256
Joined: Sun Jun 28, 2009 9:31 pm

Re: Esi Juli@ + OSS

Postby igorzwx » Fri Jan 08, 2016 2:02 pm

ossuserr wrote:funto ebuild activates quality 6 by default as people confirmed it.
fun2|gen2 rule!

Your arch sucks, man. Another jew os by the way. Make the right choice, man! I am just a bit old for that shit, that's why i have a tired vision regularly and have to ask the younger to check large code portions.


Is it really so difficult to edit a text file with a text editor?

ossuserr
Known Member
Posts: 272
Joined: Thu Jan 08, 2015 12:01 am
Sound Card: audigy 2 zs platinum, esi juli
OS: gentu riced to bo0st
Location: Earth

Re: Esi Juli@ + OSS

Postby ossuserr » Fri Jan 08, 2016 2:17 pm

The thing is that there is no need to edit because the ebuild already replace 3 by 6.
https://bpaste.net/show/a341e3c890fe see lines 69 and 71.
Agree?
Also ebuild syntax uses ; instead of /
Emerge-portage tool is nothing more than the tool to download the source code and to modify or|and generate ./configure file via commands given in ebuild file.

All that is downloaded into $WORKDIR and configured there.


Return to “Linux”

Who is online

Users browsing this forum: No registered users and 2 guests