The wayland project is using those technologies. Try going trough its sources to see whats going on. And it does work:)<div><br></div><div>BR,</div><div>Slavko<br><br><div class="gmail_quote">On Sun, Jan 9, 2011 at 2:39 PM, Alberich de megres <span dir="ltr"><<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">sorry to insist, but anyone can helpme with my problem?<br>
Or point me to some manual-tutorial about how to setup drm + kms + egl from?<br>
<br>
thanks!<br>
<br>
<br>
On Fri, Dec 31, 2010 at 4:35 PM, Alberich de megres<br>
<div><div></div><div class="h5"><<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>> wrote:<br>
> I'm using:<br>
><br>
> - libdrm 2.4.23 with nouveau support<br>
> - Mesa from git repo (las update Dec 14th)<br>
> - Nvidia NV43 device (Geforce go 6200/6400)<br>
> - using nouveau<br>
> - kernel 2.6.36 custom with this config:<br>
> graphics support<br>
> |-> <M> Direct Rendering Manager<br>
> |-> <M> Low level video output switch controls<br>
> |-> {*} Support for frame buffer devices<br>
> |->[*] Enable Video Mode Handling Helpers<br>
> |->[*] Enable Tile blitting support<br>
> |-> <M> VGA 16-color<br>
> |-> [*] Vesa VGA graphics<br>
> |-> VGA text console<br>
> |-> All options built in kernel<br>
><br>
> modetest says my connector id is 7 so I tried modetest -s 7:1 with this error<br>
> DRM_IOCTL_I915_GEM_APERTURE failed: Invalid argument<br>
> Assuming 131072Kb available aperture size<br>
> May lead to reduced performance or incorrect rendering<br>
> get chip id failed; -1<br>
> param 4, val: 0<br>
> failed to alloc buffer: Invalid argument<br>
><br>
><br>
> Thanks!!<br>
><br>
> On Fri, Dec 31, 2010 at 3:41 PM, Chia-I Wu <<a href="mailto:olvaffe@gmail.com">olvaffe@gmail.com</a>> wrote:<br>
>> On Fri, Dec 31, 2010 at 10:06 PM, Alberich de megres<br>
>> <<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>> wrote:<br>
>>> sorry to repost again,<br>
>>> but I attached a screenshoot with what happens to me.<br>
>>><br>
>>> With single buffer, just adding glFlush() and a black clear color i<br>
>>> get the result I want.<br>
>>> But if I change the color, no matter wich, i allways the same get the<br>
>>> screen attached (even with the same color)<br>
>> I am not sure what goes wrong. You might want to try modeset from<br>
>> libdrm to see if kernel modesetting is working for you (use the -s<br>
>> option). It might also be helpful to list your<br>
>> hardware/kernel/mesa/drm versions so that others with a similar<br>
>> environment may help.<br>
>><br>
>>> thanks!<br>
>>><br>
>>> On Fri, Dec 31, 2010 at 12:32 PM, Alberich de megres<br>
>>> <<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>> wrote:<br>
>>>> Oh, sorry for the type, i was trying different clear color and at the<br>
>>>> end I didn't change it back.<br>
>>>><br>
>>>> But on wayland the server doesn't call glFlush. How it render/draws<br>
>>>> the background then?<br>
>>>><br>
>>>> Also I tried drmModePageFlip, to change buffers, but i cannot get rid<br>
>>>> of these wierd things (like lots of thin columns).<br>
>>>><br>
>>>> thanks!<br>
>>>><br>
>>>> On Fri, Dec 31, 2010 at 10:11 AM, Chia-I Wu <<a href="mailto:olvaffe@gmail.com">olvaffe@gmail.com</a>> wrote:<br>
>>>>> On Thu, Dec 30, 2010 at 2:26 AM, Alberich de megres<br>
>>>>> <<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>> wrote:<br>
>>>>>> I found my error, I compiled a kernel and forgot some kms options. So<br>
>>>>>> now i can get a DRMDisplay<br>
>>>>>><br>
>>>>>> But, now I got a different problem:<br>
>>>>>> I can set a mode, using drm. And I set up the minimun so i should be<br>
>>>>>> able to clean the backgound (or the buffer) to white and see the<br>
>>>>>> screen on white. But what i really get is weird things like lots of<br>
>>>>>> columns...<br>
>>>>>><br>
>>>>>> Is there some place where i can read about drm+egl? My init code is<br>
>>>>>> barely copy+paste from wayland..<br>
>>>>>><br>
>>>>>> I attached the code, don't blame me for the code (copy+paste stuff)<br>
>>>>>> i'm only trying to understand how drm+egl works so i can create one by<br>
>>>>>> my own.<br>
>>>>> Since you are rendering to rbo[0], you should use fb_id[0] in<br>
>>>>> drmModeSetCrtc. You also need to call glFlush at the end of<br>
>>>>> draw_scene. The clear color is black, not white as you said.<br>
>>>>><br>
>>>>> These should be enough to see the correct result on screen. But you<br>
>>>>> might want to go further to implement double buffering (switch between<br>
>>>>> rbo[0] and rbo[1], and flip between fb_id[0] and fb_id[1]).<br>
>>>>><br>
>>>>>> thanks!<br>
>>>>>><br>
>>>>>><br>
>>>>>> On Mon, Dec 20, 2010 at 1:55 PM, Chia-I Wu <<a href="mailto:olvaffe@gmail.com">olvaffe@gmail.com</a>> wrote:<br>
>>>>>>> On Tue, Dec 14, 2010 at 5:24 PM, Alberich de megres<br>
>>>>>>> <<a href="mailto:alberich2k5@gmail.com">alberich2k5@gmail.com</a>> wrote:<br>
>>>>>>>> Hi !!<br>
>>>>>>>><br>
>>>>>>>> I got a problem while initializing egl, using the source on git repo:<br>
>>>>>>>> git clone git://<a href="http://anongit.freedesktop.org/mesa/mesa" target="_blank">anongit.freedesktop.org/mesa/mesa</a><br>
>>>>>>>><br>
>>>>>>>> So what i do is first<br>
>>>>>>>><br>
>>>>>>>> display = (EGLDisplay) eglGetDRMDisplayMESA(fd);<br>
>>>>>>>> if (display == NULL) return -1;<br>
>>>>>>>><br>
>>>>>>>> if (!eglInitialize(display, &major, &minor)) {<br>
>>>>>>>> ... error check<br>
>>>>>>>> }<br>
>>>>>>>><br>
>>>>>>>> When I do that i receive a message:<br>
>>>>>>>> libEGL warning: failed to create DRM screen<br>
>>>>>>>><br>
>>>>>>>> And sometimes i get this other on the same point:<br>
>>>>>>>> libEGL warning: failed to create DRM screen<br>
>>>>>>>> libEGL warning: EGL-DRI2: malformed or no PCI ID<br>
>>>>>>>><br>
>>>>>>>> I tried with both nourveau modeset=1, and radeon modeset=1<br>
>>>>>>>><br>
>>>>>>>> I compiled libdrm with the following options:<br>
>>>>>>>> ./configure --enable-nouveau-experimental-api --enable-vmwgfx-experimental-api<br>
>>>>>>>><br>
>>>>>>>> And mesa with the following:<br>
>>>>>>>> ./configure --with-dri-drivers=nouveau --enable-glx-tls<br>
>>>>>>>> --with-driver=dri --enable-xcb --disable-glut --enable-egl<br>
>>>>>>>> --enable-gles2 --with-egl-platforms=drm --disable-gallium<br>
>>>>>>>><br>
>>>>>>>> Also i tried those recomended on wayland site:<br>
>>>>>>>> ./configure --enable-egl --enable-gles2<br>
>>>>>>>><br>
>>>>>>>> Can any one point me some light?<br>
>>>>>>> The configure options look fine. It is not clear what might have gone<br>
>>>>>>> wrong. Can you try again with EGL_LOG_LEVEL=debug set?<br>
>>>>>>><br>
>>>>>>>> thanks!<br>
>>>>>>>> Albert<br>
>>>>>>>> _______________________________________________<br>
>>>>>>>> mesa-users mailing list<br>
>>>>>>>> <a href="mailto:mesa-users@lists.freedesktop.org">mesa-users@lists.freedesktop.org</a><br>
>>>>>>>> <a href="http://lists.freedesktop.org/mailman/listinfo/mesa-users" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-users</a><br>
>>>>>>>><br>
>>>>>>><br>
>>>>>>><br>
>>>>>>><br>
>>>>>>> --<br>
>>>>>>> olv@LunarG.com<br>
>>>>>>><br>
>>>>>><br>
>>>>><br>
>>>>><br>
>>>>><br>
>>>>> --<br>
>>>>> olv@LunarG.com<br>
>>>>><br>
>>>><br>
>>><br>
>><br>
>><br>
>><br>
>> --<br>
>> olv@LunarG.com<br>
>><br>
><br>
_______________________________________________<br>
mesa-users mailing list<br>
<a href="mailto:mesa-users@lists.freedesktop.org">mesa-users@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/mesa-users" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-users</a><br>
</div></div></blockquote></div><br><br clear="all"><br>-- <br>Slavko Glamočanin<br><a href="http://naprave.net">http://naprave.net</a><br>GSM: 0038631847589<br>
</div>