Skip to content

Part 9.3, materials #8

@RickardAhlstedt

Description

@RickardAhlstedt

Hi!
First off, great work.
Although I have found some problems regarding the ObjVolume-class, but it's quite an easy fix to replace StringBuilder with a simple string.
And float.TryParse requires some additional parameters such as setting the decimal-separator to use a dot instead. (My locale of my dev-machine is set to use swedish currency).

My suggestion here is:

CultureInfo ci = (CultureInfo)CultureInfo.CurrentCulture.Clone();
ci.NumberFormat.CurrencyDecimalSeparator = ".";

And then adding , NumberStyles.Any, ci, to every float.TryParse
Example:

bool success = float.TryParse(texcoordparts[0], NumberStyles.Any, ci, out vec.X);

As for my problem, I can't get the textures to work properly using OpenTK 3.0 (runtime-version 2.0.50727), the count for the texture-list remains zero.

Good to note, I also applied the above-fix for Material.cs, and I store my files in /data/Models/ and shaders in /data/Shaders/.
Any pointers are welcome, submitting this as an issue due to perhaps get the above-fix implemented

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions