Giter Site home page Giter Site logo

ftgl's People

Contributors

corngood avatar damiandixon avatar mathstuf avatar oliviersohn avatar ulrichard avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

ftgl's Issues

error undefined reference to `FTExtrudeFont::FTExtrudeFont(char const*)'

while I am compiling my opengl code I am facing this error.how to remove this?

all: sample2D

sample2D: Sample_GL3_2D.cpp glad.c
        g++ -o sample2D Sample_GL3_2D.cpp glad.c -lGL -lglfw -ldl -std=c++11

clean:
        rm sample2D

this is my contents of Makefile
and my code for rendering the font

const char* fontfile = "Monaco.ttf";
GL3Font.font = new FTExtrudeFont(fontfile); // 3D extrude style rendering

if(GL3Font.font->Error())
{
    cout << "Error: Could not load font `" << fontfile << "'" << endl;
    glfwTerminate();
    exit(EXIT_FAILURE);
}

// Create and compile our GLSL program from the font shaders
fontProgramID = LoadShaders( "fontrender.vert", "fontrender.frag" );
GLint fontVertexCoordAttrib, fontVertexNormalAttrib, fontVertexOffsetUniform;
fontVertexCoordAttrib = glGetAttribLocation(fontProgramID, "vertexPosition");
fontVertexNormalAttrib = glGetAttribLocation(fontProgramID, "vertexNormal");
fontVertexOffsetUniform = glGetUniformLocation(fontProgramID, "pen");
GL3Font.fontMatrixID = glGetUniformLocation(fontProgramID, "MVP");
GL3Font.fontColorID = glGetUniformLocation(fontProgramID, "fontColor");

GL3Font.font->ShaderLocations(fontVertexCoordAttrib, fontVertexNormalAttrib, fontVertexOffsetUniform);
GL3Font.font->FaceSize(1);
GL3Font.font->Depth(0);
GL3Font.font->Outset(0, 0);
GL3Font.font->CharMap(ft_encoding_unicode);

Undefined reference to glew

while I am working on rendering fonts using ftgl in my opengl project I am encountering errors stating

g++ -o mygame Sample_GL3_2D.cpp glad.c -lGL -lglfw -ldl -lftgl  -lSOIL -I /usr/include/freetype2 -L/usr/local/lib -lfreetype
/usr/local/lib/libftgl.so: undefined reference to `__glewGenBuffers'
/usr/local/lib/libftgl.so: undefined reference to `glewInit'
/usr/local/lib/libftgl.so: undefined reference to `__glewBindVertexArray'
/usr/local/lib/libftgl.so: undefined reference to `__glewBindBuffer'
/usr/local/lib/libftgl.so: undefined reference to `__glewUniform3f'
/usr/local/lib/libftgl.so: undefined reference to `__glewVertexAttribPointer'
/usr/local/lib/libftgl.so: undefined reference to `__glewBufferData'
/usr/local/lib/libftgl.so: undefined reference to `__glewDeleteBuffers'
/usr/local/lib/libftgl.so: undefined reference to `__glewDeleteVertexArrays'
/usr/local/lib/libftgl.so: undefined reference to `__glewGenVertexArrays'
/usr/local/lib/libftgl.so: undefined reference to `__glewEnableVertexAttribArray'

these are my contents in Makefile

all:mygame

mygame: Sample_GL3_2D.cpp glad.c
	g++ -o mygame Sample_GL3_2D.cpp glad.c -lGL -lglfw -ldl -lftgl  -lSOIL -I /usr/include/freetype2 -L/usr/local/lib -lfreetype
clean:
	rm mygame

looks like the errors is being raised by the libftgl.so library. I have installed the GLEW using the glew packages in the ubuntu. but dont understand why it isn't being referenced.

FTBufferFont clips bitmap fonts wrongly

See test/FTBufferFont-Bitmap.cpp from my pull request. (I created this test program to demonstrate fixing another bug, drawing garbage in this case, but the clipping bug remains.)

Info needed

(Edited after manually looking in the dylib for function names)

Hello,

It seems that the functions from the commit 92d175e are not present in the ftgl 2.1.3 library that was installed by brew install ftgl on my mac.

What should I do to install this version? Is it possible to merge the changes of this fork back to the main repository and make a new release?

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.