From owner-freebsd-multimedia Sun Jun 27 4: 3: 4 1999 Delivered-To: freebsd-multimedia@freebsd.org Received: from dslab7.cs.uit.no (dslab7.cs.UiT.No [129.242.16.27]) by hub.freebsd.org (Postfix) with ESMTP id C77E314C3E for ; Sun, 27 Jun 1999 04:02:59 -0700 (PDT) (envelope-from frodef@dslab7.cs.uit.no) Received: (from frodef@localhost) by dslab7.cs.uit.no (8.9.3/8.9.1) id NAA68588; Sun, 27 Jun 1999 13:00:53 +0200 (CEST) (envelope-from frodef) To: freebsd-multimedia@freebsd.org Subject: Re: bt848 channel frequencies References: <199906262132.PAA05313@orthanc.ab.ca> From: Frode Vatvedt Fjeld Date: 27 Jun 1999 13:00:53 +0200 In-Reply-To: lyndon@orthanc.ab.ca's message of "Sat, 26 Jun 1999 15:32:40 -0600" Message-ID: <2h7lopaowq.fsf@dslab7.cs.uit.no> Lines: 24 User-Agent: Gnus/5.070084 (Pterodactyl Gnus v0.84) Emacs/20.3 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Sender: owner-freebsd-multimedia@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org lyndon@orthanc.ab.ca writes: > Why not hide the implementation in the library and just pass the > frequency (in around as an ASCII string? The frequencies will be stored on disk using ASCII, obviously. But sooner or later they must be converted to some integer representation, and I think the lib should provide this as an utility function (because it's better to implement things once well, rather than many times not-so-well). Perhaps the better solution is to use a composite type for frequencies: struct tuner_frequency { long MHz; long Hz; long uHz; }; This would allow for 0-2 PHz (Peta-Hz :) in steps of micro-Hz, and the usual TV frequencies are easily extracted. -- Frode Vatvedt Fjeld To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-multimedia" in the body of the message