2013-05-31 22:01:01 +00:00
|
|
|
// Copyright 2013 The Lmath Developers. For a full listing of the authors,
|
|
|
|
// refer to the AUTHORS file at the top-level directory of this distribution.
|
|
|
|
//
|
|
|
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
|
|
|
// you may not use this file except in compliance with the License.
|
|
|
|
// You may obtain a copy of the License at
|
|
|
|
//
|
|
|
|
// http://www.apache.org/licenses/LICENSE-2.0
|
|
|
|
//
|
|
|
|
// Unless required by applicable law or agreed to in writing, software
|
|
|
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
|
|
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
|
|
// See the License for the specific language governing permissions and
|
|
|
|
// limitations under the License.
|
|
|
|
|
2012-11-01 23:14:07 +00:00
|
|
|
#[link(name = "lmath",
|
2013-03-29 22:54:05 +00:00
|
|
|
vers = "0.1.0",
|
2012-11-02 03:59:51 +00:00
|
|
|
uuid = "A2DEEB53-EB35-4B44-B247-9044B57E3BA5",
|
2012-11-01 01:59:53 +00:00
|
|
|
author = "Brendan Zabarauskas",
|
2012-11-06 04:03:14 +00:00
|
|
|
url = "https://github.com/bjz/lmath-rs")];
|
2012-09-07 10:48:47 +00:00
|
|
|
|
2012-11-01 01:59:53 +00:00
|
|
|
#[comment = "A generic linear algebra library."];
|
2012-12-18 02:26:35 +00:00
|
|
|
#[license = "ASL2"];
|
2012-09-07 10:48:47 +00:00
|
|
|
#[crate_type = "lib"];
|
|
|
|
|
2012-11-15 02:23:39 +00:00
|
|
|
pub mod mat;
|
|
|
|
pub mod quat;
|
|
|
|
pub mod vec;
|
2012-10-28 11:43:23 +00:00
|
|
|
|
2013-01-27 22:22:15 +00:00
|
|
|
pub mod projection;
|
2013-06-12 02:57:58 +00:00
|
|
|
|
|
|
|
pub trait Dimensional<T,Slice> {
|
|
|
|
pub fn index<'a>(&'a self, i: uint) -> &'a T;
|
|
|
|
pub fn index_mut<'a>(&'a mut self, i: uint) -> &'a mut T;
|
|
|
|
pub fn as_slice<'a>(&'a self) -> &'a Slice;
|
|
|
|
pub fn as_mut_slice<'a>(&'a mut self) -> &'a mut Slice;
|
|
|
|
}
|