remove debug stuff
This commit is contained in:
parent
8bd323b8a0
commit
93209bd3fb
|
@ -6,7 +6,6 @@ pub struct Image {
|
||||||
impl From<String> for Image {
|
impl From<String> for Image {
|
||||||
#[inline]
|
#[inline]
|
||||||
fn from(string: String) -> Image {
|
fn from(string: String) -> Image {
|
||||||
print!("image: \n{}", string);
|
|
||||||
let string = string.replace("NaN", "0");
|
let string = string.replace("NaN", "0");
|
||||||
let string = string.trim();
|
let string = string.trim();
|
||||||
let lines: Vec<&str> = string.lines().collect();
|
let lines: Vec<&str> = string.lines().collect();
|
||||||
|
@ -15,9 +14,7 @@ impl From<String> for Image {
|
||||||
|
|
||||||
for line in lines {
|
for line in lines {
|
||||||
let line = &line[..dimension];
|
let line = &line[..dimension];
|
||||||
println!("line: {}", line);
|
|
||||||
for char in line.chars().into_iter() {
|
for char in line.chars().into_iter() {
|
||||||
println!("Char: {} value: {}", char, match char {'1' => 1, _ => 0});
|
|
||||||
pixels.push(match char {'1' => 1, _ => 0});
|
pixels.push(match char {'1' => 1, _ => 0});
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -47,7 +44,6 @@ impl ToString for Image {
|
||||||
|
|
||||||
#[inline]
|
#[inline]
|
||||||
pub(crate) fn animation_frames_from_string(string: String) -> Vec<Image> {
|
pub(crate) fn animation_frames_from_string(string: String) -> Vec<Image> {
|
||||||
print!("animation frames: \n{}", string);
|
|
||||||
let frames: Vec<&str> = string.split(">").collect();
|
let frames: Vec<&str> = string.split(">").collect();
|
||||||
|
|
||||||
frames.iter().map(|&frame| Image::from(frame.to_string())).collect()
|
frames.iter().map(|&frame| Image::from(frame.to_string())).collect()
|
||||||
|
|
Loading…
Reference in New Issue