<?xml version="1.0" encoding="UTF-8"?><rss xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title><![CDATA[[...]has no member named[...] Load OpenGL Functions]]></title><description><![CDATA[<p>Hallo.<br />
Ich kann recht gut in jave programmieren, wollte aber mal etwas neues ausprobieren. C++. Also habe ich einfach mal angefangen, learning by doing.</p>
<p>mein problem ist, dass momentan meine member function in einer klasse nicht erkannt werden.<br />
Hier der Header:</p>
<pre><code>#include &lt;GL/glext.h&gt;
class GLF {
public:
	GLF();
	PFNGLATTACHSHADERPROC	attachShader;
	PFNGLCOMPILESHADERPROC	compileShader;
	PFNGLCREATEPROGRAMPROC	createProgram;
	PFNGLCREATESHADERPROC	createShader;
	PFMGLGETSHADERIVPROC	getShaderiv;
	PFNGLLINKPROGRAMPROC	linkProgram;
	PFNGLSHADERSOURCEPROC	shaderSource;
};
</code></pre>
<p>Hier die klasse:</p>
<pre><code>#include &lt;GLF.h&gt;

GLF::GLF(){
	attachShader	= (PFNGLATTACHSHADERPROC)	glfwGetProcAddress(&quot;glAttachShader&quot;);
	compileShader	= (PFNGLCOMPILESHADERPROC)	glfwGetProcAddress(&quot;glCompileShader&quot;);
	createProgram	= (PFNGLCREATEPROGRAMPROC)	glfwGetProcAddress(&quot;glCreateProgram&quot;);
	createShader	= (PFNGLCREATESHADERPROC)	glfwGetProcAddress(&quot;glCreateShader&quot;);
	getShaderiv		= (PFMGLGETSHADERIVPROC)	glfwGetProcAddress(&quot;glGetShaderiv&quot;);
	linkProgram		= (PFNGLLINKPROGRAMPROC)	glfwGetProcAddress(&quot;glLinkProgram&quot;);
	shaderSource	= (PFNGLSHADERSOURCEPROC)	glfwGetProcAddress(&quot;glShaderSource&quot;);
}
</code></pre>
<p>(ich benutze <a href="http://www.glfw.org/" rel="nofollow">http://www.glfw.org/</a>)</p>
<p>Allerdings habe ich scheinbar noch nicht ganz verstanden, wie ich jetzt die function pointer zugreif und sie aufrufe.</p>
<p>(Auszug aus Test.ccp)<br />
So mache ich es im moment:</p>
<pre><code>GLF* glf = (GLF*)pointer;
           int vertexShader = glf-&gt;createShader(GL_VERTEX_SHADER);
</code></pre>
<p>Allerdings bekomme ich dan noch beim Compilen diesen Fehler:</p>
<blockquote>
<p>[apply] [...]Test.cpp:16:35: error: 'class GLF' has no member named 'createShader'</p>
</blockquote>
<p>Kann mir da jemand helfen?<br />
Viele Grüße 0:08</p>
]]></description><link>https://www.c-plusplus.net/forum/topic/325303/has-no-member-named-load-opengl-functions</link><generator>RSS for Node</generator><lastBuildDate>Mon, 13 Jul 2026 04:33:17 GMT</lastBuildDate><atom:link href="https://www.c-plusplus.net/forum/topic/325303.rss" rel="self" type="application/rss+xml"/><pubDate>Thu, 24 Apr 2014 22:09:02 GMT</pubDate><ttl>60</ttl><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Thu, 24 Apr 2014 22:09:02 GMT]]></title><description><![CDATA[<p>Hallo.<br />
Ich kann recht gut in jave programmieren, wollte aber mal etwas neues ausprobieren. C++. Also habe ich einfach mal angefangen, learning by doing.</p>
<p>mein problem ist, dass momentan meine member function in einer klasse nicht erkannt werden.<br />
Hier der Header:</p>
<pre><code>#include &lt;GL/glext.h&gt;
class GLF {
public:
	GLF();
	PFNGLATTACHSHADERPROC	attachShader;
	PFNGLCOMPILESHADERPROC	compileShader;
	PFNGLCREATEPROGRAMPROC	createProgram;
	PFNGLCREATESHADERPROC	createShader;
	PFMGLGETSHADERIVPROC	getShaderiv;
	PFNGLLINKPROGRAMPROC	linkProgram;
	PFNGLSHADERSOURCEPROC	shaderSource;
};
</code></pre>
<p>Hier die klasse:</p>
<pre><code>#include &lt;GLF.h&gt;

GLF::GLF(){
	attachShader	= (PFNGLATTACHSHADERPROC)	glfwGetProcAddress(&quot;glAttachShader&quot;);
	compileShader	= (PFNGLCOMPILESHADERPROC)	glfwGetProcAddress(&quot;glCompileShader&quot;);
	createProgram	= (PFNGLCREATEPROGRAMPROC)	glfwGetProcAddress(&quot;glCreateProgram&quot;);
	createShader	= (PFNGLCREATESHADERPROC)	glfwGetProcAddress(&quot;glCreateShader&quot;);
	getShaderiv		= (PFMGLGETSHADERIVPROC)	glfwGetProcAddress(&quot;glGetShaderiv&quot;);
	linkProgram		= (PFNGLLINKPROGRAMPROC)	glfwGetProcAddress(&quot;glLinkProgram&quot;);
	shaderSource	= (PFNGLSHADERSOURCEPROC)	glfwGetProcAddress(&quot;glShaderSource&quot;);
}
</code></pre>
<p>(ich benutze <a href="http://www.glfw.org/" rel="nofollow">http://www.glfw.org/</a>)</p>
<p>Allerdings habe ich scheinbar noch nicht ganz verstanden, wie ich jetzt die function pointer zugreif und sie aufrufe.</p>
<p>(Auszug aus Test.ccp)<br />
So mache ich es im moment:</p>
<pre><code>GLF* glf = (GLF*)pointer;
           int vertexShader = glf-&gt;createShader(GL_VERTEX_SHADER);
</code></pre>
<p>Allerdings bekomme ich dan noch beim Compilen diesen Fehler:</p>
<blockquote>
<p>[apply] [...]Test.cpp:16:35: error: 'class GLF' has no member named 'createShader'</p>
</blockquote>
<p>Kann mir da jemand helfen?<br />
Viele Grüße 0:08</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396189</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396189</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Thu, 24 Apr 2014 22:09:02 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 07:18:28 GMT]]></title><description><![CDATA[<p>Willst Du wirklich versuchen C++ zu programmieren ohne Dich mit der Sprache vorher vertraut zu machen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396202</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396202</guid><dc:creator><![CDATA[Helmut.Jakoby]]></dc:creator><pubDate>Fri, 25 Apr 2014 07:18:28 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 09:18:02 GMT]]></title><description><![CDATA[<p>Ich wollte mich mit der Sprache vertraut machen, indem ich C++ programmiere.<br />
Im Wissen, dass google mein Freund ist.</p>
<p>Das hat bis jetzt gut Funktioniert.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396215</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396215</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Fri, 25 Apr 2014 09:18:02 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 09:19:52 GMT]]></title><description><![CDATA[<p>Damit wirst du bei C++ auf die Fresse fallen. Viel Glueck.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396216</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396216</guid><dc:creator><![CDATA[Kellerautomat]]></dc:creator><pubDate>Fri, 25 Apr 2014 09:19:52 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 09:54:51 GMT]]></title><description><![CDATA[<p>Hm, das scheint mir ein subtiler Hinweis zu sein, eventuell doch mal nach einem umsteiger Tutorial zu suchen.</p>
<p>Aber mag noch mal jemand auf meine Ursprungsfrage zurueckkommen, oder habe ich da etwas so verhutzelt, dass das Ganze erstmal mit einem nah zur Seite geschoben werden sollte?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396223</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396223</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Fri, 25 Apr 2014 09:54:51 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 10:36:38 GMT]]></title><description><![CDATA[<p><s>int vertexShader = (glf-&gt;createShader)(GL_VERTEX_SHADER);</s><br />
~Bashar hat recht.~</p>
<p>Sieht aber schon seltsam aus...</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396226</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396226</guid><dc:creator><![CDATA[Caligulaminus]]></dc:creator><pubDate>Fri, 25 Apr 2014 10:36:38 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 10:24:41 GMT]]></title><description><![CDATA[<p>Caligulaminus schrieb:</p>
<blockquote>
<pre><code>int vertexShader = (glf-&gt;createShader)(GL_VERTEX_SHADER);
</code></pre>
<p>Sieht aber schon seltsam aus...</p>
</blockquote>
<p>Ist auch überflüssig.</p>
<p>Der vom OP gepostete Code ist eigentlich (soweit man das anhand der Ausschnitte beurteilen kann) korrekt. Insbesondere ist die Fehlermeldung, createShader sei kein Member der Klasse, offensichtlich falsch. Also muss wohl der gepostete Code ein anderer sein als der, der das Problem verursacht.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396227</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396227</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Fri, 25 Apr 2014 10:24:41 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 10:27:20 GMT]]></title><description><![CDATA[<p>Ich sehe jetzt auch nix, was diesen Fehler verursacht.<br />
Aber eigentlich sollte der Compiler noch darueber stolpern:</p>
<p>PFMGLGETSHADERIVPROC heißt PF<strong>N</strong>GLGETSHADERIVPROC</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396228</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396228</guid><dc:creator><![CDATA[Furble Wurble]]></dc:creator><pubDate>Fri, 25 Apr 2014 10:27:20 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 10:51:34 GMT]]></title><description><![CDATA[<p>Oh, ein purer tip Fehler.<br />
Ich habe das M durch ein N ersetzt und jetzt geht alles.<br />
(Wenn ich das N jetzt wider zum M mache heißt es wieder</p>
<blockquote>
<p>'class GLF' has no member named 'createShader'</p>
</blockquote>
<p>. Achja... Ursache und Wirkung ?)</p>
<p>Es tut mir leid, dass ich euch jetzt wegen so einem M genervt habe.</p>
<p>Ein schönes Wochenende:<br />
0:08</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396234</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396234</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Fri, 25 Apr 2014 10:51:34 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 11:05:42 GMT]]></title><description><![CDATA[<p>Nochmal eine Nachfrage: Ist die Fehlermeldung (no member named createShader) die erste vom Compiler gemeldete?</p>
<p>Falls ja Frage an alle: Wie ist das zu erklären?</p>
<p>(Falls nein: Die erste Fehlermeldung ist immer relevant und oft die einzige relevante.)</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396236</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396236</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Fri, 25 Apr 2014 11:05:42 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 11:41:35 GMT]]></title><description><![CDATA[<p>Fehler oder Warnungen?</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396240</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396240</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Fri, 25 Apr 2014 11:41:35 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 12:33:00 GMT]]></title><description><![CDATA[<p>0_08 schrieb:</p>
<blockquote>
<p>Fehler oder Warnungen?</p>
</blockquote>
<p>Fehler <strong>im Output des Compilers</strong>, nicht aus irgendeiner Liste der IDE.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396253</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396253</guid><dc:creator><![CDATA[manni66]]></dc:creator><pubDate>Fri, 25 Apr 2014 12:33:00 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 12:46:53 GMT]]></title><description><![CDATA[<p>Das ist mir durchaus bewusst.<br />
Aber ich habe ja auch noch z.B. sowas hier:</p>
<pre><code>[apply] [...]Shader.cpp:10:15: warning: unused variable 'isCompiled' [-Wunused-variable]
</code></pre>
<p>Aber es stimmt, gefuelte tausend Zeilen darueber habe ich das hier gefunden:</p>
<blockquote>
<p>[apply] The ' characters around the executable and arguments are<br />
[apply] not part of the command.<br />
[apply] In file included from [...]Shader.cpp:7:0:<br />
[apply] cjgPack/src/GLF.h:12:2: error: 'PFMGLGETSHADERIVPROC' does not name a type<br />
[apply] PFMGLGETSHADERIVPROC getShaderiv;<br />
[apply] ^</p>
</blockquote>
<p>o.o Muss man aber auch erstmal nach suchen, wenn man nur ein (no member named createShader) sieht.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396259</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396259</guid><dc:creator><![CDATA[0_08]]></dc:creator><pubDate>Fri, 25 Apr 2014 12:46:53 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 13:59:52 GMT]]></title><description><![CDATA[<p>Da muss man nicht nach suchen, das ist einfach von oben der erste Fehler... falls man den vor lauter Warnungen nicht findet, macht man vorher die Warnungen weg (sollte man sowieso).</p>
<p>edit: Man beseitigt die Ursachen für die Warnungen mein ich natürlich, nicht einfach das Warnlevel runtersetzen <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /></p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396264</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396264</guid><dc:creator><![CDATA[Bashar]]></dc:creator><pubDate>Fri, 25 Apr 2014 13:59:52 GMT</pubDate></item><item><title><![CDATA[Reply to [...]has no member named[...] Load OpenGL Functions on Fri, 25 Apr 2014 13:25:27 GMT]]></title><description><![CDATA[<p>Achtung bei der Formulierung: Warning sollten prinzipiell aktiviert sein, damit sie entfernt werden können.</p>
<p>Umgekehrt hast du natürlich Recht, dass man, um solche Fehler zu suchen, die Warnungen ruhig abschalten kann/soll.</p>
<p>Aber mal grad eine Story aus meinem Leben: Hatte jetzt die Tage einen Fehler in einem Lambda-Ausdruck für std::accumulate. Und die ersten 200 Zeilen des Compilerfehlers (MSVC2013) bezogen sich nur auf den STL Code, bis endlich mal auf meinen Code referenziert wurde. <img
      src="https://www.c-plusplus.net/forum/plugins/nodebb-plugin-emoji/emoji/emoji-one/1f609.png?v=ab1pehoraso"
      class="not-responsive emoji emoji-emoji-one emoji--winking_face"
      title=";)"
      alt="😉"
    /><br />
Man kann aber dazu sagen, dass die alleroberste Meldung sowas sagte wie &quot;Das Ding passt hier nicht hin&quot;.</p>
]]></description><link>https://www.c-plusplus.net/forum/post/2396270</link><guid isPermaLink="true">https://www.c-plusplus.net/forum/post/2396270</guid><dc:creator><![CDATA[Skym0sh0]]></dc:creator><pubDate>Fri, 25 Apr 2014 13:25:27 GMT</pubDate></item></channel></rss>