John Swensen | 1 Nov 02:46 2008
Picon
Picon

Re: Text properties and FTGL


On Oct 31, 2008, at 4:41 PM, Jason Riedy wrote:

> And John Swensen writes:
>> From everything I have read and a quick glance at preview-
>> latex sources, this appears to be essentially the same process.
>
> For a fairly full set of features without LaTeX, see mimeTeX:
>  http://www.forkosh.com/mimetex.html
>
> If you cheat and make the image requests appear like web server
> CGI requests by setting the right environment variables, you
> could just exec mathTeX for high quality and fall back to running
> mimeTeX if it fails.
>
> Both are GPLv3 and probably severe overkill for plot labels.
>
> Jason

Thanks for pointing these out.  I don't know what they are not doing  
in mathTeX that I must be doing in my system calls, but mathTeX is  
significantly faster.  Since it is GPL and Octave is GPL I will  
probably actually compile this into my Octave tests and render  
straight to the openGL texture, rather than have it render to a file  
and then read it back in.  I think a time of ~0.1 seconds per LaTeX  
string and appropriate caching of the results is acceptable.

Once again, thanks for pointing this out.

John Swensen
(Continue reading)

Bill Denney | 1 Nov 03:21 2008

Re: Text properties and FTGL

John Swensen wrote:
> Thanks for pointing these out.  I don't know what they are not doing
> in mathTeX that I must be doing in my system calls, but mathTeX is
> significantly faster.  Since it is GPL and Octave is GPL I will
> probably actually compile this into my Octave tests and render
> straight to the openGL texture, rather than have it render to a file
> and then read it back in.  I think a time of ~0.1 seconds per LaTeX
> string and appropriate caching of the results is acceptable.

Just a thought, but could you render each result on a different page in
the LaTeX output and make it just ~0.1 sec total instead?

Have a good day,

Bill

Thomas Weber | 1 Nov 10:50 2008
Picon

Re: No bool matrices for imagesc in tip?

Am Freitag, den 31.10.2008, 20:08 +0000 schrieb Michael Goffioul:
> On Fri, Oct 31, 2008 at 3:46 PM, Thomas Weber
> <thomas.weber.mail <at> gmail.com> wrote:
> What does Matlab do?

It works, and it takes a colorbar from 0 to 2.
That's Matlab 7.1.

	Thomas

Michael Goffioul | 1 Nov 11:14 2008
Picon

Re: No bool matrices for imagesc in tip?

My question was badly expressed. It should have been: does
Matlab accepts that you "set(img, 'cdata', m)", where img is
an image handle and m is a bool matrix?

Michael.

On Sat, Nov 1, 2008 at 9:50 AM, Thomas Weber
<thomas.weber.mail <at> gmail.com> wrote:
> Am Freitag, den 31.10.2008, 20:08 +0000 schrieb Michael Goffioul:
>> On Fri, Oct 31, 2008 at 3:46 PM, Thomas Weber
>> <thomas.weber.mail <at> gmail.com> wrote:
>> What does Matlab do?
>
> It works, and it takes a colorbar from 0 to 2.
> That's Matlab 7.1.
>
>        Thomas
>
>

Ben Abbott | 1 Nov 13:13 2008
Picon

Re: make check failure from current sources


On Oct 31, 2008, at 7:12 AM, Jaroslav Hajek wrote:

> On Fri, Oct 31, 2008 at 11:30 AM, Jaroslav Hajek <highegg <at> gmail.com>  
> wrote:
>> On Fri, Oct 31, 2008 at 11:28 AM, Ben Abbott <bpabbott <at> mac.com>  
>> wrote:
>>>
>>> On Oct 31, 2008, at 6:16 AM, Jaroslav Hajek wrote:
>>>
>>>> On Fri, Oct 31, 2008 at 11:02 AM, Ben Abbott <bpabbott <at> mac.com>  
>>>> wrote:
>>>>>
>>>>> On Oct 30, 2008, at 7:28 PM, Ben Abbott wrote:
>>>>>
>>>>>> I pulled this evening, my tip is
>>>>>>
>>>>>>> changeset:   8295:16819ca24fa5
>>>>>>> tag:         tip
>>>>>>> user:        John W. Eaton <jwe <at> octave.org>
>>>>>>> date:        Thu Oct 30 18:03:37 2008 -0400
>>>>>>> summary:     fix typo in docs
>>>>>>
>>>>>> During my building went fine, but "make check" ...
>>>>>>
>>>>>> [snip]
>>>>>>
>>>>>> scripts/general/dblquad.m ..............................error:  
>>>>>> `pso'
>>>>>> undefined near line 248 column 23
(Continue reading)

John Swensen | 1 Nov 14:18 2008
Picon
Picon

Re: Text properties and FTGL


On Oct 31, 2008, at 10:21 PM, Bill Denney wrote:

> John Swensen wrote:
>> Thanks for pointing these out.  I don't know what they are not doing
>> in mathTeX that I must be doing in my system calls, but mathTeX is
>> significantly faster.  Since it is GPL and Octave is GPL I will
>> probably actually compile this into my Octave tests and render
>> straight to the openGL texture, rather than have it render to a file
>> and then read it back in.  I think a time of ~0.1 seconds per LaTeX
>> string and appropriate caching of the results is acceptable.
>
> Just a thought, but could you render each result on a different page  
> in
> the LaTeX output and make it just ~0.1 sec total instead?
>
> Have a good day,
>
> Bill

I just tested that and you are exactly right.  Until I had more than  
100 equations (each on a different page), the time did not go over  
~0.15 seconds.  Even at 400 equations it was only 0.3 seconds.  I also  
found out that with the poppler library I can do all the cropping and  
such, so there is no need to call the pdfcrop script at all.  This  
will probably work after all.

As a side note, I did look at the mimeTeX program that was mentioned  
in this thread.  It is not a full TeX/LaTex interpreter, but has  
almost all basic symbols and constructs.  It essentially generates  
(Continue reading)

Michael Goffioul | 1 Nov 15:26 2008
Picon

Re: Text properties and FTGL

On Sat, Nov 1, 2008 at 1:18 PM, John Swensen <jpswensen <at> comcast.net> wrote:
> I now have an OpenGL question about textures.  Poppler converts the PDF into
> a buffer of the form numpixels * (RGBA), where the PDF has been scaled and
> the DPI chosen before this conversion to pixels takes place, so things are
> anti-aliased and everything is beautiful.  My problem is that it renders a
> white background and that keeps showing up when I render the texture to
> opengl with glBegin(GL_QUADS);...glEnd();.  With other programs I have used
> before, I should either be able to (1) just set the color I want to be the
> alpha color or (2) go through and set the value in the alpha channel for
> each of the pixels where I want it to be transparent to 1 (or 255).  I don't
> know how to do (1) with OpenGL and when I try to do (2) nothing happens.

Did you enable alpha blending in the OpenGL context?

When you create you texture for the text, do you resize it to 2^n x 2^m
or do you use rectangular texture?

Note: starting from next week, I should be able to help again on the
graphics side.

Michael.

Thomas Weber | 1 Nov 20:15 2008
Picon

Re: No bool matrices for imagesc in tip?

Am Samstag, den 01.11.2008, 10:14 +0000 schrieb Michael Goffioul:
> My question was badly expressed. It should have been: does
> Matlab accepts that you "set(img, 'cdata', m)", where img is
> an image handle and m is a bool matrix?

>> m = ones(10,10)>0;
>> img = figure()
>> set(img, 'cdata', m)
??? There is no 'cdata' property in the 'figure' class.

Doesn't seem so, but the version of Matlab here is not the latest.

	Thomas

Michael Goffioul | 1 Nov 22:51 2008
Picon

Re: No bool matrices for imagesc in tip?

On Sat, Nov 1, 2008 at 7:15 PM, Thomas Weber
<thomas.weber.mail <at> gmail.com> wrote:
> Am Samstag, den 01.11.2008, 10:14 +0000 schrieb Michael Goffioul:
>> My question was badly expressed. It should have been: does
>> Matlab accepts that you "set(img, 'cdata', m)", where img is
>> an image handle and m is a bool matrix?
>
>>> m = ones(10,10)>0;
>>> img = figure()
>>> set(img, 'cdata', m)
> ??? There is no 'cdata' property in the 'figure' class.

Indeed. As I mentioned, img should be an image handle, not
a figure handle.

Michael.

Søren Hauberg | 1 Nov 22:59 2008

Re: No bool matrices for imagesc in tip?

lør, 01 11 2008 kl. 21:51 +0000, skrev Michael Goffioul:
> On Sat, Nov 1, 2008 at 7:15 PM, Thomas Weber
> <thomas.weber.mail <at> gmail.com> wrote:
> > Am Samstag, den 01.11.2008, 10:14 +0000 schrieb Michael Goffioul:
> >> My question was badly expressed. It should have been: does
> >> Matlab accepts that you "set(img, 'cdata', m)", where img is
> >> an image handle and m is a bool matrix?
> >
> >>> m = ones(10,10)>0;
> >>> img = figure()
> >>> set(img, 'cdata', m)
> > ??? There is no 'cdata' property in the 'figure' class.
> 
> Indeed. As I mentioned, img should be an image handle, not
> a figure handle.

The following code

  f = imshow (rand (50));
  m = ones(50)>0;   
  set(f, 'cdata', m) 

works just fine, and the resulting figure is a white image. Also,

  get (f)

prints

        AlphaData = [1]
        AlphaDataMapping = none
(Continue reading)


Gmane